by noelwelsh · 13y ago · 0 comments
Ruby also has utility for doing lots of scripting type tasks (things like Jekyll). The libraries you need to do this are simple to write. Python is perfectly adequate for this task already, as is Node (modulo callback spaghetti). So there is no barrier to entry here.
In summary I don't see any project going forward that provides enough value to maintain interest in Ruby. Thoughts?
[NB: I'm not saying Ruby is going to die overnight. I just think it will slowly become less relevant.]
In terms for barrier to entry with Python, the issue is that a lot of us chose Ruby over Python already for very specific reasons. Pythons whitespace usage, for example, makes it DOA for me. I'm not touching it. If it works for you, great. It doesn't work for me.
Ruby is the project that provides enough value for me to maintain interest in Ruby, and that's what I see with lots of other Ruby users too: The language is sufficiently more fun to work with that we're willing to put up with quite a lot, including horrible performance, to work with it.
Ruby might become less relevant to others, but I don't care if that were to happen. It will only become less relevant to me the day a new language comes along that is even more pleasurable to program in. So far I've not seen anything get close.
This has to be up there with people claiming they don't like Lua because array indexing starts at 1 instead of 0. Of all the weaknesses of Python, focusing on something so superficial just seems lazy.
Perhaps in the future just say that you're experienced and comfortable with Ruby and have no reason to investigate Python at the moment. :)
You can reasonably argue that a project team should already have and enforce a coding style guide, so specifying a "tab" isn't a big deal. But what if you're part of two separate projects which different coding standards? Do you use Editor A for Project A, and Editor B for Project B? Or do you maintain separate configuration profiles, one for each project? Granted, this also isn't a big deal: Just "git checkout ProjectA" in the directory where you keep your preferences before you start coding. But it is an extra step in your workflow.
You can use the "-t" or "-tt" flags to spit warnings or errors if someone mixes tabs and spaces, so any conscientious group can easily catch whitespace incompatibility problems. But Python's whitespace usage has organizational consequences, and it can affect a developer's choice of tools and/or workflow. For some people, this is not a superficial impediment.
PEP 8 has been around for over a decade, so there's no excuse for not following its recommendations.
Indexing starting at 1 is not only irritating, it's mathematically difficult. Certain concepts actually can't be described (as easily) with array indices that start at 1. It's not a trivial argument.
Similar with white space; having to write code which obeys white space and tab rules is not the way some people like to think. As much as I love Python (and I do), I find it more restrictive and less fun than Ruby. It's not just superficial, it changes the way you think, and what you think about. Of course Python has its advantages, lots of them. But it also has its own style, which may not be everyone's song and dance.
I do program in both Python and Ruby frequently, and I have to say that it has nothing to do with experience or comfort, it's truly a judgement, and a valid one at that. Nice try :)
Sure, there are certain edge cases when I wish I could represent something all in one line, or something similar, but they are so few and far between that I really cant see it as a major argument against not wanting to use python.
I felt the same way about whitespace at one time, but then I got used to it, and wonder why I ever felt so strongly one way or the other. The cases when my indentation isnt exactly like python in other languages is very rare.
If you find yourself using frequent cases of non-pythonic indentation in other languages, you may be writing some very unfriendly/unreadable code in a lot of instances.
It may make sense to you, but I wouldnt want to work on the same team.
http://www.secnetix.de/olli/Python/block_indentation.hawk
Summary: Python's whitespace usage is nothing like Make's.
Most of the good developers I know have their preferences for sure, but can be productive in all sorts of languages.
So you've never even tried it? If you like YAML, SASS or CoffeeScript, you would like Python's indentation syntax too.
I think it's lovely and elegant, and that meaningful indentation should be used more. It obviates a lot of cruft and makes things clearer and more concise. What's not to love?
Seriously, it's kind of dumb if proudly holding on to your prejudices is preventing you from enjoying a lovely programming language.
The only way Ruby becomes irrelevant is if a new paradigm becomes dominant that just isn't easy to implement in Ruby. Threaded/evented/asynchronous frameworks do fit the bill, but my sense is that enough people prefer Ruby so much to a language like Javascript (in the case of Node), that if something like web sockets become indispensable as an 80% use-case, then the Ruby community will figure out how to make it easier to use them. I'm still using MRI which has some difficult problems to solve, but it seems JRuby is pretty much ready to pick up the slack if it really becomes necessary.
I think most of the things you say sound like you haven't worked with either.
Few people are moving to pure JS front-end. Some are, some write blogposts about it, but the majority of people isn't. Some are even moving back, a year or so ago there were a lot of blogposts about that kind of stuff.
Rails offers a lot of interesting things in the M and C parts of the MVC pattern (Object persistence, REST endpoints, ...). People even write books about the topic ( https://learn.thoughtbot.com/products/1-backbone-js-on-rails )
Ruby and Python are pretty similar and as with Java and C++, there is space for both. I personally like Ruby more, but I guess that's just a matter of style.
I'm more worried about Javascript. Unlike Ruby, which has genuine advantages separate from Rails, Javascript is almost entirely propped up by its status as the only language available for DOM manipulation. Once it loses that footing, it's not a very viable language in and of itself.
I agree with this but I think there is a place for a javascript framework tied fairly closely to Rails. Possibly ember.js since the attitude towards both seems similarly opinionated and Yehuda Katz is one of the ember team. The Rails API gem accommodates this quite nicely as well although one of the benefits of Rails' modular design is that you can lose lots of the stuff you don't need if you are only building a REST API. Maybe this is the future of Rails?
The peepcode on Ember is really worth the $12, it's a great introduction. I really believe in what Ember is doing quite a bit.
As far as Ember vs. Backbone, it's like Rails vs. Sinatra: Backbone is 'easier' but then you have to write a ton of stuff yourself. Ember has more going on, but you write a lot less code.
But where Ember really shines is the way it deals with URIs and routing. I think it's super far ahead of other JS frameworks in this respect, and I hope routing.js sees some pickup.
I find that the ruby community tends to be fairly vibrant, passionate and innovative. I think the language lends itself to a creative way of thinking, and that shows in the projects that are created in it.
Blocks are amazing, and really clean up code for what is a very common usage pattern. I'm semi-offended by python because of the lack of what I deem to be an elegant equivalent. Not as offended as I am by perl or java, but I used to like those languages too. I detest the python string interpolation syntax - #{} is so much nicer. And I suspect that for other people these choices matter too.
Why weren't things like Sinatra, Sass, Less, Jekyll, Metasploit and Rails invented on another language? Other languages would be adequate for the task as you put it. Github is arguably the biggest thing to happen to open source in recent years.
As far as JS front ends/Rails go, I think we could get there one day and there are tradeoffs but you have a few problems with the model you propose; 1) Javascript sucks as a language 2) Server side rendering is always going to give you more control 3) accessibility is easier if you have a server side fallback.
"Best Practice" has always switched between centralised and decentralised throughout the history of IT. With Rails you can do both.
but more than any of that, ruby is simply the most productive language i've encountered for performing quick one-off tasks and exploring algorithms. it has all the strengths of perl (another language that plays very well in this particular niche), and adds very natural support for both object-oriented and functional approaches. i've used lots of languages (everything from basic to haskell) and ruby is almost unique in that i have never felt like i was fighting with the language to put my ideas into code. i think of the way i'd like to say something, and sure enough, ruby supports it and more often than not makes it easy and natural.
Of the three I think Ruby is the better language. I still like Perl though, so what do I know. :-)
I beg to differ, though I'm biased. Rails still offers a lot. https://github.com/rails-api/rails-api#why-use-rails-for-jso...
That's true for virtually anything. Do you think C/C++ or Java or JS will be mainstream 30 years from now. They will be in the same situation FORTRAN is today: important because of lots of legacy code, but not a viable choice when starting a new project.
Of course some of them will never die. LISP comes to my mind. :-)
Essentially every important piece of software today, from operating systems to programming language implementations to server software to applications, is written in one or both of them. All of these systems are not just going to go away.
C is over 40 years old, and C++ around 30, yet in that time nothing has come along that can compete with them. Some other languages have tried, but their success has only ever been partial, and typically in just one or two specific domains.
People still write new code these days in Fortran for scientific computation. Fortran compilers are still markedly better at optimizing numerics, multi-dimensional arrays, etc, partially because of the effort invested in the compilers and partially because the language is easier to optimize.
It's definitely a niche language.
Or, to put it another way, LISP was never alive to begin with.
If Ruby/Python had a community and third party libraries the size of LISP we would consider them mostly irrelevant languages.
And apparently "we" are using "irrelevant" to mean not fashionable. Or does it mean, "Do not use for new IT projects" or something? What does it matter what other people do, especially those with a strong (if small) community, frameworks, libraries, books, articles, conferences...
And where does Smalltalk fall? I hate to tell those people their language is "irrelevant" -- will their programs crash? And which LISP, by the way?
This irrelevance property is dumber than a language debate because we don't even debate them, we condemn them from the outside by applying our own arbitrary criteria. Why do we need to belittle the work of others? Maybe we are not as sure as we appear.
It matters because there is not enough of "community, frameworks, libraries, books, articles, conferences". If I want to do something in LISP there are 2-3 libraries in different states of broken and/or abandoned. In Python I can usually find something with much more ease. In Java even more so. The same for hiring programmers AND getting hired yourself, etc etc.
>And where does Smalltalk fall? I hate to tell those people their language is "irrelevant" -- will their programs crash?
You don't have to tell them. They know it already. It has been ever since most Smalltalk shops closed and the bigger ones turned over to supporting Java.
Now, people using Smalltalk to do hobby work, or even nice important work with paying customers, good for them.
Their programs will not crash (unless their Smalltalk platform of choice gets abandoned to die with too few contributors or is proprietary and doesn't get support for newer platforms and architectures). But they wont be getting as much new toys as the other boys.
>And which LISP, by the way?
All of them, inc. Common Lisp. Clojure might have a fighting chance, but it still is too small for people who value ecosystem over cowboy style "let's build all the wheels ourselves".
>This irrelevance property is dumber than a language debate because we don't even debate them, we condemn them from the outside by applying our own arbitrary criteria.
Irrelevant? It's very pragmatic. Number of available employers, employees, number of documentation, vibrancy of the ecosystem, new libraries and continuous support for older libraries, etc.
I would love to have a Smalltalk that is well supported to play with. One that is not aimed at kids and doesn't have a Fisher Price UI like Squeeze, and that can match Python or Java for ecosystem. Unfortunately none exists.