Ruby on Rails
Ta-da List


March 29, 12:51

Why Web Programming Matters Most

Ian Bicking has issued a call to arms for the Python community under the banner of Why Web Programming Matters Most. In the piece, he expresses his frustration with web programming not being more in the center for Python and longs for the growth curve of PHP.

A fellow Python programmer, Jonathan LaCour, responded with his opinion that Rails should be the model for how to turn Python into a relevant force in web programming and prevent that "...Rails will be the dominate open source, dynamic web framework for the next few years at least":

I don't even like Ruby very much, but Rails is obviously the best web framework out there because of the tightly integrated simplicity of it! Rails is the Apple of web frameworks — one tightly controlled stack. Sure, you may lose some flexibility, but you gain beauty, simplicity, and ease of use! I really really wanted to pick Python, but I just couldn't do it. There are too many frameworks, none of which are as good as Rails.

Jonathan further argues the damage of excessive choice and the prevalence of Not Invented Here syndrome in the Python web world. As a tangent to this discussion, I highly recommend listening to Barry Schwartz's excellent talk on The Paradox of Choice: Why More Is Less from Pop!Tech 2004.

In short, indistinguishable choices (or just too many) leads to lower satisfaction with the eventual pick and increases the chances that no pick will be made at all. The latter seeming to be exactly what Jonathan describes by being overwhelmed with choice of Python web frameworks and then picking an entirely different language altogether.

Unfortunately, it seems that there is little faith in resolving the situation of choice overload. Glyph Lefkowitz describes it as:

I can understand being frustrated with the proliferation of web frameworks, but let's face it: there is no way you are going to be able to convince anyone to give up on their pet framework to work on someone else's.

I see a lot of people in the Python web community complaining about proliferation of frameworks. I don't see anyone at all standing up and saying "My web framework X is unnecessary, I will abandon it and spend my web-framework development time working on web framework Y instead."

So there's a a somewhat shared understanding of what the problem is (too many, too similar frameworks of varying quality), a somewhat shared sense of a possible solution (combine efforts to get fewer, but stronger choices), but no will for the sacrifice or cooperation needed to make it happen.

Jonathan compares this situation of unsatisfactory choice with what we're doing in Ruby:

In the Ruby world, if you are developing a web application, there is no choice: there is Rails. And thats okay, since its so damn well done. In the Python world, if a web framework doesn't do something that you want, you just create your own framework... why not fix the original one? The whole situation is embarrassing.

Of course this is an oversimplification. There are quite a few other Ruby solutions for how to deal with the web problem. And new ones still appear, like the recent introduction of Wee (a Seaside-inspired framework in Ruby).

That being said, I strongly believe that there's a big benefit in having a dominant framework draw a strong profile for a small language. The amount of positive attention Rails has been able to shine on Ruby for a long time has made me particularly proud. Languages need blockbuster hits like that to establish their authority in the public perception for a given domain.

I'll continue to do my earnest in order for Rails to stay deserving of this honorable role for Ruby. The growing community around Rails is intent on doing the same. We're just pushing ~30,000 downloads now (through gems, across all versions) and are aiming to get that into the hundreds by year end.

I wish the Pythonists all the luck in finding their own formula for raising the attention of Python as a web language. Just as I welcome Pythonists that would like to give Rails a try while waiting for the former to happen.

Challenge by Glenn on March 29, 13:29

What's funny is there already is an "Apple web stack," WebObjects. Too bad only a handful of people know about and use it. If you like Cocoa, WebObjects has the same NeXT heritage and thoughtfulness of design.

David, when you're not busy ;-), you might look at the DirectTo* frameworks in WebObjects. WO developers claim huge productivity gains with it, and there's supposed to be nothing else like it available. Myself, I don't understand it's usefulness, but that's probably because it's a different paradigm of development that I've yet to wrap my head around. You can download a fully-functional demo from Apple Developer Connection.

Challenge by Lorenzo on March 29, 15:02

Well I bet all this big issue about having too many choice when you have to choose a web-development framework comes down to: "we need some more time for the natural selection to happen". That said I like the CherryPy ( approach (that keeps it simple). The only thing I'm really missing is some form handling/validation class done right. For which I'd rather watch at the Cerise ( approach than the RoR one.

That said I perfectly see the point of people embracing Ruby just because of Rails for the productivity gains... I might eventually turn rubyst for the same reason someday.

Challenge by James Britt on March 29, 16:22

More choice is good. In addition to Wee, Og/Nitro[] is well worth a look. These tools offer valuable alternatives for Web development.

Yes, the Rails hype has drawn a great deal of attention to Ruby, but not all of the chatter is good. Some seem to make the equation that Ruby == Rails; this is unfortuntate. Ideally, Rails might draw newcomers into Ruby, and from there they could move on and explore other options.

Challenge by Hendrik on March 29, 17:06

I used to be part of the CherryPy team and co-developed CherryPy2. I eventually left to write my own framework (yes, I'm lame) called Zylla, which I believed was superior to CherryPy2 (yes, I'm nasty). See

Once I "got" Rails, I quickly abandoned Zylla. There. Rails completely evaporated my interest in using Python for web applications. Damn you! Damn you all! But it's just so GOOD! SUBMIT!! SUBMIT!!!!!

Challenge by anders on March 29, 17:06

well, i think Glyph is at least partially wrong. i've basically abandoned work on my cgi_app ( framework to help out on Subway (, which seems to be gaining the most momentum now (though it helps that cgi_app had a small enough scope that it can basically be considered finished). i doubt he'll abandon Webware, but Ian Bicking has also been active on the Subway mailing list.

i'm also not entirely convinced that reducing the number of web frameworks in python will do that much to compete with Rails. i think Rails has been getting all the attention because, frankly, it's better than any of the existing python frameworks, at least for new users who just want to get something working quickly. the pieces were designed to fit together. the ability to basically have a full, barebones app up and running in 10 minutes is unmatched. well, you can do it in Plone, but only once you've scaled the steep learning curve.

Challenge by K on March 29, 17:10

I can't stand Python.
Thanks for wonderful framework, David.
Ruby is golden!!!

Challenge by Jonathan LaCour on March 29, 17:19

Wow, commenting can get you posted about pretty quickly if you speak loudly enough :)

I don't think that choice is _all_ bad, and yes I oversimplified a bit regarding Ruby web frameworks. But, my point still stands: having a clear choice greatly increases your chances of being chosen at all. This not only applies to web frameworks, it also applies to product marketing in general. Look at the success of the iPod and compare the simplicity of the product line to the offerings from Sony, iRiver, and the rest. Apple provides a single choice at each price point with a minimal set of great features. All the products are named simply, and are easy to understand. While the offerings from iRiver and Sony are all over the map! There is a lot to be said for consistency and simplicity.

I really love Python. I write Python code every day at work, and I have found nothing better for writing server-side applications. I consider Python and Ruby to be very similar and to have similar goals, so its great to see a dynamic language getting so much exposure due to Rails. I am hoping that Python finds its time in the spotlight too.

Ruby and Python are fighting many of the same battles (corporate acceptance, speed myths, static typing myths) against the same foes (Java, C#). So I hope Rails keeps on moving forward, as I believe that its bright future helps Python greatly in fighting its battles.

I also hope that the Python community will finally realize that sacrifices need to be made in order to make progress. One of the most important lessons that I have ever learned in software development is the willingness to throw away code in order to improve. If you cling to your legacy long enough, you might just find yourself drowning under the weight of your own bad decisions with no one left to blame but yourself.

Great work on Rails David -- keep preaching the good word for dynamic languages everywhere :)

Challenge by Jason on March 29, 19:02

How can you write ten paragraphs about how Python has no universal web framework and not even mention Zope? I haven't been embedded at all within the Python community, but to me this seems like one of its greatest acheivements.

Challenge by Watts on March 29, 21:43

I've been looking around for a web application framework to learn (mostly just for the fun of it -- I'm a long-time PHP progammer looking for something better), and I confess that I spent some time consciously looking for something _other_ than Rails, in part because the hype was putting me off. (As a Mac user, some of the hype over TextMate was tied up with Rails in my mind: I've tried TextMate, multiple times, including the most recent beta, and it drives me nuts -- but that's a different show.) I looked at Python, thought its syntax was a little easier than Ruby for me, and looked around for web frameworks.

I found dozens of them. And they're all, well, irritating. Other than Zope, Quixote is the only one that feels like it's really fully baked, and it's still relatively verbose. Subway is promising but quirky, and both it and its core piece, CherryPy, are woefully underdocumented. (If there's a way to run CherryPy _from_ Apache with something like FastCGI, rather than using mod_rewrite to just pass Apache requests off to the Python web server running on a different port, I couldn't figure it out, and frankly that's a deal-breaker for me.) Aquarium looked very interesting, but it's tiny and, again, underdocumented.

And Zope -- well, you're right, Jason, it _is_ a great achievement, but Zope is not an application framework, it is a web application server. It's kind of the Python equivalent of WebSphere. Installing and configuring Zope, then developing applications for it, is not a trivial undertaking. Using it for lightweight web applications is like using your business jet to go pick up a few groceries.

So, eventually, I ended up breaking down and coming back to seriously look at Rails. It pretty much does what it says it's going to do. I got it running under FastCGI with Apache without virtual hosts or any terrible effort, and this was at version 0.10; I gather Rails 0.11 makes this even simpler. I still find Ruby's syntax a little weirder than Python's, but Rails is really straightforward.

There's certainly nothing intrinsic about Python that makes it less useful than Ruby for web applications, and it looks like the _pieces_ of how to do it well are scattered all around the Python community. Subway's a good move in that direction, despite the obvious "we're trying to be like Rails, just in Python!" approach. But LaCour is quite right: there are too many "interesting" web frameworks with no momentum behind them in Python, and the lack of momentum means that if you want to adapt them, you're going to have to spend a lot of time doing infrastructure work that's largely done for you in Rails.

Challenge by Vincent Foley on March 29, 22:04

One thing that I think is very important and has helped Rails tremendously is the documentation. Some projects fail to constantly provide up to date and thorough documentation, and I think that they suffer from it. My favorite example is Seaside. Seaside is a wonderful way to program web application in one of the most wonderful languages I've ever used (Smalltalk). However, the documentation is very, very slim: there is no reference like, the code is almost without comments, so if you want to learn about it, you often need to dig in the classes yourself, search the mailing list for similar problems, etc.

When I started with Rails, there was no tutorial, so I had to watch the Rails video quite a lot of time, but there was the complete reference and I used it a lot. And with each release, all new features are documented.

It's easier to use something and recommend it if you can actually get started and easily get help, wouldn't you agree?

Challenge by phil on March 29, 22:55

When I hear that people are trying to recreate Rails in (Python|Perl|Java|C++|Cobol) I always wonder if it is possible to recreate the essence of Rails in those languages. The ease of defining domain specific langauges in Ruby (I haven't had a chance to use Rails yet, but that looks like the approach taken) had to be a big influence in the development of Rails. Lots of things that are quite easy to do in Ruby (like passing code blocks around or things that generally get filed under "metaprogramming") are probably not so easy to do even in a dynamic language like Python let alone in a static one like Java.

Challenge by Jonathan LaCour on March 29, 23:16

phil -- Rails really isn't doing anything spectacularly groundbreaking from a technical standpoint that Python cannot do. You might be able to argue code blocks, but there are ways to do things like that in Python (just not anonymously). Python has very powerful metaprogramming capabilities.

And Python doesn't need a Rails clone. Its needs something as _cohesive_ as Rails. Rails is good because its a full stack that takes advantage of Ruby's strong points. Python similarly needs a full stack that takes advantage of Python's strong points.

I think you are correct about the static languages though... not much chance of anyone being able to create a really simple and great Java web framework without embedding something like Jython :)

Challenge by on March 30, 2:05


Challenge by relative^ambition on March 30, 2:05


Challenge by antisense on March 30, 4:25

python powers half of google and all of yahoo groups. in that respect it already matters a lot more than Ruby on Rails.

Ian and his fellow lost souls have simply chosen to work for the wrong companies.

Challenge by Bill Katz on March 30, 8:44

Zope is not an application framework, it is a web application server.

You'll probably get some disagreement from the Zope folks. Here's how Stephen Richter describes it:
Zope is an application and backend server framework that allows developers to quickly implement protocols, build applications (usually Web-based) and function as glue among net-enabled services.

I did consider Zope X3, but I like Ruby better than Python, and I love the way Rails has created a web domain language.

Challenge by bof. on March 31, 2:22

I think one reason for the abundance of Web Frameworks in Python is that the whitespace makes it hard to use directly embedded in HTML la rhtml. Therefore, you either deal with the weirdness or invent ANOTHER language to embed. Language design, almost from the ground up (unlike simple DSLs). Zope is already on its second or third HTML-embedded language.

Also, there's no DBI-equivalent (in ruby neither, but the DB situation seems better) and most DB drivers are poorly documented. That's Bad.

Then yes, there are documentation problems. Although it might be pretty good, the PyDoc homepage screams "half-finished project". When I tried it, most Zope doc talked about the old, deprecated HTML embedding language. However, I like the Python HTML help better. And daily python-url is very good, I wish there was something like it for Ruby.

Last but not least, Python had its "rails moment" years ago when Zope was open-sourced. And just as it was gaining hype, the dot-coms crashed. Rails has benefited from a mostly stable economic situation.

Challenge by Lau Taarnskov on April 01, 13:35

bof, a DBI equivalent does exist for Ruby.

Challenge by Gunther on April 02, 23:59

While I have a Mac, I do all my development, open source or not, on Windows. By my choice. I've never had a problem with collaborators (right now, I'm working on a big rails/ruby/perl project with someone on a Mac and someone on Linux).

Instead of endlessly futzing around with compiling stuff from source, I get nice bundled installers, and instead of the execrable CPAN module, I get ActiveState's PPM. I get an Eclipse that's not slow as molasses, unlike on OS X. I don't see why I should use anything else. It is, of course, your prerogative to think otherwise, but I don't see the disconnect. Windows ports of software exist for a reason, and I don't want to waste hours on compiling prerequisites and tools I might need, especially not with ports or fink.

Challenge by Gunther on April 03, 0:00

I did, however, comment on the wrong entry. Sorry.

Challenge by . on April 04, 19:46

Um, PHP still rules the web you know. Then there is ASP(.NET), then Java, and THEN later on there is Ruby on Rails, and much later on there are about two dozen Python frameworks. Actually I don't have any stats to back that up, but that's the impression I get.

I prefer separating the web framework from the language, so I'm not forced to code in a language I don't like (or worse, do most everything in XML). This isn't possible in any of the frameworks except for some java (if you use jython, for example) and .NET ones.