peterbe / django-mongokit

Bridging Django to MongoDB with the MongoKit ODM (Object Document Mapper)
Other
122 stars 20 forks source link

Replace django.utils.simplejson with json #23

Closed shenqihui closed 9 years ago

shenqihui commented 9 years ago

In Python 2.5, json module was build-in.

And simplejson in django.utils was removed in Django 1.5.

So if we use django 1.5+ ,it will case import error.

So I try to change it into import json.

Look: http://stackoverflow.com/questions/28048943/cannot-import-name-simplejson-after-installing-simplejson

Thanks

shenqihui commented 9 years ago

local test ok.

peterbe commented 9 years ago

How about, instead replace ALL occurances of simplejson and replace them with json and at the top of the file just do import json instead.

shenqihui commented 9 years ago

@peterbe
Hey, I replace all simplejson into json.