Camelia, the Perl 6 bug

IRC log for #mojo, 2013-05-06

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

All times shown according to UTC.

Time Nick Message
00:00 zacts joined #mojo
00:26 ka2u joined #mojo
00:30 ahutton joined #mojo
01:01 hotsnow joined #mojo
01:24 good_news_everyone joined #mojo
01:24 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/bHgckA
01:24 good_news_everyone mojo/master d5d5bd5 Sebastian Riedel: a few more small optimizations
01:24 good_news_everyone left #mojo
01:52 rem_lex| joined #mojo
01:57 Meiermann joined #mojo
02:22 asarch joined #mojo
03:10 tempire neilb wants a tpf grant to review web frameworks
03:11 tempire seems like a bad idea that will cause more turmoil than help noobs
03:33 buu Just think of the fun that could be had!
03:38 sri yea, no way it's going to be a "success"
03:39 jberger if it was done well, I think it would be useful, then again, that would be REALLY hard to do
03:41 sri you can't review mojolicious without highlighting the real-time features (websockets especially)... but if you do it's unfair towards the others... which are oriented differently and never promised such features
03:42 sri you'd basically need very different apps to actually show where each framework shines, but then it's very very hard to compare them
03:42 sri and neilb seems to care a lot about comparisons
03:43 jberger I agree, the apps would have to be very different
03:44 jberger though if he's asking for that much cash, I would HOPE he's planning a thorough review
03:45 rihegher joined #mojo
03:45 preflex_ joined #mojo
03:46 sh4 joined #mojo
03:55 zacts joined #mojo
03:58 fildon_ joined #mojo
04:03 mandreacchio joined #mojo
04:30 russum joined #mojo
04:32 russum left #mojo
04:32 russum joined #mojo
04:32 russum left #mojo
04:46 Meiermann joined #mojo
05:01 rihegher left #mojo
05:09 sh4|2 joined #mojo
05:20 good_news_everyone joined #mojo
05:20 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/pwAOeQ
05:20 good_news_everyone mojo/master 8e90fbb Sebastian Riedel: made router internals a little more consistent
05:20 good_news_everyone left #mojo
05:26 d4rkie joined #mojo
05:56 basiliscos joined #mojo
05:57 mandreacchio_ joined #mojo
05:59 mandreacchio__ joined #mojo
06:03 mandreacchio joined #mojo
06:07 dpetrov_ joined #mojo
06:16 good_news_everyone joined #mojo
06:16 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/BSU3hA
06:16 good_news_everyone mojo/master 4ecb40f Sebastian Riedel: match routes a little more efficiently
06:16 good_news_everyone left #mojo
06:19 basiliscos joined #mojo
06:35 Mike-PerlRecruiter_ joined #mojo
07:01 rihegher joined #mojo
07:01 mire_ joined #mojo
07:12 dod joined #mojo
07:14 dod joined #mojo
07:15 mandreacchio joined #mojo
07:23 mandreacchio joined #mojo
07:32 ver joined #mojo
07:35 rihegher left #mojo
07:39 suy joined #mojo
07:41 dod joined #mojo
07:45 fhelmber_ joined #mojo
07:53 mattastrophe joined #mojo
07:54 Vandal joined #mojo
08:01 maxhq joined #mojo
08:24 mrphilov joined #mojo
08:24 jzawodn joined #mojo
08:26 ynonp joined #mojo
08:40 judofyr joined #mojo
08:51 d4rkie joined #mojo
09:07 ynonp joined #mojo
09:47 wu-lee joined #mojo
10:09 mtths joined #mojo
10:37 MeierM joined #mojo
10:45 hotsnow joined #mojo
10:47 hotsnow how can i get all session value on mojolicious server ?
10:48 hotsnow I mean all users' session info
10:56 hrupp joined #mojo
10:57 batman hotsnow: the session is stored in the browser, not on the server
10:57 batman hotsnow: you need to store it in the server as well (using some backend), if you want the sessions
10:58 Meiermann joined #mojo
11:01 hotsnow session id store ni the browser, server side can get the session value from the key
11:02 hotsnow It means I can get all value on server site ?
11:09 bowtie joined #mojo
11:21 Meiermann joined #mojo
11:26 judofyr hotsnow: no, the full session is stored in the browser
11:27 judofyr hotsnow: it's JSON-encoded
11:27 judofyr in a (signed) cookie
11:31 hotsnow ok, may be i need to store the value in another way. thanks
11:33 judofyr hotsnow: https://metacpan.org/module/Mo​jolicious::Sessions::Storable might work
11:37 hotsnow thanks, i will try that
11:39 rihegher joined #mojo
11:42 marvin joined #mojo
11:44 marvin hi guys, could anyone help we with memory leak bug? i don't know how to recognize the component, which causes this issue. @sri, help
11:49 judofyr marvin: how have you diagnosed it so far?
11:49 user_bowtie joined #mojo
11:50 keedi joined #mojo
12:08 russum1 joined #mojo
12:21 rihegher left #mojo
12:31 mattastrophe joined #mojo
12:43 batman marvin: can you isolate the leak and post the code online somewhere?
12:52 rem_lex|pivo joined #mojo
12:53 moltar joined #mojo
13:09 bluescreen joined #mojo
13:10 btyler joined #mojo
13:39 whitebook joined #mojo
13:40 andrefs joined #mojo
13:43 hotsnow joined #mojo
13:57 btyler joined #mojo
14:02 gryphon joined #mojo
14:07 gryphon_ joined #mojo
14:07 tadamo_ joined #mojo
14:12 tadamo_ joined #mojo
14:12 al802 joined #mojo
14:13 al802 hi guys,
14:14 sh4 joined #mojo
14:14 al802 I have some files that are pre-gzipped in an in-memory hash cache, the key is the path of the file e.g /blah/bootstrap.css
14:14 al802 how can I serve them out
14:15 al802 do I use render?
14:15 al802 I assume I do this from an early hook like before_dispatch
14:15 al802 if do, how do I pass the data
14:16 al802 to the renderer
14:17 al802 also, in an example http://mojolicio.us/perldoc/Mojolicious#hook it states: # Dispatchers will not run if there's already a response code defined
14:17 al802 I cannot fathom this
14:17 judofyr al802: you can just use a regular route: get '/blah/bootstrap.css' => { shift->render(data => 'hello') }
14:18 judofyr (I think)
14:19 ynonp joined #mojo
14:20 al802 thanks, I will try that, but was hoping I could serve the file without going thru the entire render cycle
14:20 al802 for example I would need to detect this in all my before/after hooks
14:22 al802 I was under the impression that if I did say render(data=>'hello') that other subsequent hooks would not be called (if I set the response code) but other hooks still get called e.g. before routes
14:27 ynonp joined #mojo
14:31 mrphilov joined #mojo
14:37 gryphon joined #mojo
14:41 judofyr al802: not sure about the hook behavior. but in general: implement the easy way first, then benchmark, then tweak :)
14:45 rihegher joined #mojo
14:45 rihegher left #mojo
14:50 rihegher joined #mojo
14:51 al802 I think I have it working ok now, I did not know about the render(data=>''), can I use a reference for that or does it have to contain data?
14:53 judofyr I think it has to be a string
14:55 rihegher joined #mojo
14:56 al802 yer, it looks like it
15:33 btyler joined #mojo
15:33 Kulag joined #mojo
15:37 rihegher left #mojo
15:46 zivester joined #mojo
15:57 gryphon joined #mojo
16:06 xaka joined #mojo
16:19 * sri wonders if the PoweredBy plugin should be removed for 4.0
16:20 sri it doesn't seem like such a valuable example these days
16:21 sri also interesting that the RequestTimer plugin costs about 100 rps for a hello world that does around 2k rps
16:23 sri app->plugins->unsubscribe('before_rou​tes')->unsubscribe('after_dispatch') if app->mode ne 'development';
16:24 sri that can remove it in production mode
16:28 mattastrophe joined #mojo
16:34 dpetrov_ joined #mojo
16:36 mattastrophe joined #mojo
16:36 inokenty joined #mojo
16:37 mtths joined #mojo
16:37 beyondcreed joined #mojo
16:39 basiliscos joined #mojo
16:40 crab yay, goodbye PoweredBy!
16:49 sh4 joined #mojo
16:49 mtths joined #mojo
16:55 kvorg joined #mojo
16:55 kvorg_ joined #mojo
17:01 alester joined #mojo
17:02 Britzel_ joined #mojo
17:03 yko what kind of env/configuration do you use for that rps benchmarks nowadays?
17:08 yko sri: ^^ for these rps benchmarks
17:19 sri yko: depends on what i'm benchmarking
17:19 janus joined #mojo
17:19 sri crab: the headers would still be set, just in Mojolicious.pm
17:19 sri s/headers/header/
17:20 sri the question is if it's a useful example
17:21 sri yko: in this case "hypnotoad -f examples/hello.pl" and "wrk -c 100 -r 10k http://127.0.0.1:8080/"
17:22 yko sri, this time I'm interested in benchmarking accessors in Mojolicious app context
17:22 sri "hypnotoad -f examples/fast.pl" might give you a better idea then
17:23 yko but I'm curious about the general use cases as 'simple hello world' you mentioned, so thanks for both example
17:23 yko s
17:23 yko and for fast.pl as well :)
17:24 sri fast.pl is for the Mojo stack, hello.pl for Mojo and Mojolicious
17:24 sri gives you a good idea of how much the actual framework costs atm
17:25 sri (in the most minimal case)
17:27 * sri loves wrk, finally a benchmark tool that can easily overwhelm servers so you can test the actual limits
17:38 preaction left #mojo
17:44 ynonp joined #mojo
17:50 preaction joined #mojo
17:54 labrown joined #mojo
18:15 btyler joined #mojo
18:16 sh3 joined #mojo
18:18 crab sri: boo
18:19 sri /o\
18:25 sri crab: i suppose that means you're against the removal now... considering you can currently unload it with app->plugins->unsubscribe('before_dispatch');
18:27 crab yeah, or by substituting a poweredby.pm with an empty sub register.
18:29 crab what is wrk?
18:29 crab ok, github/wg/wrk
18:29 sri modern replacement for ab that actually works
18:30 sri when you say you want 10k concurrent connections you actually get them :)
18:37 Mike-PerlRecruiter_ joined #mojo
18:37 dod joined #mojo
18:43 good_news_everyone joined #mojo
18:43 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/1drMBw
18:43 good_news_everyone mojo/master cff43a5 Sebastian Riedel: mention which methods set up hooks
18:43 good_news_everyone left #mojo
18:47 good_news_everyone joined #mojo
18:47 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/lIwasA
18:47 good_news_everyone mojo/master ac9df07 Sebastian Riedel: documentation tweaks
18:47 good_news_everyone left #mojo
18:54 good_news_everyone joined #mojo
18:54 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/MKRVzQ
18:54 good_news_everyone mojo/master 5d4a77a Sebastian Riedel: better plugin tests
18:54 good_news_everyone left #mojo
18:57 sri oh, i guess the value of my two letter .io domains just went way up :)
18:59 suy joined #mojo
19:07 sh4 joined #mojo
19:22 SmokeMachine joined #mojo
19:32 sh3 joined #mojo
19:45 jpn joined #mojo
20:09 dod joined #mojo
20:21 good_news_everyone joined #mojo
20:21 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/tuOitw
20:21 good_news_everyone mojo/master 1a8542b Sebastian Riedel: better plugin descriptions
20:21 good_news_everyone left #mojo
20:40 KindOne joined #mojo
20:41 batman my app wants to authenticate with facebook using the OAuth2 plugin (by marcus). how do i test that?
20:42 gryphon joined #mojo
20:42 batman i'm thinking i could 1) replace the helper or 2) make the _ua inside the helper return mocked data.
20:42 rwstauner left #mojo
20:43 batman i was hoping i could go by #2, but where can the _ua get the data from? can i *any* $ua return data from the Test::Mojo server?
21:00 good_news_everyone joined #mojo
21:00 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/64P8bg
21:00 good_news_everyone mojo/master 2f013e2 Sebastian Riedel: better recipe for operating modes
21:00 good_news_everyone left #mojo
21:02 good_news_everyone joined #mojo
21:02 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/OwOxGQ
21:02 good_news_everyone mojo/master 6fe17d1 Sebastian Riedel: improved operating mode recipe a little
21:02 good_news_everyone left #mojo
21:09 SmokeMachine joined #mojo
21:24 ka2u joined #mojo
21:27 gryphon joined #mojo
21:27 batman Mojo::UserAgent->app($t->app); # seems to do the trick
21:28 batman is it evil..? why is it done in Mojolicious::Lite ?
21:35 lukep joined #mojo
22:07 good_news_everyone joined #mojo
22:07 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/GzVrJw
22:07 good_news_everyone mojo/master 0a98e3e Sebastian Riedel: documentation tweaks
22:07 good_news_everyone left #mojo
22:24 batman is this a bug: Mojo::URL->new('redis://localhost:80')->host # prints nothing
22:24 batman marcus: we got a serious bug in Mojo::Redis if that ^^ is not a bug :(
22:27 sri not a bug
22:27 batman sri?
22:28 batman I got v3.97.
22:29 _xaka_ joined #mojo
22:32 sri it's your bug
22:33 sri i had the same bug in Mango though
22:34 batman can you explain how to fix it?
22:34 sri https://github.com/kraih/mango/commit/5​dc6d67bb84f32aa16bbd5967650366006672747
22:36 sri just read the Mojo::URL documentation
22:40 batman i don't get how that makes life easier.
22:47 gryphon joined #mojo
22:53 btyler joined #mojo
22:59 tianon it makes sri's maintenance life easier :)
22:59 batman oh?
23:05 batman marcus: i just released 0.9905
23:12 sri it doesn't, it makes new features possible
23:12 sri <%= link_to Contact => Mojo::URL->new('mailto:sri@example.com') %>
23:13 sri this did not work in the past, since data for unknown schemes got mangled
23:14 sri it only gets split in scheme and scheme data, so you can safely change the scheme and reparse it if you like
23:14 batman couldn't you add special handling for \w+:[^/] or something?
23:14 sri which is what i did in Mango
23:15 sri batman: that's ridiculous
23:15 sri :/ is not an indicator for a URL
23:15 sri file:/// anyone?
23:16 batman but how is "ftp://foo.com" not an url ?
23:16 sri it is, but not relevant for mojolicious core
23:17 batman btw: i wasn't trying to indicate what was an url, i was trying to make a rule for what would match mailto:
23:17 batman and friends
23:17 batman i wasn't saying :/ either. i was saying : + NOT /
23:18 sri and i repeat myself.... file:///
23:19 sri our current behavior is based on http://url.spec.whatwg.org
23:19 batman you're not making any sense sri :/
23:19 batman *pun intended*
23:19 * sri gives up
23:20 batman perl -le'print shift =~ m,^\w+:[^/], ? "MATCH" : "NOPE"' mailto:bar
23:20 batman perl -le'print shift =~ m,^\w+:[^/], ? "MATCH" : "NOPE"' http://yikes
23:20 batman perl -le'print shift =~ m,^\w+:[^/], ? "MATCH" : "NOPE"' redis://yikes
23:20 batman prints MATCH, NOPE, NOPE
23:21 batman perl -le'print shift =~ m,^\w+:[^/], ? "MATCH" : "NOPE"' file:///
23:21 batman ..also prints NOPE.
23:21 batman i think it's a better exception rule than grep { $_ eq $proto } qw/ http ... /
23:31 ka2u joined #mojo
23:35 sri i:/just/made/this/up is a valid URI too
23:47 sri batman: i'm not sure what exactly you're arguing for anyway
23:48 sri even if you check for the presence of "://", that only indicates the presence of an authority
23:48 sri not what format the authority has
23:49 sri Mojo::URL can only parse certain kinds of authorities, blindly accepting everything is not gonna work
23:51 sri mongodb:// is an example for that http://docs.mongodb.org/manual​/reference/connection-string/

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