Updated (current) Rails recommendation compared to Django?

(Disclaimer: I asked this question yesterday at Hacker News . While the answers were good, there was a lack of technical discussion and more “you should use the rails because this is what you know.” Since Joel and Jeff clearly state that they don’t mind repeating questions from other sites ... and since I really like the answers that I find here ... here goes)

Hi guys.

I understand that this post is a shameful question against and, undoubtedly, superfluous with older posts. However, most of the information I find in Rails and Django is outdated and based on much earlier versions of the frameworks, so please forgive me.

First of all ... I'm a Rails guy. I came to him three years ago and really enjoyed what he brought to the table. I'm not the only guy from Ruby ... I have about 11 years of experience, including Java, C / C ++, Perl, Tcl, (some) Python, etc.

In any case, I have an idea, I believe that it will take over the world. I have already made sure that some people will also have friends and family funding to take on some offshore developers and get it in beta as quickly as possible.

Now, however, I left a decision about which technology to use. Although I really enjoyed Ruby ... I'm tired of magic and the abuse of open classes. This is very nice when you need to quickly introduce some kind of behavior, but it can be a real pain when you need to support your project or any of its plugins. I personally prefer Ruby over Python (mainly because of the blocks), but I envy the first occurrence in the Python community. Given this frustration, I am seriously thinking about diving deep into Django and using it for this project.

The pros that I see on the Rails side are:

  • Community size (which, given some of this "community", includes PHP refugees, is not necessarily a plus)
  • My acquaintance and experience
  • The number of companies using it and striving to improve it.
  • Availability of offshore resources

Rails disadvantages include:

  • Too much magic
  • The documentation is still terrible in places
  • Inconsistent API
  • Did I mention magic?

(perceived) pluses on the side of Django:

  • Clarity
  • Performance ... I believe that Unladen Swallow will really change the Python landscape and give it a competitive edge.
  • Google support for the language itself (see No. 2)

Django disadvantages:

  • Learning curve
  • Smaller community
  • Slower development cycle of the project itself?
  • (un) Availability of offshore resources

So this is my thinking process. It’s very convenient for me that I can quickly speed up work on Django, and I have the basics of Python, still in my memory. But I wanted to get your opinion, because I really respect the vision and experience of many people that I read here.

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

And to say, to choose Rails simply because I have experience, it just doesn't sound right. If so, I will still use Perl or C.

Thanks!

+7
python ruby django ruby-on-rails
source share
4 answers

[Repost from HN, same link as question, as I would like to hear yours (you did not answer HN) and SO answer.]

I am obviously biased as I run the django development company. However, I will start by answering Django's flaws,

  • Learning Curve: No more than any other structure. In addition, the documentation is at the top. (The documentation was sold by me when I was pricing.)

  • Smaller community: Definitely true. But outside the critical size, the size of the community does not matter. Django is much larger than this size. (Irc: any given time ~ 200 Devs. Google Group: 14000+ users)

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

  • (un) Availability of offshore resources: Definitely less than Rails, but still not as bad as you might think. A very small list, http://uswaretech.com/blog/2009/03/web-development-companies ...

Thats said, given the information you have, I chose Rails in your case. Even if most of the work you are looking for in offshore, your existing Rails experience will be a huge plus, helping you evaluate suppliers, track.

In a semi-dependent note, Django is a less mature / smaller community, blurry, some numbers,

  • Years are being developed. ROR: 5 / Django 5
  • Members of the big google group: ROR 18000 + / Django 14000 +
  • Members at Irc currently: Ror 436 / Django 401
  • Performing repo: Ror? / Django 11000 +
+8
source share

You have forgotten at least one advantage of Rails - extended validation through RSpec / Cucumber. In fact, the main (additional) advantage is the attention to Ruby / Rails from the flexible testing community. Using natural language testing should significantly increase the ability to reason from your tests and promote understanding. In some ways, this would make up for the “magic” you hate by documenting it with easily readable tests.

In addition, I would suggest that the new project that you spend the money of your friends and family on is probably not an ideal situation in which you can learn a new language / structure. Why add extra risk to an already risky venture?

+7
source share

I will just argue with many of your statements:

  • Django may have less magic than Rails, but there still is. Python is clearer, so you get clarity.
  • Django is known for being easy to learn, so I don't think the Djangos learning curve is a problem.
  • An unfilled swallow is still steam cookware. Never DO software decisions based on the promise that some software will be available in the future.

Since you already know Rails, you should stick to it if you don't know that it will be painful. Also, if you are not comfortable with Rails, I would recommend you go through tutorials for some other Python frameworks like Turbogears 2, BFG, and Grok. Perhaps you would prefer something less monolithic or more complete than Rails / Django.

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

+6
source share

I have a different perspective regarding these two frameworks on how they compare. I am still a noob in these two, as I am a Java developer looking for something more interesting to do in my free time. I followed these two structures closely and came up with the following:

Rails

As you know, Rails is born from a web application built with 37signals, which affects the if architecture. I really don't use Rails in a real application, though, but I think I can use it for my next pet project.

  • Basically, what I see from Rails is that it is a monolithic type of framework (although this will change in Rails 3 since it will adopt the Merb architecture). This architecture from my point of view will also affect the delivery / packaging of your project. A monolithic project, which I think is good, is suitable if you want to deliver the entire application in one bundle to your client.
  • According to the architecture, Rails uses a plugin if you want to expand or add another function. I think this is good if you want to create a community-based product where a user can add a plugin.
  • They said that Ruby is slow, but if you want to pack Rails applications as a product, it is pretty twisted to pack it as a war file with JRuby and warble. For example: Thoughtwork Mingle use this approach.
  • With that in mind, IMHO (well, DHH also said this at the Ruby vs Snakes conference) Rails is suitable for web applications.
  • Rails has good native support for ajax (rjs). Django is easy to add Ajax support to django, but an abstraction like Rails still makes it quite worthy, which I consider.

Django

Django was born from a newspaper site, therefore, in the same aspect, which also affects the architecture of the django itself. I used only django on my sandbox website, and so far I really like creating sites on it.

  • Most of the dirty work was done for you (RSS feed structure, general view, admin, comment structure, etc.).
  • Django has a "plug-in application" architecture. This is good if you want to connect community-made django applications that you already have or share this application on several of your sites.
  • As I said, if these are internal / internal websites, I find it very useful to use django, because you can reuse these applications on multiple websites. But it would be very difficult to deliver this to a single application such as a package, because usually (well, best of all, as I would say), these django applications live in PYTHONPATH, and do not combine all this together into your application. Although Pinax distributes all the applications in one package, I am curious how Ellington does it.
  • Since the current Python is faster than the current Ruby (1.8), this makes django itself faster than Rails (there are a lot of tests about this on the Internet). Thanks to this design, IMHO django is really suitable for high traffic sites (think of twitter as traffic websites).

Some people may disagree with me as they may find a workaround for using Rails as websites and django as a web application. But this is what I consider the difference between the two, based on their architecture. In this way, he will also determine what they are good for. Feel free to disagree with me :-)

Greetings.

+6
source share

All Articles