~/talk

No Static Types? No Problem!

Talkat RubyConf 2024 · 2024-11-13..11-15· [ruby, developer-experience]
slides:none on file

A small Rails app called the cookie_cutter app has a rake batch that sometimes passes a recipient string instead of a Person and charges payment before crashing; Sorbet catches that mismatch as a runtime and editor error by failing at the method call, RBS/YARD give editor hints, and the new literal gem enforces checks at initialization. Fixes shown include coercions (string → Person, HashWithIndifferentAccess), GlobalID lookups, a refactored checkout object that validates in initialize, and the null object pattern to avoid late failures.

AI-written summary · about

  1. 0:00Introduction
  2. 15:07What is a type in Ruby
  3. 27:20Static type systems overview
  4. 35:10Caller vs static typing
  5. 48:15Break and return hook
  6. 52:31Ruby type errors in production
  7. 1:00:20Data coercion techniques
  8. 1:18:58Object design and encapsulation
  9. 1:33:22Polymorphism and null objects
  10. 1:43:22Static typing pros and cons
  11. 1:48:44Q&A
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.