snapframework / snap

Top-level package for the official Snap Framework libraries, includes the snaplets API as well as infrastructure for sessions, auth, and templates.
http://snapframework.com/
BSD 3-Clause "New" or "Revised" License
455 stars 68 forks source link

-fdevelopment Snap servers can hang with GHC warnings switched on #130

Open JulianBirch opened 9 years ago

JulianBirch commented 9 years ago

Hi, apologies if this isn't the right place to log this. It's pretty easy to reproduce:

Project compiles fine, then proceeds to hang when you access the first page, printing the warning out on the console.

Having tracked down the cause, I don't know if it's even solvable...

(Updated: initial report was a lot more complex)

chowells79 commented 9 years ago

This isn't solvable so long as we're using hint to do the interpreting. It can't handle code that compiles successfully with warnings.

chowells79 commented 9 years ago

Though hanging is odd behavior. I'm not sure why it'd do that.

mightybyte commented 9 years ago

Could it be a bug in GHC or hint?

JulianBirch commented 9 years ago

This is probably just my inexperience talking, but I really don't understand the behaviour. For instance, my reading of the cabal file says that Wall is switched on, but if I run cabal install I don't get any warnings. So, even if I did cabal install && cabal install -fdevelopment I'd run into the problem.

Edit: I discovered this: http://stackoverflow.com/questions/12273315/how-to-recompile-haskell-with-cabal-build-showing-only-warnings