Short Ruby Newsletter

Share this post

Short Ruby News - Edition #59

newsletter.shortruby.com

Discover more from Short Ruby Newsletter

A Monday summary of the articles, discussions, and news from the Ruby community
Over 3,000 subscribers
Continue reading
Sign in

Short Ruby News - Edition #59

Discover the world of Ruby in this comprehensive newsletter covering week 36 of 2023. Find code samples, community updates, gems, resources, and thought-provoking discussions.

Lucian Ghinda (from ShortRuby)
Sep 18, 2023
1
Share this post

Short Ruby News - Edition #59

newsletter.shortruby.com
Share

You can jump directly to a section:

πŸš€New Products & πŸ“… Events

πŸ‘‰Β All about Code and Ruby

🧰 Gems, Libraries, and Updates

🀝 Related (but not Ruby-specific)

More content: πŸ“š πŸ—ž 🎧 πŸŽ₯ ✍🏾 (articles, podcasts, videos, newsletters)


[Sponsor⬇]

Visit try.revelo.com/tech-vetting
Stop spending countless hours screening developers! Create tech assessments in seconds and learn who the best candidate is through Revelo AI-powered insights. 100% free.

πŸš€ New Products

πŸš€ Ruby Cademy announced they launched a new course on Rubycademy:

Source: @RubyCademy (read on nitter)

πŸš€ Jason Swett launched a new section Let's talk - Code with Jason where he invites us to a talk:

I always enjoy meeting my fellow programmers. I’d love to have a call with you to get to know you. If that sounds fun to you, fill out the form below.

Source: @JasonSwett (read on nitter)

πŸš€ Luke launched Markie

Source: @lc_ancez (read on nitter)

πŸš€ Miguel Michelson announced the open source version of rauversion/rauversion-ror: Self hosted music industries

Source: @michelson (read on nitter)

πŸ“… Events

πŸ“… Sergy Sergyenko shared that people can ask questions and the most liked one will be answered by Matz at Euruko:

Source: @sergyenko (read on nitter)

πŸ“…Fukuoka Ruby shared FUKUOKA Ruby Award 2024 - 福岑県Rubyγƒ»γ‚³γƒ³γƒ†γƒ³γƒ„γƒ“γ‚Έγƒγ‚ΉζŒ―θˆˆδΌšθ­°

Source: @Fukuoka_Ruby (read on nitter)

πŸ‘‰ All about Code and Ruby

πŸ‘‰ Emmanuel Hayford shared a tip about Rails 7.1 enum validation:


[Promo Content⬇]

visit try.revelo.com/tech-vetting
πŸ‘¨β€βœˆοΈCandidates' skills testing on autopilot - let Revelo guide you through it!

πŸ‘‰ Kirill Shevchenko shared about how using module in Ruby simulates multiple inheritance:

Source: @kirill_shevch (read on nitter)

πŸ‘‰ Ruby For Good shared that the majority of UK Government websites are built with Ruby on Rails β†’ Conventions for Rails applications - GOV.UK Developer Documentation

πŸ‘‰ Chris Oliver shared a tip about Rails 7.1 normalize:

Source: @excid3 (read on nitter)

πŸ‘‰ David Heinemeier Hansson shared a post about companies using Ruby on Rails that generated a lot of conversations about which company uses or not:

Source: @dhh (read on nitter)

I am going to include some replies here but I think if you want to get a better image of the discussion, you should read yourself the replies (read on nitter) and the quotes:

Source: @mscccc (read on nitter)
Source: @ciaran_lee (read on nitter)
Source: @ciaran_lee (read on nitter)
Source: @DakotaChambers (read on nitter)
Source: @schleyfox (read on nitter)
Source: @mjackson (read on nitter)
Source: @spikebrehm (read on nitter)
Source: @mjackson (read on nitter)
Source: @dnstevenson (read on nitter)
Source: @DakotaChambers (read on nitter)
Source: @alexjackhughes (read on nitter)
Source: @hopsoft (read on nitter)
Source: @theshroy (read on nitter)
Source: @rstankov (read on nitter)
Source: @hopsoft (read on nitter)
Source: @oldmoe (read on nitter)
Source: @SebastianSzturo (read on nitter)
Source: @mikejohnsdotcom (read on nitter)
Source: @GregMolnar (read on nitter)
Source: @tonysmdev (read on nitter)

πŸ‘‰ Julian Rubisch shared a new challenge for Hotwire Club Challenge 11: Turbo Frames - Scroll Position Restoration | Patreon

Source: @julian_rubisch (read on nitter)

πŸ‘‰ Vincent Rolea shared a tip about rendering partials within a partial layout:

Source: @vincentrolea (read on nitter)

[job ad from this edition partner Revelo.com]  

πŸš€ [Remote][Latin America] Get a full-time, long-term remote job and a dollar salary in amazing US tech companies.  Apply atΒ careers.revelo.com

Apply to Revelo


πŸ‘‰ Rob Zolkos shared a tip about rendering a different view template if the user is on a phone or other devices:

Source: @robzolkos (read on nitter)

Pleasesider becoming ad subscriber to support this newsletter and you will receive an ad-free version. Your contribution aids growth and maintains the quality of ShortRuby for everybody:

πŸ‘‰ Scott Watermasysk asked about how people are managing comments that specify when the code can be cleanup:

Source: @Scottw@ruby.social

Among the possible solutions it was suggested to use normal TODOs and manage them with bin/rails notes or add the events in a shared calendar or use the gem todo_or_die. Here an alternative solution by Petrik De Heus:

Source: @p8@ruby.social

πŸ‘‰ Noel Rappin shared an update about the Programming Ruby 3.2 book:

Source: @noelrap@ruby.social

πŸ‘‰ Pragmatic Bookshelf shared an update for the book High Performance PostgreSQL for Rails

Source: @pragprog@ruby.social

πŸ‘‰Joel Drapper shared that feedbin is using Phlex β€” Fast, Object Oriented View Framework For Ruby

Source: @joeldrapper@ruby.social

πŸ‘‰ Agnieszka MaΕ‚aszkiewicz shared their slides from Wrocloverb about Ruby Rendezvous: Method Call, Proc, and Beyond

Source: @womanonrails (read on nitter)

πŸ‘‰ William Kennedy shared they noticed a few commits about Strada:

Source: @_williamkennedy (read on nitter)

πŸ‘‰ Jeanro announced that on Ruby on Rails Jobs - France et Europe all Junior profiles can be seen for free:

Source: @jeanrokr (read on nitter)

πŸ‘‰ Leandro shared about how timestamps in Ruby work depending on the platform:

Source: @leandroico (read on nitter)

πŸ‘‰ Gabriel shared how SQlite can be used to merge CSV files faster:

Source: @GabrielChuan (read on nitter)

πŸ‘‰ Mohammad A. Ali shared a post about more simplicity being needed in Rails:

Source: @oldmoe (read on nitter)

πŸ‘‰ Stephen Margheim shared a checklist to see if you should use SQLite or not with Rails:

Source: @fractaledmind (read on nitter)

πŸ‘‰ Brad Gessler shared about Sitepress performance

Source: @bradgessler (read on nitter)

πŸ‘‰ Matt Swanson shared about when the rule of not having data changes in migrations would contradict the actual way deploys are happening:

Source: @_swanson (read on nitter)

πŸ‘‰ Nate Berkopec shared a tip about web performance:

Source: @nateberkopec (read on nitter)

πŸ‘‰ Matt Swanson shared a code sample about CurrentAttributes:

πŸ‘‰ Greg Navis shared a thread about Ruby Heredocs:

Source: @gregnavis (read on nitter)

πŸ‘‰ Rafael FranΓ§a shared Development containers

Source: @rafaelfranca (read on nitter)

πŸ‘‰ Fast Ruby.Io shared a tip about providing column type in migrations:

Source: @fastrubyio (read on nitter)

πŸ‘‰ Ruby Cademy shared a tip about dependency injection:

Source: @RubyCademy (read on nitter)

πŸ‘‰ Rob Zolkos shared that reading the logs is important:

Source: @robzolkos (read on nitter)

πŸ‘‰ Josef Strzibny shared about the number of contributions for Rails:

Source: @strzibnyj (read on nitter)

🧰 Gems, Libraries, Tools and Updates

🧰 Postmodern announced that Ruby 3.3.0-preview2 is available on ruby-install:

Source: @postmodern@ruby.social

🧰 Hiroshi Shibata announced a new release for ruby-build 20230914 · rbenv/ruby-build

Source: https://github.com/rbenv/ruby-build/releases/tag/v20230914

🧰 Ruby on Rails announced the release of Rails 7.1.0.beta1:

There are some posts about this but you will find many more in this newsletter:

  • Go Rails published a video about Rails 7.1 Authentication From Scratch (Example)

  • Deepak Mahakale published a new article about What’s new in Rails 7.1

  • Rashmi published a new article about Rails 7.1 - authenticated_by

  • Emanuel Hayford published a series of articles about Rails 7.1: Part I, Part II, Part III

🧰 Mike Perham shared a new version for Sidekiq, read the release notes for Sidekiq, Sidekiq Pro and Sidekiq Enterprise:

Source: @getajobmike@ruby.social

🧰 Avo announced a new release for both Avo 2 and Avo 3:

🧰 Jason Meller submitted a PR that has been merged β†’ Add Bun support by terracatta Β· Pull Request #49241 Β· rails/rails

Source: https://github.com/rails/rails/pull/49241

🧰 Maciej Mensfeld announced they released the UI for karafka

Source: @maciejmensfeld (read on nitter)

🧰 Nicolas Buduroi shared they discovered a new gem trace_location: πŸ”Help you get reading the huge open souce libraries in Ruby and trace its source locations

Source: https://github.com/yhirano55/trace_location

πŸ†•πŸ§° Dmitry Tsepelev announced a gem called β€œrubocop_director”, read more about how to use it to refactor in this article:

Source: https://github.com/DmitryTsepelev/rubocop_director

🧰 Vinicius Stock announced a new version for Release v0.10.0 · Shopify/ruby-lsp

Source: @vinistock (read on nitter)

🧰 Bozhidar Batsov shared Release RuboCop 1.56.3 · rubocop/rubocop

Source: @bbatsov (read on nitter)

🧰 Donal McBreen submitted a PR that was merged to Kamal Asset Paths By Djmb · Pull Request #449

Source: https://github.com/basecamp/kamal/pull/449

🧰 Yuichiro Kaneko announced a new version of lrama Release v0.5.6 · ruby/lrama

Source: https://github.com/ruby/lrama/releases/tag/v0.5.6

πŸ†•πŸ§° Jeremiah Parrack published a new gem revise_auth-jets - A pure Ruby on Jets authentication system like Devise

Source: https://github.com/jeremiahlukus/revise_auth-jets

🧰 Chris Oliver announced that Jumpstart Pro now runs on Rails 7.1:

Source: @excid3 (read on nitter)

🧰 Jeremy Evans announced a new version for Tilt β†’ Tilt 2.3.0 Released Β· jeremyevans tilt Β· Discussion #9

Source: @jeremyevans0 (read on nitter)

🧰 Espen shared that we need to upgrade ImageMagick due to a security issue Security: shell escape using ghostscript · Issue #4172 · ImageMagick/ImageMagick (see instructions about how to override ImageMagick settings)

Source: @Espen_Antonsen (read on nitter)

🧰 Kevin Newton announced a new version for YARP β†’ Release v0.12.0 Β· ruby/yarp

Source: @kddnewton (read on nitter)

🧰 Greg Molnar shared a PR for Rails about Ignore env files (except templates) by dhh · Pull Request #49278 · rails/rails

Source: @GregMolnar (read on nitter)

🧰 Brad Gessler shared PR for dockerfile-rails about Generates a Dockerfile for a sqlite production environment if Litestack is present

Source: @bradgessler (read on nitter)

🀝 Related (but not Ruby-specific)

🀝 Samuel Williams asked about 101 HTTP status code:

Source: @ioquatix (read on nitter)

and Roy T. Fielding answered:

Source: @fielding (read on nitter)

🀝 John Nunemaker shared a PostgreSQL code sample about calculating distance between two strings (see the gist here or documentation at F.17. fuzzystrmatch):

Source: @jnunemaker@ruby.social

🀝 Adam Wathan shared about the importance of being part of a group:

Source: @adamwathan (read on nitter)

🀝 Nate Berkopec shared about scaling

Source: @nateberkopec (read on nitter)

More content: πŸ“š πŸ—ž 🎧 πŸŽ₯ ✍🏾

πŸ—ž Newsletters

πŸ—ž Andy Croll published a new One Ruby Thing β†’ Express yourself clearly with positive? and negative? for numbers

πŸ—ž Greg Molnar published a new edition about This Week in Rails: 7.1 beta release, Bun support and more!

πŸ—ž Ruby Weekly published an article about A Ruby 3.3 preview and Rails 7.1 beta

πŸ—ž Awesome Ruby Newsletter published an article about Issue 382 - It’s dangerous to go alone: take our guide to the β€œIDEAL” HTTP client! (With examples in Ruby)

🎧 Podcasts

🎧 Creston Jamison published a new podcast about When Should You Use Background Jobs? | Rubber Duck Dev Show 99

🎧 Code And The Coding Coders Who Code It published a new podcast about Episode 28 - Matt Swanson

🎧 Code And The Coding Coders Who Code It published a new podcast about Bonus Canadian Football Episode

🎧 Jess Brown published a new podcast about Starting a Business in a Snowstorm | 2min snip from IndieRails

🎧 The Ruby On Rails Podcast published a new podcast about The Ruby on Rails Podcast Episode 487: Building the Rails World Application with Shami Tomita and Eric Halverson

🎧 Ruby Rogues published a new podcast about Stimulus, Hotwire, and Turbo, Oh My! - RUBY 607 - Ruby Rogues - Top End Devs

🎧 Jason Swett published a new podcast about Code review with Jonathan Bennett (tests, namespaces)

🎧 The Bike Shed published a new episode about The Bike Shed: 401: Making The Right Thing Easy

πŸ“½οΈ πŸŽ₯ Videos

Talks

πŸ“½οΈ Hanami Mastery shared a new video about Hanami 2.0 an alternative to Rails - Daniel Nguyen from Ruby Australia

Screencasts

πŸŽ₯ Chris Oliver published a new video about Rails 7.1 Authentication From Scratch (Example) | GoRails

πŸŽ₯ LΓ‘zaro Nixon published a new video about Creating native apps with turbo

πŸŽ₯ Dean De HartΒ published new videos about:

  • Testing The Routes Component React On Rails Part 10

  • Jest Code Coverage In React On Rails Part 11

  • Testing The Post Index Component React On Rails Part 12

  • Testing The Post Show Page React On Rails Part 13

✍🏾 Articles

What’s new πŸ†•

Mike Perham published a new articlea bout Ruby HTTP Server from scratch | Mike Perham β†’ β€œRecently I decided to add support for Kubernetes HTTP health checks to Sidekiq Enterprise. This means, within each Sidekiq worker process, we need to implement an HTTP server which listens on port X and simply returns 200/OK if the process is alive”

Dmitry Tsepelev published a new article about Ruby goes to the movie theater: directing the refactoring of your application β†’ β€œThis post introduces a method I use to refactor big applications. I want the process to happen in a predictable manner and make sure that important things are addressed before others”

Brad Gessler published a new article about Sqlite & Rails in Production β†’ β€œWhen deploying a Rails application to production, its rare to question the idea of running a Postgres or MySQL database to persist data and Redis for caching, background job processing, and WebSockets, but what if it could all be done without running these services?”

Deepak Mahakale published a new article about What’s new in Rails 7.1 β†’ β€œLet’s see what is new in rails 7.1”

Rashmi published a new article about Rails 7.1 - authenticated_by β†’ β€œIn Rails 7.1 authenticated_by method has been introduced”

Gabriel Chuan published an article about Merge Csv Files In Ruby Efficiently Dev Community β†’ β€œEver had issues merging CSV files in Ruby? Use sqlite instead! Theoretically, it can handle large csvs, and is very fast”

I published an article about Use Gpt 4 To Refactor A Simple Html Page β†’ β€œUtilizing Cursor IDE and GPT-4 for logo placement, spacing adjustment, equal column height, and group hover element display”

Harrison Broadbent published an article about Refactoring From Feature Specs To System Specs β†’ β€œIn it, I break down the difference between system specs and feature specs in RSpec and Rails, and walk you through refactoring your feature specs to system specs”

Prasanth Chaduvula published an article about Set And Restore Public Attributes Around A Block Using Object#With β†’ β€œObject#with helps to streamline and elegantly improve this technique. It is an addition to the Ruby Object class that offers a simpler method of managing object states”

Deep Dives πŸ”

Shalvah published an article about Exploring Concurrent Rate Limiters, Mutexes, Semaphores β†’ β€œThis is a dump of my learnings and experiments while going down a little rabbit hole (…) I was studying Sidekiq's page on rate limiters (…) So I asked myself, how would I implement a concurrent rate limiter?”

Matheus Richard published a new article about Mining Gold in Digital Conversations β†’ β€œGold Miner is an app I created to transform interesting conversations we have at thoughtbot into blog posts”

Akshay Khot published a new article about How To Debug And Step Through Rails Codebase β†’ β€œDo you want to read the Rails source code for a deeper understanding of the framework, but feel intimidated by the sheer size of the codebase, or don't know where to start?”

Artur Petrov published an article about It’s Dangerous To Go Alone: Take Our Guide To The β€œIdeal” Http Client! β†’ β€œThis guide is about understanding the best practices for any HTTP client and how to leverage them to your advantage. This guide is not limited to backend applications (although most of the examples are in Ruby), the same principles are applicable for any language and platform, even the frontend”

PaweΕ‚ Urbanek published an article about How To Improve Rails Caching With Brotli Compression β†’ β€œIn this blog post, I’ll describe optimizing the Rails caching mechanism using the Brotli compression algorithm instead of the default Gzip. I’ll also discuss a more advanced technique of using in-memory cache for extreme performance bottlenecks”

Ariel Juodziukynas published an article about Exploring Ruby Warnings Fast Ruby.Io | Rails Upgrade Service β†’ β€œIn this article we will explore how to use them, how to analyze them, and some examples of interesting warnings that can be really helpful during upgrades”

Akshay Khot published an article about The Complete Guide To Working With Cookies In Rails β†’ β€œThis post covers almost everything you need to know about HTTP cookies in the context of Rails. We'll explore what a cookie is, why we need it, how to set & get a cookie, how to restrict cookies to a particular domain/path, prevent JavaScript access, how to sign & encrypt cookies, and much more”

How-Tos πŸ“

Jeff Dwyer published an article about Let's Talk Tagged Logging Vs Structured Logging In Ruby Or Rails β†’ β€œWhat is Tagged Logging? Should you be using it? What libraries support it? Is it the same as structured logging?”

Alkesh Ghorpade published an article about Ruby 3.2 Introduces Data, A New Core Class For Immutable Value Objects β†’ β€œRuby 3.2 introduces Data, a new core class for immutable value objects. Value objects are a powerful tool for improving the quality of code. They are easy to understand and use and can help improve the readability and maintainability of code by making it more concise, consistent, and easier to reason about”

Davide Santangelo published an article about Exploring The Null Object Pattern In Ruby Dev Community β†’ β€œThe Null Object Pattern is a behavioral design pattern that helps eliminate the need for explicit null checks in your code. It is particularly useful when dealing with missing or optional objects in your application. In this article, we will explore the Null Object Pattern in the context of Ruby”

Julian Rubisch published a new article about Using Turbo Frames for Navigation - RailsReviews β†’ β€œNavigating the intricacies of Turbo Frames can be both rewarding and challenging. These custom HTML elements present a method to refine the user experience on web applications. Let's explore some patterns and use-cases that can be achieved with Turbo Frames”

PaweΕ‚ Urbanek published a new article about How to Improve Rails Caching with Brotli Compression β†’ β€œI’ll describe optimizing the Rails caching mechanism using the Brotli compression algorithm instead of the default Gzip. I’ll also discuss a more advanced technique of using in-memory cache for extreme performance bottlenecks”

Lucas Barret published a new article about ActionPolicy , GraphQL and Rails β†’ β€œI wanted to create an article showing you how simple yet powerful ActionPolicy the Gem he develops for Authorization”

Avi Flombaum published a new article about Turbo Forms, Ruby on Rails Drag-Drop: Pt.1 β†’ β€œIn this series of posts we're going to build a Drag and Drop feature to add music tracks to playlists”

Stephen Margheim published a new article about Enhancing your Rails app with SQLite Array columns β†’ β€œtoday I want to show you that it is possible to build on top of SQLite’s primitives to provide matching behavior for one of my favorite features of Postgresβ€”array columns” and Local snapshots.

Maful Prayoga published an article about Build Drag And Drop With Rails Hotwire β†’ β€œToday, we're diving into something super cool: adding drag-and-drop functionality to your Rails app, all powered by the magic of Hotwire”

PaweΕ‚ Pacana published a new article about Six ways to prevent a monkey-patch drift from the original code β†’ β€œMonkey-patching in short is modifying external code, whose source we don’t directly control, to fit our specific purpose in the project. When modernising framework stack in β€œlegacy” projects this is often a necessity when an upgrade of a dependency is not yet possible or would involve moving too many blocks at once”

Patricio Mac Adden published an article about Talking To Hostile Ap Is | Sinaptia β†’ β€œA hostile API is an API that gets in your way, that fights you when you're trying to use it. That seems to be against you using it”


Please consider becoming a paid subscriber to support this newsletter for just $1.8/week ($7.5/month), and you will receive an ad-free version. Your contribution aids growth and maintains the quality of ShortRuby for everybody:

Support the newsletter for ~ $1.8/month

If you consider upgrading and want more information, please read Why to subscribe to paid.

1
Share this post

Short Ruby News - Edition #59

newsletter.shortruby.com
Share
Previous
Next
Comments
Top
New
Community

No posts

Ready for more?

Β© 2023 Lucian Ghinda
Privacy βˆ™ Terms βˆ™ Collection notice
Start WritingGet the app
Substack is the home for great writing