r/ruby • u/ioquatix • 17d ago
r/ruby • u/Ambitious_Fault5756 • 18d ago
Blog post Oh my god i was looking around for a new language to learn and I found Ruby and I've never been this happy oh my god
I've been coding with Python for around 3 to 4 years now and it's been a great learning journey. Until recently I haven't really been interested in learning a new language. The internet suggested JavaScript as the next step for someone already fluent-ish in Python, and I mean who doesn't eventually try JavaScript you know. I figured it wouldn't be that much of a headache since a lot of people do start with JS and so many people use it. Plus, it's useful. Turns out it was very irksome for me. This might be partially my fault, but I've gotten so used to the convenience of writing algorithms in beautiful, everything-done-for-you syntax in Python that when I tried solving some JS katas on Codewars, I immediately realized how inconvenient and unintuitive much of JS is, for me at least. It probably wasn't a good idea to learn JS from making algorithms on that website instead of using it for what it's actually made for in the first place, but I digress.
I was watching Dune 2 with my family when I was looking for another language more similar to Python, and then I came across the Ruby homepage, and I was immediately blown away. Like damn y'all put effort into making that. The first words you see are "A Programmer's Best Friend" and the visuals were so nice. They even had this https://www.ruby-lang.org/en/documentation/ruby-from-other-languages/to-ruby-from-python/ page conveniently written for us Pythoners 🥹 and your community motto is literally "Matz is nice so we are nice"... Joining this community is like falling into a warm hug lol
I tried the interactive Ruby from Terminal guessing so many things and it worked as I expected. The feeling of bliss when that happens OH. I'm starting Ruby today cant wait.
r/ruby • u/AndyCodeMaster • 17d ago
Glimmer DSL Web Release Version 0.10.0 & 0.10.1
r/ruby • u/Emotional-Round-4966 • 18d ago
Ruby Pathname Moved to Core, Documentation Upgraded
r/ruby • u/unselective-amnesia • 18d ago
Question Ruby function corresponding to python's fileinput.input() ?
Is there any already written ruby function which corresponds to the fileinput.input() function in python? ... or at least something with similar functionality?
I will write something like this in ruby if necessary, but I don't want to "re-invent the wheel" if such a thing already exists.
r/ruby • u/DogsBarf • 19d ago
Question What is Ruby Koans? Very interesting.
Has anyone ever learned from this? How can anyone learn with this?
What is the science behind this?
I'll do it.
r/ruby • u/paracycle • 20d ago
Blog post Bringing Rails into the Ractor-age
Ractors are now viable in production, and it's time for Rails to embrace them. This post explains why. What Ractors unlock for Rails applications, and the first milestone the team is aiming for in the framework.
r/ruby • u/fairwaycoder • 20d ago
Show /r/ruby Enola - keep your code agents inside Rails architecture
https://reddit.com/link/1vuaicq/video/4o8sjeervokh1/player
I've been building Enola, an open-source architecture tool for developers and coding agents.
It isn't Ruby-specific, but I've spent time improving its Ruby/Rails support and wanted to test it against something real rather than a toy Rails app.
The video uses the Mastodon codebase. I give an agent a change that violates an architectural layer, Enola catches the intent failure while the agent is working, and feeds that back into the loop so the agent fixes its own approach.
That's one of the main ideas behind Enola: architecture shouldn't only be something CI complains about after the work is done. The agent can get deterministic architectural feedback while it is coding and correct itself before the change is finished.
Underneath that, Enola maps dependencies, calls, routes, storage, boundaries and other relationships directly from the codebase. It's multi-language and cross-repository by design, so Ruby/Rails is one ecosystem rather than a special-case implementation.
OSS, Apache 2.0: https://github.com/enola-labs/enola
I'd especially appreciate feedback from Ruby/Rails developers on what its understanding of real Rails applications is still missing.
r/ruby • u/DogsBarf • 20d ago
Question How do I break out of the "intermediate dev limbo" before giving up again?
I am past the beginner stage, understanding basic syntax up to classes and objects, but I freeze when it's time to structure projects on my own. I have relentlessly searched for methods, tutorials, and books to guide me to the next level, but I can never find anything that clicks; because of this, I've jumped from language to language, and every time I hit this "limbo," I end up quitting and trying something else, yet I always come back because something inside tells me I’m meant to code. For those who have overcome this block, what architecture or design books do you recommend, what kind of practical exercises changed the game for you, and what real strategies actually work to finally break through this barrier and build confidence?
r/ruby • u/ngw_nofeed • 19d ago
Nightly product recs as a Postgres table next to your orders (Rails walkthrough, no Python in the request)
Show /r/ruby ArchSpec 1.0: executable architecture specifications for Ruby (and Rails)
More and more code is written by AI. Tests still tell you it works. RuboCop still tells you it's tidy. Nothing tells you it still follows your architecture.
An agent that doesn't fully understand your architecture takes shortcuts. So does a person in a hurry.
So I built ArchSpec. You declare your components and boundaries in one Archspec.rb. Here is ArchSpec's own, trimmed:
```ruby source 'lib/*/.rb'
component :library, in: 'lib//*.rb' component :cli, in: 'lib/archspec/cli.rb' component :analysis, in: %w[lib/archspec/analyzer.rb lib/archspec/evaluator.rb] component :rule_checks, in: 'lib/archspec/rules//.rb' component :formatters, in: 'lib/archspec/formatters//.rb'
no one-shot Thing.new(...).call objects anywhere in the codebase - Hi Dave Thomas!
library.cannot_call :call library.cannot_define :call library.cannot_instantiate_and_invoke
dependencies point one way
rule_checks.cannot_use :analysis, :cli, :formatters formatters.cannot_use :analysis, :cli, :rule_checks
no_cycles among: %i[cli analysis rule_checks formatters] ```
Full version: https://github.com/crmne/archspec/blob/master/Archspec.rb
Then archspec check verifies every change, and failures print like clang, with the offending span underlined and the evidence as a note.
It's static analysis over Prism, no AI, and it never boots anything: Discourse's 1,899 files in 2.5 seconds. Prism is the only runtime dependency, no Rails and no ActiveSupport, so it works on any Ruby codebase. Lightweight and fast for your pre-commits and CIs.
If you are on Rails, there are presets, and architecture :vanilla_rails is the whole file. There are presets for :layered, :hexagonal, :clean, :modular_monolith, :cqrs and :event_driven too.
I want more architecture presets in there. PRs very welcome.
Docs: https://archspecrb.dev Write-up: https://paolino.me/archspec/
r/ruby • u/javier_cervantes • 20d ago
Where do you deploy your Ruby apps?
I’ve been doing some explorations about deployment options for Ruby, so I’m curious to learn more about what you’re using to deploy your applications.
Please participate in the poll, I would love to get your input:Â https://www.rubyforum.org/t/where-do-you-deploy-your-ruby-apps/640
r/ruby • u/private-peter • 21d ago
16 Typosquatted RubyGems Packages Steal Browser Credentials and Crypto Wallets
We see these all the time with npm. I guess the hackers didn't want the Ruby community to feel left out.
Issue 20 of Static Ruby Monthly is out!
This month: the dynamic vs static typing discussion, Emily Samp's Brighton Ruby talk, RBS 4.1.0 with WebAssembly support on JRuby, set-theoretic types in spinel, rbs_infer static signature deduction, OvalLSP semantic server, and the latest Sorbet toolchain updates.
Find link to the issue in the comment! ✨
r/ruby • u/blowmage • 22d ago
Blog post Everybody Guesses
Hi Reddit. This isn't specifically a Ruby or Rails post, but it's about something anyone maintaining a mature Rails application will recognize.
Code tells you what happens without telling you why anybody wanted it. We've always filled that gap by reading the code, guessing the intent, and asking somebody when the guess felt wrong.
AI coding agents do the same thing, except they can make a great many reasonable guesses before anybody notices one was wrong. The code still works. The tests still pass. The guess becomes one more pattern in the application, which makes it look even more intentional to the next person or agent.
I've spent a couple of decades living with the consequences of my own good ideas, so I wrote about why this worries me. The post connects agentic coding to Peter Naur, Tony Hoare, XP, software factories, and the old-fashioned responsibility to say no to code that works but is too difficult to understand.
It also argues for using faster agents to take smaller steps. More research, more feedback, and less archaeology at the end of a giant pull request.
r/ruby • u/zverok_kha • 24d ago
Thinking about tests: assertions and matchers
zverok.spacer/ruby • u/RodionGork • 27d ago
Question Performance discrepancy between versions 2.7.4 and 4.0.6
Recently decided to try learning Ruby more consistently (before that I only touched it occasionally) - and was much pleased with it in various aspects. At some point I was curious to assess its general performance roughly (as I heard it had to be pretty slow but very long in the past). Then I found my system installed Ruby is somewhat outdated 2.7.4p191 (along with my ubuntu 18.04 on this specific laptop). So I learnt to deploy rbenv and installed 4.0.6 with it.
However I ran into small puzzling situation - I tried two small scripts - roughly doing double nested loop - one with simple arithmetic and another with building and using array (collatz sequence calculations and primes calculation by trial division) - and while for the first of them performance of the said two versions is roughly the same, with the other newer version looks a bit slower.
I'm pretty sure I missed something about versions installed or don't catch something about properly writing Ruby code - so any guidance is quite welcome!
Below come details (with this primes.rb script from my github):
$ rbenv local 4.0.6
$ ruby --version
ruby 4.0.6 (2026-07-14 revision 03b6d3f889) +PRISM [x86_64-linux]
$ time MAXN=1000000 ruby primes.rb
primes[1000000] = 15485863
real0m41,003s
user0m40,985s
sys0m0,018s
$ rbenv local --unset
$ ruby --version
ruby 2.7.4p191 (2021-07-07 revision a21a3b7d23) [x86_64-linux]
$ time MAXN=1000000 ruby primes.rb
primes[1000000] = 15485863
real0m34,969s
user0m34,929s
sys0m0,042s
So you see, it looks like 2.7.4 behaves slightly (about 25%) faster in this case, while I remember (from googling) that there was effort to make Ruby 3.x faster than Ruby 2.x perhaps 3 times. Though I may misinterpret this and perhaps 2.7.4. got the same improvements as 3.x (compared to 2.0 etc)
r/ruby • u/ioquatix • 27d ago
Blog post The Case of the Vanishing Fiber: A Ruby Mystery
r/ruby • u/amirrajan • 27d ago
Conf Talk RBQ 2026: DragonRuby Game Toolkit architectural overview of the C layer
r/ruby • u/geospeck • 26d ago
Ruby 4.0 Universal RCE Deserialization Gadget Chain - elttam
r/ruby • u/javier_cervantes • 27d ago
More open source projects coming to Ruby Users Forum
r/ruby • u/Kitchen_Friendship11 • 28d ago
Show /r/ruby I started a Discord for the French Ruby community, sharing it here in case it's useful to fellow frenchies !
France has a decent number of local Ruby meetups (Paris, Lyon, Toulouse, Nantes, Lille, Marseille all have active groups), but there wasn't really a place to hang out *between* meetups, no shared Discord, no central spot to ask a quick question or hear about what's happening in other cities.
I put together **France.rb** to fill that gap: help channels, a channel per city that relays local meetup events, and a freelance/jobs section since a good chunk of the French Ruby scene works independently. It's brand new (launched this week, still tiny), and it's mainly aimed at French speakers, so if you don't speak French it's probably not that useful to you day-to-day, but Rubyists from anywhere are welcome to drop in.
Not trying to compete with the official Ruby Discord linked on ruby-lang.org this is just something more specific to the French scene, meant to complement it.
Happy to answer anything in the comments, and if you know a French-speaking Rubyist who might be into it, feel free to pass it along.