-
Notifications
You must be signed in to change notification settings - Fork 37
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
可否提供 load 方法,用于载入 dump 方法导出的数据,以便于用户缓存数据 #492
Comments
leancloud 对象的实现无法 pickle,忧桑... class Object:
def dump_picklable(self):
return {"class": self._class_name, "dump": self.dump()}
@classmethod
def load_picklable(cls, data):
return cls.extend(data["class"]).load(data["dump"]) |
2.2.0 以前的 _merge_metadata 是坏掉的,上面那段代码仅能用于 2.2.0 以后 |
建议升级到最新版,2.2.0 和最新版之间基本没有破坏兼容性的改动。如果实在要用旧版的话,可以 fork 一份然后 cherry-pick 下 |
dump 中没有保存下来被 include 的 Pointer 字段的数据,可能需要单独实现一个 dump; |
对,Pointer 不会展开 #399 |
无法直接通过
__init__
方法还原一个 dump 出来的数据,所以自己做了一个:The text was updated successfully, but these errors were encountered: