forked from orbit-oss/flask
added workaround for json on Google AppEngine
Google AppEngine unfortunately does not offer json/simplejson where we would expect it to be, but since they do offer django and django comes with simplejson as a frozen dependency, we can import it from there. prior art: http://github.com/facebook/python-sdk/blob/master/src/facebook.py#L50
This commit is contained in:
parent
f1a6fbe250
commit
0198313a22
1 changed files with 6 additions and 1 deletions
|
|
@ -26,7 +26,12 @@ except ImportError:
|
|||
try:
|
||||
import json
|
||||
except ImportError:
|
||||
json_available = False
|
||||
try:
|
||||
# Google Appengine offers simplejson via django
|
||||
from django.utils import simplejson as json
|
||||
except ImportError:
|
||||
json_available = False
|
||||
|
||||
|
||||
from werkzeug import Headers, wrap_file, is_resource_modified, cached_property
|
||||
from werkzeug.exceptions import NotFound
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue