02:42:50 <stepcut> srhb: yeah, looks right
02:43:14 <stepcut> :: SimpleForm Text
15:58:24 <srhb> In the crash course on reform, in the definition for postPage, a function "form" is used. Where is that from?
15:59:31 <srhb> Derp, it says so.
16:42:21 <srhb> Hum, am I supposed to use decodeBody manually also when using reform?
16:48:08 <donri> srhb: yup. happstack-foundation does it for you though
16:50:39 <srhb> Haven't yet checked that out.
16:52:19 <donri> though it chooses hsp for you
16:54:04 <srhb> I'm confused. I have a testPage :: ServerPartT IO Response but I'm not allowed to liftIO $ decodeBody ... in it
16:54:05 <srhb> Why?
16:54:23 <srhb> I get no instance for ServerMonad (IO)
16:57:52 <srhb> And actually i would expcet to be able to juse use decodeBody directly in there. But then it seems as if I haven't even called it. Compiles, but I can't get at the input data.
17:01:45 <donri> srhb: wrong type, don't liftIO
17:02:04 <srhb> Indeed.
17:02:20 <srhb> But nothing happens if I just decodeBody (defaultBodyPolicy ...)
17:02:30 <donri> where are you doing that?
17:02:41 <srhb> In the Right msg -> do .. part
17:02:49 <srhb> Of the page that handles the reform stuff
17:03:02 <srhb> Ie. that's the Right result of happstackEitherForm
17:03:03 <donri> you need to decodeBody before you do anything that uses it
17:03:10 <srhb> Is that not before?
17:03:15 <donri> nope
17:03:17 <srhb> Right msg -> decode ... >> use stuff
17:03:28 <srhb> How come? :S
17:03:34 <donri> do it before happstackEitherForm
17:03:41 <srhb> I see.
17:03:44 <alpounet> ACTION should switch to reform
17:03:47 <srhb> Well, no, I don't, but ok. Thanks.
17:03:52 <srhb> alpounet: Hmm. :P
17:04:08 <donri> it has to read the request body to validate the form
17:04:17 <alpounet> well it's supposed to be the nicest solution
17:04:31 <donri> alpounet: mm_freak_ is working on a netwire based solution
17:04:35 <srhb> alpounet: I'm just griping because I've been battling with it for days without really getting anywhere.
17:05:39 <alpounet> donri, I think I'll stay with the stock one
17:07:40 <alpounet> srhb, just that decodeBody issue?
17:42:30 <srhb> alpounet: Nah, everything. But maybe it's just my type-fu that's not strong enough
17:42:55 <alpounet> i'm not fond of the API either, though
18:08:49 <srhb> What do people do to get rid of annotations on Text everywhere with OverloadedStrings?
18:09:53 <mightybyte> I rarely have that problem.
18:10:04 <srhb> Okay.
18:10:10 <mightybyte> But I write type signatures for almost all my functions.
18:13:44 <srhb> ahppstackEitherForm (form "/foo") bar baz <--- need to annotate "/foo"
18:15:56 <mightybyte> Ahh, I don't use reform
18:17:46 <srhb> People keep telling me to use it.. :P
18:47:18 <mightybyte> srhb: Oh, I just ran into that issue.
18:47:27 <mightybyte> But it was only because I was using Text.Printf.
18:48:01 <mightybyte> And a type signature on the right function eliminated the need to use an inline one.
18:50:24 <donri> srhb: one solution in this particular case is to use web-routes for the form
18:50:59 <donri> (form MyFormRoute)
18:51:55 <donri> assuming you're using hsp ...
19:24:48 <srhb> I'm using Blaze.
19:25:02 <srhb> But yeah, that was just one place.
19:25:15 <srhb>  ... <*> label ("Description: " :: Text) ++> inputText "" <++ br ...
21:33:39 <stepkut> overloaded strings drives me nuts
21:33:53 <stepkut> I think the solution there is to add labelText
21:34:38 <stepkut> which I have actually added to reform-hsp, but not yet reform-blaze
21:35:01 <stepkut> anyone, mm_freak_ is supposed to create something to replace reform anyway :)
21:42:05 <mm_freak_> i have to do other things right now, but it's still planned =)
21:42:37 <mm_freak_> the next library i release is crypto-related, so it may actually be interesting here as well
21:42:45 <stepkut> \o/
21:48:42 <donri> srhb: label MyI18nDescriptionMessage! yay hsp
21:48:55 <stepkut> :)
21:49:33 <stepkut> srhb: there should really be a labelText function I think (which just calls label, but expects only a Text argument)
21:50:58 <donri> t = id :: Text -> Text
21:51:15 <donri> label (t"Description:")
21:51:19 <stepkut> :)
21:52:29 <donri> {-{-# LANGUAGE OverloadedStrings #-}-}
21:54:07 <donri> but then you have to call fromString or pack on strings to get Text instead :(
21:55:12 <donri> {-# OPTIONS_GHC -F -pgmF stepcut's-magical-text-literals2hs #-}
21:55:21 <stepkut> make it so!
21:55:47 <donri> [t|Description:|]
21:55:55 <donri> nowait t is taken
21:56:00 <stepkut> :)
21:57:19 <donri> label <>Description:</> -- does this work in hsp?
21:58:13 <stepkut> I think it would be, label <%>Description</%>
21:58:35 <stepkut> I've done, label <span>Description:</span>, but I think <%> </%> should work
21:58:37 <donri> oh right that's the syntax
22:01:04 <srhb> You're right about the t = id thing.
22:01:11 <srhb> At least it's prettier than :: Text littering everywhere. :)
22:01:28 <srhb> I might even consider killing OverloadedStrings and making it just pack
22:03:17 <stepkut> I dislike OverloadedStrings for this very reason.. I think it would be better if you could declare that all the string literals in a file had some specific type like String or Text
22:05:49 <donri> "Description"^.packed -- yay lens!
23:15:13 <srhb> stepkut: Polymorphic modules, please. :-)
23:15:21 <srhb> LIke in ML.
23:15:39 <stepkut> yeah those are nice
23:40:12 <donri> stepkut: btw i noticed you using ProxyFast in hyperdrive. my understanding is that if you use Proxy p => p instead, you get the same correctness guarantees as with ProxyCorrect but can use Fast to run the thing?
23:46:52 <donri> http://ircbrowse.net/browse/freenode/haskell  this would be nice to have for #happs
23:47:03 <donri> chrisdone's latest creation
23:51:22 <bergmark> åhå
23:51:47 <bergmark> i'm trying to use boxen, i don't understand anything :(
23:52:24 <donri> what's boxen
23:56:47 <bergmark> http://boxen.github.com/
23:57:21 <bergmark> some kind of layer on top of puppet
23:57:28 <bergmark> but i don't know puppet either so that doesn't help :)
23:58:24 <donri> bergmark: biegunka?
23:58:37 <bergmark> what :(
23:59:14 <donri> http://biegunka.budueba.com/
23:59:57 <donri> http://biegunka.budueba.com/pages/overview.html