Proposal to Contribute an Exhaustive Error Check Helper to Effect Library
After my talk at Effect days, I already had one person asking for the code snippet implementing the exhaustive error check. I was wondering, if it was of any value to try and contribute it back to Effect. I've refined its implementation even further using the
The idea is to make it easy to enforce exhaustive error handling without having to type out
I'm also very open to suggestions for a more intuitive name.
effect/Function module:The idea is to make it easy to enforce exhaustive error handling without having to type out
satisfies Effect.Effect<MySuccessType, never, MyRequirements>. I usually reach for this helper in my Kafka consumers at the very top of the message handler, so I can make the decision of whether to retry or discard the message in a single central place. Would anybody else find value in this helper being exported from Effect? If so, would you prefer it to be a standalone function (as suggested above), or like pipe be part of the Effect interface, i.e.:I'm also very open to suggestions for a more intuitive name.
