Re:Open-sourcing Sorbet: a fast, powerful type checker for Ruby
by imhoguy on Thursday June 20, 2019 @03:07PM
(#20236172)
Excellent work! I wonder if somebody already tried to run it against Rails codebase.
[ Parent
| on HN ]
Re:Open-sourcing Sorbet: a fast, powerful type checker for Ruby
by hdoan741 on Thursday June 20, 2019 @04:05PM
(#20236787)
Original author of sorbet-rails here. I tried and it did take some work to integrate with Rails, because how dynamic Rails code can be.
But it's pretty useful once setup. It can know when an attribute is nullable or non-nullable, which is a big deal. We even use Sorbet to limit the usage of some dynamic Rails API so that it's more sane.
Re:Open-sourcing Sorbet: a fast, powerful type checker for Ruby
by darkdimius on Thursday June 20, 2019 @03:49PM
(#20236647)
Companies that use Rails have also started working on https://github.com/chanzuckerberg/sorbet-rails, worth checking out!
Re:Open-sourcing Sorbet: a fast, powerful type checker for Ruby
by dwheeler on Thursday June 20, 2019 @08:45PM
(#20238899)
While we're on the topic of static analysis of code that uses Rails... I suggest also using other static analysis tools as they make sense. I lead the Railroader project, an open source security static analysis tool for programs built on Rails. It doesn't guarantee finding all security problems, but it can help. More info here: https://railroader.org/
Re:Open-sourcing Sorbet: a fast, powerful type checker for Ruby
by darkdimius on Thursday June 20, 2019 @03:15PM
(#20236260)
Yes, join the slack! While Stripe doesn't run rails all other companies in private beta did!
Re:Open-sourcing Sorbet: a fast, powerful type checker for Ruby
by ksec on Thursday June 20, 2019 @03:46PM
(#20236616)
Both Shopify and Kickstarter are on Rails.
I wonder why Github didn't join the private Beta?
Re:Open-sourcing Sorbet: a fast, powerful type checker for Ruby
by heartbreak on Thursday June 20, 2019 @07:16PM
(#20238397)
Maybe their forked version of Ruby had something to do with it.
Re:Open-sourcing Sorbet: a fast, powerful type checker for Ruby
by WA9ACE on Friday June 21, 2019 @02:09AM
(#20240244)
IIRC last time I poked at their enterprise image and dumped the code there were bits of custom type annotations. That was around 2-3 years ago.
Re:Open-sourcing Sorbet: a fast, powerful type checker for Ruby
by ptarjan on Friday June 21, 2019 @03:08AM
(#20240537)
The parser for Sorbet was actually entirely given to us by GitHub. They were fabulous partners early on in the project and we're grateful for their contributions.
Re:Open-sourcing Sorbet: a fast, powerful type checker for Ruby
by heartbreak on Friday June 21, 2019 @11:40AM
(#20243474)
Understated, but awesome! Thanks for the insight!