#​617 — August 25, 2022

Read on the Web 🇺🇦

In case you missed my note in the last issue, we took a week off last week, but we're now back until Christmas.. just 122 days to go, not that we're counting ;-)
Peter Cooper, your editor.

Ruby Weekly

syntax_suggest Joins Ruby 3.2's Standard Library — Formerly known as DeadEnd and focused on finding 'dangling' end keywords, SyntaxSuggest is now part of Ruby 3.2 (🐦 as announced by Hiroshi Shibata on Twitter) (due in its final form in December) and will find missing keywords, missing pair characters, and other syntax problems. This Ruby issue tracker thread tells the whole story.

Ruby Project

▶  Debugging Rails Apps with Visual Studio Code — Ruby 3.1 included a new, powerful debugging gem and one benefit it introduced is being able to integrate with editors like VS Code. In this 20 minute screencast, Justin shows how to use debug.gem along with VS Code to work on a Rails 7 app.

Justin Searls

Is Your App’s Heart Beating? 💓 — Remember when your monthly backup failed, or when those customers didn't get billed? How did you find out? Our heartbeat feature monitors critical tasks, so that you'll never miss another silent failure. When Honeybadger is quiet, life is good.

Honeybadger sponsor

Requiring MFA for Popular Gem Maintainers — We first mentioned the RubyGems project’s intentions around making the gem supply chain more secure a couple of months ago and multi factor authentication is now being enforced on owners of gems with over 180 million total downloads. This policy is sure to expand over time, so if you’re able to adopt MFA for your own RubyGems account, it’s worth looking into.

Jenny Shen (RubyGems)

Quick Bits:

📖 Articles, Stories & Videos

Effective Queries with Rails and Postgres — If you’re not 'into' databases enough to be noodling on optimizing queries and tweaking schemas as a matter of course, this is for you. Pavel gives some tips on index types and basic principles to apply to keep things running quickly.

Pavel Tkachenko

An Introduction to Ractors‘Ractors’ (once known as ‘guilds’) turned up in Ruby 3 as a new actor-based concurrency mechanism. If you’ve not played with them yet, this is a comprehensive introductory post where you learn how to create them and the rules for sharing (and not sharing) objects.

Abiodun Olowode (AppSignal Blog)

What Happens in Ruby on Class Instantiation — Did you know you could hack instantiation? I’ve never found a use for the allocate approach myself (though Gregory Brown explains one here) but it’s worth knowing about its existence just in case!

Emmanuel Hayford

Migrating Postgres from Heroku: A Customer Study on Crunchy Bridge

Crunchy Data sponsor

Validating YAML Files in Ruby — A practical look at using dry-schema.

Harisankar P S

Visitor Pattern in Ruby: Examples from Rubocop — Learning about patterns is all well and good, but seeing how real code applies (and tweaks) a pattern can be much more instructive.

Nick Wasabigeek

Thinking in Hotwire: Progressive Enhancement — Matt explains how your mental model for Hotwire should be progressive enhancement: start with the basics and then layer on Turbo Frames, Streams, and Stimulus as you build out.

Matt Swanson

Rails 7's Beginless Range Support on In-/Ex-clusivity Validations — For example: validates_inclusion_of :price, in: ..5000

Murtaza Bagwala

Fetching the 'Top n Per Group' with SQL Window Functions
Benito Serna

🛠 Code & Tools

ActiveRecordExtended 3.0: Add Extended Postgres Functionality to Ruby and Rails Apps — Introduces support for things like array value overlaps, network address manipulation, window functions, and some JSON and HSTORE operators into Active Record.

George Protacio-Karaszi

Que 2.0: A Ruby Job Queue Using Postgres's Advisory Locks — A perfect use for Postgres’s built in advisory locking mechanism for more reliable job queue functionality. If you already use Que 1.x, note the upgrade process necessary.

Chris Hanks

Don’t Let Your Issue Tracker Be a Four-Letter Word. Use Shortcut — The best issue tracking software is one that software developers are actually happy to use.

Shortcut (formerly Clubhouse.io) sponsor

Ruby 2D: A Simple Cross Platform 2D App Library — A mature project though still slightly under the radar and deserving of more attention – you get graphics, audio, and input device support, and getting started is very easy. GitHub repo.

Tom Black et al.

▶️ If you want to actually build a game, Mario Visic has this neat Ruby2D screencast series to follow along with.

Sequenced 4.0: Generate Scoped Sequential IDs for Active Record Models — The sequential ID is not a replacement for the usual primary key, but adds another way to retrieve the object without exposing the primary key.

Derrick Reimer

JRuby Released — The Ruby 2.6.x compatible JVM-based Ruby implementation.

JRuby Team

Ruby OAuth 1.0: OAuth 1.0 Client and Server Library“Please upgrade to version 1.0. The only breaking change in 1.0 is dropping old Rubies.”
Cook, Halff, Braendgaard, Boling, et al.

React on Rails 13.1: Bringing React, Webpack, and Rails Together with Webpacker


redis-rb 4.8 – Redis client library. (Adds sadd? and srem?)
MockRedis 0.33 – Mock Redis gem for testing against.
Resque 2.3 – Redis-backed background jobs.
Elasticsearch.rb 8.4 – Ruby integrations for Elasticsearch.
Stripe Ruby 7.1 – Ruby library for the Stripe API.
StoreModel 1.2 – JSON-backed attributes in ActiveRecord-ish style.
Gruff 0.19 – Long standing basic charting library.
Good Job 3.4.4 – Multithreaded, Postgres-based, ActiveJob backend.
Puma 5.6.5
Sidekiq 6.5.5
Hanami 2.0.0 beta 2


Senior Ruby on Rails Backend Engineer - Integrations — Are you a self-starter looking to learn and grow? We are hiring around the world to strengthen our rapid growth. Join our journey.

Senior Backend Engineer-Ruby on Rails (Remote-United States) — Health tech startup looking for Senior ROR Engineers. Help us build a sustainable future for healthcare professionals.

Find Ruby Jobs Through Hired — Create a profile on Hired to connect with hiring managers at growing startups and Fortune 500 companies. It's free for job-seekers.