Camelia, the Perl 6 bug

IRC log for #mojo, 2010-11-16

| Channels | #mojo index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:17 forwardever left #mojo
00:18 chansen marcus: BTW the document you where referring me to to doesn't mention "mime type based rending" in the sense you mentioned it on #catalyst (http://search.cpan.org/~kraih/Mojolicious-0.​999939/lib/Mojolicious/Guides/Rendering.pod)
00:22 chansen sri: basically it means content based (user provided data)  dispatching?
00:22 tl left #mojo
00:24 sri chansen: guess you could say that
00:25 sri chansen: i've experimented with Accept, but it's not user friendly at all
00:26 sri we mostly use file extensions through routes
00:26 sri /foo.xml vs /foo.json
00:59 sri btw. iphone 4 rocks! :)
00:59 sri marcus: should have told me how nice the retina display is
01:01 chansen sri: to which browsers has it not been user friendly to?
01:01 sri not the browser, the user
01:01 sri the user usually knows what he wants to see, the browser doesn't
01:02 chansen sri: read client thhen
01:02 chansen s/thhen/then/
01:02 sri file extension has been a great success so far
01:03 sri so not really looking for a new strategy unless it is massively better :)
01:04 chansen Any client not coping is a major bug for implementor, and so far you haven't mention a single one
01:04 sri i'm not sure what you're after
01:04 sri i'm not saying there is a bug
01:05 sri just that rendering based on Accept is clumsy if done automatically
01:06 chansen is it? based on which facts is it clumpsy?
01:07 sri the idea here is to use one action for different content formats, /foo.html and /foo.rss can reach the same action, but different templates, it is simple and just works
01:09 chansen you are wrong, it's not about extensions its's about mime, I suggest you go bak to the basic, RFC 2616
01:09 * sri doesn't follow
01:10 sri are you trying to point out that we are using the word mime in the wrong context?
01:12 chansen you said "here is to use one action for different content formats, /foo.html and /foo.rss can reach the same action", but they can reach the same response since they are not the same resource
01:13 chansen s/can/can't/
01:14 sri ok
01:24 * chansen is off to sleep. I'll happily discuss why it can't be so tomorrow
01:28 alnewkirk left #mojo
02:17 alnewkirk joined #mojo
02:42 tempire joined #mojo
02:43 tempire sri: I presume you're trying to say using /action.[response type] is a whole lot easier than specifying a mime type in the headers.
02:43 sri tempire: yes
02:44 tempire agreed.  It's annoying to debug something by having to write a script or use some tool to present the correct mime type
02:44 tempire response type should be pulled from the extension, but be overridable using the mime-type headers.
02:45 sri you sure about that?
02:47 sri what if you get /foo.rss with Accept: text/html
02:49 tempire Hmm, I wasn't thinking about the default string in all browsers.
02:49 tempire application/xml,application/xhtml+xml,text/ht​ml;q=0.9,text/plain;q=0.8,image/png,*/*;q=0.5 in chrome.
02:50 sri right, html gets preference there
02:51 sri i would always give file extension preference, because the user usually knows what he wants best
02:52 sri Accept "could" be a fallback
02:52 crab any best practices when it comes to doing https with mojo?
02:52 sri just do it? :)
02:53 crab i'm wondering if i should just enable https in apache and leave mojo alone
02:53 sri yea
02:53 sri built in support is mostly for client
02:53 sri and testing
02:53 sri nginx or apache will do it better
02:53 tempire I'm 50/50 on that.  The accept header is RFC defined way of doing things.  Maybe if there's only 1 type in the accept header, use that.
02:54 tempire that would solve the problem for use of use, and still allow for stickler usage.
02:54 tempire *ease of use
02:54 sri think about it the other way, why would the file extension ever be wrong?
02:54 sri unknown ok, but wrong?
02:55 sri and can you trust Accept if the file extension is wrong?
02:55 sri imo this is just common sense :)
02:55 sri screw the rfc
02:55 tempire ...I don't disagree.  And it does make things simpler.
02:55 daviddelikat1 joined #mojo
02:56 tempire But specifically ignoring the rfc seems wrong.
02:56 sri i love RFCs if they make my life easier
02:56 crab sri: thanks
02:56 sri but in this case they just don't
02:57 daviddelikat2 joined #mojo
02:57 tempire One of these days I'm going to have an opinion and you're just going to agree 100% and buy me a 6 pack of izzes.
02:57 tempire one day.
02:57 sri ;p
02:58 sri it's like pipelined requests
02:58 sri they are part of the rfc, but on the client side it is better to ignore that part
02:58 daviddelikat3 joined #mojo
02:59 tempire I feel like it should bother me that I tend to agree with all your arguments.
02:59 sri 2616 is more of an all you can eat buffet
02:59 daviddelikat left #mojo
03:00 sri while others like 4627 are a simple pizza, that needs to be eaten at once
03:00 sri yea, i'm hungry :(
03:01 daviddelikat1 left #mojo
03:03 daviddelikat2 left #mojo
03:04 sri i'm still thinking about merging Mojolicious::Lite and Mojolicious::Routes
03:05 sri $r->get('/foo')->to('foo#bar')
03:05 sri my $under = $r->under('/bar' => sub {...});
03:06 sri $under->post('/bar' => sub {...});
03:06 sri $under->get('/baz')->to('lalala#yada');
03:07 sri $under->get->to('lalala#foo');
03:07 daviddelikat joined #mojo
03:07 sri well, not really merging
03:07 sri but allow them to share some code
03:08 tempire would you still support the old way?
03:08 sri everything
03:08 tempire 'cause that's a hell of a change.
03:08 sri it would be additional sugar
03:08 sri and almost no additional code
03:08 sri maybe 2 or 3 lines more
03:09 daviddelikat1 joined #mojo
03:09 tempire I don't see any downside.
03:09 sri confusion maybe
03:09 sri too many options
03:10 sri upside would be that the lite -> normal transition becomes simpler
03:10 tempire What would $r->get('/foo')->via('post')->to('foo#bar') do?
03:10 sri post /foo
03:10 daviddelikat3 left #mojo
03:10 sri via redefines get
03:11 sri get() is a shortcut for route()->via()
03:11 daviddelikat2 joined #mojo
03:11 sri you can do that already in lite :)
03:12 sri get('/foo' => sub {...})->via('post');
03:13 daviddelikat left #mojo
03:14 daviddelikat joined #mojo
03:15 daviddelikat1 left #mojo
03:18 Alias joined #mojo
03:19 daviddelikat2 left #mojo
03:22 achromic_ joined #mojo
03:22 achromic left #mojo
03:29 sri hmm, took only 5 minutes and turned out to be less code
03:29 sri and cleaner
03:46 GitHub16 joined #mojo
03:46 GitHub16 mojo: master Sebastian Riedel * 37c77c5 (4 files in 3 dirs): allow Mojolicious::Lite style routes in Mojolicious - http://bit.ly/dfYJWF
03:46 GitHub16 left #mojo
03:46 sri already done :)
03:47 perlrocks Twitter: "This small #mojolicious change might turn out to be really big. :) http://bit.ly/9araBb #perl" --kraih http://twitter.com/kraih/status/4379957060960257
03:48 tl joined #mojo
03:49 sri REST purists can now do stuff like $r->under('/lalala')->get(sub { shift->render(text => 'Go away!') });
03:49 sri under('/foo')->get->to('foo#bar') sounds funny too
04:03 tholen42 joined #mojo
04:05 tl left #mojo
04:22 Alias__ joined #mojo
04:32 tempire Ha
04:33 tempire The latest blogs.perl.org post is a recruiter looking to fill the position I'm vacating.
04:35 Alias__ :)
04:48 daviddelikat left #mojo
05:01 GitHub82 joined #mojo
05:01 GitHub82 mojo: master Sebastian Riedel * 644f824 (3 files in 3 dirs): added base_tag helper to Mojolicious::Plugin::TagHelpers - http://bit.ly/a5Vu4g
05:01 GitHub82 left #mojo
05:16 daviddelikat joined #mojo
05:36 daviddelikat left #mojo
06:06 Alias__ left #mojo
06:11 alnewkirk left #mojo
06:29 daviddelikat joined #mojo
06:29 ltriant left #mojo
06:32 kvorg left #mojo
06:37 koban joined #mojo
06:50 daviddelikat left #mojo
07:14 ysyrota joined #mojo
07:33 al left #mojo
07:39 lee7 left #mojo
07:52 kimoto left #mojo
07:59 breaker313 joined #mojo
08:01 lee7 joined #mojo
08:04 MojoGuest849 joined #mojo
08:04 MojoGuest849 From: http://www.google.pl/search?sourceid=ch​rome&ie=UTF-8&q=websockets+demo (1 hits)
08:05 MojoGuest849 left #mojo
08:09 MojoGuest516 joined #mojo
08:09 MojoGuest516 From: http://www.google.com.hk/search?sourceid=chrome​&ie=UTF-8&q=websocket+demo&qscrl=1 (1 hits)
08:10 MojoGuest516 hi
08:12 MojoGuest516 /help
08:15 MojoGuest516 left #mojo
08:24 marcus HALP
08:26 perlrocks Twitter: "Mojolicious:: Plugin:: JsonConfig or read-only. Write Mojo:: JSON or something." (ja) --Naney http://twitter.com/Naney/status/4450288010272768
08:34 breaker313_ joined #mojo
08:34 breaker313_ left #mojo
08:37 stephan49 HELP! we will all die!
08:39 breaker313 left #mojo
08:40 breaker313 joined #mojo
08:41 breaker313 left #mojo
08:41 breaker313 joined #mojo
08:41 * marcus kills stephan49 .
08:43 breaker313 left #mojo
08:47 al joined #mojo
09:22 rhaen hello world.
09:27 otaviof joined #mojo
09:36 fhelmberger joined #mojo
09:55 crab hello.
10:02 spleenjack joined #mojo
10:10 yakudzo If I include mojo 'template1' in 'template_main' variables from template_main willbe passed to template1? or I should add all of them as arguments to include function ?
10:17 perlrocks left #mojo
10:18 kvorg joined #mojo
10:41 lee7 left #mojo
11:11 kvorg left #mojo
11:27 mrSln joined #mojo
11:27 mrSln hello everyone
11:28 mrSln I'm getting error:
11:28 mrSln # ./myproject daemon_prefork
11:28 mrSln Can't locate object method "prepare_pid_file" via package "Mojo::Server::Daemon::Prefork" at /usr/local/share/perl/5.10.0/​Mojo/Server/Daemon/Prefork.pm line 90.
11:28 mrSln what the problem might be?
11:28 mrSln sri, sir?
11:28 omega wasn't Prefork deprecated?
11:29 mrSln wow, really?
11:29 omega removed from 0.999930
11:29 omega http://cpansearch.perl.org/src/KR​AIH/Mojolicious-0.999940/Changes
11:29 omega it recommends using PSGI server instead
11:30 mrSln omega, thank you very much!
11:50 mrSln left #mojo
11:59 rhaen :) some things are easy :)
12:09 lee7 joined #mojo
12:36 forwardever joined #mojo
12:50 yko joined #mojo
12:53 spleenjack left #mojo
12:54 MojoGuest528 joined #mojo
12:55 MojoGuest528 left #mojo
13:00 spleenjack joined #mojo
13:03 spleenjack left #mojo
13:17 yko left #mojo
13:25 MojoGuest597 joined #mojo
13:25 MojoGuest597 From: http://www.google.hu/url?sa=t&source=web​&cd=2&ved=0CCEQFjAB&url=http%3A%​2F%2Fdev.xantus.org%2F&rct=j&q=webso​cket%20demo&ei=CobiTKe7I8Tssgb7-_H7Cw&am​p;usg=AFQjCNGw6nZv0wO42uzUnHhWcD0vcKNULg (1 hits)
13:25 MojoGuest597 left #mojo
13:26 daviddelikat joined #mojo
13:28 daviddelikat left #mojo
13:40 arthas joined #mojo
13:54 spleenjack joined #mojo
13:55 tempire What's the purpose of Moo, when Mouse already exists and does more?
13:58 omega To do less than Mouse I believe
13:59 omega for when you don't want a meta-model at all
13:59 omega but when stuff that consumes you want to (I think a goal for pre-1.0 is to use Moose if it is already loaded)
14:00 yko joined #mojo
14:00 tempire yeah, rjbs just commented on it: " to be faster and not worry about providing a metamodel"
14:03 giwi joined #mojo
14:03 giwi left #mojo
14:06 koban left #mojo
14:26 otaviof left #mojo
14:34 ysyrota left #mojo
14:34 ysyrota joined #mojo
14:47 dotan joined #mojo
15:00 Akron joined #mojo
15:18 dotan left #mojo
15:22 mrSln joined #mojo
15:22 sri mrSln: a new prefork server is in development
15:25 mrSln sri, that's great, but I need it now
15:26 sri use a psgi one then
15:27 mrSln yeah, I think it would be our choice
15:39 su-bzero Moo ;)) What a nice name.
15:39 su-bzero Moo + Mojo
15:39 su-bzero Mojo on Moo
15:39 su-bzero ;)
15:44 und3f[A] is now known as und3f
16:00 Akron left #mojo
16:02 GitHub135 joined #mojo
16:02 GitHub135 mojo: master Sebastian Riedel * 390f5e6 (1 files in 1 dirs): added new routes recipe - http://bit.ly/aBGBTV
16:02 GitHub135 left #mojo
16:06 GitHub127 joined #mojo
16:06 GitHub127 mojo: master Sebastian Riedel * cdd94f7 (1 files in 1 dirs): simplify example - http://bit.ly/bc3AlJ
16:06 GitHub127 left #mojo
16:10 sri hope thats the right place to make that connection
16:20 GitHub86 joined #mojo
16:20 GitHub86 mojo: master Sebastian Riedel * 7dad34e (1 files in 1 dirs): fixed websocket example - http://bit.ly/atv503
16:20 GitHub86 left #mojo
16:21 sri guess i could also remove it from the guide, since that websocket api will break anyway
16:23 sri since the next version of the handshake won't have a path to dispatch anymore
16:25 kvorg joined #mojo
16:41 daviddelikat joined #mojo
16:57 alnewkirk joined #mojo
16:58 ysyrota left #mojo
17:12 und3f is now known as und3f[A]
17:23 su-bzero_ joined #mojo
17:27 su-bzero left #mojo
17:30 tholen joined #mojo
17:32 Akron joined #mojo
17:42 otaviof joined #mojo
17:43 MojoGuest208 joined #mojo
17:43 MojoGuest208 From: http://news.ycombinator.com/item?id=1277067 (51 hits)
17:44 MojoGuest208 left #mojo
18:08 GitHub21 joined #mojo
18:08 GitHub21 mojo: master Sebastian Riedel * 6c3fef4 (1 files in 1 dirs): pod cleanup - http://bit.ly/bNZxd3
18:08 GitHub21 left #mojo
18:11 perlrocks joined #mojo
18:13 perlrocks Twitter: "Here are some examples for what you can do with the new #mojolicious routes syntax. http://bit.ly/9G79Rh #perl" --kraih http://twitter.com/kraih/status/4598029826924544
18:19 GitHub49 joined #mojo
18:19 GitHub49 mojo: master Sebastian Riedel * 5c6c3ba (1 files in 1 dirs): pod cleanup - http://bit.ly/bM3Yz1
18:19 GitHub49 left #mojo
18:20 sri ok, i think now i have it :)
18:20 yko nice
18:29 * yko handshaker
18:30 yko Test::Mojo++ # and mojo-way app testing
18:31 sri :)
18:33 yko writing siomething about websocket anyway damands testing.
18:34 yko btw, abot ws: are they rly so bad at the moment?
18:39 spleenjack left #mojo
18:42 sri yes
18:42 sri everything will break any day now
18:43 sri you just can't use them in production
18:58 gabb whats the status of the draft?
18:59 gabb still at 76 or so? google still blocking?
18:59 sri hybi wg does its thing
18:59 sri http://www.ietf.org/mail-archive​/web/hybi/current/maillist.html
19:00 sri there you can follow what's going on
19:00 sri the framing format seems to be done now
19:00 sri the handshake not at all
19:01 sri two weeks ago it looked like CONNECT had won
19:01 sri now it is all open again
19:02 otaviof left #mojo
19:08 marcus Fight!
19:09 MojoGuest691 joined #mojo
19:09 MojoGuest691 From: http://www.google.com/search?sourceid=c​hrome&ie=UTF-8&q=websocket+demo (2 hits)
19:09 MojoGuest691 test
19:09 marcus Nope!
19:09 MojoGuest691 :'(
19:09 marcus Production!
19:10 marcus Don't be a crybaby
19:10 MojoGuest691 nah, just testing the websocket demo...
19:12 marcus :)
19:13 Akron left #mojo
19:19 MojoGuest691 can anyone tell me how i can track the websocket with wireshark?
19:22 MojoGuest691 left #mojo
19:22 MojoGuest714 joined #mojo
19:22 MojoGuest714 From: http://www.google.com/search?sourceid=c​hrome&ie=UTF-8&q=websocket+demo (3 hits)
19:22 MojoGuest714 left #mojo
19:24 sri hmm, i guess a fist fight wouldn't be the worst method for picking a websocket handshake
19:26 tab joined #mojo
19:26 crab maybe a fistfight should BE the websocket handshake
19:31 stephen left #mojo
19:32 tab left #mojo
19:32 stephen joined #mojo
19:43 arthas left #mojo
19:45 yko that's sux. ws is so yammy stuff
19:45 yko well, i can use it anyway for internal api comunications :D
19:45 sri yea
19:45 yko inside one version of mojo ws should work, damnit
19:45 sri the mojo websocket api will break too though
19:45 sri sadly
19:46 yko hmm. api?
19:46 sri ye, there won't be a path anymore
19:46 yko you mean that declaring routes and 'on_message' will change one day?
19:46 yko *$#@!
19:47 yko that was so sween
19:47 yko *sweet
19:47 sri websocket 'foo_protocol' => sub {...}; and $client->websocket('ws://127.0.0.1:3000', 'foo_protocol')
19:47 sri something like that
19:47 sri we will have to dispatch based on a sub protocol
19:47 yko *cry*
19:48 MojoGuest793 joined #mojo
19:48 MojoGuest793 From: http://www.google.de/search?sourceid​=chrome&ie=UTF-8&q=extjs+irc (1 hits)
19:48 sri sadly nothing we can do
19:48 yko hmm. but client will still ask 'ws://127.0.0.1:3000/foo_protocol' ?
19:48 sri no
19:48 MojoGuest793 left #mojo
19:48 sri only host and port
19:48 yko aha. rly sux
19:49 sri Sec-WebSocket-Protocol: foo_protocol
19:49 sri we get a header
19:49 yko aha.... that's better than nothing. finally, we can turn it into a path :D
19:49 sri bad idea
19:50 yko but that's bad. path was a good thing. what they are thinking about?
19:50 sri we'll just use the sub protocol name
19:50 yko ye, agree
19:54 forwardever left #mojo
20:08 fhelmber_ joined #mojo
20:43 fhelmber_ left #mojo
20:50 tholen left #mojo
21:01 ltriant joined #mojo
21:26 y0j left #mojo
21:46 perlrocks Twitter: "@BSFMag do tell! Love exciting mojolicious stuff!" --DecadenceDesign http://twitter.com/DecadenceD​esign/status/4651454442774528
21:57 y0j joined #mojo
22:05 yko left #mojo
22:23 perlrocks Twitter: "Redis bindings for #Mojolicious http://tinyurl.com/2vshndb #Perl" --vtivti http://twitter.com/vtivti/status/4660838329753601
22:24 daviddelikat left #mojo
22:24 daviddelikat joined #mojo
22:25 daviddelikat left #mojo
22:25 perlrocks Twitter: "RT @vtivti: Redis bindings for #Mojolicious http://tinyurl.com/2vshndb #Perl" --und3f http://twitter.com/und3f/status/4661388299468801
22:27 daviddelikat joined #mojo
22:28 daviddelikat left #mojo
22:29 marcus My Mojolicious talk at LPW 2010 just got accepted.
22:29 marcus Time to work on my slides I guess.
22:30 daviddelikat joined #mojo
22:30 daviddelikat left #mojo
22:45 sri \o/
22:48 crab i wonder if i can "decorate" routes to say that they're e.g. "admin-only"
22:48 sri sure
22:48 sri condition
22:48 crab explain?
22:49 sri a clever condition could check the session for an admin role
22:49 sri but i guess you really want to keep that on the app layer
22:49 sri not routes
22:50 crab hmm, condition is neat.
22:50 sri under/bridge are better for this task though
22:50 crab but yes, i want to evaluate it at the app layer, in the handler.
22:50 sri ye
22:51 sri login and stuff are app logic
22:51 crab i'm already handling login using bridge
22:51 sri conditions are better for geo or browser detection
22:51 crab this is to provide admin/user role-based access to things, and it suddenly seemed that it might be useful to declare that up front where i declare all the routes
22:52 sri stuff that just says yes/no... while app logic can say "go there first and come back"
22:52 sri crab: like apply roles to routes?
22:52 crab sri: something like that.
22:53 sri could just put roles into the stash and have a bridge deal with it
22:54 crab yeah. maybe that's best.
22:54 crab i certainly don't want to have to do the evaluation in multiple places, that's just asking for trouble.
22:58 Ned sri: do you know of any suitable tools to use as a reverse http proxy that'll support websockets ?
22:58 sri Ned: impossible
22:58 Ned err, impossible ?
22:58 sri websockets are not http
22:58 Ned well, they are to start with
22:59 sri forget about websockets
22:59 Ned and all a proxy needs to do is leave the connection open (doing pass-through)
22:59 sri the spec is changing as we speak
22:59 Ned oh ? :-(
22:59 Ned that's annoying :p
22:59 sri do not use websockets for anything else than testing
22:59 Ned right
23:00 sri and no it is not http compatible atm
23:00 Ned right, so I'm back to long polling :-(
23:00 sri the handshake message has a fixed length content without a Content-Length header
23:00 Ned because streaming has the spinner issue
23:02 sri absolutely everything about websockets is going to change
23:02 Ned right
23:21 memowe_ joined #mojo
23:21 memowe left #mojo
23:22 crab left #mojo
23:38 crab joined #mojo
23:39 crab can i somehow make all submitted parameters be logged?
23:40 marcus Wow, I love LimeChat.  Great iPad irc client
23:59 diegok left #mojo

| Channels | #mojo index | Today | | Search | Google Search | Plain-Text | summary