bson-fix
This commit is contained in:
parent
743ab1e18f
commit
3eba61b36f
|
@ -15,13 +15,13 @@ def json_tables():
|
|||
"email_subscriptions": [],
|
||||
"users": [],
|
||||
"comments": [],
|
||||
"remarks": []
|
||||
}
|
||||
for table in data.keys():
|
||||
print('[migration] bson2json for ' + table)
|
||||
gc.collect()
|
||||
lc = []
|
||||
with open("dump/discours/" + table + ".bson", "rb") as f:
|
||||
bs = f.read()
|
||||
f.close()
|
||||
bs = open("dump/discours/" + table + ".bson", "rb").read()
|
||||
base = 0
|
||||
while base < len(bs):
|
||||
base, d = bson.decode_document(bs, base)
|
||||
|
|
Loading…
Reference in New Issue
Block a user