Camelia, the Perl 6 bug

IRC log for #mojo, 2012-09-27

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

All times shown according to UTC.

Time Nick Message
00:14 davido joined #mojo
00:16 davido The new "pre-beta" dashboard for dotCloud is excellent:  http://dashboard.dotcloud.com (log in with an account name and grant access).  It hints to some good things to come such as the ability to monitor (or maybe even select) EC2 availability zones.
00:46 zivester joined #mojo
00:52 laouji joined #mojo
00:53 mandreacchio joined #mojo
01:23 jnap joined #mojo
01:45 d4rkie joined #mojo
02:17 Foxcool joined #mojo
02:22 Foxcool joined #mojo
02:25 venomo_ joined #mojo
02:33 noganex_ joined #mojo
02:51 Jason___ joined #mojo
02:55 venomo joined #mojo
03:01 Averna joined #mojo
03:12 mandreacchio_ joined #mojo
03:17 l3l1p joined #mojo
03:30 asarch joined #mojo
03:59 xaka joined #mojo
04:11 l3l1p joined #mojo
04:14 venomo joined #mojo
04:38 Foxcool joined #mojo
04:47 pertze_ joined #mojo
04:49 Foxcool_ joined #mojo
05:03 dross joined #mojo
05:08 vishwanathms joined #mojo
05:08 vishwanathms_ joined #mojo
05:12 sunson joined #mojo
05:14 sunson is there a n00b guide to using models with Mojo?
05:15 sunson DBIx::Class::Schema::Loader breaks (had to do force install and what dbicdump it generates doesn't make any sense)
05:17 omega first tip would be to get your schema working outside of mojo first
05:18 omega (#dbix-class can probably help better with that)
05:19 sunson omega: ok. thanks.
05:47 Vandal joined #mojo
05:49 davido_ joined #mojo
05:52 spleenjack joined #mojo
05:59 l3l1p joined #mojo
06:23 dpetrov_ joined #mojo
06:27 l3l1p joined #mojo
06:47 AmeliePoulain joined #mojo
06:59 sunson Can I access $self inside a template? I'm trying to debug what is being passed from the controller code (via stash) to the template.
06:59 sunson ideally, I'd like to do %= $self->dumper($stash_var)
07:02 tempire sunson: you can, but for helpers you don't need to.
07:02 tempire $self-> is implied
07:02 crab sunson: %= dumper $var
07:04 mattp_ joined #mojo
07:04 tempire <3 selenium webdriver
07:04 drift_ joined #mojo
07:06 fhelmber_ joined #mojo
07:08 rem_lex| joined #mojo
07:09 sunson crab: tempire: thanks
07:17 sunson In my controller, I'm doing $self->stash(test => $self->db->resultset('Test')->search( { id => $testid } )->next); and in my template I did <%= dumper $test %>. But this times out. There is no info on what is going on in the console too. How do I debug?
07:18 batman joined #mojo
07:18 crab try MOJO_LOG_LEVEL=debug morbo ...
07:19 sunson never mind, figured MOJO_LOG_LEVE
07:19 sunson crab: righto
07:42 pau4o joined #mojo
07:43 davido_ joined #mojo
07:44 crab what was wrong? it didn't find the template or something, right?
07:45 sunson crab: I used DBIx::Class incorrectly. I was trying to loop over a Result. weird.
07:54 D4RK-PH0ENiX joined #mojo
08:01 ghandi joined #mojo
08:02 ghandi Hi There! Is there any default upload-limit in Mojolicious? The Cookbook says something about big download, but does this 5MB limit of MOJO_MAX_MESSAGE_SIZE also affect uploads?
08:04 marcus sri: failed render inside ev isn't rendered?
08:04 marcus sri: https://gist.github.com/3792801
08:06 Foxcool joined #mojo
08:06 ghandi By trail and error: Seems like MOJO_MAX_MESSAGE_SIZE also affects uploads which explains a lot to me. Maybe this should be stated in the doc more clearly
08:11 * marcus starts a support group 'safety for callbacks'
08:17 Foxcool_ joined #mojo
08:19 Foxcool_ joined #mojo
08:21 ghandi Hmm...next question: I've got an action which processes a large excel file. This takes up to 5 Minutes. Afterwards i want to redirect to the index-route. The log say "302 Found" but the Browser say "Error"? Is there a request-timeout?
08:22 ghandi Oh, found the "inactivity timout" paragraph in the FAQ :D
08:27 daxim joined #mojo
08:31 arthas joined #mojo
08:37 andrefs joined #mojo
08:48 dross joined #mojo
08:49 zivester joined #mojo
09:13 ryanc joined #mojo
09:31 judofyr joined #mojo
09:31 judofyr hm… given: route('/*names'). shouldn't maybe url_for(…, names => ["a", "b"]) return /a/b ?
09:39 judofyr joined #mojo
09:43 JiYu mhmm any thoughts how I can use $self within a Mojo::IOLoop->recurring();?
09:43 judofyr JiYu: just use $self?
09:44 JiYu judofyr, unfortunately not working?. this results in: Global symbol "$self" requires....
09:45 judofyr JiYu: well, where does $self come from? example code?
09:47 JiYu $self should inherit itself like: https://rt.fm/pd3
09:47 JiYu for the any [GET]? it is working, but in the ioloop its not
09:48 judofyr JiYu: $self is only available inside the sub
09:49 JiYu in the first sub its available, but in the second its not
09:50 judofyr JiYu: what are you trying to do?
09:50 judofyr JiYu: the any-block can be invoked several times (by several clients).
09:50 JiYu e.g.: https://rt.fm/pd4
09:51 JiYu or to access a plugin
09:51 judofyr just use "app"
09:51 judofyr to get access to the app
09:51 JiYu yeah thats working ;)
09:51 JiYu okay bad example ;)
09:52 JiYu I have a Plugin which I normally access like: $self->auth($baseid);
09:53 JiYu I create the Plugin like: https://rt.fm/pd5
09:54 judofyr JiYu: I just don't see why you want to access it in a recurring. unless you're using an async-callback in the controller, the recurring-block will never run while the request is still pending.
09:54 judofyr more likely it will be like this: Request comes in. Action executed. Request goes out. Recurring invokes. etc.
09:55 JiYu I want to create kind of a backend service, which is only communicating with a mysql database and is checking rows.
09:56 JiYu its like a worker or cron that should run every x minutes and if new data are found it will do some other executing
09:56 JiYu its okay when the recurring-block will be blocked for the time its running
09:57 judofyr and why do you need access to $self?
09:58 JiYu to access my mojo plugins
09:59 kitt_vl joined #mojo
10:00 nic moritz++  # It keeps popping into my head how awesome & valuable the irclog is
10:01 judofyr JiYu: ehm. sub register { my ($self, $app) = @_; $app->attr('myplugin'); $app->myplugin($self) }
10:03 judofyr JiYu: it should be pretty easy to make the plugin accessible from the $app
10:05 JiYu hey great
10:06 JiYu (facepalm)
10:09 JiYu don't know why I didn't tried that before, but they are already accessibly through e.g. app->android(); since I am going to register them through $app->helper(android => sub {};
10:16 nic bpmedley: I liked your 5-slide gearman intro
10:16 bpmedley nic: Thank you
10:16 nic Was http://www.slideshare.net/andy.sh/gearman-and-perl the presentation you said you liked?
10:16 nic I wish I had found that one earlier cos it answers lots of my questions
10:17 bpmedley nic: I have read it.  It's information firehose.. :)
10:17 nic It's a shame so much of gearman.org is misleading due to being so out of date
10:17 bpmedley nic: It could be re-organized.
10:25 andrefs joined #mojo
10:26 Vandal joined #mojo
10:54 mandreacchio joined #mojo
10:56 judofyr_ joined #mojo
11:20 sri ghandi: http://mojolicio.us/perldoc/M​ojolicious/Lite#File_uploads # how much more clearly could we explain MOJO_MAX_MESSAGE_SIZE than having it covered by half of the whole upload section in the tutorial? Oo
11:21 ObseLeTe joined #mojo
11:21 sunson joined #mojo
11:22 sri marcus: lolwut?
11:22 purl lolwut is the pic with that freaky giant pear with a mouth
11:22 * sri sees EV and runs away screaming
11:23 sri marcus: maybe you should ask mlehmann! :D
11:23 marcus sri: I'd rather not.
11:23 marcus sri: we're using elasticsearch ,and ev seemed like the easiest way to use it with mojo
11:24 marcus hmm, actually, I suppose we could easily implement ElasticSearch-Transport-Mojo
11:29 sri that new sherlock holmes show is interesting
11:30 marcus elementary? I thought it sucked.
11:31 sri it's nowhere near as good as the other series, but i think it still has potential
11:31 judofyr_ sri: new? link?
11:31 sri elementary
11:31 sri http://www.tv.com/shows/elementary/
11:32 ObseLeTe joined #mojo
11:33 judofyr oh
11:33 judofyr it was actually called elementary
11:34 sri just don't expect something like the bbc version
11:44 marcus effin' lucy liu
11:46 ovnimancer joined #mojo
11:48 ObseLeTe joined #mojo
11:57 batman any how to keep "connection: keep-alive" though a upstream server in nginx?
12:05 judofyr batman: difficult. it currently only supports HTTP 1.0 to upstream servers.
12:05 judofyr batman: I think maybe the latest version supports keep-alive (it's a work-in-progress related to WebSockets)
12:06 batman ok. that is a deal breaker for me.
12:06 batman does apache support 1.1?
12:06 batman i was hoping proxy_http_version 1.1; would fix it (for nginx)
12:07 judofyr there's a TCP-upstream for Nginx, but then Nginx isn't actually doing anything else than directly routing request to the upstream (e.g. you better have a secure parser etc.)
12:07 batman well... i got mojolicious ;)
12:07 batman where can i read more about this tcp upstream?
12:08 judofyr batman: https://github.com/yaoweib​in/nginx_tcp_proxy_module
12:08 batman thanks
12:13 batman "From nginx 1.1.14 onwards, nginx support HTTP 1.1 for upstream servers." hm....
12:17 sri mod_proxy does support keep-alive to backend servers
12:18 sri right, nginx learned it recently too :)
12:18 judofyr batman: yeah, I know there have been work on this, so I'm not 100% up-to-date
12:21 batman i got upstream { keepalive 16; ... } and server { proxy_http_version 1.1; }
12:21 batman not sure what else to do...
12:21 batman still getting connection: close; in the client
12:23 sri batman: "For HTTP, the proxy_http_version directive should be set to “1.1” and the “Connection” header field should be cleared"
12:24 sri proxy_set_header Connection "";
12:24 batman *testing*
12:25 batman btw... shouldn't you be on vacation sri?
12:25 sri every now and then i'll also be here :)
12:25 batman still not working... :/
12:25 batman hehe. #mojo is just too much fun :)
12:29 batman https://gist.github.com/c0925bcdec484f7c12c8 <-- this is what i got
12:31 sri btw. if anyone is looking for a small mojolicious task to hack on, try to get html_escape to favor lower case entities over title case ones
12:31 sri https://github.com/kraih/mojo/b​lob/master/lib/Mojo/Util.pm#L36
12:32 sri basically hack that sort
12:32 sri and perlgolf it down, shortest solution wins :)
12:33 batman what's "title"? is it the same as uppercase?
12:33 sri or camel case for some
12:33 sri title case is the wrong word i guess, it means the first character of every word is upper case
12:34 batman ah
12:34 sri everything happens, some entities are all lower case, some all upper case, some mixed, and many entities have multiple versions :)
12:36 sri would be nice if in the end &nbsp; wins over &NonBreakingSpace; for example
12:36 sri the current sort favors the longer camel case versions
12:37 sri results are easily visible with t/mojo/util.t
12:41 Lucas1 joined #mojo
12:51 d4rkie joined #mojo
13:07 * marcus switched to source code pro light 16pt as his monospace font.
13:08 andrefs joined #mojo
13:08 marcus 14pt in textmate
13:09 marcus looks soo great on the retina mbp.
13:16 sri source code pro is pretty great, but i still like consolas a little more
13:17 sri but it's a close second
13:18 judofyr sri: here's one idea: http://pastie.org/private/scry5ztyuxrn8o02bc6p2w
13:19 sri judofyr: clever!
13:23 judofyr sri: I wanted to use =~, but scalar-vs-list context was tricky
13:25 * sri nods
13:32 jnap joined #mojo
13:33 good_news_everyone joined #mojo
13:33 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/C8akyw
13:33 good_news_everyone [mojo/master] improved html_escape to favor lower case entities - Sebastian Riedel
13:33 good_news_everyone left #mojo
13:33 sri judofyr++ # setting the bar pretty high already
13:36 judofyr \o/
13:41 arpadszasz joined #mojo
13:42 Lucas11 joined #mojo
13:43 gryphon joined #mojo
13:50 inokenty joined #mojo
14:08 ryozi joined #mojo
14:09 Vandal joined #mojo
14:15 Leandr joined #mojo
14:15 Jason_ joined #mojo
14:32 good_news_everyone joined #mojo
14:32 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/qyEgTg
14:32 good_news_everyone [mojo/master] prevent deprecation warning on Perl 5.10.1 - Sebastian Riedel
14:32 good_news_everyone left #mojo
14:32 sri it's a bit stupid
14:33 sri but i guess 5.10.1 users wouldn't like "Use of implicit split to @_ is deprecated at..."
14:38 judofyr sri: what does that warning mean?
14:39 sri before 5.12 split in scalar context used to put all values into @_
14:39 judofyr sri: but if you need to wrap it, you might as well use: @{[$a =~ /[A-Z]/g]}
14:40 sri i suppose it was an attempt at using @_ like $_... or something silly like that
14:40 judofyr yeah, that seems kinda silly…
14:43 mire_ joined #mojo
14:44 good_news_everyone joined #mojo
14:44 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/qk79iQ
14:44 good_news_everyone [mojo/master] tweaked reverse entity mapping a little - Sebastian Riedel
14:44 good_news_everyone left #mojo
14:51 knshaum joined #mojo
15:09 abra joined #mojo
15:12 JiYu is this an encoding problem or a limitation in the rendering engine -> https://rt.fm/pd6
15:13 sri neither
15:13 sri http://mojolicio.us/perldoc/Mojolic​ious/Guides/Rendering#Embedded_Perl
15:23 JiYu cool :)
15:23 purl cool :) are you oging to either event tomorrow?
15:23 JiYu thx sri
15:24 Lucas1 joined #mojo
15:26 labrown joined #mojo
15:53 preflex joined #mojo
15:54 ghandi joined #mojo
15:57 xaka joined #mojo
16:19 njlg joined #mojo
16:21 kellen joined #mojo
16:23 kellen left #mojo
16:31 jzawodn joined #mojo
16:34 arpadszasz joined #mojo
16:50 perlite_ joined #mojo
16:52 perlite joined #mojo
17:01 Htbaa joined #mojo
17:03 batman joined #mojo
17:09 perlite joined #mojo
17:15 jwang joined #mojo
18:36 abra joined #mojo
18:38 davido_ joined #mojo
18:46 gryphon joined #mojo
19:21 jwang joined #mojo
19:26 arpadszasz joined #mojo
20:00 MidnighToker joined #mojo
20:04 xaka joined #mojo
20:05 asarch joined #mojo
20:39 Jason__ joined #mojo
21:14 foo joined #mojo
21:19 foo I pity the foo
21:37 gryphon I pity the bar.
21:42 vividsnow joined #mojo
22:14 preflex joined #mojo
22:47 zivester joined #mojo
23:47 vividsnow joined #mojo
23:48 * tempire digs the new show revolution
23:48 tempire reminds me a bit of afterworld
23:48 tempire .tv
23:49 Adura joined #mojo

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