Get the latest tech news
Idiomatic Errors in Clojure
Dave Liepmann's home on the web
Particulars vary but the goal is usually to rearrange control flow to show the happy path while smoothly handling errors. We have Ivan Grishaev’s pact, fmnoise’s monad-rejecting flow, Adam Bard’s monad-embracing failjure, Druids’ railway-oriented (and secretly-monadic) rop, lazy-cat’s pair-centric tenet, Shantanu Kumar’s casually-monadic promenade …there is no shortage of implementations. Because Clojure doesn’t automatically enforce constraints (whether types or something more expressive) on function arguments the way Java does, those who want to guard against sloppy callers must do so explicitly.
Or read this on Hacker News