Camelia, the Perl 6 bug

IRC log for #mojo, 2012-02-04

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

All times shown according to UTC.

Time Nick Message
02:02 noganex joined #mojo
03:12 vel joined #mojo
04:19 jwang joined #mojo
04:50 mire joined #mojo
05:14 xaka joined #mojo
06:04 Vandal joined #mojo
07:33 kaare joined #mojo
07:45 sherr joined #mojo
07:57 black joined #mojo
08:59 melmothX joined #mojo
09:16 ki0 joined #mojo
09:41 kaare_ joined #mojo
09:47 rhaen ho!
10:07 lammel2 joined #mojo
10:30 tempire ha!
10:35 lammel2 joined #mojo
10:50 Topic for #mojo is now Mojolicious real-time web framework 💝  http://mojolicio.us 💝 http://irclog.perlgeek.de/mojo/today
10:51 Topic for #mojo is now Mojolicious real-time web framework 💝  http://mojolicio.us/   💝   http://irclog.perlgeek.de/mojo/today/
10:51 Topic for #mojo is now Mojolicious real-time web framework 💝  http://mojolicio.us/   💝   http://irclog.perlgeek.de/mojo/today
10:51 Topic for #mojo is now Mojolicious real-time web framework 💝  http://mojolicio.us/   💝 http://irclog.perlgeek.de/mojo/today
10:52 Topic for #mojo is now Mojolicious real-time web framework 💝     http://mojolicio.us/     💝     http://irclog.perlgeek.de/mojo/today
11:02 Topic for #mojo is now  Mojolicious real-time web framework  💝    http://mojolicio.us/ 💝   http://irclog.perlgeek.de/mojo/today//
11:08 Topic for #mojo is now  Mojolicious real-time web framework  💝    http://mojolicio.us/ - http://irclog.perlgeek.de/mojo/today/💝
11:08 tempire ok, that should do it.
11:09 Topic for #mojo is now  Mojolicious real-time web framework  💝    http://mojolicio.us/ - http://irclog.perlgeek.de/mojo/today/ 💝
11:09 tempire derned unicode.
11:27 fibo joined #mojo
11:30 ki0 joined #mojo
12:03 blabos joined #mojo
12:15 briang joined #mojo
12:22 blabos joined #mojo
12:38 ki0 joined #mojo
12:45 * trone discover the respond_to pleasure.
12:58 briang joined #mojo
13:08 ki0 joined #mojo
13:08 noganex_ joined #mojo
13:19 Vandal joined #mojo
13:28 ki0 joined #mojo
14:27 ki0 joined #mojo
14:51 trone Playing with respond_to method (REST). If client use a not defined (in respond_to args) Accept header Mojo-app return 204 (ask text/plain when respond_to work on json/xml/html), but if server receives wrong header (ie: text/plainz) it fallback in default (ie: html). Is what you want? For me is ok, but feel weird.
15:09 grim_fandango joined #mojo
15:15 memowe o/
15:18 marty trone: I'm not sure if I understand your question.  However, this might help.  $self->respond_to( html => { text => 'hello' }, any => { data => '', status => 204 } );
15:35 trone marty: thanks for attention, but my problem is about mojolicious respond_to implementation (I think).
15:35 trone the code: http://paste.debian.net/154864/
15:36 trone that app works perfectly in first three case: 200, 200, 204 (html, json, text/plain is not defined in respond_to)
15:37 trone but 4th case have an Accept header "wrong". And mojolicious return the default (html)
15:38 trone This could to be "right" because help the framework to "show something", but indeed I'll wait a 204 (no content for text/plainz request).
15:38 trone I saw the code: https://github.com/kraih/mojo/blob/mas​ter/lib/Mojolicious/Controller.pm#L410
15:39 marty trone: any reason you are not using the "any" with respond_to?
15:39 trone And the else is perfect. Just seen this "collateral effect" and ask (to sri, or other) if it's ok.
15:40 trone marty: it's the fallback situation. if target is not defined, it render 204 status (line 423-424)
15:42 trone marty: furthermore, I don't believe any change something: if respond_to method don't detect type (L404), you have however the unless(@formats) else that play.
15:42 trone marty: so I believe that any doesn't help in this case.
15:43 trone all happen before for $target loop
15:46 sri trone: respond_to semantics have been up for discussion for months, you're too late
15:48 sri https://github.com/kraih/mojo/issues/237 # one example
15:49 sri now i simply refuse to discuss it further
16:00 trone sri: ah ok. if it has already been discussed in the past, is perfect for me. ^_^ This is the first time that I play with that method, and so... thanks for link.
16:01 trone (for me was not a problem, just an oddity)
16:05 trone sorry sri, I did not want to renegotiate anything. I swear! :)
16:10 briang joined #mojo
16:35 black joined #mojo
16:47 Foxcool joined #mojo
16:55 ZadYree Q: I would like to add an upload function(from users to webserv), but don't know how it works. Is Mojo::Upload appropriate?
16:56 abra_ joined #mojo
16:59 inokenty ZadYree: http://mojolicio.us/perldoc/M​ojolicious/Lite#File_uploads
17:04 ZadYree ty!
17:18 ZadYree btw app>req->upload('example') is equal to Mojo::Upload->filename('foo.txt');   ?
17:26 ZadYree this 'example' sounds ambiguous
17:28 inokenty ZadYree: Mojo::Upload is just a container
17:29 ZadYree ok
17:31 inokenty (and it knows nothing about request)
17:31 ZadYree anyway, my issue was just I didn't know if 'exemple' was the filename or the data in Mojolicious::Lite example
17:32 ZadYree by data, I mean its content.
17:33 inokenty 'example' is the name of input[type=file] field
17:33 inokenty <input type="file" name="example">
17:33 ZadYree aah ok, I didn't see it like this
17:33 ZadYree I have to watch the entire codes -_-
19:23 fibo joined #mojo
19:41 j3nnn1 joined #mojo
19:49 marcus joined #mojo
20:21 GabrielVieira joined #mojo
20:23 perlite_ joined #mojo
20:32 tempire http://news.perlfoundation.org/2012/0​2/2012q1-grant-proposal-easy-ins.html seems interesting.
20:32 tempire wonder how he's planning to accomplish the "easy" part
20:43 abra__ joined #mojo
20:44 GitHub181 joined #mojo
20:44 GitHub181 [mojo] kraih pushed 1 new commit to master: http://git.io/rQVVZQ
20:44 GitHub181 [mojo/master] redesigned Mojo::IOWatcher api - Sebastian Riedel
20:44 GitHub181 left #mojo
20:54 abra_ joined #mojo
21:00 sri http://mojolicio.us/perldoc/Mojo/IOWatcher#watch # i'm still not "happy" with this, but can't think of a better alternative
21:00 sri using constants seems tedious
21:05 blabos joined #mojo
21:13 GitHub111 joined #mojo
21:13 GitHub111 [mojo] kraih pushed 1 new commit to master: http://git.io/Gj6i4w
21:13 GitHub111 [mojo/master] better Mojo::IOWatcher descriptions - Sebastian Riedel
21:13 GitHub111 left #mojo
21:13 blabos_ joined #mojo
22:04 tempire hmm
22:05 tempire was mojolicio.us always consolas as a first choice?
22:07 tempire I know what you mean with constants..but they are really easy to understand.
22:08 tempire and the ->start, ->stop changes seem fine to me
22:22 sri tempire: you would prefer $watcher->watch($handle, Mojo::IOWatcher::READWRITE);?
22:23 sri to $watcher->watch($handle, 1, 1);
22:23 tempire oh, no.  when I said constants, I meant constants in the math sense.
22:23 tempire meaning 1, 1 is fine.
22:23 tempire Mojo::IOWatcher::READWRITE is the devil
22:23 tempire subjective opinion, of course
22:23 * sri nods
22:24 tempire you could always do Mojo::IOWatcher::WatchCons​tants::Specific::READWRITE
22:25 * sri pokes out his eyes
22:26 sri i've also considered $watcher->readable/writable($handle => sub {…}) instead of $watcher->io($handle => sub {…})
22:26 sri but we have surprisingly little use for separate callbacks in core
22:27 sri http://mojolicio.us/perldo​c/Mojo/IOWatcher#SYNOPSIS
22:28 tempire $watcher->io($handle => read => sub {})
22:28 sri would be nice if Mojo::IOWatcher could become so simple that it actually lowers the learning curve for event loops
22:28 sri tempire: simplify, not more complicated -.-
22:29 * tempire enjoys making use of => in arbitrary places
22:29 sri HASHROCKETS!
22:29 tempire WEBSOCKETS
22:29 purl WEBSOCKETS!!!
22:31 sri purl: you like websockets?
22:31 purl bugger all, i dunno, sri
22:58 sri tempire: consolas was not even in the list until two days ago btw :)
22:59 sri i'm really falling in love with it
22:59 tempire it's a bit blurry in my browser
23:00 sri doubt menlo was more clear before
23:02 tempire hmm.  did you make the code snippets smaller?
23:02 sri few weeks ago
23:02 sri with the 404 redesign i think
23:03 sri but only slightly
23:03 sri i've just zoomed in on Menlo, anti alias looks just the same in safari
23:03 tempire They're about the same.  it's the size with the change that makes me notice it.
23:04 tempire and I think the diagonal lines add to the blurriness for text heavy snippets.
23:05 sri that has always been the same
23:05 tempire looks alright on the macbook screen.  guess it's the effect on the brighter screen setting.
23:09 sri 0.9 instead of 0.8 font size might be worth a try
23:09 sri and maybe you should compare menlo with consolas
23:12 tempire I compared them, you were right, they're about the same in terms of sharpness
23:18 sri the slight size difference between consolas and menlo doesn't make it easier
23:18 sri consolas looks great at 0.9, menlo gets a bit massive
23:41 federated_life joined #mojo
23:58 marcus joined #mojo

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