11๐
app-engine-patch currently has the most of django functional, including sessions, contrib.auth, sites, and some other standard django apps. However, its main drawback (my opinion) is that it uses a zip file of a modified version of django to achieve this functionality and the current maintainers donโt seem to have kept pace with current django releases. Currently it seems to be the consensus of the past and present maintainers that this approach is too cumbersome to maintain and therefore no one is currently maintaining it.
google-app-engine-django, uses a monkey patch approach of the latest django version included in the production GAE runtime, so as long as google continues to track django releases youโll be kept up to date regarding django. However, it currently has not fully ported contrib.auth, so you can only authenticate with google accounts โ which can be a big drawback depending on whether you want contrib.auth User models to work as you know them on sql backends. There is also no django admin support in the helper as there is in app-engine-patch. A fork of django-app-engine-django exists which adds in some of the contrib apps, such as flatpages, sites, and sitemaps. Also note, it only works on django versions up to 1.1, until issue #3230 Django 1.2 is added to use_library, unless you upload django as a zip file.
On the horizon, the original developer of app-engine-patch has been working on the django-nonrel branch, but this may be pretty far away from being included in a django release. This django developers thread has a lot of information about these efforts.
Separately, there is a google summer of code project working on integrating some aspects of nonrel dbโs.
3๐
app-engine-patch gets most of those things working inside AppEngine โ so you can (mostly) use straight Modelforms, use the Django users and admin, etc.
Iโve only used it for fairly simple projects (being quite new to django), but they claim that most Django apps will work with (at most) minor modifications on appengine. For instance, app-engine-patch uses the AppEngine Model classes rather than the Django classes; and there are some of the basic views that are too inefficient to run on Appengine.
added: google-app-engine-django is similar; but provides a BaseModel that appears identical to Djangoโs BaseModel. My understand is that google-app-engine-django was released by Google, then forked to create app-engine-patch. The maintainers of app-engine-patch seem to have some different goals from the creators of google-app-engine-django, so you may find that one of the two suits your needs better than the other.
Google have provided some articles on running Django apps on appengine; the most recent is actually a guest post from the authors of app-engine-patch.
- [Django]-Django DeleteView without confirmation template
- [Django]-How do I deal with this race condition in django?
- [Django]-Cannot import name _uuid_generate_random in heroku django
1๐
Iโve had the best success by simply picking and choosing the Django features that I need and patching them into webapp myself. In my latest project I actually just cut out the webapp stuff entirely. I still import and call several webapp utility functions, but it is mostly a hand rolled application built from the good parts of GAE and Django.
- [Django]-Django date query from newest to oldest
- [Django]-Sharing django sessions on specific subdomains
- [Django]-Execute code when Django starts ONCE only?
1๐
You might be interested to check out web2py, another Python framework that supposedly has less friction between GAE and a โnormalโ web server.
- [Django]-Why does DEBUG=False setting make my django Static Files Access fail?
- [Django]-Django REST Framework viewset per-action permissions
- [Django]-Django self-referential foreign key
1๐
It is now quite easy to use full Django on GAE:
https://developers.google.com/appengine/articles/django-nonrel#ps
- [Django]-Overriding initial value in ModelForm
- [Django]-Django: Can I create a QueryDict from a dictionary?
- [Django]-PyCharm can't find the right paths if I open a directory that is not the Django root
0๐
The Django version provided with App Engine has been updated to 1.2.5 with the latest SDK release (1.4.2, changelog). This version is available through the use_library()
declaration, so you no longer need to mess around with monkey patching to the same extent.
- [Django]-Django.db.utils.ProgrammingError: relation "bot_trade" does not exist
- [Django]-Django : Is it impossible to static tag into block tag?
- [Django]-What's the proper way to test token-based auth using APIRequestFactory?
0๐
The GoogleAppEngine (GAE) Python 2.7 runtime provides several third-party libraries that your application can use, in addition to the Python standard library, GAE tools, and GAE Python runtime environment. One of them is Django. The below is copied from the GAE docs page on third-party libraries:
To use Django in Python 2.7, specify the WSGI application and Django library in app.yaml:
...
handlers:
- url: /.*
script: main.app # a WSGI application in the main module's global scope
libraries:
- name: django
version: "1.2"
- [Django]-Django Templating: how to access properties of the first item in a list
- [Django]-Django DoesNotExist
- [Django]-How Can I Disable Authentication in Django REST Framework