- 1y ·
-
Public·
-
ruby.social
If you said "often", or "all the time", I'm curious about what kinds of things you are seeing, and what it would take to catch them sooner in Ruby…
If you said "often", or "all the time", I'm curious about what kinds of things you are seeing, and what it would take to catch them sooner in Ruby…
@noelrap I work with numbers a lot. In my experience, most bugs come from not dealing with nil as a possible value.
Another “issue” is dealing with nil values where it can’t logically be nil.
@noelrap rarely if ever. If anything I've seen Sorbet encourage some really bad patterns when used by novices, especially when T::Struct and interfaces proliferate everything.
@noelrap I answered “all the time”, but I was thinking almost entirely of unhandled `nil`s, which a lot of static type systems also don’t prevent.
@noelrap every time you have an unexpected nil is a type error, right? That seems to be an extremly common class of errors, even if it was caused by a subtle logic bug.