Tuesday, January 10, 2006

Ruby/Rails Redux

I tried. I really did.

If you've been following this blog, you'll know that I gave Ruby a look-see when the hype over Rails first started to build up. I didn't particularly like what I saw and being a bit of a Java weenie, I went back into its all encompassing, XML filled, embrace.

But I've absolutely had it with Java now. It's great for large complicated projects with teams of developers working together, but for a one man effort, cobbled together in what free time I have, Java is over-kill. It's official, I'm finally sick to death of the ginormous configuration files and over-engineered class hierarchies. Do I really need 10+ classes just to access the database? I hope not.

So I succumbed to the siren like call of the Rails fanboyz and decided to give Ruby on Rails a try... but I couldn't do it; I just couldn't. [cue weepy music]

The rational reason I'll trot out is that Ruby has terrible support for I18n/Unicode, but the real reason is that Ruby's syntax is just too much like Perl (aka 'line noise'). Enough to give me flashbacks about my time in the trenches writing that filth. They had to drag me out from under the bed and pull my thumb out of my mouth.

And don't get me started on the 'magical' ways of Rails. I hate config files as much as the next guy, but you can have too much of a good thing.

So what's the alternative?

Python.

Now, I don't need reminding that Python has it's warts, I've had to stare at them often enough. I dislike the explicit 'self' variable, the lack of access control modifiers and the almost-but-not-quite OOP schematics. But's it's leagues better than Ruby and it's got fairly decent I18n.

Pythons not been getting the buzz Ruby has as far as its frameworks go, but there are two that are certainly worth considering.

1. TurboGears
2. Django

Both promise Rails like speed of development and simplicity through a single integrated Web Application stack. TurboGears glues together various best of breed frameworks for it's needs while Django builds up everything from scratch.

Some people seem to prefer Django, but I haven't decided which way I'll go yet. This much however, is clear...

Ruby can ride the next train out of town and good riddance.

4 comments:

Adrian Holovaty said...

Definitely give Django a shot -- it rocks.

You may particularly be interested in its i18n support.

Anonymous said...

Try both frameworks and decide wich one is the best for you.

Jigar Gosar said...

ya be sure to try both and then dont forget to post a review. Heres my 2 cents, turbogears is lil bit too verbose, compared to rails. And if u want to go for Django, it has same magic that you dislike abt rails.

Once you have selected a python based web framework, we can start ruby vs python web-framework war ;)

Sandeep Shetty said...

For me personally, the choice is between libraries and frameworks and not between frameworks and frameworks.

You have to give up a little freedom for convenience. I prefer freedom.

Maybe this will help you decide between the two or drop both of them :)