IRC Logs for #circuits Monday, 2013-08-19

prologicit's required00:01
prologiccircuits.web will throw an error if you try to serve up a file with a relative path00:01
prologicyou just need to use the full path to whatever it is you're serving up00:01
tokyopancake_right00:01
prologicthere is also serve_file00:02
prologicwhich takes optional parameters like type and dispotition00:02
tokyopancake_yeah I noticed00:02
tokyopancake_but in essence they are the same?00:02
tokyopancake_you could still override the headers if you wanted to before calling the serve_download ofcourse?00:02
prologichttp://codepad.org/m7DbcCT400:03
prologicThis will display the image inline in your browser00:03
prologicyes of course00:03
tokyopancake_cool00:03
prologicserve_file is just a convenient shortcut00:03
tokyopancake_that's sweet00:03
tokyopancake_thanks for that james00:04
tokyopancake_your help is much appreciated00:04
tokyopancake_are you in the US or UK?00:05
prologicno problems00:05
prologicneither00:05
prologicAU00:05
prologicso I'm at work right now :)00:05
tokyopancake_ah wow00:05
tokyopancake_lol00:05
tokyopancake_I'm in the UK, it's close to bedtime :)00:05
tokyopancake_I'll catch some sleep, and implement all the rest tomorrow00:06
tokyopancake_have a good day at work, and see you tomorrow :)00:06
prologicnps00:06
*** tokyopancake_ has quit IRC00:06
ninkotechprologic: writing ipv6 (and ipv4) web server is not as easy as it should be...10:43
ninkotechweb/servers.py  in line 60-64 needs some love10:43
ninkotechSocketType = TCPServer if ":" in bind else UNIXServer10:43
ninkotechimagine me having ipv6 style addresses10:43
ninkotechor binding to all of them -- like ("::", 8000)10:44
prologicAhh yes10:46
prologicyou are qutie right10:46
prologicit does need some love :)10:46
prologicthe underling TCPServer supports ipv610:46
prologicso circutis.web.servers should too10:46
ninkotechi have seen tcpserver...10:51
ninkotechbut i was not sure how to use that10:51
ninkotech:D10:51
ninkotechand how to not break compatibility10:51
ninkotech(when trying to figure out how to implement that into web/servers.py)10:53
ninkotechalso, ssl support would be nice :)11:03
ninkotechbut i would rather use https://startpage.com/do/search?nossl=1, as it might be much faster for me11:07
ninkotech(too many little connections)11:08
ninkotechahh, lol wrong link11:08
ninkotechthis one http://blog.affien.com/archives/2013/04/16/simple-elliptic-curve-cryptography-in-python-compatible-with-seccure/11:08
ninkotechdid you see that seccure python implementation i linked to you few days ago?11:08
ninkotechalso msgpack looks to be emerging winner of serializing11:10
ninkotechhttp://msgpack.org/11:10
prologichmm11:29
prologicit should already be possible to use ipv611:29
prologicand ssl11:29
prologicwith circuits.web11:29
spaceone('::1', 8080)15:53
ninkotechhmm did i miss something?  lol15:54
ninkotechi will try and contribute example web server :)15:55
ninkotechi am a bit shaken today, my head got strong hit by hard/sharp object15:56
ninkotech(furniture, not axe)15:56
ninkotechsorry for confusion :)15:57
ninkotech:) ok15:58
*** tokyopancake has joined #circuits16:17
tokyopancakehi16:17
tokyopancakeI'm back for more mayhem!16:17
tokyopancakemy entire circuits app is working16:18
tokyopancakeajax callbacks and whatnot16:18
tokyopancakebut there's one issue16:18
tokyopancakeI think it might be 'session' related?16:18
tokyopancakeI'm rendering an emailConfirmation page for the user, at which time I set a cookie, and this page does a javascript timeout after which it does a window.location.href, back to the original downloadPage16:19
tokyopancakenow in my download method, I set up that if the user comes to this page and has a cookie, and a filename, it should start the download16:19
tokyopancakebut right now, it just calls back to that page, and the emailInput page is rendered again.16:19
tokyopancakeonly when I hit a proper Refresh, do I get the download..16:20
tokyopancakemaybe I'm confused and it's something outside of circuits?16:20
*** tokyopancake has quit IRC20:35
*** tokyopancake has joined #circuits21:04
prologicninkotech, yeah that should work22:05
prologicif it doesn't I'll have to investigate22:05
prologicwhich means setting up my ipv6 tunnel at home again22:05
prologictokyopancake, you'll have to explain a bit more with code22:07
prologicI'm just about leaving home for work22:07
tokyopancakehi22:07
tokyopancakeI'm not sure what my last problem was..22:07
tokyopancakeI think it was the cookies22:08
tokyopancakeI overwrote the cookie headers, and it's working fine now22:08
tokyopancakeEverything is working now22:08
tokyopancakewow22:08
tokyopancakethe only rabbit-hole opening up is I want to set global cookies22:08
tokyopancaketo be able to browse around and download my files without having to leave your email address every single time22:09
tokyopancakebut I don't think circuits has anything to do with this22:09
tokyopancakehang on22:14
tokyopancakeI just figured any parent paths on the cookie will also be returned to its children22:14
tokyopancakethat's great news!22:14
tokyopancakeeverything will be working fine22:14
prologicoh sweet23:10
prologicglad you sorted it out then :)23:10
prologicyes so circuits.web has support for standard cookies23:11
prologicwhich are just transmitted via HTTP headers23:11
prologicit has basic in-memory session handling23:11
prologicbut nothing more23:11
prologicif you want more elaborate session handling you'll have to code it up yourself23:11
prologice.g: a mysql backed session store for example23:11
tokyopancakeah yes23:57
tokyopancakeI'll do it brute force guerilla style this time23:57
tokyopancakeI'm just dumping a userID cookie into the '/' path23:57
tokyopancakeso any directories up will be able to catch that same userID/cookie23:57
tokyopancakeyou can try it out here23:58
tokyopancakehttp://212.71.253.170/download/23:58
tokyopancakebut give me a shout once you've added to the database, so I send you your verif code23:58
tokyopancakethe emailer is working with a application specific password, but is only linked to my own email for the time being23:59
prologicnice23:59
prologicI'll give it a try23:59

Generated by irclog2html.py 2.11.0 by Marius Gedminas - find it at mg.pov.lt!