In the Rails world, the layer which generates the final markup sent to the browser is called the View layer. In a Rails View, you can chuck as much rails code as you like in amongst your markup.

Some of the early sites I worked on many years ago were written in PHP, which had the same idea.

Um. . . Sure, you can put any logic you want in a Rails template, but people don't. Rails applications tend to have a nice separation of layout and application logic. Django really likes to constrain users here - not even letting them use a full "if" statement. It's really unfair to just say Rails == Unmaintainable PHP. PHP often becomes that way because there is no immediate way of separating the code. Smarty and others can force you, but both Rails and Django put a really obvious place to put your app logic and developers tend to respect that. Part of this is just how much rope do you give a developer and it's fair to say that one shouldn't give developers that much leeway. However, it's wrong to just equate the two.

Multiple Apps in a Project

Really, neither framework (or any code) is as pluggable into random situations as we programmers would like. The author suggests that you can use models from different applications in Django. That sounds cooler than it is. They're all running off the same database and in the same project. Really, what Rails creates are projects in Django-speak. And the "apps" convention in Django doesn't help you in development. It helps in organization sometimes - especially the admin interface - but it isn't some spectacular thing where you can just reuse random code in a way that you can't with Rails. Well, I take that back, there is one way that is really nice: namespacing. You can have a blog app that has an Entry and Category model without having to name it BlogEntry and BlogCategory because it would conflict with your Category model for, say, a real estate part of your app. And that is helpful in a way that Rails doesn't solve nicely. However, for the most part Rails and Django provide decently equal utility in this area, they just name the things differently.

URL Routing

Django's routing is really verbose. You have to specify each route you want. Rails has a bunch of shortcuts for common cases (REST as well as :controller/:action/:id). In a way, this is just the explicit vs. implicit thing. Django makes you explicitly state your URLs while Rails will let you state them, but you don't have to should you like the defaults. The Django folk say that it takes very little time to write routes (true) and that one should be thoughtful when making URLs (also true). But sometimes it just feels tedious. Really, it's just a matter of preference.

Ruby (Perl’s Ugly Sister)

This is kinda low at some points (why I went to it last - I don't like dwelling on such poor arguments). Ruby doesn't actually use that many symbols ala Perl. All variables are done without symbols; I think strings built as "#{var} is cool" are easier to understand than "%(var)s is cool" % {'var': var}. And it isn't like Python doesn't have weird things like "/".join(list).

Really, my beef with Ruby would be how easy (and common) it is to add methods to ancestors without really making it clear. As you start adding methods to Object, you can get yourself into a position where Python's explicitness is really nice. However, when you want to get something done, Ruby can be nice in that respect. It's like having a circular saw: really good for both cutting wood and cutting your hand off. Likewise, Python's mixins are put onto attributes of the model - so that you have things like house.photo.url rather than house.photo_url (although Django did create the second for a long time). That makes it very clear what you're adding while if you say "acts_as_nested_set" in Rails, you don't immediately see which methods are being added.

Ruby's problems aren't really syntactic, but it can have things that one could define as problems.

--

I've put out two sites in Django and one in Rails and at this point I'm developing two projects in Rails. The Django community is really smart and understated and I still read a lot (smart information translates well to anything), but Django just doesn't see the same pace of development that Rails does. Even something simple such as following reverse foreign keys isn't implemented in Django. Yep, if you try Entry.objects.all(select_related="comments") it will just silently fail (how's that for letting errors pass silently that shouldn't!). And it is difficult and Malcom has way more on his plate than any normal person could even conceive of, but. . . it's still missing.

And the Rails community has calmed down a bit, the Merb camp seems to be adding nicely to Rails 3, the Rails framework covers so many more edge cases than it used to as well as just seeming more reliable, and deployment has really stepped up with Passenger.

Django is a wonderful piece of software with great features and really smart, considerate people using it. It just isn't seeing as great a push toward little simplifications for more edge cases in the way that Rails has been. Frankly, they're so much alike in all the meaningful ways - I think that's why I have such an easy time wrapping my head around both.

Eh, I have to get dinner.