Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Updated (current) recommendation on Rails versus Django? [closed]

(Disclaimer: I asked this question yesterday on Hacker News. While responses were good, there was a notable lack of technical discussion and more of a "you should use rails because that's what you know". Since Joel and Jeff state clearly they don't mind reposts of questions from other sites...and since I really enjoy the answers I find here...here goes)

I realize this post is an infamous "versus" question, and undoubtedly redundant with older posts. However, most of the information I find on Rails versus Django is out of date and based on much older versions of the frameworks, so please forgive me.

First and foremost...I'm a Rails guy. I came to it three years ago and really enjoyed a lot of what it brought to the table. I'm not solely a Ruby guy...I have around 11 years of total experience, including Java, C/C++, Perl, Tcl, (some) Python, and more.

Anyway, I have an idea I believe will take over the world. I've already convinced a few folks it will as well and have friends and family funding to take on some offshore developers and get it in beta as quickly as possible.

Now, however, I am left with the decision of what tech to use. While I've really enjoyed Ruby...I'm growing tired of the magic, and the abuse of open classes. It's very nice when you need to inject some behavior quickly, but it can become a real pain when you have to maintain your project, or any of the plugins it depends on. I personally prefer Ruby over Python (largely because of blocks), but I envy the clarity-first attitude in the Python community. Given this frustration, I'm seriously considering a deep-dive into Django and using it for this project.

The pluses I see on the Rails side are:

  1. Size of community (which, given some of this "community" includes PHP refugees, is not necessarily a plus)
  2. My familiarity and experience
  3. Number of companies using it and striving to improve it
  4. Availability of offshore resources

Drawbacks of Rails include:

  1. Too much magic
  2. Documentation continues to be awful in places
  3. Inconsistent API
  4. Did I mention magic?

The (perceived) pluses on the Django side:

  1. Clarity
  2. Performance...I believe Unladen Swallow will really change the Python landscape and give it a competitive advantage
  3. Google's support of the language itself (see #2)

Drawbacks of Django:

  1. Learning curve
  2. Smaller community
  3. Slower development cycle of the project itself?
  4. (un)Availability of offshore resources

So, this is my thought process so far. I'm pretty comfortable I could come up to speed quickly on Django, and I have the basics of Python still in my memory somewhere. But I wanted to get your opinions as I really respect the vision and experience of a lot of the folks I read on here.

I appreciate your help. I really think this idea will take off, so it's very important to me to make the right technology decision.

And saying to choose Rails simply because I have experience there just doesn't sound right. If that were the case, I'd still be using Perl or C.

Thank you!

like image 849
Parna Avatar asked Jul 20 '09 11:07

Parna


3 Answers

[Repost from HN, same link as question, as I would like to hear your(you did not reply on HN) and SO response.]

I am obviously biased, as I run a django development company. That said, Ill start with answering the drawbacks of Django,

  1. Learning curve.: Not more than any other framework. Plus the Documentation is top notch. (The documentation was what sold me when I was evaluating.)

  2. Smaller community: Definately true. But beyond a critical size, size of community does not matter. Django is well above that size. (Irc: any given time ~200 Devs. Google group: 14000+ Users )

  3. Slower development cycle of the project itself?: Why? If you give more details, I can answer that.

  4. (un)Availability of offshore resources: Definately less than Rails, but still not as bad as you would have thought. A very small list, http://uswaretech.com/blog/2009/03/web-development-companies...

Thats said, given the information you have, I your case I would choose Rails. Even if most of the work you are looking to offshore, your existing Rails experience would be a huge plus, helping you evaluate vendors, keep track.

On a semi-related note, Django is less mature/smaller community is way overblown, some figures,

  1. Years under development. ROR: 5/Django 5
  2. Members in largest google group: ROR 18000+/Django 14000+
  3. Members in Irc currently: Ror 436/Django 401
  4. Commits to repo: Ror ?/Django 11000+
like image 165
agiliq Avatar answered Sep 29 '22 10:09

agiliq


You forgot at least one advantage of Rails -- enhanced testability via RSpec/Cucumber. Really, the main (additional) advantage is the attention to Ruby/Rails from the agile testing community. Using natural language testing should significantly enhance the ability to reason from your tests and promote understandability. In some respects this would offset the "magic" that you abhor by documenting it via easily readable tests.

Beyond that, I would suggest that a new project that you are spending your friends' and family's money on is probably not the ideal situation in which to learn a new language/framework. Why add the additional risk to an already risky venture?

like image 22
tvanfosson Avatar answered Sep 29 '22 11:09

tvanfosson


I'm simply going to argue with many of your statements:

  • Django may have less magic than Rails, but there is still some there. Python is clearer though so you will gain clarity.
  • Django is renowned for being easy to learn, so I don't think Djangos learning curve is a problem.
  • Unladen Swallow is so far vapour ware. Never ever EVER make software decisions based on the promise that some software will be available in the future.

Since you already know Rails, you should stick with it unless you know it's going to be painful. Also, if you aren't happy with Rails, I would recommend you go through tutorials for some of the other Python frameworks in existance, like Turbogears 2, BFG and Grok. It may be that you would prefer something less monolithic or more complete that Rails/Django.

http://bfg.repoze.org/ http://grok.zope.org/ http://turbogears.org/

like image 37
Lennart Regebro Avatar answered Sep 29 '22 11:09

Lennart Regebro