Live data from Hacker News

Where is Ruby Headed in 2021?

bignerdranch.com

311–320 of 360 posts

Re: Where is Ruby Headed in 2021?

#311

Earlier quoted context omitted.

I wonder why Crystal is not more popular today that it reached 1.X, as you say, it fixes some important Ruby issues but most importantly it also fixes Elixir's weaker points.

I can't comment on the Elixir stuff since I haven't really touched it at all yet (only ever seen one job opening in hundreds over 5+ years mentioning Elixir - only one, total!). But I have a theory on the rest... I think the actual reason why it's not more popular is something I personally call "The Tyranny of the Masses". In short, what's popular/flavor-of-the-month is automatically "right", and everything else is a…

It isn't complicated. Crystal doesn't work on Windows. If elixir ecosystem is small, Crystal is 10 times smaller. Unless there is an active community that decide to do the grind and fill in all the missing pieces. Crystal may remain a niche in the foreseeable future.

Re: Where is Ruby Headed in 2021?

#312

Earlier quoted context omitted.

The best features about this bridge are that it's made out of soap bubbles and it doesn't necessarily span the river at any given time. This flexibility is wonderful.

That is not a good metaphor for anything, really: no-one was enlightened; at best some reddit-grade snark was conveyed.

I worked with Ruby for two years. The metaphor is apt when considering software development as an engineering discipline. It was certainly not meant as snark. You disagree, that's fine.

Re: Where is Ruby Headed in 2021?

#313

Earlier quoted context omitted.

I've worked with Java, Ruby and Python but I don't get your point. Can you recommend any resource to help understand what you mean? Or maybe some short examples in Python and Ruby that would highlight how implicit imports allow solving problems in a way that explicit imports prevent?

Not the parent, but I’ve found Sandi Metz conference talks to be an amazing resource for learning more about this message focused approach.

But back to the original point, Sandi Metz wouldn't suggest that implicit imports are good.

Re: Where is Ruby Headed in 2021?

#314

Earlier quoted context omitted.

Ok, but Objective-C also does messages and most of them are defined statically and can be easily searched for in a codebase. I’m not saying Ruby needs header files to send messages to something, but being able to figure out where the code for something is isn’t off the table for languages with dynamic dispatch and it can come in handy.

For that, there's object.method(:name).source object.method(:name).source_location but frankly this is still thinking in a rigid mindset that suits other languages better. Ruby isn't just "dynamic dispatch"; a typical metaprogramming technique handles all incoming calls without named methods, or by dynamically writing the code. To put it bluntly, assuming there's a method on the other side of your message, is practic…

Yeah this is pretty much why I decided I didn't want to write Ruby anymore. You may be right that this is the philosophy of the language, but if it introduces a speed bump or cognitive overhead when trying to understand what a snippet of code is doing (and I contend that "there might not even be a method there responding to your message" is a speed bump), then it's not a good thing, even if it's clever and somehow ideologically pure and interesting. I can appreciate programming languages as art pieces, but when I'm at work I want them to just be a tool.

Re: Where is Ruby Headed in 2021?

#315

Earlier quoted context omitted.

The often impossibility of finding the definition of the methods I'm calling is the main thing that soured me on Rails. I think a more explicit style is more common nowadays, which is a good thing.

“git grep” is pretty amazing for tracking things down.

I did that for many years, then I switched to languages with good static analysis and felt really silly about how many years I had wasted wandering around in darkness.

Re: Where is Ruby Headed in 2021?

#316
post #266

Earlier quoted context omitted.

Well, no, not really. It is more of the equivalent of showing how to read (or where to find) maps instead of pointing out something on one. If the searcher is in a hurry the latter is more helpful, otherwise the former is preferable.

Yeah, but you shouldn't need git grep to find out what something is. I understand using to find out why it's there, but not what it is.

Yeah the problem is that grep understands lines of text but not the structure of code. But code should be understandable by a computer program (by definition it has to be at some point) so you should be able to use a tool that understands the structure of the code it's reading rather than just seeing a bunch of lines of text.

Re: Where is Ruby Headed in 2021?

#317

Earlier quoted context omitted.

The often impossibility of finding the definition of the methods I'm calling is the main thing that soured me on Rails. I think a more explicit style is more common nowadays, which is a good thing.

Would a Ruby IDE be able to figure it out?

RubyMine was impressive (because it's a hard problem) but still hit or miss when I was writing Ruby about 5 years ago. It may very well have improved a lot since then!

Re: Where is Ruby Headed in 2021?

#318

Earlier quoted context omitted.

> Honestly I don't get why some people want to move to static types I don't understand how anyone that has experience with dynamically typed languages and the insane runtime errors that can result from them would ever consider using a dynamically typed language. It's terrible and it actually provides little to no benefit in development speed. People always say development is faster in a dynamically typed language, th…

>Given the popularity of typescript and how nearly all major internet companies have moved to typed versions of their dynamically typed languages it's clear to me the whole dynamic typing experiment has failed absolutely miserably. Python is one of the most popular programming languages.

And they added types to it

Re: Where is Ruby Headed in 2021?

#319

Earlier quoted context omitted.

> I’ve tried python, but I end up having to deal with the mess of importing modules Without those imports, how will people reading the code find the definitions? How will they track down the source code for all the methods being called? If the answer is "with an IDE / tools", then can't those same tools be used to solve the "mess of importing modules"? If you're using a good IDE, imports and go-to-definition are both…

The often impossibility of finding the definition of the methods I'm calling is the main thing that soured me on Rails. I think a more explicit style is more common nowadays, which is a good thing.

You need to be using RubyMine. Simply command-click on ANYTHING to jump to the definition, even if it's nested deep in a gem that your project uses.

RubyMine, and the "jump to definition" feature in particular, is the primary thing that enabled me to really "get" Ruby and finally understand how everything worked together.

Re: Where is Ruby Headed in 2021?

#320

Earlier quoted context omitted.

Why is JS one of the worst languages ever designed? I've used many languages and JS is one of the better designed ones in my opinion.

There is the kernel of a nice idea in JS but so many bad early design decisions can never be walked back.

I would argue that TypeScript does yeoman's work in doing much of that walking back.

I plumb forgot that assigning a variable without `var` or `let` put it in the global scope because TypeScript yells at you for it.

Post reply on HN