[Haskell-cafe] Re: [Haskell] ANNOUNCE: control-monad-exception 0.5 with monadic call traces

Henning Thielemann lemming at henning-thielemann.de
Tue Nov 3 08:24:22 EST 2009


Jose Iborra schrieb:
> Folks,
> 
> I'm happy to announce a new release of control-monad-exception with
> monadic call traces,
> available in Hackage. Grab it now while it is still online!
> 
> Monadic stack traces are described in detail in a blog post [1].
> 
> In short, what this means for your code is the ability to generate
> errors like this:
> 
> 500 Internal Server Error
> The CGI server failed with the following error:
> DeleteException (BmPK 2009-10-26 19:39:51.031297 UTC "Testing RPO")
>  in deleteBenchmarkFromPK,
> NarradarBenchmarkDB(src/NarradarBenchmarkDB.hs): (186, 44)
>     deleteBenchmarkFromPK,
> NarradarBenchmarkDB(src/NarradarBenchmarkDB.hs): (186, 25)
>     deleteBenchmarkFromPK,
> NarradarBenchmarkDB(src/NarradarBenchmarkDB.hs): (184, 17)
>     deleteBenchmarkFromPK,
> NarradarBenchmarkDB(src/NarradarBenchmarkDB.hs): (180, 90)
>     deleteTests, NarradarBenchmarkCGI(src/NarradarBenchmarkCGI.hs):
> (108, 3)
>     deleteTests, NarradarBenchmarkCGI(src/NarradarBenchmarkCGI.hs):
> (106, 20)
>     cgiMain, NarradarBenchmarkCGI(src/NarradarBenchmarkCGI.hs): (52, 33)
>     cgiMain, NarradarBenchmarkCGI(src/NarradarBenchmarkCGI.hs): (52, 30)
>     cgiMain, NarradarBenchmarkCGI(src/NarradarBenchmarkCGI.hs): (50, 9)
>     cgiMain, NarradarBenchmarkCGI(src/NarradarBenchmarkCGI.hs): (46, 11)

Sure, this is a nice functionality. But isn't it about debugging, not
exception handling? Internal Server Error means to me, the server has a
bug, thus we want to know, how to reproduce it, thus the stack trace.
For handling expected irregularites, what exceptions are, you would not
need that, right?



More information about the Haskell-Cafe mailing list