11:27:22 <mekeor> sorry for asking twice but i forgot the answer:  how do i use handlers for certain (sub-)domains? i mean something like the 'dir'-function but for sub-domains.
12:39:45 <ozgura> hi. I get a 500 (Internal Server Error) as a response. How can I debug this?
13:09:04 <HugoDaniel> ozgura create a handle that prints everything and runs on top of all the others
13:09:20 <HugoDaniel> then you can comment it out in production
13:09:40 <HugoDaniel> i usually have a handle that prints requests and responses, and some other stuff that i like to see
13:11:04 <ozgura> what is a handle? do you mean an exception handler?
13:13:06 <mekeor> ozgura: did you ever write a happstack-application?
13:14:29 <mekeor> :)
13:15:12 <ozgura> I believe I did.
13:15:35 <mekeor> ozgura: take a look at www.happstack.com/C/ViewPage/9 .
13:16:09 <ozgura> OK, so you mean routing handlers?
13:16:27 <mekeor> there, each of 'dir "echo"    $ echo' and 'homePage' in the definition of myApp are handlers.
13:16:56 <mekeor> ozgura: i think so, yes. i'm not sure how they are called exactly.
13:17:03 <mekeor> ACTION is a happs-noob, actually.
13:17:21 <ozgura> HugoDaniel used the word "handle" rather than handler
13:17:35 <ozgura> and I thought he might be referring to something different
13:17:37 <ozgura> anyway.
13:17:57 <ozgura> I don't understand how creating a catch-all handler would help in this case
13:18:22 <ozgura> because I successfully do the routing already, but one of the routes just give a 500 response back
13:19:16 <mekeor> ozgura: oh, i see. sorry.
13:19:29 <HugoDaniel> http://hpaste.org/68625
13:19:30 <ozgura> no need to be sorry :)
13:19:31 <HugoDaniel> ozgura, check it out
13:19:33 <tazjin> Do you get anything on the terminal stdout? Are you using web-routes or normal routing?
13:19:36 <HugoDaniel> yes, sorry
13:19:47 <HugoDaniel> thats usually my approach
13:19:58 <HugoDaniel> its simple, but it fits my needs :)
13:20:31 <ozgura> yeah, but the problem is about the generated response in this case.
13:20:53 <ozgura> so dumping the request body wouldn't help
13:20:56 <ozgura> but thanks.
13:21:34 <ozgura> tazjin: I am using normal routing, and nothing on stdout other than my miserable debug efforts
13:22:03 <tazjin> Can you show us some of your code? (the route and the handler that it calls?)
13:22:58 <HugoDaniel> ozgura: print everything out, and see where it breaks
13:23:43 <HugoDaniel> and have two modes, a development where everything is printed, and a production that doesn't print anything
13:24:32 <ozgura> tazjin: it is *very* simple really.
13:24:52 <ozgura> dir "sth" $ path $ \ s -> do methodM POST; decodeBody'; doStuff
13:25:06 <ozgura> doStuff uses "looks" to get some post variables
13:25:12 <ozgura> and generates a json response
13:25:35 <ozgura> can this be timeout related?
13:27:53 <tazjin> I think there's a separate error code for timeouts. Can you paste your doStuff function on hpaste.org ?
13:28:44 <ozgura> unfortunately
13:28:58 <ozgura> that part is tied to a huge codebase
13:29:03 <ozgura> wouldn't help
13:29:04 <ozgura> but,
13:29:10 <ozgura> i found the problem
13:29:27 <ozgura> embarrassingly it was an incomplete case in a function
13:29:43 <tazjin> oh
13:29:51 <ozgura> I had to invoku doStuff from ghci to see the error
13:30:03 <HugoDaniel> oh, those are tricky
13:30:07 <ozgura> what surprises me is happstack not giving me access to the error message
13:30:24 <HugoDaniel> ghc usually warns about missing patterns... those should actually be errors imo :/
13:31:05 <ozgura> well this is not exactly a missing case, but anyway. I just wanted to keep it simple :)
13:31:29 <ozgura> if I understand correctly happstack generates the 500 from http://hackage.haskell.org/packages/archive/happstack-server/latest/doc/html/src/Happstack-Server-Internal-Handler.html
13:31:35 <ozgura> (search for "500")
13:33:34 <ozgura> aaaaah silly me. happstack gives the exact same error message, it was just my javascript not understanding it.
13:33:53 <ozgura> sorry for the whole noise, I'll shut up now. :)
15:22:07 <donri> 2814 lines cabal file yay
15:23:53 <mekeor> heh
15:40:58 <HugoDaniel> ouch :)
15:41:14 <HugoDaniel> that must take an eternity to resolve depencencies
15:41:36 <donri> nah, most of it is in data-files due to the limits of wildcards there
15:41:58 <donri> bundling yui
15:47:20 <HugoDaniel> :)
20:36:31 <ppseafield> Hey, I'm fiddling around with happstack-lite, but I'm getting `No instance for (ToMessage Html)' when I use toResponse on any Html. Any idea what I can do?
20:37:51 <stepkut> ppseafield: yes, that is because happstack-server is built against blaze-html 0.4, but you also have blaze-html 0.5 installed
20:38:24 <stepkut> you can use the -package flag to specify 0.4.x.y
20:38:41 <ppseafield> stepkut: Thanks.
20:38:42 <stepkut> I am hoping to push a new happstack-server that updates to blaze-html 0.5 later today
20:39:21 <stepkut> while updating happstack-server itself was easy.. it had some large side-effects that hade to be dealt with
20:39:31 <stepkut> but I just got everything working
20:39:54 <stepkut> so now it is just a matter of bumping versions, committing things and uploading to hackage
20:43:14 <stepkut> donri: I am looking to release the happstack.com source code this weekend
23:22:33 <donri> stepcut: nice :)
23:22:42 <stepcut> :)
23:49:40 <tazjin> For a second I thought that new thread on the mailing list was spam