I was worried about Acid State generating to many event files and checkpoints, and the user "stepcut" told me there were an implementation of the solution in acid called createArchive which delete old events... The problem is that when I use it I get this error :
<fileName.exe>: thread blocked indefinitely in an MVar operation
I think its due w7 permissions but when i run it under 'admin' i cant get to see console but the events files are still there so i assume its not working.
If i run code through ghci, i dont get an error, but it locks the console, so i need to CtrlC to keep working.
did somebody got this error?
It's certainly not anything to do with permissions. The error arises when trying to read from an empty MVar
to which no-one can write, or similarly trying to put a value in an MVar
that is already full and won't be emptied. It means there is a bug in someone's code.
If vivian (in the comments) is right about this being related to this GHC bug then this related bug suggests that compiling with -fno-state-hack
might suffice as a workaround for your problem. Looks like the bug has existed since at least GHC 7.2.2, but is fixed in the (so far unreleased) GHC 7.4.2.
Alternatively, it might just be a bug in acid-state
, which appears to make significant use of MVar
s. In that case you should make sure you are using the latest version of the library, then try to produce a simple testcase so that other people can verify the problem.
This error disappeared from my program after I compiled my program without optimizations, as in ghc --make -O0 Main
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With