4

(Please note that this question and some of the answers are old)


I want to use an existing python framework to develop an application on google appengine.

It should be quick and easy to start and support test driven development practices in an easy way.

Can you recommend a stack? What about django?


Additional Information:

There are several django ports, but the stackoverflow questions are already old. There were several django/appengine solutions, I do not know which one is currently leading. (This is now outdated, see accepted answer and also the other answers).

But also other frameworks are interesting, not only django.

What also sounds good but is not a condition is the possibility to run the app on the framework and the appengine and maybe later run it on a self hosted (noSql-) version of this framework (which maybe could be django, or maybe somehting else).

mit
  • 11,083
  • 11
  • 50
  • 74
  • there is no framework that can't be test driven. Also, most frameworks are more "up to date" than appengine (python2.5 at the moment though 2.7 is supposedly coming soon). No one can predict the future but using the appengine api's and webapp would be a safe bet since there's some level of commitment from google to keep it around for a while. everything else is just people throwing out there favorite framework and insisting you use it. I use pyramid and it suits the project just fine. – Tom Willis Oct 01 '11 at 19:09

7 Answers7

3

UPDATE: This answer is now out of date.

For me the choice is djangoappengine.

It's a fork of the django project made specifically for no-sql databases like Google App Engine and MongoDB. The main benefit of it is that you get to piggy-back on all the cool stuff coming out of the django project, while also running on GAE's scalable architecture. Another benefit is that with djangoappengine, you can more easily move off of App Engine than if you used their API directly (although that is probably easier said than done).

There were rumors that Django would merge the changes into the mainline Django project, but it has not happened yet (as of May 2014).

Some relevant links:

speedplane
  • 15,673
  • 16
  • 86
  • 138
2

I personally have enjoyed using Flask on App Engine using this template: https://github.com/kamalgill/flask-appengine-template

The code is organized pretty well in this template and it includes many of the nice development features like profiling and app stats.

Robert Do
  • 188
  • 2
  • 10
2

If you want to build large scale application and need a more flexible framework, then you can take a look at

Pyramid Python Framework

Previously it was called Pylons. There are lot of good companies using this framework.

You can find instructions for the process of deploying it to appengine on their website: http://docs.pylonsproject.org/projects/pyramid_cookbook/en/latest/deployment/gae_buildout.html The process uses buildout and also includes a local testing environment.

mit
  • 11,083
  • 11
  • 50
  • 74
Fizer Khan
  • 88,237
  • 28
  • 143
  • 153
  • I know pylons and I left it, I prefer a more explicit style – mit Feb 08 '14 at 12:06
  • Btw does it run on appengien? This is part of the question – mit Feb 08 '14 at 12:07
  • yes, it runs on google app engine. http://docs.pylonsproject.org/projects/pyramid_cookbook/en/latest/deployment/gae_buildout.html – Fizer Khan Feb 09 '14 at 12:43
  • that's amazing. I added the link to your answer :) – mit Feb 09 '14 at 19:01
  • disclosure: I am the author of pyramid_appengine it is based on a fairly sophisticated project(pyramid backend/emberjs front end) at a company I used to work at. After attempting django on appengine, I feel pyramid was the right choice because it doesn't try to abstract away the app engine api's and thus it's api's can integrate with appengine fairly easily and it made entity level permissions a breeze. But not every app needs that. – Tom Willis Feb 11 '14 at 02:23
2

I'm very happy with this boilerplate:

https://github.com/coto/gae-boilerplate

Take a look at its functions and features, it's very complete!

HarlockBcn
  • 51
  • 1
  • 3
2

(Note that this answer is old and no longer valid.)


After reading Tom Willis' comment on the question and also this SO question's accepted answer I noticed that webapp/webapp2 looks promising.

  • There's some level of commitment from google
  • It is not necessary to create and maintain own versions for existing SDK handlers
  • There are libraries that were created with App Engine in mind which are based on webapp and would need a port or adapter to work with other frameworks
  • It can be used outside appengine
  • Unit testing is easy to setup and documented here
Community
  • 1
  • 1
mit
  • 11,083
  • 11
  • 50
  • 74
1

I am enjoying

http://ferris-framework.appspot.com/

which was written specifically for GAE. I love Django in general, but not for gae, I felt using django-nonrel still requires too many caveats that it is not worth it.

Dave Parizek
  • 61
  • 1
  • 5
1

I wrote GAEStarterKit, which aims to get you up to speed as quickly as possible. It's in a similar vain to projects like GAE-Boilerplate or gae-init, but a few key differences:

  • First and most obvious, I used UIKit over HTML5 Boilerplate. Boilerplate is a great choice, and obviously is popularity comes with perks, but for the purposes of getting started quickly, I find uikit a bit more "complete."
  • I put a lot of work into making sure the user login/registration system is as well-thought-out as possible. Users can have multiple email addresses, multiple authentication methods, and be associated with multiple tenants, if applicable. The social login side for non-Google users is done via Authomatic, which is a great project and very well-supported.
  • Although it's a little rough around the edges, I did something pretty similar to Django's GenericViews, but in Flask and with GAE Models. I used WTForms integration for that, so it all works pretty well out of the box. It's certainly not perfect, but it's pretty good.
  • I really took seriously the idea of not repeating myself. For example in gae-init, you'll find a lot of CRUD code. For the admin side, you can add a model to your admin GUI in GAEStarterKit with one import, and one function all.

Might be worth considering.

Lipis
  • 21,388
  • 20
  • 94
  • 121
Ken Kinder
  • 12,654
  • 6
  • 50
  • 70