How to prevent a deadlock in reactive-banana with event-switching? (Exception: thread blocked indefinitely in an MVar operation)

This page summarizes the projects mentioned and recommended in the original post on /r/haskell

Our great sponsors
  • WorkOS - The modern identity platform for B2B SaaS
  • InfluxDB - Power Real-Time Data Analytics at Scale
  • SaaSHub - Software Alternatives and Reviews
  • reactive-banana

    Library for functional reactive programming in Haskell.

    I am building a GUI-application in GTK and try to use reactive-banana as the style of FRP seems a lot better to work with in Haskell. The basis works: receiving events from the GTK-side lets me properly update the internal state. The problem however is when I want to create my own events and hook them onto the rest of the event-network I get a deadlock. I already sent an issue on Github, https://github.com/HeinrichApfelmus/reactive-banana/issues/216 , but looking at the commits it seems it is not that actively maintained anymore. I was able to find some kind of work-around for a basic use-case, but it is not enough when dealing with an event-stream that will fire multiple events. I created the following test-code to check where the problem lies (a bit simplified from the one on Github): {-# LANGUAGE RecursiveDo, LambdaCase #-} module Main where import Control.Monad.IO.Class (liftIO) import qualified Reactive.Banana as B import qualified Reactive.Banana.Frameworks as BF

  • WorkOS

    The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts