sketches
unliftio
Our great sponsors
sketches | unliftio | |
---|---|---|
12 | 5 | |
122 | 150 | |
1.6% | 0.0% | |
2.9 | 3.9 | |
2 months ago | 4 months ago | |
Haskell | Haskell | |
- | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
sketches
- Hierarchical Free Monads: Mostly Pointless (2020)
-
Functional Declarative Design: A Comprehensive Methodology for Statically-Typed Functional Programming Languages
but free monads are an effect system and not an ergonomic one. I have a post on how one can do the same with constraints as with Hierarchical Free Monads, except with less boilerplate.
- Teaching GHC to Play Minesweeper
- Teaching GHC how to play Minesweeper
-
What's the modern idiomatic way to write this? / Inductive typeclasses with Nat
I have a post about pretty much exactly this problem. It has a good type families solution (no need to specify the arity of the zipping function) and an even better fundeps one.
- A custom warning hack
- Custom type equality errors
- Trouble in Paradise: Fibonacci
- Trouble in paradise: Fibonacci
- Enumerating type variables
unliftio
-
UnliftIO, ExceptT and Coercible
FWIW, your suggestion is very similar to a proposed instance for MonadUnliftIO (ExceptT e), except that effectfuls use of the type system means that it doesn't suffer from one of the proposed downsides (dubious interaction with catchAny).
-
How introduce `ResourceT` into my stack
Possibly interesting thread here: https://github.com/fpco/unliftio/issues/68
-
Is `MonadBaseControl` dead?
Any way quoting u/snoyberg : https://github.com/fpco/unliftio/issues/17#issuecomment-363655106
-
Try.do is dangerous
That's not true. It's just writing that instance is a bit tricky: https://github.com/fpco/unliftio/issues/68
-
Try.do for recoverable errors in Haskell
However, ExceptT cannot be an instance of MonadUnliftIO – because it necessarily requires multiple exit points. See this discussion which should give you an idea of how hairy and unpredictable this can be.
What are some alternatives?
polysemy - :gemini: higher-order, no-boilerplate monads
recursion-schemes - Generalized bananas, lenses and barbed wire
eff - 🚧 a work in progress effect system for Haskell 🚧
lifted-base - IO operations from the base library lifted to any instance of MonadBase or MonadBaseControl
functional-declarative-design-methodology - Article: Functional Declarative Design
mmorph - Monad morphisms
Workflow - re-startable monad that recover the execution state from a log, and workflow patterns
managed - A monad for managed values
exceptional - A simple Haskell type for pure code that could go wrong.
layers - Modular type class machinery for monad transformer stacks.
ReplicateEffects - Composable replication schemes of applicative functors in Haskell
effectful - An easy to use, fast extensible effects library with seamless integration with the existing Haskell ecosystem.