阅读背景:

Python,迭代地将json / dictionary对象写入文件(一次一个)

来源:互联网 

I have a large for loop in which I create json objects and I would like to be able to stream write the object in each iteration to a file. I would like to be able to use the file later in a similar fashion later (read objects one at a time). My json objects contain newlines and I can't just dump each object as a line in a file. How can I achieve this? in which I create json




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: