10 ms·
Ask HN: What does Ruby have that Python doesn't?
About 6 months ago I decided to learn either Python or Ruby because I wanted a language to write webapps and simple computergames fast.
I kind of tried both for a while and Python gave the better impression in every way, readability, ease of use, libraries, documentation, expressiveness etc.
But there are so many really enthusiastic posts about Ruby and while Python has a lot of users and is very popular and successful I rarely see anyone rave about it. But maybe that just means it has gotten mainstream.
But anyway I like the Python philosophy that there should preferrably be one obvious way to do things.
While similar in most ways, there the languages differ.
So, what do you Rubyists like so much about Ruby? Especially what do you think Pythion lacks?
- waldrews 18y agoThough I'm pro-Python on maintainability grounds, there's one Lispish feature Ruby has that I wish were available in Python, that's not even in the Py3000 spec: continuations. The Ruby community doesn't seem to be too enthusiastic about using them though. We're just beginning to see continuation-based web framework experiments on Ruby, in the spirit of Seaside in Smalltalk. The continuation-based web frameworks make state management on the server transparent; but they have a scalability problem since state can't move between servers or even be taken out of memory on the same server. Now once somebody makes serializable continuations practical - certainly a hard problem - it would be a jolt to web development on at least the same that Rails has been.
- LogicHoleFlaw 18y agoIn Lua, the Pluto serialization library has no problem persisting coroutines, which are isomorphic to one-shot continuations. Lua isn't terribly active in the web space, though this feature has been used to good effect in games.
- blasdel 18y agoSerializable continuations are already practical in Smalltalk: http://www.seaside.st http://www.seaside.st
- davidw 18y agoI don't think Python lacks much, if anything. It's a very fine language, with a great community. Over the years though, I just lost interest in it, and have come to prefer Ruby after having rediscovered it because of Rails. It's pretty much a matter of taste: I like the syntax and convenience more. One (fairly minor) real world case where the syntax makes a difference is in web templates: you can use Ruby pretty much straight up to do templating, but Python requires more hoops and hacking, due in part to the whitespace issue. I like the fact that Ruby is flexible enough to be used as-is for templates as well as other code. BTW, it also needs to be said that that is the only place I've ever noticed the whitespace issue being any kind of problem: it's not the big deal that some python detractors make it out to be. In short: if you're happy with Python...great! Keep using it, you made a good choice. If you want to learn another language, pick something a bit further from it... say, Erlang, Tcl, Java, or C, depending on what your needs are.
- gaius 18y agoNote that Python is sensitive to indentation not whitespace per se. So long as your line is at the right level there's no difference between a=1+2 and a = 1 + 2 In fact I wish Python were more sensitive to whitespace, then I could say my-variable without it mistaking a hyphen for a minus.
- rbanffy 18y ago"then I could say my-variable without it mistaking a hyphen for a minus" That's something cool. It would involve a new PEP and aggressive enforcement of PEP 8
- gaius 18y agoReckon it'd break too much existing code, but hyphens are so much nicer than underscores or interCapping. Using a language that supports that, my hands are noticeably more comfortable without needing to reach for the shift key all the time.
- 18y ago
- rit 18y agoI've always taken the approach of learning both and deciding for myself. If you're interested in true proficiency and building something for yourself, go with whatever rings most true to you. I liked Ruby, but found that Python clicked better for me. That, and call me crazy - but I prefer quiet competence to foaming at the mouth zealotry. There are plenty of people who rave about Python - but they've been doing it for a lot longer than the Ruby people (simply age of language). Ruby also has gotten lots of people hooked via Rails, and that seems to be where most of the evangelism is coming from. (edit: commented to clarify my meaning below, in another comment: http://news.ycombinator.com/item?id=283771 http://news.ycombinator.com/item?id=283771)
- deleted 18y ago[deleted]
- ericb 18y ago>> but I prefer quiet competence to foaming at the mouth zealotry. Do you really pick your language by your perception of its users? I'm not sure that's a great criteria for choosing a tool. If an annoying dinner guest admired the butter knives, would you butter your roll with a fork?
- iron_ball 18y agoWell, working extensively with a language means working with its community, as a reader of news and documentation if nothing else. The size, expertise, and helpfulness of the community are all important factors in deciding whether to adopt a language. If a programmer finds the community annoying, that could be a legitimate problem.
- gaius 18y agoThe community also determines what is and isn't easy. This is something that a lot of otherwise smart people don't seem to get. Everytime someone into a powerful but obscure language wonders why it isn't more popular the answer is almost always something like "because Haskell's interface to Oracle is rubbish". And that's fine, because the Haskell community care about other things, if they want to be popular tho' they'll have to address that. Concrete example: The Ruby community is very focussed on the Web, so there's Rails but they aren't really interested in scientific computing so there isn't a real equivalent to NumPy.
- Alcides 18y agoRails. but you have Django which is better ;) Seriously, I envy ruby's blocks and being able to redefine a class later in your code (monkeypatching-easy-syntax). Oh, and Shoes :)
- pavelludiq 18y agoYeah, me too. Is it a good idea to learn ruby just to use shoes? I mean is it easier that qt/tk/gtk+/wx?
- utnick 18y agoyou should try it out and see if you like it.. shoes is a good way to learn ruby shoes is good for simple apps. But if you need complex controls like trees and sliders, coding in shoes would get annoying. Also the documentation for shoes leaves something to be desired. but it is pretty fun.. i'm coding a shoes app right now and would recommend it
- ghiotion 18y agoI chose RoR over Python/Django for one simple reason: RoR's tight integration with the Prototype AJAX javascript library. Personally, I like Python as a language much better than Ruby. But if I'm going to code up a Web app, I want easy AJAX integration - I don't want to hand craft a bunch of javascript. It's not that I've got anything against writing javascript, but I hate, hate, hate trying to debug it.
- cstejerean 18y agoTight integration with prototype is one of the things I don't like about Rails, mainly because I don't like Prototype (I'm a big fan of JQuery).
- tptacek 18y agoThen what you want is jRails, which subs jQ in for Prototype in all the Rails helpers and removes Prototype from your project. You "plugin install" it, forget about Prototype, and use nothing but jQuery from then on.
- jonhohle 18y agothis is never really brought up, but objects in ruby fully encapsulate their instance and class variables. the only way to get at them from the outside is by sending an object a message asking for them (like Smalltalk or Objective-C). what appears to be setting a property on an object, is really calling a method: `foo.bar = 5` isn't directly setting the property, its calling a method named `#bar=` in my opinion, this is powerful and elegant. that being said, i have little experience with python, but what i've seen never wowed me. it seems like it has a well written collection of libraries, but that seems to come from the community more than the language. correct me if i'm wrong.
- simonw 18y agoTwo good things and one bad thing. The good things are multi-line lambdas (which Ruby calls blocks) and loose syntax rules, which I found weird at first but is the secret behind all of that DSL stuff. The bad thing is the cultural tendency of the Ruby community towards monkey patching, which in my opinion trades long term maintainability for short term convenience.
- LogicHoleFlaw 18y agoWith the rapid growth of the community I think that the monkey patching mentality will eventually subside. More and more toes are being stepped on.
- aconbere 18y agoTo be fair... blocks are not lambda's, but things would be a lot better if they were.
- deleted 18y ago[deleted]
- gaius 18y agoMy experience is that the languages are similar in terms of features, but the communities are very different and there isn't much overlap between them. Ruby types tend to be younger, focussed on the web, probably employed as full-time developers. Python types tend to be older and not employed as developers, but write code as part of their main jobs. Python people often have experienced a nightmare of unmaintainable Perl, that is why there is the insistence on there being one right way to do everything (which is the exact opposite of what Perl people believe). Ruby people (being younger and hence less experienced) haven't, which is why they talk about expressiveness and do things like monkey-patching. Neither group is "smarter" and neither language is "better". The choice is a choice of what community you want to join, not a technical one.
- cstejerean 18y ago"Python types tend to be older and not employed as developers, but write code as part of their main jobs." I'm curious, how did you arrive at that conclusion?
- gaius 18y agoMainly through direct observation. Among my own circle of friends, it's surprising how neatly we (well, those of us who use either language) divide into those categories. But you can see the pattern in job ads, discussions on mailing lists and in the domain-specific libraries for each language too. As many people got into Python through NumPy as a MATLAB alternative as got into Ruby via Rails, I'll bet. Like I say, this isn't a good thing or a bad thing, it's just interesting.
- rw 18y agoYour comment made me realize that the phrase direct observation sounds so much better than anecdotal evidence.
- gaius 18y agoYou'll notice I did say my experience :-) I'm not trying to "win" an argument here, which would require "evidence", just pointing out that there are more important things in language selection than the features/characteristics/quirks of the language itself, especially given there's not much to call between Ruby and Python. But, y'know, you could try quantifying it if you like, by looking at the libraries available for each language, and looking at how many jobs are "Ruby" as their main skill and how many are "10 years of whatever + Python".
- jazj 18y agoRails.
- maxklein 18y agoThe languages are similar enough that it does not really matter. Just pick any, but make sure you balance it out by also knowing a low level language or a functional language. Remember this: Every language you learn is a big investment in time and energy, and I don't think many people can be really proficient in more than 2 or 3 languages. Some can, but not most. So, choose wisely, because you will likely be using that language for a long time to come. I personally prefer python because it's more widespread and right now, you have more available to you when you know it than with ruby.
- subwindow 18y agoI couldn't disagree more. Even if you spend a month learning Ruby and never use it again, it will still irrevocably change the way you approach writing code.
- maxklein 18y agoYou mean that ruby has a greater learning effect than python on a C++ programmer?
- rbanffy 18y agoIf we are talking a month of involvement, you may as well learn both. I would also throw Lisp in. And Forth. And Haskell. And Smalltalk... But then, we are not talking about a month anymore...
- aconbere 18y agoI definitely did not have this effect on me. Usually when I hear comments like this it's from Java programmers. But coming from a background of already knowing several expressive dynamic languages (Python, Perl) and having a strong functional background in Lisp. I didn't really find Ruby that mind blowing. Very cool? YES! worth learning? Absolutely! "changing the way I write code irrevocably? Not a chance!
- davidw 18y ago
- olavk 18y agoI prefer Python, but I am somewhat envious of Ruby blocks. Also I like the idea that method calls are messages.
- pdubroy 18y agoI've done quite a bit of Smalltalk programming, and I agree about the blocks. But what do you mean by "method calls are messages"?
- LogicHoleFlaw 18y agoIn Ruby calling a method on an object basically sends a message to the object with the name of the method and the arguments. You can hook into the dispatch code and do pretty much whatever you want with that message at the class level. I don't know the internals of Python's method dispatch that well, so I can't say how it compares in that regard.
- gaius 18y agoI believe Python's __getattr__() and __setattr__() allow you do the same thing, but I don't know enough Ruby to say for sure :-)
- aconbere 18y agoYou couple those with ruby's method_missing and then you have some interesting functionality. But basically the way that Ruby handles operator overloading and function accessing is a lot cleaner than pythons. It would be pretty nice to get rid of a lot of the dunders.
- pdubroy 18y agoAre you referring to Ruby's method_missing? As I understand it's about the same as Smalltalks #doesNotUnderstand:. Python doesn't have an equivalent, but it does have __getattr__, which is arguably more powerful but less convenient.
- pdubroy 18y agoHype? ;-)
- subwindow 18y agoIt isn't so much about language features, as both languages are roughly equivalent in that sense. It is about how the language makes you feel. If you're going to be spending >5 hours a day writing in some language, it is of great importance how that language makes you feel when you write it. Simply said, writing Ruby makes me happier than I've ever been while writing code. Python is to German as Ruby is to French. You can get roughly the same message across equally well in both languages, but French just sounds so much better.
- LogicHoleFlaw 18y agoWell... unless you want to sound really angry! Then er... Python is better? I think I'm stretching the metaphor past its breaking point.
- deleted 18y ago[deleted]
- donw 18y agoTwo words: "French Engineering".
- gdee 18y agoTwo counter words: Ariane, Nuclear (as in 80%+ national electricity)... not too shabby as far as engineering goes... I would add Airbus, LHC, etc... but two are enough.
- deleted 18y ago[deleted]
- comatose_kid 18y agoHave you ever worked with engineers from Les Grandes écoles? You might reconsider your view.
- demallien 18y agoyeah, as an engineer working in France, I can honestly say that their engineers are pretty good. The problem is that there's another grand école that specialises in producing bureaucrats (seriously!). And for whatever perverse accident of history, they are considered to be la crème de la France, so they call the shots in most large businesses. They consider themselves to be better than lowly engineers, so don't deign to listen to any suggestions about what is technically possible or not. /bitter :-)
- tokipin 18y agopersonally i don't like the 'one way' mantra that Python is designed by, because it seems to imply a couple things. 1, the language is probably not as flexible and powerful as it could be. and 2, the design goal is similar in nature to that of production languages, eg Java which forces object orientation. the intentions are good... to allow the construction of readable, maintainable software by normal humans, and Python is at least not as retarded about it as Java, but i have found that languages which constrict aren't for me so to me Python seems more of a team production dynamic language than one where i can get into flow and crank shit out
- nostrademons 18y agoThe practical benefit of "one true way" is that it eliminates decision points. Most of the time in a software project is wasted in making decisions; if you eliminate all decisions that are not relevant to getting the software finished, you have a huge head start on everyone else. There's a joke going around that a Python team will finish a project before a C++ team can decide which brace style to use...
- demallien 18y agoThere really isn't a huge difference between the two. For what it's worth, I personally prefer Ruby because it has better support on the Mac - Apple use ruby a fair bit themselves. For example, the command line tool gen_bridge_metadata (supplied by Appleto make it possible to access system frameworks written in C from scripting languages) is itself a ruby script. I notice that on Linux it's the reverse - python seems to be the preferred scripting language. But don't take my comments as saying only ruby is supported on the Mac, or only python on Linux - in reality it's only a light preference one way or the other.
- tpherndon 18y agoThe CalDAV server authored by Apple and included with OS X Server is written in Python. PyObjC receives a lot of attention from Apple employees. I don't think there's much preference exhibited by Apple one way or the other. And vice versa, there must be some Linux distros that have tools written in Ruby, right? Particularly some of the newer ones, I seem to recall hearing that their system tools were Ruby.
- evgen 18y agoFWIW, the wiki that Apple includes in Leopard Server is also written in Python. Apple apears to be making much more use of Python than it is of Ruby.
- rcoder 18y agoCounter-counter: Podcast Producer is a Rails app. I think Apple is just letting their employees pick their tools (at least for server apps) as they see best, rather than arbitrarily enforcing the choice of a single language.
- BrandonM 18y agoAll of Gentoo's tools are written in python, bash, or C.
- demallien 18y agoAs I said, it's just a slight preference. But I look at things like the official Apple support for MacRuby (Apple is employing Laurent to re-implement ruby in Objective C, so that ruby objects are Objective C objects - you'll be able to program Cocoa in Ruby without having to take the performance hit of crossing a scripting bridge all of the time!), and I don't see a commensurate support of the Python world. But as I said, it's only a slight preference - Apple s evidently right behind both languages, as they make leveraging the power of OS X so simple.
- thisisnotmyname 18y agoThe lack of built-in regular expressions is a pain point for me.
- jrsims 18y agoI really like Python, but it doesn't have an equivalent to CPAN or RubyGems. I'm actually quite puzzled by this.
- shabda 18y agopypi? www.python.org/pypi
- tpherndon 18y agoRead up on setuptools and the Python Package Index, aka the Cheeseshop. Setuptools hasn't yet been adopted as the one true packaging format by all library creators, but it gaining acceptance.
- jrsims 18y agoOk, awesome. And that's the same story as RubyGems. I've noticed that Python peeps are pretty big on "show me the code" anyway, but I think a lot of untapped potential is lost by not having a dead-simple distribution mechanism, as good as Python libs tend to be overall. That's one thing I do like about Ruby; it wasn't always this way, but RubyForge + GitHub (Oh, GitHub!) + RubyGems combine to make for a very fluid feedback mechanism and make good use of The Cloud. The result is that new libs get announced, distributed, tested, and improved by rabid Rubyists rather... rapidly.
- raganwald 18y agoThey're both impressive, modern languages. What I find interesting when comparing Python to Ruby is how much Python isn't like Lisp. Matz has said outright that he considers Ruby to be "MatzLisp" and it shows, whereas Guido has absolutely no problem chucking Lispy things overboard--like multi-line anonymous functions--if they do not fit the rest of the language. Instead, Python finds another way, like powerful list comprehensions that can be used wherever Ruby would use blocks and maps. So I would say you can learn some very interesting things from either language, and there's a good chance they will be different interesting things.
- aconbere 18y agoMatz might say that, but doing functional things in Ruby is a pain in the arse as well. Blocks, Lambdas, Procs, and Methods, all which are slightly different and require transformative functions to move one into the other. That's about as far from an s-expression as you can get. That being said, having the easy ability to create lambdas or blocks is hugely benefitial. sighs and I wish python would hop on board there, but I don't think it ever will.
- raganwald 18y agoI dig: http://weblog.raganwald.com/2008/06/what-does-do-when-used-as-unary.html http://weblog.raganwald.com/2008/06/what-does-do-when-used-a...
- aconbere 18y agoYeah... sobs it's a nice band-aid, but an inelegant solution. I would much rather that they all just be Proc or all some other mythical procedure class of the future. I figure that would break the whole ruby method call chain, though I don't see any reason why blocks couldn't just become straight syntactic sugar for lambda (I would love that)
- raganwald 18y agoA little off-topic, and I apologise to everyone for our exercise in bikeshedding, but... :-) The problem is that Ruby blocks were designed to imitate the behaviour of C-like blocks, while lambdas are true closures. (Don't get me started on why procs are just like lambdas only different). The difference between a block and a lambda is most clearly seen by asking what the return keyword does in a block vs. what it does in a lambda. So in Ruby you can write something like: def which_answer_is_correct(*answers) answers.each_with_index do |answer, index| return index + 1 if answer.to_s == '42' end return 'none of the above' end which_answer_is_correct('black','white',42,:symbolic_logic) => 3 If blocks were syntactic sugar for lambdas, this method would always return 'none of the above'. Of course, there is another, very elegant way to write this method that doesn't rely on the return keyword or the semantics of blocks, and one can easily argue that this would be an improvement.
- gtani 18y agoWell, they're both foundational languages, pretty much, not in the sense of this blog, i.e. most instructional language http://mvanier.livejournal.com/998.html http://mvanier.livejournal.com/998.html but in the sense of can you put up a significant web app in 2 or 3 days, do lots of companies use it (along with C, java, C#, javascript). r vs. p can't be reduced to 15 bullet points, but one of the best things i remember is Alex Martelli in 2003, so he was talking about ruby 1.6 and python 2.3, i believe, but still valid http://groups.google.com/group/comp.lang.python/msg/28422d707512283 http://groups.google.com/group/comp.lang.python/msg/28422d70... and here's the last thread from May. http://news.ycombinator.com/item?id=157269 http://news.ycombinator.com/item?id=157269 There's the other killer apps: Python: twisted, zope, SQLalchemy, mercurial. Ruby: rake, capistrano, rspec, adhearsion, merb, puppet, metasploit. I'm sure python has a bunch more, but i've been living in rails-land.
- Zak 18y agoFirst class symbols are the big one, I think. Of course, we all know about Python's brain-damaged function literals.
- eznet 18y agoI think that a lot of the popularity of Ruby came not so much from Ruby itself, but Rails. I think that with the emerging popularity of Django, you are likely to begin noticing a similar influx of Python enthusiasm...
- rit 18y agoAdmittedly, Django was what first got me really going with Python (we started using it for some small projects as a possible replacement for PHP a few jobs ago). There are however also some great alternatives within the Python community, in addition to Django which I no longer tend to use. Pylons, which is very Rails like including having similar WebHelpers functions, and a port of the Rails "routes" system. TurboGears, which is currently re-tooling itself to be based on Pylons. And a variety of others that I'm probably forgetting. I'm admittedly ignorant on alternatives on the Ruby side, but would be interested to see what other web frameworks people have built and the pros cons vs. Rails.
- jon_dahl 18y agoI'm admittedly ignorant on alternatives on the Ruby side, but would be interested to see what other web frameworks people have built and the pros cons vs. Rails. Merb is the big one. Think Rails, but more lightweight, greater emphasis on scaling and performance, and open to several ORMs (not just ActiveRecord), templating languages (not just ERB), and Javascript libraries. Camping is a Ruby micro-framework that's been around for a while. The framework itself is 4kb, and Camping apps are designed to sit in one file. Used a bit on the side, but not especially widely for production work. Sinatra is a newer microframework that looks similar to web.py, but in Ruby. Looks useful, and I've been meaning to get around to it. The nice thing about Rails, Merb, and Camping is that if you know one, the others will be familiar. They're all MVC frameworks that support ActiveRecord (and other ORMs, sometimes). They all favor convention over configuration.
- rit 18y ago>> Merb is the big one. Think Rails, but more lightweight, greater emphasis on scaling and performance, and open to several ORMs (not just ActiveRecord), templating languages (not just ERB), and Javascript libraries. Sounds exactly like the reasons why I went to Pylons. I found SQLAlchemy to be a lot more powerful than the Django ORM, and we needed more application components to be 'detached' from the web interface which got wonky in Django. I'll have to check these out, thanks.
- iamnirav 18y agoI like how this conversation has gone on for so long, but on the whole, everyone's still polite and detailed in their responses. :-) warm fuzzy feeling
- tptacek 18y agoWhat the hell, they're only karma points: I lived with Python for 4 years before I lost an argument at my own company and had my project moved to Ruby. I've since moved in with Ruby and haven't looked back. * Everything in Python feels like a symbol table hack. Private methods? We have those! Just exploit this bug in the class symbol table lookup code! * First-class symbols. There may be little difference under the hood between a Ruby interned string and a Python string atom, but there's definitely a difference syntactically. This is a difference that is hard to articulate, but if you've written much C, it's like having every "enum" you could ever want predefined for you, and completely eliminates "magic numbers". * Blocks and lambdas. I've read GvR's take on this. I know he thinks a named function is just as good --- maybe even better! --- than an anonymous function. I had nested named functions/functors in C++ and Java. Even Tcl "uplevel" is better than Python's castrated lambda. * Method definitions in Ruby don't need to accept a "self" argument. Again: all of Python feels like a symbol table hack to me. * Ruby has first-class Regexps. Python has an "re" library. You know what else has an "re" library? C. * I haven't found an expression that is better written as a list comprehension than as a map/reduce/select expression. There are painful things about Ruby: * The FFI is immature. Outside of Common Lisp, Python ctypes may be the best FFI out there. * I never got Python to crash on me (at least, not where it was Python's fault). I crash Ruby once a week. * Ruby is palpably slower than everything. If performance matters to you and you don't know C, you may be better off in Python. * The community is led by the nose by Rails developers, which can at times feel like a worst-of-all-worlds grab bag of methodology programmers, web designers, and dabblers.
- tomjen 18y agoYou can add inline c to ruby for the few places where speed matters.
- tptacek 18y agoYes, and that simply costs you the ability to distribute your software to anything but your own servers.
- ajross 18y agoBlocks and lambdas Yeah, but this is an area where both languages are just a mess. If python's lambda is castrated, ruby's notion of an anonymous function is tumorous. We've got blocks, procs, lambdas and methods? What's the difference? Ruby mixes up the syntactic requirements of "passing" some code to a loop to iterate with with the data requirements of binding a function to a scope. It's just a huge mess. LISP and Scheme figured all this out decades ago, and yet only Javascript (and, almost, perl) among common scripting languages has managed to absorb the lesson.
- iamelgringo 18y agoAbout 6 months ago I decided to learn either Python or Ruby because I wanted a language to write webapps and simple computergames fast. If you're after writing simple computer games fast, then you might have a look at Pygame: http://www.pygame.org/news.html http://www.pygame.org/news.html There are also a number of visual effects companies (ILM, Dreamworks) that use Python as their system scripting language. I don't know if it's because of that community, but I find a number of graphics/games libraries in Python: http://www.vrplumber.com/py3d.py http://www.vrplumber.com/py3d.py and http://vpython.org/ http://vpython.org/ Blender the open source 3D modeling program used Python as it's scripting language last I checked: http://www.blender.org/ http://www.blender.org/ I don't know if Ruby has libraries like that or not. I've only used Ruby to mess around with Rails.
- pauljonas 18y agoFor me, the question isn't so much what Ruby has that Python lacks, but the extra Python bits I find annoying and/or tedious: * having to declare "self" in every method argument — reading code, it just clutters up the screen/page * the big use of of double underscores for special methods (i.e., __init__, __str__, __getattr__, etc...) — IMV, it's gooberish... * no switch/case statement In defense of Python over Ruby: * I prefer the whitespace over the Pascal-ish begin/end, especially for real life code solutions * the Ruby shorthand syntax IMV at times obfuscates code clarity - is it a method or variable I am looking at? That said, I'd much rather code in either Ruby or Python than in Java or C...
- abdelazer 18y agoAfter leaving Ruby (non-Rails) for Python this year, I've mostly noticed the difference in the obsession about testing. The Ruby crew is very into TDD (and now BDD)–that isn't to say that Python folks don't test (or do TDD/BDD), but simply that the tools available in Python aren't quite as polished. Ruby's RSpec, RCov, Flog, Autotest, & Heckle are all quite wonderful. I do like Nose, but get annoyed by lack of friendly code coverage tools in Python.
- deleted 18y ago[deleted]
- DougBTX 18y ago_why
- mroman 18y agoI would love to read pg's thoughts on this question. Actually, I would love to read more of pg's thoughts on Ruby, what I have read of his thoughts on it has been brief yet highly positive.
- terminator3000 18y agonothing. rails is crap. python rules.
- petercooper 18y agoConsistency in class definitions (that is, not two "types" of class). Python's packaging is less consistent. Oh, and far better community sites.