Camelia, the Perl 6 bug

IRC log for #mojo, 2012-11-10

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

All times shown according to UTC.

Time Nick Message
00:21 Molaf joined #mojo
01:17 Mike-PerlRecruiter_ joined #mojo
01:30 daniel_ joined #mojo
01:34 * dross ponders
01:47 dross tempire: you don't like rethinkdb because it doesn't work on osx? that's sort of vain
01:51 dross haha, oh wow
01:51 dross http://news.ycombinator.com/item?id=4763879
01:51 dross A yc company hired me. I showed up at their mountain view office. The founder said "This is the former office of RethinkDB! I hope we are as successful as them."
01:51 dross 3 days later he asked me to clear my desk and leave. He said "You are the sort of person who should work in RethinkDB".
01:53 mattastrophe joined #mojo
01:59 dross hmm, rethnkdb doesn't look all that glamourous yet, maybe it will be a mongodb competitor soon
02:07 sunson joined #mojo
02:11 xaka joined #mojo
03:35 noganex_ joined #mojo
03:51 asarch joined #mojo
03:54 sawtooth joined #mojo
04:04 dvinciguerra joined #mojo
04:14 inokenty joined #mojo
04:21 daniel_ joined #mojo
04:32 Molaf joined #mojo
04:33 Molaf joined #mojo
04:41 Foxcool joined #mojo
05:45 Foxcool joined #mojo
05:57 Kulag joined #mojo
06:17 Vandal joined #mojo
06:28 Polarn_ joined #mojo
06:32 ladnaV joined #mojo
06:36 Kulag joined #mojo
06:37 Vandal joined #mojo
06:38 Caelum is mojolicious good for cgis? (actual cgis, not registry)
06:45 kitt_vl joined #mojo
06:46 Caelum well, silly to expect anyone to be here on a friday night :)
06:47 avenj https://metacpan.org/module/Mojolicious::Lite
06:47 avenj pretty great, yeah
06:50 Caelum avenj: neat, thank you
06:50 Caelum avenj: is it possible to use TT as your template engine?
06:55 avenj I've never tried, Mojo::Template is pretty decent.. but there's a thing for conveniently adding other template systems
06:55 avenj mm
06:55 avenj ah, this -> http://search.cpan.org/~sri/Mojolicious-​3.56/lib/Mojolicious/Guides/Rendering.po​d#Adding_your_favorite_template_system
06:56 * avenj not much of an expert, just slightly drunk user :o
06:56 Caelum :)
07:13 mire_ joined #mojo
08:26 Vandal joined #mojo
08:38 * sri yawns
08:49 sh4 joined #mojo
08:51 crab hi sri.
08:57 sri hi mr crab
08:57 Kulag joined #mojo
09:26 * sri has to wait 3 more days for his new macbook :S
09:26 * tempire sprinkles
09:31 tempire sri: ram size?
09:31 tempire hdd?
09:31 sri 8gb/128gb
09:32 tempire 8g...snazzy.
09:32 tempire i7?
09:32 sri i5
09:32 sri i7 is not worth the price according to reviews
09:33 sri the i5 comes with pretty much everything enabled this time
09:34 sri i7 just has a slightly different clock speed and cache
09:36 * sri would have gone i7 if it was quad core :)
09:37 tempire huh.  surprised the airs aren't quad co' yet
09:37 sri heat problems i suppose
09:38 * tempire hugs his quad core
09:38 * tempire stays warm
09:39 marcus <3 quad core i7
09:40 tempire I'm glad I purchased before the retina came out
09:40 sri your rMBP is not dead again yet? ;p
09:40 tempire I would have jumped on that immediately
09:40 marcus I'm glad I purchased the retina one.
09:40 marcus sri: nope, it's working fine, and the latest software update even fixed the annoying graphics glitches I was having.
09:40 marcus for the record, the previous damage was a physical one :-/ They found a small bend on the screen.
09:41 marcus so it must have been damaged during transport.
09:41 sri reviews said the retina screen is fragile :)
09:41 tempire marcus: do you operate at 1440x900?
09:41 marcus tempire: yepp.
09:42 * sri doesn't early adopt new apple products
09:42 marcus sri: well, it is thinner than the previous one.
09:42 * marcus treats apple products like pokemon.
09:42 tempire I don't think I would have been happy without the 1680x1050 hires
09:43 sri had my old macbook survived i prolly would have waited for the second generation
09:43 marcus tempire: given that actual resolution is 2880x1800, you can just adjust the font size...
09:44 * sri can't believe how terrible the 13" rMBP turned out
09:45 Britzel joined #mojo
09:49 sri wow, the rethinkdb thread on hackernews exploded
09:52 Kulag joined #mojo
10:00 Kulag joined #mojo
10:04 dabudabu joined #mojo
10:09 d4rkie joined #mojo
10:11 mire_ joined #mojo
10:26 crab do you like rethinkdb?
10:30 sri the architecture looks pretty cool
10:30 sri it's just missing a few important features, which are planned for the next few months
10:30 sri like secondary indexes
10:31 sri the query language is very mongodb like, maybe better, it uses plain json, and adding nodes is absolutely trivial
10:31 sri devops folks will like it a lot more than mongodb
10:32 sri mvcc seems like a good choice too, append only btree, like couchdb, but with an automatic garbage collector
10:35 sri i don't quite understand how they did sharding, but since it's all just plain old master/slave internally it must be simple
10:38 sri wire protocol is protobuf... which i don't like much
10:42 Drossel joined #mojo
10:44 jayallen joined #mojo
10:49 crab that's the google one?
10:54 Vandal joined #mojo
10:57 kvorg joined #mojo
10:58 good_news_everyone joined #mojo
10:58 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/JlHr3A
10:58 good_news_everyone mojo/master 107c36e Sebastian Riedel: fixed range bug in Mojo::Asset::Memory
10:58 good_news_everyone left #mojo
11:01 sri it is, with the ugly .proto files
11:02 * sri wonders why Mojo::Asset::File/Memory->contains return a position and not true/false
11:02 sri seems pointless
11:03 sri is that useful in any way for plugins?
11:06 yakudza joined #mojo
11:09 Kulag joined #mojo
11:12 crab maybe if you're looking for a file signature to verify that something is a PDF or a JPG or something
11:12 crab dunno.
11:15 mire_ joined #mojo
11:18 Kulag joined #mojo
11:23 Drossel joined #mojo
11:57 Kulag joined #mojo
12:37 ObseLeTe joined #mojo
12:48 jayallen joined #mojo
12:52 good_news_everyone joined #mojo
12:52 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/xnu8hw
12:52 good_news_everyone mojo/master 721dbe9 Sebastian Riedel: improved performance of contains method in Mojo::Asset::File by 100%
12:52 good_news_everyone left #mojo
12:52 Adura So, it's free?
13:02 Vandal joined #mojo
13:17 Foxcool joined #mojo
13:18 Mike-PerlRecruiter_ joined #mojo
13:18 sunson joined #mojo
13:20 d4rkie joined #mojo
13:20 sunson The "access_token" here --> https://metacpan.org/module/Mojo::Facebook refers to the "code" redirected to by FB upon completing oauth2? or is it the FB App secret?
13:43 Polarn joined #mojo
14:11 mire_ joined #mojo
14:24 Vandal joined #mojo
14:35 * batman just updated Mojo::Facebook with better doc for access_token
14:35 batman too bad it was too late for sunson...
14:40 zpmorgan joined #mojo
14:48 crab what is the answer?
14:51 batman https://github.com/jhthorsen/mojo-facebook/co​mmit/7f5fa7c7e78d000790e0fcfc534b4b2b8ce718df
14:52 crab heh, suddenly i realise that i don't care enough to click on the link :-)
14:57 batman ;)
15:09 lammel2 joined #mojo
15:19 coff joined #mojo
15:32 ryozi joined #mojo
15:52 batman i see that i need to make Mojo::TFTPd now...
15:52 batman just to make the circle complete :)
15:53 batman got a modified version of Net::TFTPd, a POE version a broken AE version, so....
16:12 nic joined #mojo
16:13 dpetrov_ joined #mojo
16:18 coff joined #mojo
16:19 dod joined #mojo
16:26 D4RK-PH0ENiX joined #mojo
16:27 mire_ joined #mojo
16:30 inokenty joined #mojo
16:31 murray joined #mojo
16:32 murray hi.  trying to combine helpers called from within a Mojo::IOLoop (inside a Mojolicious app) and it's throwing weird errors.
16:32 murray this demonstrates my problem https://gist.github.com/4051592
16:33 murray any suggestions on what i'm being stupid about?
16:34 murray it's calling /pretty/delay that throws the errors into the server log (Mojolicious 3.56, morbo, perl 5.10.1)
16:35 sri why do you ->finish after rendering? and why do you utf8 encode your json?
16:37 murray finish because http://mojolicio.us/perldoc/Mojoli​cious/Guides/Cookbook#REALTIME_WEB says when using recurring timers like this, they … need to be stopped manually, or they would just keep getting emitted.
16:37 murray and without it, the timer does appear to just keep on going
16:37 sri not the finish event
16:37 sri the ->finish call
16:38 murray rum, not sure I'm following you, but i was following the example for recurring timers on http://mojolicio.us/perldoc/Mojoli​cious/Guides/Cookbook#REALTIME_WEB
16:39 murray ^urm
16:39 sri http://mojolicio.us/perldoc/M​ojolicious/Controller#finish
16:40 sri do you have a websocket or a long poll stream?
16:41 murray jQuery ajax get http request from browser client to server.  I want/need support for i.e. < 10, which i believe means I can't rely on js WebSockets
16:41 Netfeed left #mojo
16:41 murray same error occurs if i curl to the server for /pretty/delay
16:42 sri perhaps i should be more clear, ->finish makes no sense at all in your example
16:42 sri i was just asking because there might be context missing
16:42 Britzel Isn't the render(text => $json) call missing a format and or a status? I remember that my JSON replies failed when at least status was missing.
16:43 sri render(text => $json) is pretty much guaranteed to be wrong and end up with double encoded garbage
16:43 sri http://mojolicio.us/perldoc/Mojolici​ous/Guides/Rendering#Rendering_text
16:44 murray Britzel: it may well be incomplete json, but it works in a browser.  /, /pretty and /delay all work without error.  /pretty/delay works, but logs the two error lines to the server log
16:44 murray ok, how can I get  $self->render(json => {foo => [1, 'test', 3]}); to be emitted in pretty format?
16:44 murray aka, more human readable
16:47 murray sri: ok, I get you're saying ->finish makes no sense here, but what I'm failing to get is why it's shown in the examples on http://mojolicio.us/perldoc/Mojoli​cious/Guides/Cookbook#REALTIME_WEB that I'm trying to follow.  The Mojo::IOLoop->recurring example has a $self->finish there.  Why's it make sense there, but not in my case?
16:47 sri murray: that's a long poll example
16:48 sri read what i linked before
16:48 sri don't just cargo cult method calls you don't understand
16:48 dod joined #mojo
16:49 sri those recipes are for advanced users, not beginners
16:49 sri the other guides are a prereq
16:49 murray ok, i'm clearly missing something, but thanks for the help.  I'll go and re read and see if i can figure it out
16:51 coff joined #mojo
16:55 sh4 joined #mojo
16:58 dod1 joined #mojo
17:05 sh4 joined #mojo
17:15 Polarn_ joined #mojo
17:44 murray left #mojo
18:00 motoboi joined #mojo
18:17 ladnaV joined #mojo
18:19 SmokeMac_ joined #mojo
18:38 sri perhaps i should have said that i have no clue what caused his error... i just pointed out obvious flaws
18:38 * sri shrugs
18:53 sri hmmm, it's actually not very hard to make Mojo::UserAgent work blocking and non-blocking at the same time
18:54 sri as far as i can see it is only ->app_url preventing it atm
18:55 sri connections would just have to be flagged a blocking and non-blocking, and we would need two test servers and keep alive caches
18:56 sri the problem is ->app_url wouldn't be unique anymore
18:56 sri two versions would be required, breaking backwards compatibility
19:15 inokenty joined #mojo
19:15 inokenty left #mojo
19:18 kongelaks joined #mojo
19:39 sh4|2 joined #mojo
19:39 kongelaks Hi all. If I have a variable ($data) containing a raw multipart HTTP response (http status, headers,  body), must I do anything besides call Mojo::Message::Response->new->parse($data) to get the properly built response object?
20:14 sh4 joined #mojo
20:32 rem_lex| joined #mojo
21:12 batman https://github.com/jhthorsen/mojo-tftpd <-- i hope you won't "disable" my module sri :)
21:13 * sri disables batmans module
21:14 batman noooooo!
21:14 batman https://metacpan.org/module/​AnyEvent::TFTPd#DESCRIPTION <-- referring to this
21:15 sri i don't see anything controversial in the code
21:16 batman Mojo::TFTPd ?
21:16 sri $reactor->io is meant to be used exactly like that
21:16 batman yeah. and i think it's amaaaaaaazing!
21:16 batman it's so neat
21:16 batman :)
21:16 sri i guess mlehmann is upset because people treat UDP like TCP streams
21:17 sri had you used Mojo::IOLoop::Stream i would yell at you too :)
21:17 jamesw now there's a new ae-handle-udp anyway so you could probably write a new ae-tftpd
21:17 batman sri: yeah, you've already told me not to :)
21:17 batman jamesw: yeah. it's a fork of my module
21:18 batman jamesw: don't care though. Mojo is 100000x easier to work with
21:18 * sri wishes UDP was a little easier to do right in perl
21:20 sri batman: bug report, you don't support ipv6 ;p
21:20 batman right?
21:20 batman sri: i know. need to save something for version 0.02 :)
21:21 sri more like the node.js api, i find that a lot more pleasant to work with than IO::Socket http://nodejs.org/api/dgram.html
21:21 sri batman: perhaps a more generic Mojo::IOLoop::Datagram would be useful
21:22 batman could be... not sure if i'm the person to make it general...
21:22 batman also, it seems too easy to put into a separate module imo
21:23 batman or... maybe not with the IPV6 stuff
21:23 batman i might do a draft one day
21:23 sri $datagram->bind('127.0.0.1', '3000'); $datagram->on(message => sub { my ($datagram, $message, $address, $port) = @_; });
21:23 batman makes sense
21:25 sri perhaps Mojo::Datagram... so the Mojo::IOLoop::Datagram name stays free for core inclusion in the future ;)
21:25 batman hehehe
21:26 sri i still think at some point we may have the need to real UDP support
21:26 batman i can make a gist and you can pull it into core if you like it
21:26 sri not yet
21:26 batman ok
21:28 sri maybe we'll have the need for a non-blocking resolver again in the future, who knows
21:28 batman non-blocking resolver?
21:28 batman dns?
21:29 sri yes, a failed experiment between 1.0 and 2.0
21:29 batman ok
21:29 sri https://github.com/kraih/mojo/blob/​d280d02beb74b3a45733b185aebf5497fa3​3c04b/lib/Mojo/IOLoop/Resolver.pm
21:30 sri the UDP code was pretty terrible, but the dns parser worked pretty well
21:32 sri wasn't worth the trouble in the end
21:32 batman *reading*
21:33 sri many many people were unhappy that we often bypassed the system resolver and its special features
21:34 batman :)
21:34 batman typical
21:34 sri well, they are right
21:37 batman i think i need some more wine, food and a movie
21:37 * sri needs sleep
21:37 batman yeah. that to :P
21:41 dod joined #mojo
21:48 sri batman: btw. i tend to use only the reactor when a module is low level enough
21:49 sri has reactor => sub { require Mojo::IOLoop; return Mojo::IOLoop->singleton->reactor };
21:49 sri https://github.com/kraih/mojo/blob/m​aster/lib/Mojo/IOLoop/Client.pm#L21
21:52 sri (instead of Mojo::IOLoop)
22:02 daniel_ joined #mojo
22:53 jzawodn joined #mojo
23:28 motoboi joined #mojo
23:34 bjoernfan http://www.flickr.com/photos/mojolicious/ wth
23:38 batman sri: i've been considering that, but i think my module is both low and high level

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