Short Ruby Newsletter

Share this post

πŸ‘ Short Ruby News - edition #22

newsletter.shortruby.com

πŸ‘ Short Ruby News - edition #22

Briefly about everything in Ruby world

Lucian Ghinda
Dec 12, 2022
5
Share this post

πŸ‘ Short Ruby News - edition #22

newsletter.shortruby.com

This edition was created with the help ofΒ @adrianthedev/@adrian@ruby.socialΒ fromΒ Avo for Ruby on Rails (a friendly full-featured Rails admin panel) and @jcsrb.

You can jump directly to one of the following sections if you like:

πŸ‘ Our Community

πŸ‘‰ All about Code and Ruby

🧰 Gems, Libraries, and Updates

🀝 Related (but not Ruby-specific)

More content: πŸŽ₯ 🎧 πŸ—ž (articles, podcasts, videos, slides and newsletters)


πŸ‘ Our Community

πŸ‘ Drew Bragg invited me to his podcast. If you want to learn more about why I wanted to create this newsletter and some further plans I have for it, listen to Episode 12 - Lucian Ghinda (available on all platforms), and please be kind, as this was my first podcast ever πŸ™ˆ

Image from Apple Podcast

ζˆη€¬Β shared that Ruby 3.2.0 RC 1 has been released:

Source:Β @nalsh

You can install it right now with:

Source: @postmodern@ruby.social

πŸ’” Sad news hit the community this week when we learned that Chris Seaton had died:

  • Mike Dalessio first shared this news on Twitter and Ruby.social along with the words from the Shopify Ruby and Rails Infrastructure team.

  • Aaron PattersonΒ wroteΒ In Memory of a Giant

  • Benoit Daloze wrote In Memory Of Chris Seaton

  • Brandon Weaver wrote To Be Known for our Kindness

  • Justin Searls wrote The Best Kind of Brilliant

  • Joel Drapper wrote In memory of Chris Seaton

A lot of people shared how amazing Chris was:

  • Read quotes and replies about the announcement on Twitter

  • Read replies about the announcement on Ruby.social

  • Read the HN thread about the announcement.

  • Read the comments on Reddit.

If you need more context to process this, Richard published a good thread about how to think about this event. Please be safe! Call a friend or colleague today and see how they are!


πŸ‘ Richard Schneeman asked on Reddit about suggestions for Ruby accounts to follow on Mastodon:

Source: r/ruby

Check out the replies here

πŸ‘ u/ogarocious asked on r/rails about stories of landing their first junior entry-level RoR job:

Source: r/rails

Read the replies, as there are good stories there.


πŸ‘‰ All about Code and Ruby

πŸ—£οΈ Sticking to their once-every-two-weeks schedule, Adrian and Paul launched Avo 2.21. This week's release makes it way easier to authorize at row-level the has_many associated records, adds the disabled option to fields to give you more control over how you display them in a form, and adds callable action messages where you can customize the action messages using the selected record, current_user, context data and more, making it even more dynamic:

Source: Avo 2.21

(Avo has supported Short Ruby from the beginning. Thank you!)

πŸ‘‰Β Greg NavisΒ shared a code sample showing the helper methods defined by belong_to in Rails:

πŸ’‘ Rails tip: belongs_to defines 8 helper methods on the model that can help you write more idiomatic Rails code. 1️⃣ Setter 2️⃣ Getter 3️⃣ Build 4️⃣ Create 5️⃣ Create or raise 6️⃣ Reload 7️⃣ Has changed? 8️⃣ Has previously changed? (= before last save)
Source:Β @gregnavis

πŸ‘‰Β Cezar HalmageanΒ shared a list of topics that are important to focus on when learning Rails

What do you need to know as a Rails beginner? Here are some big topics: 1. Databases 2. REST 3. MVC 4. Testing 5. APIs 6. Deployment 7. Mailers 8. Asset management 9. Background jobs 10. Storage 11. Hotwire 12. Websockets And build lots of pet projects.
Source:Β @chalmagean

πŸ‘‰ Joel Drapper announced the release of Phlex 1.0:

Source: @joeldrapper@ruby.social

πŸ‘‰Konnor RogersΒ published the first version ofΒ Rhino Editor - an Actiontext compatible editor (currently based on TipTap and having plans to integrate with ProseMirror):

Source:Β @RogersKonnor

πŸ‘‰Cezar HalmageanΒ shared some ideas to build with Rails:

Struggling to find ideas about what projects to build with Rails? Here are a few ideas: - Expenses tracker - Pomodoro app - Blog engine - Reddit clone - Notes app - Chat system - Weight tracker - Bill tracker - Personal journal - Book database - Recipe platform - Forum
Source:Β @chalmagean

πŸ‘‰ Greg NavisΒ shared a code sample about working with Ruby date objects:

πŸ’‘ Ruby tip: Date objects provide a bunch of methods for determining various facts about a date βœ… Date, month, year βœ… Leap year βœ… Week number βœ… Day number (in a year) βœ… Monday? Tuesday? ... Sunday? It's all vanilla Ruby, no Rails needed!
Source:Β @gregnavis

πŸ‘‰Ko1Β sharedΒ a link to Ruby Consultancies Companies

Source:Β @_ko1

πŸ‘‰Kevin NewtonΒ shared a Ruby code sample showing a bit of the Perl heritage/inspiration:

Source:Β @kddnewton

Josh Cheek replied, showing more examples:

Source: @josh_cheek

πŸ‘‰Chris OliverΒ shared a code sample showing how to use custom Turbo StreamActions in Rails:

I love the power custom Turbo StreamActions gives you in Rails.
Source:Β @excid3

πŸ‘‰Β Greg NavisΒ shared a thread showing the Ruby Forwardable module:

Source:Β @gregnavis

πŸ‘‰Β Tim MorganΒ sharedΒ their Compiler Fun series:

Source:Β @timmrgn

πŸ‘‰David TerenΒ sharedΒ a guide written with ChatGPT help about Paradigms of Ruby: OOP Principles & Design Patterns

I've been collating the #Ruby OOP answers #ChatGPT has provided me.
Source:Β @davidteren

πŸ‘‰ u/Merlynndo asked a question on r/ruby about how to get better quickly:

Source: r/ruby

Here are some of the responses:

  • Books: Programming Ruby 3.2, Practical Object Oriented Design with Ruby

  • β€œIf you need to edit something and you don’t understand the surrounding code, do some googling (or searching api references) to figure it out. Likewise, if you find an example code somewhere, take the time to understand it and all the syntax. That’s a quick way to pick up lots of useful knowledge.” (source)

  • Pair programming with many people in the company to get technical knowledge and domain and company-specific knowledge (source)


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


🧰 Gems, Libraries, and Updates

🧰 Brad Gessler shared they added in sitepress support for Phlex and ViewComponents: read the commit

🧰 Gavin Morrice talked about their gem jiminy. Here is a good explanation from gem Github:

Source: https://github.com/bodacious/jiminy

🧰 Vladimir Dementyev released a new version of test-prof: Read release notes for v 1.1.0

🧰 Kevin Newton published a new gem rails-pattern_matching:

This gem provides the pattern matching interface forΒ ActiveModel::AttributeMethods,Β ActiveRecord::Base, andΒ ActiveRecord::Relation

Here is a code sample:

Source: https://github.com/kddnewton/rails-pattern_matching

🧰 Bozhidar Batsov published a new version of Rubocop: Read release notes for v1.40. New cops added:

  • Style/RedundantConstantBase

  • Style/RequireOrder

  • Style/ArrayIntersect

🧰 Leastbad shared a new version for stimulus-hotkeys v2.3:

Source: https://github.com/leastbad/stimulus-hotkeys

🧰 Alessandro Rodi published a new gem named validation_errors:

Source: https://github.com/coorasse/validation_errors

🧰 Guillaume Briday shared a npm package they created turbo-frames-debug that helps add debug information for turbo frames.

🧰 A new improvement is coming in Ruby: ObjectSpace.dump_all: dump shapes as well


🀝 Related (but not Ruby-specific)

🀝Jason Swett shared about making sure the AI writes also tests not only code:

AI can write code. But probably not ALL the code. Programming will have to be a collaboration between AI and humans. In that case, we better make sure to have the AI write not just code but also tests. Otherwise humans will inevitably introduce regressions.
Source:Β @JasonSwett

🀝 Kent Beck shared a piece of advice about reversible/irreversible changes:

Source: @KentBeck

🀝 Peter Solnica shared:

Source: @solnic@ruby.social

More content: πŸŽ₯ 🎧 πŸ—ž

Slides

Charles Oliver NutterΒ sharedΒ their slides from RubyConf: Using JRuby: What, Why, When, and How

Nate Berkopesc shared their slides from RubyConfTh about: A Beginner’s Guide to Puma Internals

Newsletter

πŸ—ž Greg MolnarΒ published a new edition of This Week in Rails:Β Disabled IRB autocompletion, bugfixes and more!

πŸ—ž Ruby Radar published a new edition: Ruby Radar #80 - Rest In Peace, Chris Seaton

πŸ—žοΈ Ruby Weekly published a new edition: RIP Chris Seaton

πŸ—žοΈ Ruby LibHunt published a new edition of the Awesome Ruby Newsletter

Podcasts

🎧Jason Swett published a new episode of The Code with Jason Podcast: 166 - Feature Flags and Duplication with Julian Fahrer

🎧 Code And The Coding Coders Who Code It published a new episode Episode 12 - Lucian Ghinda

🎧 The Ruby on Rails Podcast published a new episode Episode 447: Rubyconf Mini Recap + The Rails Foundation (Brittany + Jemma + Emily)

🎧 Ruby For All published a new episode about GitHub Codespaces & Julie's RubyConf Mini Recap

🎧 Remote Ruby shared a new episode about Jason gets Twitchy with Hanami

Videos

πŸŽ₯ Creston JamisonΒ sharedΒ a new episode for Rubber Duck Dev Show: What Happens After RubyCritic with Ernesto Tagwerker

πŸŽ₯ The Rubber Duck Dev ShowΒ shared the last episode this year about Should you store business logic in your database?

πŸŽ₯ Nate HopkinsΒ published a new video aboutΒ Quick intro to ReflexBehaviors

πŸŽ₯ The Rubber Duck Dev ShowΒ sharedΒ a stream from Jason Charnes about using Hanami. There are already two videos saved on Jason stream:

  • Hi, Hanami

  • Building a Ruby web app with Hanami and ROM

πŸŽ₯ Drifting RubyΒ published the video version ofΒ This Week in Rails - Dec 9th, 2022

πŸŽ₯ Deanin published a new video about Keyboard Hotkeys With Stimulus In Ruby On Rails 7

Articles

Celso De Sa published an article about SOLID Principles Explained by GPT-3 with Analogies and Ruby Code

Mike MunroeΒ sharedΒ an article they published about their program of helping junior Rails devs OBLSK 30/60/90 Apprenticeship Program

PaweΕ‚ Ε›wiΔ…tkowskiΒ published a new article on AppSignal aboutΒ A First Look at Hanami 2 for Ruby

Gavin Morrice published an article about Understanding n+1 query problems in Ruby on Rails

Kevin NewtonΒ published a series of articles this week explaining how the CRuby virtual machine works. These articles are great if you are looking to understand how Ruby works inside:

  • Advent of YARV: Part 5 - Changing object types on the stack

  • Advent of YARV: Part 6 - Calling methods (1)

  • Advent of YARV: Part 7 - Calling methods (2)

  • Advent of YARV: Part 8 - Local variables (1)

  • Advent of YARV: Part 9 - Local variables (2)

  • Advent of YARV: Part 10 - Local variables (3)

  • Advent of YARV: Part 11 - Class and instance variables

Benito Serna published a new article about Examples to explore possible race conditions when caching custom computed values in Rails

Thought BotΒ published a new article aboutΒ A Journey into Site Reliability Engineering.

Scott WatermasyskΒ published an article aboutΒ Optimizing ActiveRecord SQL Memory Usage in Rails

Yukihiro Matz shared an article about Ruby, meet Compute@Edge! Building on Fastly with Yuta Saito

Greg NavisΒ sharedΒ an article they wrote about Elixir-style Pipelines in 9 Lines of Ruby

Janko Marohnić published an article about Social Login in Rails with Rodauth

Workhunty published an article analyzing data from Linkedin: Number of open positions for Ruby jobs per country


Thanks for reading Short Ruby Newsletter! If you enjoyed this and want to receive the newsletter weekly in your inbox, consider subscribing:

Share this post

πŸ‘ Short Ruby News - edition #22

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