

Discover more from Short Ruby Newsletter
Short Ruby News - Edition #29
Briefly about everything happening in Ruby world - week 6 of 2023 (web edition)
You can jump directly to a section:
๐ย Our Community
๐ย All about Code and Ruby
๐งฐย Gems, Libraries, and Updates
๐คย Related (but not Ruby-specific)
More content: ๐ฅ ๐ง ๐ย (articles, podcasts, videos, and newsletters)
๐ค Founding Members supporting this newsletter
You can subscribe for free
Or you can consider upgrading to paid
Investing in the Ruby Weekly Newsletter as a paid subscriber is a valuable way to support the community around you. For ~1.5$/week (6.5$ per month), you can support its growth and ensure that high-quality information about the latest developments in Ruby continues to be available to everyone, both paying and non-paying subscribers alike.
If you consider upgrading and want more information, please read Why to subscribe to paid
๐ Our Community
๐ We have to deal with hard truths, and one of these is an invasion happening in Ukraine, and we know at least one of our community members Victor Shepelev is there, facing complex challenges every day.
Yukihiro Matz Matsumoto shared Victorโs article that I invite you to read about Participating in programming language's evolution during interesting times

๐ ๐ Peter Cooper announced that Ruby Weekly reached 640 issues ๐ Congrats, and I wish they would release at least 640 more numbers.
Read the 640th issue of Ruby Weekly

๐ Morgan Fogarty asked for recommendations of woman heroes in Rails community:

Here is the list of Twitter accounts from replies in a random order: @leenyburger, @amyhoy, @eileencodes, @adriannakchang, @sandimetz, @BrittJMartin, @saronyitbarek, @LiliVerrot, @JemmaIssroff, @nodunayo, @b0rk, @jessitron, @HeyChelseaTroy, @vaidehijoshi, @OngMaple, @womenonrails, @juuh42dias, @kytrinyx, @the_thagomizer, @lindaliukas
๐ย Ruby Centralย announced they offer Coaching Sessions for people who want to talk at the conference. Register at Call for Proposal (CFP) Coaching Session

๐ RubyCentral published all videos from RubyConf 2022 Mini and Huston. Open the YouTube playlist
๐ Davis W. Frankย shared an idea about creating a community for mid-sized Ruby on Rails organizations:

๐ Greg Molnar asked what the most challenging part when learning Ruby/Rails is:

Here are some of the responses:
Asset management
Learning to think about Rails security
Outdated learning material
Not knowing how to go off the rails
Domain modeling, especially abstract models
Struggling to model what theyโre building in Ruby / Rails. Going from idea to paper kind of thing
Advanced ActiveRecord queries
๐Rubyday Verona announced their Call for Papers are now open at rubyday.it

๐ Jeremy Smith announced a new podcast called IndieRails about Rails and indie business, having Jess Brown as co-host:
๐ Saroj Zoras called for participation in Ruby Google Season of Docs project. Read more about it here at github.com/rubygsoc:

๐ All about Code and Ruby
If you're to hire top Ruby on Rails talent, I'd like to introduce you to RailsDevs.com (referral link). This unique platform puts the power back in the hands of developers by allowing them to post their profiles and empowering companies to reach out to them. I believe in the value RailsDevs can bring to the hiring process, and I'm confident you will.
I invite you to use the referral link for RailsDevs.com so you can support this newsletter, too (it does not cost you anything extra).
๐Luca Guidi shared an excellent thread explaining with code samples how to create a Hanami web app using GraphQL:

You should read the entire thread, but in case you are curious about how the code looks like, here is step 9:

๐Emmanuel Hayford shared that Rails 7.1 now has support to pass options to explain:

๐Tekin Sรผleyman shared a code sample showing how to use the format sequence

If you want to read more, there is an entire section called Format Specifications on docs.ruby-lang.org

๐Noah Gibbs asked about what are some good Rubocop rules

Here are some replies from the conversation:


๐Rishi Pithadiya shared a code sample showing how to use assert_valid_keys from Rails to validate Hash keys:

๐ Chris Salzberg shared they built a demo rails app that isolated Rails application constants under a single top-level namespace rails_on_im

๐Noel Rappin started a discussion about what if Ruby would support other symbols at the end of the method name:
Here are some interesting gists from the replies:


๐Benoit asked about mixing concurrency in Ruby/Rails with parallelism on the DB part:

Here is one explanation of how this works:

๐Karol Bฤ k shared a quick Ruby tip for paginating APIs:
๐Joel Drapper shared that phlex-rails will have adapters for 184 Rails view helpers:

You can read the merged PR for more details about this.
๐Postmodern asked a question about the pattern of defining methods that return a value on success and nil on failure compared with methods that raise an exception on failure:

Here are some replies from the conversation:




You might also find interesting this code prototype shared by Noel Rappin in a gist

๐ Kevin Newton shared that ruby-syntax-tree can now help generate a mermaid diagram of a sea-of-nodes representation of Ruby code in Syntax Tree:

Here is what it looks like:

๐Jess Brown shared a code sample showing how to use provide the option to download as CSV in the same Rails controller action:

๐Kevin Newton shared a great infographic explaining what SyntaxTree does and how it fits into Ruby:

๐Greg Navis shared a thread about instrumentation API from ActiveSupport.
Here is one of the code samples he shared, but I suggest you read the entire thread:

๐Chris Oliver asked a great question about what Ruby or Rails feature should be more known:

Here are some of the answers but for the full context you should read the conversation:
Pattern Matching
Fixtures
Active Jobs
YARD docs
Arel
Seed data
The built-in authentication
TurboStreaming chunked HTTP requests from APIs
ActionController::Metal to ping endpoints
๐ Takashi Kokubun shared Chris Seaston RubyConf talk and announced they are continuing to implement some of Chrisโ proposals: RubyConf 2022: Rubyโs Core Gem by Chris Seaton

๐Zilvinas Kucinskas shared a thread describing how they hosted bridgetownrb as a custom origin on a subdirectory path on Cloudfront:

๐Jess Brown shared a quick tip about how to add a new column and set default only for new records:

๐Lewis Youl shared some code samples showing how to use the Ruby splat operator *
to do array manipulations:

๐งฐ Gems, Libraries, and Updates
๐งฐ Ruby Weeklyย sharedย a gem fixture_champagne that has the purpose of doing:

๐งฐ Stan Lo shared they are starting to create a new Ruby tracer library. This seems to be the Github repo: st0012/ruby_tracer

๐งฐ Paul Bucur shared a Ruby library called browser that helps do browser detection with Ruby.
๐งฐ Joel Drapper shared Lookbook v2 that now has support for any other Rails renderable:

๐งฐ Carlos Silva announced they published a new gem rails-graphql
rails-graphql is a fresh new implementation of a GraphQL server, designed to be as close as possible to Rails architecture and interfaces, which implies that it has shortcuts, lots of syntax sugar, and direct connection with Rails features like ActiveRecord and ActionCable.
This gem has its own parser, written from scratch, using the C-API of Ruby, which empowers it with an outstanding performance. Plus, all the features provided were carefully developed so that everyone will feel comfortable and able to apply in all application sizes and patterns.

๐งฐ Joel Drapper announced the release of Phlex 1.3.2 and Phlex Rails 0.6:

๐งฐ Ada announced they published yarm: yet another Ruby monad gem:

Here is a code sample:

๐งฐ Nate Berkopec announced they published Release 6.1.0 The Way Up ยท puma/puma
๐งฐ Vladimir Dementyev shared their talk at RubyConf about their new gem mock-suey:
A collection of tools to keep mocks in line with real objects.
๐งฐ Jeremy Evans announced the release of their new gem by: Ruby Library Preloader
๐งฐ Andrew Kane announced fast tokenizers for Ruby tokenizers-ruby

๐งฐ A new Ruby version 3.2.1 was released. Read the changelog created by Hiroshi Shibata

๐งฐ Matt Swanson shared they merged a new feature to Rails 7.1 about Added option to show all headers for mailer previews
๐งฐHeartcombo announced that the PR that adds support for Hotwire/Turbo is not merged to the main:

๐งฐ Marco Roth announced the release of v.0.52.0 of stimulus-use containing a breaking change. Read about how to migrate here
๐งฐ Dragon Ruby announced their roadmap for Dragon Ruby in 2023. Checkout the announcement
๐งฐDmitry Tsepelev announced their new gem rubocop-graphql - a Rubocop extension for enforcing GraphQL best practices.
๐ค Related (but not Ruby-specific)
๐ค Paul Bucurย shared how to open iCalendar file as a subscription and not open the download file:

๐คDavid Stosik shared a piece of code showing how to use option -execdir for find

๐คStanislav (Stas) Katkov shared a thread about various ways to approach the purpose of a side project:

๐คJason Swett shared why it is good to test your objects:

๐คAndy Budd talked about what they see as the biggest problems in product management:

๐คJosef Strzibny shared some Git tips about organizing stashes with names:

๐Nick Schwaderer shared a great quote from why:

More content: ๐ฅ ๐ง ๐
๐ Nate Berkopecย shared the slides they used at Tokyo Tech Meetup about How to contribute to Open Source
๐ Nate Berkopec announced they turned on Purchasing Power Parity for all their books Get them here

๐ Newsletters
๐Emmanuel Hayford announced a new edition of This Week in Rails Parameter filtering and an improved ActionView::Helpers::TagHelper#...
๐ Nate Berkopec published a new edition of Ruby/Rails performance newsletter If queue times are getting long, consider optimizingย the 95th percentile
๐๏ธย Ruby Weeklyย published a new edition:ย Everything new in Ruby 3.2
๐ Ruby Radar published a new edition Ruby Radar #89 - RubyConf 2022 Videos and DHH is Cooking
๐๏ธย Ruby LibHuntย published a new edition of theย Awesome Ruby Newsletter
๐ Women On Rails published a new edition Newsletter #43: the framework war, optimisation with Ruby, being promoted. The newsletter is available in French, Italian and Spanish.
Podcasts
๐ง Drew Bragg published a new episode of Code and the Coding Coders who Code it with Mike Munroe and Dave Kroondyk
๐ง Brittany Martin shared a new episode of The Ruby on Rails podcast: The Rubyโs Got You Covered World Tour with Kevin Murphy
๐ง Content For :Devs published a new episode about Streaming Magic with Christ Booth! - content_for :devs
๐ง Collin Donnell published the latest episode of Rooftop Ruby with Joel Drapper
๐ง Content For :Devs published a new episode Streaming Magic with Christ Booth! - content_for :devs
๐ง Remote Ruby published a new episode about Concurrency Problems Bro | Remote Ruby | Episode 217
๐ง Ruby Rogues published a new episode The Evolution of Opal
๐ง Ruby for All published a new episode about Favorite Ruby Methods: Part 2 - The Hash
Videos
Talks
๐ฝ๏ธ Drew Bragg shared his talk at Ruby Conf Mini 2022: Who Wants to be a Ruby Engineer? by Drew Bragg. If you like discovering Ruby tips, this talk is excellent and entertaining
๐ฝ๏ธ Boulder Ruby published a talk by Brooke Kuhlmann about Ruby Function Composition
๐ฝ๏ธ Rubber Duck Dev Show published a new episode about Hobby programming with Nick Schwaderer
Screencasts
๐ฅ Deanin published a new video about Storing and Searching JSON in Ruby on Rails
๐ฅ Dave Kimuraย published a new video about Strict Locals
๐ฅ The Ruby Learning Center published two more videos streamed by Brandon Weaver for the two classes that are running now:
Articles
Whatโs new
Thomas Fernandez published an article about Ruby Adds Support for WebAssembly: What Does This Mean for Ruby Developers?
Joe Masilotti published a new article about Progressively enhanced Turbo Native apps in the App Store
Murtaza Bagwala published a new article on Saeloun about Rails preserves entry TTL when incrementing or decrementing an integer value
How-Tos
Wilbur Suero published Getting Started with Ruby on Rails - A Beginner's Guide - [Beginner]
Yaroslav Shmarov published a new article about Omniauth without Devise
Sulman Baig published an article about How to send slack notifications from Rails app using sidekiq
Mattias Velamsson published the second part of this series about how to Organize Your Downloads Folder with Ruby #2
Brandon Christman shared a how to create a Carousel - TurboStreams (no javascript)
Akshay published an article about Docked Rails: Setup a Ruby on Rails Application on Docker
Deep Dives
Younes Serraj published a new article explaining ActiveRecord: finally understand transactions.
Ivo Anjo published an article about Rubyโs unexpected I/O vs CPU unfairness - ivo's awfully random tech blog
More general
Paweล ลwiฤ tkowski published a new article explaining various ways to think about events and their benefits while showing some examples of code design based on events: Events, events, events
Lucian Ghinda published a new article about short methods and long methods: A methodโs gravity
๐ค Founding Members supporting ShortRuby
Drew Bragg, host of Code and the Coding Coders who Code it
Avi Flombaum, the founder of Flatiron School, is a product engineer interested in full-time/contract work.
Adrian Marin, creator of Avo - a Ruby on Rails application building framework
Adam McCrea, creator of Judoscale (formerly Rails Autoscale)โtheย dead-simple autoscalerย for Rails, Sidekiq, etc.
Stephen Ierodiaconou from www.diaconou.com
Read more about what is a Founding Member or about Why pay for ShortRuby newsletter