Python on Rails: The bazzar

Everybody know Ruby on Rails right now. There is a lot of post all over the web, showing us the new latest new web programming style. This is a little funny because in a past life (4 years ago), I worked on something quite similar for Zope, name ZModeling. And I guess a lot of people has done the same, by generating the html from a data model (It tooks me about 1hours to do that for my latest website). That’s it and this is the latest hype stuff. IT loves hype !

Anyway, as this become usual, (grrr) there is a bunch of projects that try to clone the rails features. The well know python proverb can be used:
Divide to loose

Here ‘s a little list:


Django is the total new one, it’s written from scratch, and doesn’t re-use anything.

  • it use mod_python for apache integration (no SCGI for lighttpd ??)
  • custom ORM
  • custom template engine (why not another one !!)

This one has a lot of good comments, and a lot of people see in this stuff a Zope killer app.. or something like that but ..


Subway was born just after Ruby on rails, and is the direct competitor.

  • CherryPy: stable, simple and robust HTTP framework
  • SQLObject: the world famous ORM for Py
  • Cheetah: a plain old fashion template engine.

This is nothing more a app skelton generator, with a little wraps around the whole stuffs, nothing magic, but simple .. perhaps too simple ?


TurboGears is a the latest one I think

  • CherryPy
  • SQLObject ORM
  • Kid template: a simple ZPT like
  • A powerfull Ajax toolkit.

The API is a bit Frankhein right now I think (I don’t like the raise CherryPy in the middle), and the templating is not powefull enought. But it’s really interesting (meanly the Ajax API).


Paste is something a bit different of rails, It has a more large framework

  • WSGI
  • SQLObject ORM
  • ZPT: The powerfull Zope Page Templates

So now, which is the best ?

Perhaps none right now:

  • Django use (for me) too much indoor product, I think there is a lot goods frameworks for python right now, and re-writting a ORM expose the project to a some strange bugs, or missing features, or wrong design (the meta api is freak) . same for template engine.
  • Subway and TurboGears are really quite the same product, and they are lacking of some features like the admin page for objects. I prefer TurboGears meanly for the Ajax toolkit.
  • Paste, is as usual a very well written stuff from Ian. The API is clear, and tools are well known. But I think the framework take too much place. I mean force you too use it’s configuration stuff, and other WSGI server.

So perhaps, you can pick just one of this, as they’re all looking close:

  • If you want to discover something really different: Django
  • If you want something closer to rails: TurboGears
  • If you like the servlet and threads choose: Paste ..

But take care that the framework you choose feet with:

  • your way of web programming (servlet vs controller + template)
  • the project load (I mean mod_python is awfull to debug but provide some very good performance)

Anyways, the choice is really hard because it’s time to choose right now, and I believe that some frameworks will die sooner than others.. Django seems to be the next big python project, but some people share my opinion about :” I don’t want to learn another ORM !”

But, beside there is a lot of frameworks, they ‘re loosing the main goal: Using a good framework is a good stuff. But using good products is better. They all miss the component model. HTTP + ORM + Template engine = Web Framework, but for a application framework you need a little more. Some stuffs have been done on Webware, and Quixote about this, but it looks like people designing framework never look at the past, and keep on going building the same stuff over and over.

What we need now, is a application framework. Something we can use to build website not webapp. Clients are now asking for : “I need something to post articles + a forum + a wiki + ..” That’s too much for a quick answer like: “Ok I gonna use this web frameworks”. On the PHP scene right now, you have some great products that tend to share some component, like user rights, templating .. and this is really a bad news for Python users, because the only stuff we have to fight against this is Zope. And it’s getting even worst since right now, most products need Plone and all the bloat it’s about.

Related Posts

20 thoughts on “Python on Rails: The bazzar

  1. Have you looked closely at Django? It has a concept of apps, that reside within a project and are portable over to other projects. This would allow you to for example use a wiki app in many different projects (just change the templates as necessary).

  2. BTW, Django recently changed it’s module api to something quite similar to SQLObject.  Also, while SCGI is not yet supported, you can put it behind lighttpd with FastCGI.  (I am doing that currently.)

    For me, the main thing django has going for it is the free admin interface.  (Although, the URL mapping is pretty cool too.)


  3. What about Zope 3? It’s more than ready for production, there are some nice finished applications written with it, and my company did quite a substantial application from scratch in about three weeks. Zope 3 is like all of the good aspects of the CMF / Plone, but without the bloat or need to be content specific. It can be made even lighter. But with, you do get a fairly complete framework, and a more flexible base to work from to build more specific frameworks with.

    Components are more pluggable and replaceable than in Zope 2, and it’s easier to write reusable utilities and libraries and components than before. The Schoolbell calendaring application (a complete Zope 3 app) has a Relationship package that can be used to specify complex inter-object relationships. A very handy package on its own. The Zope 3 Base Project has a few interesting projects, including a SQLObject support lib for using SQLObject based objects in Zope 3, and there’s Hurry which provides some components writing easier catalog queries, doing simple workflow, and providing a file upload schema item and widget. On the high end of content management tool development, there’s the Z3ECM project at

    Note that the name for the Zope 3 project, as it was incepted in the Zope development subsite, was ‘Component Architecture’

  4. I’m not sure to understand the all point of this article to be honest. Django has started quite a long time ago, even before some poeple in the Python community starts only talking about Rails. Evene though Django hit the public road last july it has been built before then.

    Anyway, so what all those frameworks offer the same as Rails. There are not 1000 different ways of building Web framework, are they?

    So what is the point of your article really?

    """What we need now, is a application framework. Something we can use to build website not webapp."""

    Uh?! I don’t understand that either. Would you mind explaining it?

    • Sylvain
  5. Just to clarify,

    Subway integrates FormEncode too, has autocompilation of Cheetah templates, partial templates and simple authorization/authentication facilities. We are also integrating Django-like filters with Cheetah. Subway aims to reduce boilerplate code as a mimimun — and i think it’s pretty good at that (compared to the rivals). Version 0.2 is finally coming into shape and will feature a stable API.
    You can spot an example using MochiKit in the Subway SVN repos. Personally I have very high hopes for the MochiKit future.

    We are also seeking developers to join the project, please join us instead to start your own. :)

    – deelan.

  6. Oh god, so much answer.

    • Manuzhai, you mean you can reuse your own code that’s it. But does Django support project sharing ? I mean does it have a standard way to look at usership, or access role, and so many other aspect of a website. Perhaps, I loose something but I don’t find this kind of stuff in the doc.
    • Matthew, Phil, ok Django has a SCGI support that’s a good news, but only a part of the problem.
    • Jeff, I work in a Zope company for a while, and (beside I forgot a big part) I know quite well Zope. For me Zope 3 has nothing to deal with Rails, but it provide some good Component Arch. Most products I tested for Zope 3 are buggy and Zope 3 isn’t stable enought to use it in company products. Not talking about the docs ..
    • Sylvain, this is the main argument for Django: We wrote this for a long time now. Ok and ?
    • Deelan, please take a chat with TurboGears. I really think you should merge this too projects. The only difference is the templating engine, and yes filter in cheetah will rock!
  7. Well that’s my question too. I don’t see the point of your article at all. I’m sorry but I just don’t get your point :/

  8. If i can add a bit to the discussion, Django follows the loose-coupling principle, that means it has to have a minimum set of external dependencies, so as to ease the installation by the lambda developer.

    Though, now that Eggs are all around, i guess this is a bit less important, but heh, Django was designed long time before Eggs

    (Maintenant on sait qui de l’oeuf ou de la poule etait le premier :)) )

  9. On the subject of deploying applications, precisely why I developed WebStack (and presumably why the WSGI people did their thing) was to avoid the “it only runs on mod_python/Zope/FOTW”. But it’s been glaringly obvious to me for a long time that even framework authors want to start from nothing and provide some end-to-end solution, even if that means coming up very short at one end.

  10. Paste isn’t really intended to be anything like the other frameworks — it’s not a framework of its own. To take Kevin’s term from TurboGears, Paste is a toolkit for building megaframeworks.

    The other thing I’m working on is making deployment of small applications into larger sites easier. That’s what we do a lot of at work, so it’s an important goal for us. Right now I got it down to a couple commands — when you want to release you do python tag --version=0.3.1, then check out the new tag and do python iscape_deploy to package and upload it (should combine those somehow). Finally on the server I run paster deploy site_name AppName url=/appname which downloads, installs, configures (skeleton) and attaches the application to the given URL. Since I’ve been doing it for work not all of it is open source (yet — it’s just a matter of separating our internal processes from more general stuff), and the priorities have been getting-stuff-done (not so much documentation), but I think it’s looking pretty good and offers unique features. And none of it is connected to WebKit at all, so it’s something other frameworks could take advantage of if they chose (though it is connected to making distutil-packaged WSGI applications).

    Besides the templating issue, and some configuration issues, the best way to achieve website-as-components (IMHO) is through easy-to-deploy applications like this. I don’t care if something is in WebKit, Subway, or even Zope 3, if I can pop them all into place the same way.

  11. Ian, I ever read your comment about WSGI to act as glue for website. This can be usefull clearly.But once again, I really thing we need a "megaframework" as you said but some components to put in. That’s my point of vue. And I don’t think the user should build it’s own mega-stuff.

    I really think that having a bunch of different technologies in a single
    website is not a great stuff, because this will be Frank-N-Stein style, beside we already have this kind of websites in the PHP community, I really thing this won’t be a good step for us.

    Bye, Bye.

    Somebody has a doc about ACL in Django ???

  12. I wrote a test website for each, except Paste, mainly because it distrub my main :) . So yes, I "even try any of those frameworks" ..

  13. I Hi there! I?m in search for credit cards with airline miles. There are several offers at three websites. But I chose one site about credit. Is a reliable, please, tell me? Go to

    fixing credit problems

  14. Hello! I believe credit cards are used almost by everyone. But unfortunately, credit cards with 0% balance transfer, rewards, lowest interest rates are mainly for those with strong credit. If your credit is not good, you can apply for bad credit cards online to build good one at

    discovery balance transfer

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>