#​699 — April 18, 2024

Read on the Web

Together with  Memetria

Ruby Weekly

Prism in 2024 — Ruby 3.3 included a new standard library called Prism, a Ruby language parser that can be used internally by Ruby itself or as a library by your own code. It’s been a huge effort, and Kevin shares the full story of Ruby parsing (starting all the way back in 1994!) and how Prism is rapidly becoming a key part of the Ruby ecosystem.

Kevin Newton

Memetria: Secure, Scalable Redis Hosting — High performance Redis hosting with large key tracking, detailed metrics, and a superior uptime record.

Memetria sponsor

SQLite on Rails: The How and Why of Optimal Performance — Stephen is the person I look to when it comes to thinking about using SQLite in Ruby and Rails, and he’s been digging deep into the hows and whys of getting the best performance out of a SQLite + Rails setup. Here, he also covers some of the problems he’s stumbled upon (and solved) along the way.

Stephen Margheim

  • 💎 Gift Egwuenu has the latest RubyGems update for March 2024. Nothing huge, though gem install now respects the umask of the target system and the RubyGems team pulled off a major Postgres upgrade with no downtime. 👏

  • 📅 RailsConf 2024 is now less than a month away (May 7-9 in Detroit) and you can still register to attend. Elsewhere, Rails World takes place in September in Toronto and tickets are expected to be available very soon..

  • 🪙 RubyGems' Maciej Mensfeld writes about an odd surge of empty RubyGems related to some sort of crypto nonsense.

📄 Articles, Tutorials & Videos

A Reintroduction to Ruby's Heredocs — If you think you know everything you need to know about heredocs (essentially a syntax for multi-line strings), this article might throw up some surprises.

Brooke Kuhlmann

How I Read the Rails Source Code — How do you start reading the code for a codebase the size (and age) of Rails? Grab the debug gem (Rails includes it) and use Bundler to start your coding journey. You can use a similar approach for running all (or some) of Rails’ tests, too.

Akshay Khot

Need to Pay Down Tech Debt on a Budget? Let’s Talk 🚀 — Too many vulnerabilities? Too much tech debt slowing you down? FastRuby.io’s maintenance services start at $2,000/month.

Bonsai By FastRuby.io sponsor

▶  Implementing One Time Payments with Pay and StripePay is a gem that implements a payments engine for Rails and you can quite quickly integrate it with Stripe to get one-time payments in your apps. (39 minutes.)

Collin Jilbert

Making a (Sidekiq) Batch Recipe — If you have multiple jobs that can run concurrently, but you need to bring their individual outputs together, you can batch them and listen for callbacks, provided you’re a Sidekiq Pro user.

Kevin Murphy

📄 The Tale of an XSS in Phlex“I reported an XSS to Phlex yesterday and since it was pretty quickly fixed, I wrote a post about it.” Greg Molnar

📄 Hands-off Eclipse Photography with Ruby and Gphoto – This is a fun use case. Youssef Boulkaid

📄 Handling Exceptions in Grape for Ruby Kingsley Chijioke

📄 Active Record's Transaction Callbacks Greg Molnar

🛠 Code & Tools

sqlite3-ruby 2.0: The Popular Ruby SQLite Driver — As implied by the version number, this is a major release and, notably, drops support for Ruby 2.7. Native gems are now shipped for 11 platforms, newly including an array of Musl-based Linux ones. It now runs SQLite 3.45.3 and there are numerous smaller improvements.

Sparkle Motion

Gemfast: A Drop-in Replacement for Geminabox — A new self-hosted Rubygems server written in Go, so it can be compiled down a single file and easily deployed on multiple operating systems. You can mirror and cache gems from the main RubyGems registry, as well as serve up your own internal gems, of course.

Gemfast

APM Deployment That Isn’t Painful and Is Free - Try Scout Monitoring — Renaissance developers, rejoice. One gem, five minutes to performance insights. No DevOps team required.

Scout Monitoring sponsor

Zammad 6.3: A Web-Based Open Source Customer Support System — A long standing, full scale Rails app (currently on Rails 7.0) that we first linked to seven years ago! If you need an app to handle an influx of emails for management by a team of agents, this is for you. Screenshots.

Zammad

Along similar lines is Chatwoot, an open source live chat and email support app, also built on Rails 7.0. v3.8.0 dropped this week.

validates_email_format_of: Validate Email Addresses Against RFC 2822 and RFC 3696“This gem is the O.G. email validation gem for Rails.” It can now validate email addresses using internationalized domain names too.

Alex Dunae