Tuesday, 14 June 2011

My Top Ten Python Web Frameworks

An updated version of this article can be found here.

I have recently revisited all of the Python Web Frameworks that I know of and re-evaluated them for use in a new project.

I did this first two or three years years ago and so I imagine I will be biased by the decisions that I made then, so I think it's only fair to say that I started using Django because of it's fantastic documentation and I suppose the helper scripts which help the beginner along. However, all that Convention over configuration stuff can be too much for me sometimes.

I then moved onto Tipfy because it slotted in so easily to Google App Engine which I was using a lot at the time  and the Django framework itself was starting to be more of a hindrance than a help.

One day however I stumbled upon Bottle which was a revelation. Being a micro framework it's explicit. That is if you want to use something, you make up your mind to do so; it's not some cleverness built into the framework over which you have no obvious control. If you want to know how it works, then read the code!

Finally I came to Flask, another micro framework, because I like the way it is based on Werkzeug and other well trusted libraries which gives me a some peace of mind that it is supportable, and secondly because it is also explicit like Bottle.

All that being said, here's my top ten:

  1. Flask - small, fast, easy to learn and built on reassuringly supported libraries.
  2. Bottle - small, fast and a great tool for learning.
  3. Tipfy - built for GAE, easy to pick up and well supported.
  4. Django - contains most of what you will ever need to build a website, well documented, but starting to bulge at the wasteline.
  5. Pyramid - the successor to Pylons, this one has great docs and great ideas. It is a framework, but you can unpick the bits you don't like.
  6. CubicWeb - like Django, Convention over configuration, but nice in some ways. 
  7. GAE framework - Simple, built for GAE, and well documented.
  8. Web2py - I hate it, but love it. All that framework kinda helps, kinda hinders. Give it a little time and you can definitely pull a website together, it depends on your personality whether or not you go mad first though.
  9. Nagare - I admit I haven't built a full system with this one, but I have a feeling I will be soon. I'd rather it was a wee bit more mature though, but the libraries/concepts it's built on is all good stuff.
  10. Weblayer - Another micro framework. Some good ideas here, but could do with a little love, If you are a developer looking for a worthwhile project, you should consider lending a hand.

[Please note I am currently updating this article here]


For more information, please read:

5 comments:

  1. Any particular reason for excluding CherryPy?

    - Bob

    ReplyDelete
  2. zx12bob - No, no reason at all. Feel free to put down a few lines singing it's praises if you are a particular fan of CherryPy.

    Col

    ReplyDelete
  3. Not exactly a web framework but on the rise: http://getcolony.com/

    ReplyDelete
  4. Markus; as interesting as it looks, it looks closed source. Am I right?

    ReplyDelete
  5. @Terse Col: colony core is GPL'ed http://getcolony.com/docs/colony/documentation_licenses.html . But you can provide plugins at any license

    ReplyDelete