Experimental IRC log happs-2007-05-27

Available formats: content-negotiated html turtle (see SIOC for the vocabulary)

Back to channel and daily index: content-negotiated html turtle

These logs are provided as an experiment in indexing discussions using IRCHub.py, Irc2RDF.hs, and SIOC.

04:11:15<nburlett_>hello!
04:11:23<nburlett_>I'd like to try out happs, but I can't get the examples to build
04:25:25<scsibug>nburlett_: try downloading the latest dev version
04:25:46<scsibug>nburlett_: they should all work from there
04:25:57<nburlett_>scsibug: I used darcs to pull the 0.8.8 tag.. is there a way to tell it to pull the latest?
04:26:23<scsibug> darcs get --partial http://happs.org/HAppS
04:26:52<nburlett_>no way to ask darcs to swtich my current one?
04:27:11<nburlett_>(not that it matters, I'm just trying to figure out darcs)
04:27:18<scsibug>i'm afraid I don't know enough about darcs to answer that...wish I did
04:27:21<nburlett_>no worries
04:27:28<nburlett_>ACTION fetches HAppS
04:27:37<scsibug>I just know that I submitted patches to fix the examples because I had the same problem you did ;)
04:28:00<nburlett_>scsibug: thanks :->
04:29:57<scsibug>perusing through the changelogs, it looks like there is the start of a new tutorial, sweet :)
04:30:05<nburlett_>huzzay
04:30:12<scsibug>an extra bonus of getting the dev copy i guess :)
04:30:30<nburlett_>I want to get away from rails, but I'm not sure if HAppS is the way to go :-<
04:33:23<jeffz>ACTION is interested in HAppS to do away with php.
04:33:39<scsibug>and I'm a J2EE guy ;)
04:33:54<nburlett_>I write a lot of Twisted.Web at work
04:34:01<nburlett_>I like it for what I'm doing
04:34:09<nburlett_>but in my spare time, I'd prefer something else
04:34:11<jeffz>hmm, I'd like to avoid the Java stuff I do too :p
04:34:35<nburlett_>ug, java
04:35:35<jeffz>I've grown even less fond of it since I read someone say it was the new COBOL.
04:35:42<scsibug>that it is
04:36:35<scsibug>ACTION shudders at how much auto-generated java code will have to be supported for the next umpteen years..
04:37:25<scsibug>atleast legacy COBOL was written by real people, afaik
04:37:39<jeffz>ACTION is still waist deep in auto-generated cobol.
04:38:09<scsibug>wow, nevermind then... those who don't study history are doomed to repeat it I suppose..
04:40:51<scsibug>this channel is way too quiet most of the time
04:41:18<scsibug>it impedes my usual process of learning by osmosis
04:47:22<nburlett_>scsibug: that didn't seem to help :-<
04:47:39<nburlett_>@paste
04:47:39<lambdabot>Haskell pastebin: http://hpaste.org/new
04:48:35<nburlett_>http://hpaste.org/68
04:53:03<nburlett_>scsibug: any ideas?
04:56:49<nburlett_>awesome, the code in the tutorial doesn't build either
06:08:10<scsibug>nburlett: what isn't compiling?
06:08:24<scsibug>I think all I had to fix was hello_world and httpd
06:09:33<nburlett>httpd is borked
06:09:40<nburlett>http://hpaste.org/68
06:09:53<nburlett>and I'm trying the tutorial, and it won't work for me either :-<
06:10:14<scsibug>I'm afraid that API-ish things are just changing too frequently :(
06:10:35<scsibug>you /could/ get 0.8.8, and just pull my specific changes
06:11:05<nburlett>blah
06:11:16<scsibug>ya :/
06:11:19<nburlett>maybe I should give HAppS a few more months to stablize
06:11:44<nburlett>I need to spend most of this weekend at the office beating Python into submission, so I don't really have time this weekend anyway ;<
06:14:55<scsibug>sorry that didn't end up working for you. I will be taking a look at what is broken in HEAD and doing my best to fix it, fyi.
06:15:13<nburlett>thanks
06:16:17<nburlett>HTTP request failed with: <socket: 8>: hPutBuf: illegal operation (handle is finalized)
06:17:38<nburlett>hmm.. that just seems to be what it does if I don't put the /index.html
06:53:37<nburlett>huzzay, the tutorial code is working :->
11:08:42<tuukkah>i'm currently a bit lost with h, hs, multi trying to implement a serverpart which calls other serverparts in its implementation
11:09:39<tuukkah>i can use multi to turn a list of serverparts into one serverpart, but how would i call that serverpart within another?
11:10:37<Saizan>why do you need to call the server part? and not directly the handlers?
11:11:32<tuukkah>because i want to have a list of server parts depending on the request uri
11:13:00<Saizan>have you seen multiIf?
11:13:38<Saizan>however, runServerParts :: (Monad m, Monad m') => [ServerPart m request m' response] -> request -> m (Either request (m' response)), is the way server parts are runned
11:13:42<tuukkah>no, that might be exactly what i want
11:15:09<tuukkah>right, the definition of multiIf calls runServerParts :-)
11:15:22<Saizan>yeah :)
11:15:29<tuukkah>thanks Saizan, i think i can find a way now :-)
11:15:41<Saizan>i use it like this, for example:
11:15:50<Saizan>,multiIf (Prefix ["admin"]) [GET,POST] [h () () $ seeOther $ withSesR withSession (checkUser withAdmins) .... ]
11:54:33<tuukkah>h (Prefix ()) () $ \path req -> getTime >>= \time -> let ?time = time; ?root = concatMap (\(_::String) -> "../") path in runServerParts [app] req
11:56:14<tuukkah>this makes ?time and ?root available everywhere in app
11:57:56<Saizan>> concatMap (const "../") (replicate 5 "path")
11:57:58<lambdabot> "../../../../../"
11:59:30<tuukkah>hmm, do i have a bug or are you saying (const "../") is a better way to write (\(_::String) -> "../") ?
12:00:06<Saizan>no, it just wasn't clear to me what you were doing :)
12:11:16<tuukkah>so actually there is a bug since now it's Prefix () instead of Prefix ["somepage"]
12:13:37<tuukkah>thus: h (Prefix ()) () $ \(path::[String]) req -> getTime >>= \time -> let ?time = time; ?root = concatMap (const "../") $ drop 1 path in runServerParts [app] req
13:34:05<tuukkah>Saizan, where should we add these examples?
13:37:26<Saizan>in the tutorial on the wiki maybe?
14:00:57<tuukkah>i think i'll add a section about this later
14:12:20<Saizan>cool
19:30:36<ndm>i don't suppose Alex is in this channel?
19:31:16<ndm>he was asking about deriving Xml and encoded Data instances with Data.Derive
19:35:13<ndm>"Currently, you still have to write instances for FromMessage and ToElement, but we hope to make that automatic soon."
19:35:21<ndm>that looks like a prime target for Data.Derive
19:37:59<Igloo>He's here as alexj* when he's online
19:38:39<ndm>cheers
22:26:43<tuukkah>does this stuff make sense: http://www.haskell.org/haskellwiki/HAppS_tutorial#How_to_structure_your_handlers.3F
22:26:46<lambdabot>Title: HAppS tutorial - HaskellWiki, http://tinyurl.com/2d9fra
22:28:10<tuukkah>Saizan, your multiIf example could go between hs and runServerParts but i don't know enough to actually write about it
22:32:23<Saizan>uhm
22:33:06<tuukkah>see, i've never used sessions %-)
22:33:30<Saizan>well multiIf doesn't really have much to do with sessions :)
22:33:46<Saizan>i think a cleaner example maight come from hpaste code
22:34:35<Saizan>i'll add it tomorrow
22:38:43<tuukkah>i can try to look at hpaste code myself, but it would be cool if you could improve on it tomorrow :-)
22:39:37<tuukkah>is http://zzodici.yi.org/s/hpaste-devel the right repo, it's quite slow
22:41:17<Saizan>well that's the one on my machine, the only one i'm sure compiles with current happs
22:41:48<Saizan>shapr might have pushed the patch on the "official" one on scannedinavian
22:42:07<tuukkah>ok, sorry for using your upload bandwidth :-)
22:42:35<Saizan>np :)
22:42:45<nburlett>isn''t that tutorial out of date?
22:43:50<Saizan>http://www.scannedinavian.com/~eric/hpaste-devel <-- a quick darcs diff says that the patch have been applied
22:43:57<Saizan>*patches
22:44:10<Saizan>nburlett: have you found non-working code?
22:44:25<nburlett>Saizan: I thought I had... but now I don't recall
22:44:41<nburlett>maybe it's the one in my checkout that's out of date
22:45:02<nburlett>ah yes, that must have been it
22:46:15<Saizan>well, please report if you happen to find something broken :)
22:46:24<nburlett>ok, I will
22:46:33<nburlett>I just got some of the HAppS stuff working last night
22:46:37<nburlett>I don't ahve a lot of free time though
22:46:38<nburlett>:-<
22:46:50<nburlett>right now I'm trying to track down a python out of memory error on my embedded system :-<
23:55:16<tuukkah>posted something about multiIf in HPaste and deployment of HAppS applications
23:57:33<tuukkah>now I don't think the HPaste example came out well, since i can't see why you wouldn't instead of multiIf (Prefix ["admin"]) ... [ hs () .. rather use multi [ hs (Prefix ["admin"]) ...
23:59:47<tuukkah>especially since there's h ["admin","delete"] anyway instead of h ["delete"]. first i thought the latter would be outside the scope of HAppS, but perhaps you could create combinators for Prefix

Back to channel and daily index: content-negotiated html turtle