Python on Rails?
Asked Answered
C

4

26

Would it be possible to translate the Ruby on Rails code base to Python?

I think many people like Python more than Ruby, but find Ruby on Rails features better (as a whole) than the ones in Python web frameworks.

So that, would it be possible? Or does Ruby on Rails utilize language-specific features that would be difficult to translate to Python?

Cumulonimbus answered 25/11, 2009 at 1:56 Comment(6)
It's called: DjangoLuong
The groovy language has grails, which was originally called "Groovy on Rails".Candis
And now there's Rango, which is Django on ruby, exactly the opposite of what you want. rubyinside.com/rango-ruby-web-app-framework-2858.htmlCandis
tomayko.com/writings/no-rails-for-pythonFreemanfreemartin
possible duplicate of Why is Ruby more suitable for Rails than Python?Rottenstone
Python is very nice also, but documentation especially on 3rd party libraries/modules is something like "huh"... RoR looks like easier to develep and deploy, than Django. But, if we are going to port "Rails" to somewhere else than "Ruby", "Java" will be absolutely one of the best platform, if GOD wishes.Blodgett
M
19

This is a great blog post. Rails developers chose a framework, and coding in Ruby is the afterthought.

Python developers chose the language for the language, not the framework. On the other hand, that made a lot lower bar to entry for frameworks.

Misbeliever answered 25/11, 2009 at 2:21 Comment(3)
Agreed - In 90% of discussions I've encountered regarding Ruby in front-facing web development, the name "Ruby" is almost used interchangeably with referring directly to Rails.Katekatee
While I will not downvote this post, because it is obviously an opinion, I would definitely like to point out that it is an absurd generalization. Ruby is most certainly not an afterthought and its metaprogramming facilities and extensibility have played a crutial role in its popularity. Also, Rails developers chose Ruby for a reason. They simply could not have done what they did (atleast equally elegantly) in python.Hayrack
Do python developers chose the language for the language or for the batteries (like numpy)?Withers
L
16

Many of the methodology used in Rails has been translated into Django. Have you tried it?

http://www.djangoproject.com/

Leathers answered 25/11, 2009 at 2:14 Comment(4)
@Juanjo: Then you'd know it answers your question entirely, since it's practically a Python Rails in most regards -- right?Luong
The MVC architecture (or MTV as Django calls it) is a little silly. Rails interpretation of MVC is much cleaner.Schmooze
I could not disagree with this more. I work in both rails (for fun) and django (for work) and they are very different. Django feels watery and neglected compared to rails. Approach is totally different. If we were starting over again it would be rails all the way down.Depression
Yes, this was two years ago, and I think I agree with you more now, Jason.Leathers
F
14

I think one of the things that people like about RoR is the domain-specific language (DSL) style of programming. This is something that Ruby is much better at than Python.

Flagstone answered 25/11, 2009 at 2:2 Comment(0)
R
1

I know that Rails does not necessarily = MVC per se, but I think a lot of what makes Rails productive is that it enforces (well, strongly encourages) MVC development, so you might find something similar if you look for Python MVC, such as this previous post here on Stack: What's a good lightweight Python MVC framework?

There are lots of Python MVC frameworks out there, but I keep hearing a lot about Django (http://www.djangoproject.com/) so that should definitely be on your list of things to check out IMO.

Rwanda answered 25/11, 2009 at 2:14 Comment(2)
Two other frameworks worth mentioning are Pylons (pylonshq.com) and TurboGears (turbogears.org)Rwanda
Tough to say if this opinion was accurate in 2009, but in 2022 Rails is entirely MVC. You can run it in API-only mode ... but then you’re really just delegating the V to something else.Effulgent

© 2022 - 2024 — McMap. All rights reserved.