Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Playing with Sorbet
Search
Luciano Sousa
September 12, 2019
Programming
0
52
Playing with Sorbet
A short presentation about how Sorbet could help your project
Luciano Sousa
September 12, 2019
Tweet
Share
More Decks by Luciano Sousa
See All by Luciano Sousa
Knowing mina deploy
lucianosousa
1
77
Creating your startup without Developer
lucianosousa
0
170
Patterns Falacy v2
lucianosousa
0
120
Project Management like Software Developer
lucianosousa
1
110
The Patterns Falacy - Rails Version
lucianosousa
1
120
Sinatra::Ftw
lucianosousa
0
110
Other Decks in Programming
See All in Programming
RubyとGoでゼロから作る証券システム: 高信頼性が求められるシステムのコードの外側にある設計と運用のリアル
free_world21
0
310
S3ストレージクラスの「見える」「ある」「使える」は全部違う ─ 体験から見た、仕様の深淵を覗く
ya_ma23
0
730
OTP を自動で入力する裏技
megabitsenmzq
0
120
What Spring Developers Should Know About Jakarta EE
ivargrimstad
0
620
メタプログラミングで実現する「コードを仕様にする」仕組み/nikkei-tech-talk43
nikkei_engineer_recruiting
0
200
PHP 7.4でもOpenTelemetryゼロコード計装がしたい! / PHPerKaigi 2026
arthur1
1
130
仕様漏れ実装漏れをなくすトレーサビリティAI基盤のご紹介
orgachem
PRO
6
2.1k
どんと来い、データベース信頼性エンジニアリング / Introduction to DBRE
nnaka2992
1
300
[SF Ruby Feb'26] The Silicon Heel
palkan
0
110
Swift ConcurrencyでよりSwiftyに
yuukiw00w
0
270
Claude Codeログ基盤の構築
giginet
PRO
7
3.4k
コードレビューをしない選択 #でぃーぷらすトウキョウ
kajitack
3
1k
Featured
See All Featured
Utilizing Notion as your number one productivity tool
mfonobong
4
260
Neural Spatial Audio Processing for Sound Field Analysis and Control
skoyamalab
0
220
Become a Pro
speakerdeck
PRO
31
5.8k
Scaling GitHub
holman
464
140k
Leading Effective Engineering Teams in the AI Era
addyosmani
9
1.7k
Art, The Web, and Tiny UX
lynnandtonic
304
21k
Designing Powerful Visuals for Engaging Learning
tmiket
0
280
The innovator’s Mindset - Leading Through an Era of Exponential Change - McGill University 2025
jdejongh
PRO
1
130
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
360
30k
We Analyzed 250 Million AI Search Results: Here's What I Found
joshbly
1
980
Skip the Path - Find Your Career Trail
mkilby
1
84
Navigating Weather and Climate Data
rabernat
0
140
Transcript
Playing with Sorbet
What
Sorbet is a fast, powerful type checker designed for Ruby.
Why
Once upon a time
We expose a public API
Expecting params = { user: { first_name: "Luciano", last_name: "Sousa"
} }
We got a
params = { user: "a" }
TypeError (no implicit conversion of Symbol into Integer)
None
NoMethodError (undefined method `where' for nil:NilClass)
Let’s talk about Java
None
Let’s talk about dynamic vs static typed languages
• •
• • •
String javaString = new String(“I am a Java string”) ruby_string
= “I am a Ruby string”
Dynamic languages
Ruby
Examples
begin do_something rescue StandardErro do_something_else end
Tests
Let's talk about Shopify
~1500 devs
~40 deploys/day
~5 million req/min
~83k req/sec ~170k req/sec peak
Sorbet at Shopify
~36 issues fixed
~17 dead code never hit
~16 name error
~3 wrong args
Maybe some millions
Examples
“I hate type annotations.”
class UserHelper def name_length(name) name.length end end
# typed: true class UserHelper def name_length(name) name.length end end
# typed: true class UserHelper extend T::Sig def name_length(name) name.length
end end
# typed: true class UserHelper extend T::Sig sig { params(name:
String).returns(Integer) } def name_length(name) name.length end end
How it works
Disclaimer
None
# typed: true
None
extend T::Sig
sig { params(name: String).returns(Integer) }
sig { params(name: String).returns(Integer) }
Resources •
Resources •
Resources •
Resources •
Thanks!