Object of type ‘ObjectId‘ is not JSON serializable

Object of type ‘ObjectId‘ is not JSON serializable

解决办法

from bson import json_util
 
json_util.dumps(data)

posted @ 2022-05-24 19:22  莫贞俊晗  阅读(86)  评论(0编辑  收藏  举报