Short Ruby Newsletter

Share this post

Short Ruby News - Edition #28

newsletter.shortruby.com

Short Ruby News - Edition #28

Briefly about everything happening in Ruby world - week 5 of 2023 (web version)

Lucian Ghinda
Feb 6
Share this post

Short Ruby News - Edition #28

newsletter.shortruby.com

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 support keeping this newsletter free and sustainable for ~1.5$ per week (actually 6.5$/month) if you can afford it:

Support the newsletter for ~1.5$/week

Read Why to subscribe to a paid plan for a longer explanation.


If you are looking to hire a Ruby or Rails Developer, I recommend checking RailsDevs.com (referral link). I invite you to use the referral link for RailsDevs.com so you can support this newsletter (it does not cost you anything extra).


๐Ÿ‘ Our Community

๐Ÿ‘ Robby Russellย shared why Ruby on Rails is great for small teams:

Source:ย @robbyrussell

๐Ÿ‘ Gabriel Arcangel Zayasย shared how they find Ruby:

Source:ย @gazayas

๐Ÿ‘ Rails Confย announcedย that RailsConf 2023: Call for Proposals is open:

Source:ย @railsconf@ruby.social

๐Ÿ‘ Adrian Marinย shared they want to organize a European Ruby conference:

Source:ย @adrian@ruby.social

๐Ÿ‘ Hanami Masteryย sharedย they plan to host a Q&A with the Hanami Team for their 50th episode. If you want to ask questions, send it via this form

Source:ย @hanamimastery@ruby.social

๐Ÿ‘ Justin Jacksonย shared in a thread that he is still on the team full stack web dev and talked about new companies using Rails:

Source:ย @mijustin

He also shared possible advice (from a marketing/PR perspective):

Source: @mjustin

You might want to listen to this 2022 conversation about What's the future of the full-stack web developer? Taylor Otwell interview (creator of Laravel) where they also talk about How to attract more young developers to Laravel and Rails? (at 3:34)

๐Ÿ‘ Andrew Culverย announcedย The Rails SaaS Conference happening in Athens/Greece on 1-2 June 2023:

Source:ย @andrewculver

๐Ÿ‘ Victor Shepelevย announced he added theย Ruby 3.2 changes to RubyReferences - a fantastic resource for discovering whatโ€™s new in the Ruby language:

Source:ย @zverok

๐Ÿ‘‰ All about Code and Ruby

๐Ÿ‘‰David Stosikย shared a riddle about why adding a month might change the timezone:

Source:ย @DavidStosik@ruby.social

You should read the threads about this on ruby.social and Twitter. More ideas and strange behavior are happening when working with dates.

In case you want the solution, here are two good answers:

Source: @paracyle
Source: @pixeltrix

This is explicitly stated in Ruby documentation, and you can see how Rails is using Date#ยป here:

source: docs.ruby-lang.org/en/3.2

๐Ÿ‘‰ Justin Searls asked about a tool to use git bisect over a Rails app and see where some behavior was introduced:

Source: @searls@mastodon.social

He then shared the solution he found by using the following two scripts (links to their Gists)

  • migration_version_at_ref

  • rails_bisect_step

๐Ÿ‘‰ De Silvaย shared a piece of code that makes use of checking if a class is part of the descendants of another one:

Source:ย @aesthetikx@ruby.social

๐Ÿ‘‰Adarshย invited the community to submit talks about Mastodon this year at RailsConf:

Source:ย @adarsh@ruby.social

๐Ÿ‘‰Justin Collinsย shared a benchmark about using explicit block params:

Source:ย @presidentbeef@ruby.social

๐Ÿ‘‰Alexandre Rubanย shared how to define methods in Ruby using meta-programming:

Source:ย @alexandre_ruban

He showed the second way of creating new methods using the class_eval with heredoc and explained why add __FILE__ and __LINE__ there:

Source: @alexandre_ruban

๐Ÿ‘‰ Greg Molnarย shared a better explanation of what regroup does in Rails 7.1:

Source:ย @GregMolnar

๐Ÿ‘‰Jean Boussierย shared the result of running a load test on a small app with GVL instrumentation enabled:

Source:ย @_byroot

๐Ÿ‘‰Acceisย asked a question about spotting vulnerability in a code:

Source:ย @acceis

๐Ÿ‘‰Matt Swansonย shared a code showing how to build a feature flag at the account level:

Source:ย @_swanson

๐Ÿ‘‰ Eric Berryย shared a piece of code about setting initialising an array before adding an element:

Source:ย @coderberry

There are a couple of replies in the thread. Here are two interesting solutions:

Source: @josh_cheek
Source: @bsilva96
Source: @DmitryDrobotov

๐Ÿ‘‰ Chris Oliverย shared a code sample about how JumpStartRails uses the new built-in API client generator:

Source:ย @excid3

๐Ÿ‘‰Greg Navisย shared how to use the hstore column type from PostgreSQL in Active Record:

Source:ย @gregnavis

๐Ÿ‘‰Eric Berryย askedย about what to use for complex queries:

Source:ย @coderberry

There is a good thread discussing Arel and what happened to Arel after being part of Rails and becoming private API.

Here is a comparison between Arel and Sequel:

Source: @jankomarohnic

And later on the thread, there is a good discussion about how to use Sequel. Here is a short reply:

Source: @coderberry
Source: @jankomarohnic

๐Ÿ‘‰ HeartComboย announced they are looking for volunteers toย Integrate with Hotwire/Turbo by configuring error and response statuses

Source:ย @heartcombo

/u/collinmarco asked about what extensions people use for Ruby on VS Code:

Source: /u/collinmarco

Among the recommendations are:

  • https://github.com/Shopify/vscode-shopify-ruby

  • Setting up Solargraph

  • https://github.com/orangedsoft/RailsAutoCompleteHelper

  • https://marketplace.visualstudio.com/items?itemName=vortizhe.simple-ruby-erb

  • https://github.com/bung87/vscode-rails

  • https://github.com/rubyide/vscode-ruby


If you have read so far and you like the content, maybe you take into consideration sharing this and subscribing:


๐Ÿงฐ Gems, Libraries, and Updates

๐Ÿงฐ Avo released version 2.25, bringing data attributes to table headers and more bug fixes. Read the change log

๐Ÿงฐ Hanamiย announced the release ofย Hanami 2.0.3

Source:ย @hanami@ruby.social

๐Ÿงฐ Nate Berkopecย recommended a gem called Bumbler for finding slow-loading gems in projects that are using Bundler:

Source:ย @nateberkopec@ruby.social

๐Ÿงฐ Mike Perham :Sidekiq:ย sharedย that the new Bundler 2.4 has very nice improvements. Read the changelog โ†’ Bundler: Bundler v2.4: new resolver, gems with Rust extensions, and more

๐Ÿงฐ Nate Berkopecย shared a new gem released by John Nicholsย rubyatscale/singed:

Source:ย @nateberkopec@ruby.social

๐Ÿงฐ Ben Sheldonย announcedย a release of bensheldon/good_job that now supports batches. To read more about this, read the following two PRs: Support for Batches?ย #417 and Implement batch functionalityย #691

๐Ÿงฐ Pawel Osiczko published an updated fork of real-world rails, a project that brings together 100+ active, open-source Rails apps.

๐Ÿงฐ JRuby announced the release of version 9.3.10.0 with compatibility and performance fixes. Read the change log

๐Ÿค Related (but not Ruby-specific)

๐ŸคJason Swettย shared a simple way to decide whether to tolerate a piece of duplication or not:

Source:ย @JasonSwett

๐ŸคDrew Braggย asked about how to organize tech debt:

Source:ย @DRBragg

Here are some of the responses received, but there are a lot of good ideas in the thread:

Source: @alex_takitani
Source: @cnorm35
Source: @kennethmayer

๐ŸคKelsey Hightowerย shared an answer about giant monoliths effectiveness:

Source:ย @kelseyhightower

A more nuanced reply worth considering from Luca Guidi:

Source:ย @jodosha

๐Ÿค Thiago Ghisiย shared a thread about pair programming good practices:

Source:ย @thiagoghisi

More content: ๐ŸŽฅ ๐ŸŽง ๐Ÿ—ž

๐Ÿ“š Books

๐Ÿ“š Noah Gibbsย announced their bookย Rebuilding Rails - Understand Rails by Building a Ruby Web Framework now supports Purchasing Power Parity:

Source:ย @codefolio@ruby.social

๐Ÿ“š Josef Strzibnyย announced thatย Deployment from Scratch now supports Purchasing Power Parity:

Source:ย @strzibnyj

๐Ÿ—ž Newsletters

๐Ÿ—ž Greg Molnarย sharedย a new edition of This Week in Rails Week 05: Spring is here? written by zzak

๐Ÿ—ž๏ธย Ruby Weeklyย published a new edition:ย Rusty gem skeletons with Bundler 2.4

๐Ÿ—ž Ruby Radar published a new edition Ruby Radar #88 - Conferences Galore!

๐Ÿ—ž๏ธย Ruby LibHuntย published a new edition of theย Awesome Ruby Newsletter

Podcasts

๐ŸŽง Andy Crollย sharedย the final episode from the current season of Chats in the Cupboard with Vaidehi Joshi โ†’ Listen to Talk about Talks

๐ŸŽง Avdi Grimmย shared a podcast where he talked about building and running this training and consulting business ย Running a training business for Ruby developers

๐ŸŽง Jason Swettย published a new episodeย 173 - Phlex with Joel Drapper - The Code with Jason Podcast

๐ŸŽง The Ruby on Rails Podcastย published a new episode aboutย The Ruby on Rails Podcast Episode 455: Adventures in TruffleRuby (Brittany + Nick)

๐ŸŽง Ruby for All published a new episode: Favorite Ruby Methods: Part 1

๐ŸŽง Remote Ruby published a new episode How Derek Sivers Uses Ruby And His Programming Philosophy

๐ŸŽง Ruby Rogues published a new episode about The Significance Of Salary Transparency With Hilary Stohs-Krause

Videos

Talks

๐Ÿ“ฝ๏ธ Adrian Marinย sharedย a video where he shows how to use Avo to build amazing Admins for Rails

๐Ÿ“ฝ๏ธ Noah Gibbsย sharedย an old video where he talks about RubyConf 2019 - Conscious Coding Practice: The Three Concrete Steps by Noah Gibbs

๐Ÿ“ฝ๏ธ Dave Kimuraย published the video version ofย This Week in Rails - Feb 3rd, 2023

๐Ÿ“ฝ๏ธ Content For :Devsย published a new screencast aboutย Screencasting tips! | content_for :devs - Episode #003

๐Ÿ“ฝ๏ธ Jason Swett published two new episodes of Code With Jason Meetup about:

  • How to keep Rails controllers organized

  • Duplication

๐Ÿ“ฝ๏ธ Rubber Duck Dev Show published a new episode with Amir Rajan about Game Development in DragonRuby With Amir Rajan

Screencasts

๐ŸŽฅ Yaroslav Shmarovย published two new videos:

  • Ruby on Rails #107 How to display locations on a map with Mapbox API and gem Mapkick like AirBnBArticles

  • Ruby on Rails #108 How to use the Browser Geolocation API with Rails

๐ŸŽฅ Deaninย published two new videos:

  • Minecraft In ThreeJS On Rails? | Ruby on Rails 7

  • Image Cropping With Active Storage & CropperJS | Ruby On Rails 7 Tutorial

๐ŸŽฅ /u/mehdifarsi shared a video showing Ruby Tricks #6: Customize your Rails console prompt (display Project Name & RAILS_ENV)

๐ŸŽฅ The Ruby Learning Center published two more videos streamed by Brandon Weaver for the two classes that are running now:

  • Ruby Learning Center - Complete Guide to Rails Performance - S5

  • Ruby Learning Center - Effective Testing in RSpec 3 - Ch 4

Whatโ€™s new

Ruby Lib Huntย sharedย an update from Ruby Central about Ruby Shield Update - Winter 2023

Lucian Ghinda published an article about We should adopt and use new Ruby features

How-Tos

  • Hash Patelย publishedย two articles about multi-tenant architecture in Rails:

    • Set up a basic multi-tenant architecture in Rails 7 using apartment gem

    • Set up a basic multi-tenant architecture in Rails without gem

  • Alvaro Padilla published an article explaining Monkey-patching: Messing with your Ruby methods

  • Brandon C published an article about Intro to Enumerables in Ruby, and an example with Active Record

  • Caleb Hearth published an article explaining how to use The Decree Design Pattern

  • 1klap published an article showing how to configure Rails 7: production deploy from scratch (Ubuntu 22.04 edition)

  • Sulman Baig published an article about how to run Rubocop for Rails in GitHub Actions

  • Daniel Fintinariu published an article about Unlock the Potential of VS Code for Ruby Programming

  • Brandon Christmanย published an article showing how toย Build a Table Editor with Trix and Turbo Frames in Rails

Deep Dives

  • Jฤ™drzej (NJ) Urbaล„ski published an article about. What you (probably) don't know yet about pattern matching in Ruby?

  • Joel Mossย shared an article written by ย Nested Modules in Ruby

  • Dmitry Tsepelevย publishedย an article explaining Fantastic global methods in Ruby and where to find them

More general

  • Mike Perham sharedย an article describing a vulnerability in Ransack library: Ransacking your password reset tokens | Positive Security

  • Dave Copelandย publishedย an article about My Toolchain for Building Programming Book

  • Andrew Atkinsonย published an article describing his experience atย Ruby for All | The Database Wizard with Andrew Atkinson

  • Eric Berry shared an article written by Jeremy Frisen aboutย The Why and How of Yardoc

  • Hiroshi Shibataย sharedย slides from a talk by John Cline about Demystifying RBS and Rails


๐Ÿค— 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

Read more about what is a Founding Member or about Why pay for ShortRuby newsletter


Share this post

Short Ruby News - Edition #28

newsletter.shortruby.com
Previous
Next
Comments
TopNewCommunity

No posts

Ready for more?

ยฉ 2023 Lucian Ghinda
Privacy โˆ™ Terms โˆ™ Collection notice
Start WritingGet the app
Substackย is the home for great writing