monad-rail: Railway-oriented error handling for Haskell

[ bsd3, control, library ] [ Propose Tags ] [ Report a vulnerability ]

Monad.Rail is a Haskell library for Railway-Oriented Programming (ROP), a functional approach to error handling that makes error paths explicit and composable.

The library provides:

  • RailT - A monad transformer for building reliable applications

  • Type-safe error handling with support for error accumulation

  • Automatic JSON serialization of errors for logging and monitoring

  • The <!> operator for combining validations while collecting all errors

  • Integration with any error type implementing HasErrorInfo

Railway-Oriented Programming separates success and failure paths, making it easy to handle both cases explicitly. The <!> operator is particularly useful for validation scenarios where you want to report all validation errors at once rather than stopping at the first failure.

For more information and examples, see the documentation for Monad.Rail.

Modules

[Index] [Quick Jump]

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

Versions [RSS] 0.1.0.0
Change log CHANGELOG.md
Dependencies aeson (>=2.2.3.0 && <2.3), base (>=4.17 && <4.21), mtl (>=2.3.1 && <2.4), text (>=2.1.3 && <2.2) [details]
License BSD-3-Clause
Author Ismael Carlos Velten
Maintainer ismaelcarlosvelten@gmail.com
Uploaded by ivelten at 2026-03-19T01:09:20Z
Category Control
Source repo head: git clone https://github.com/ivelten/monad-rail
this: git clone https://github.com/ivelten/monad-rail(tag v0.1.0.0)
Distributions
Downloads 0 total (0 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs uploaded by user
Build status unknown [no reports yet]