The web in a box - a next generation web framework for the Perl programming language

IRC log for #mojo, 2015-12-15

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

All times shown according to UTC.

Time Nick Message
00:18 disputin joined #mojo
00:30 orev joined #mojo
00:34 good_news_everyon joined #mojo
00:34 good_news_everyon [mojo] kraih tagged v6.37 at ba0d53b: http://git.io/v0uz1
00:34 good_news_everyon left #mojo
00:36 good_news_everyon joined #mojo
00:36 good_news_everyon [mojo] kraih pushed 1 new commit to master: http://git.io/v0ugv
00:36 good_news_everyon mojo/master 7c5aa51 Sebastian Riedel: bump version
00:36 good_news_everyon left #mojo
00:36 sri odd how postgres 9.5 just doesn't get released
01:19 nnutter joined #mojo
01:44 aborazmeh joined #mojo
01:59 nnutter joined #mojo
02:12 meshl joined #mojo
02:17 meshl joined #mojo
02:22 jberger sri++
02:44 Zoffix joined #mojo
02:59 nnutter joined #mojo
03:14 asarch joined #mojo
03:18 kaare joined #mojo
03:31 noganex_ joined #mojo
04:00 meredith joined #mojo
04:00 worklapperl joined #mojo
04:00 mikegrb joined #mojo
04:00 kwa joined #mojo
04:00 crux joined #mojo
04:00 dustinm joined #mojo
04:00 skaji joined #mojo
04:00 esh joined #mojo
04:00 crab joined #mojo
04:00 mgrimes joined #mojo
04:00 SmokeMachine joined #mojo
04:00 salparadise joined #mojo
04:00 genio joined #mojo
04:00 ashleydev joined #mojo
04:00 voldemortensen joined #mojo
04:00 charsbar joined #mojo
04:00 Andreas joined #mojo
04:00 anon joined #mojo
04:00 stuart joined #mojo
04:00 phillipadsmith joined #mojo
04:00 stokachu joined #mojo
04:00 Zoffix joined #mojo
04:00 jnbek joined #mojo
04:00 inokenty joined #mojo
04:00 CandyAngel joined #mojo
04:00 CHYC joined #mojo
04:00 berov joined #mojo
04:00 allison joined #mojo
04:00 absolut_todd joined #mojo
04:00 mattp joined #mojo
04:00 ssm joined #mojo
04:00 jabberwok joined #mojo
04:01 chansen joined #mojo
04:01 sawtooth joined #mojo
04:01 y1mmm joined #mojo
04:02 robinsmidsrod joined #mojo
04:03 diegok joined #mojo
04:04 ashimema joined #mojo
04:05 FatalNIX joined #mojo
04:14 Trelane joined #mojo
04:22 nnutter joined #mojo
04:38 nnutter_ joined #mojo
04:41 nnutter_ joined #mojo
04:53 tyldis joined #mojo
05:09 inokenty-w joined #mojo
05:28 sri wow, childhood's end is great, syfy is upping their game
05:29 nnutter joined #mojo
05:52 aborazmeh joined #mojo
06:08 sri jberger: i guess it would be nice if all code that subscribes to transaction events in Mojo::UserAgent moved into the channel
06:08 sri which should be the two resume subscribers
06:09 sri then you don't have to propagate the event
06:10 sri still feels odd to separate the $stream->on(read => sub {...}) from the $stream->write(...) into two separate modules though
06:13 nnutter joined #mojo
06:14 sri the refactoring really doesn't seem that hard anymore :)
06:15 sri and the user agent is actually the hard part, daemon is much easier
06:15 Phil21 jberger: worth tossing Mobjo::Websockify on github or something for folks like me who copy/paste our way into glory when hacking PoC's out ;)
06:15 Phil21 only spelled right
06:19 * sri wonders if Mojo::UserAgent should just leave the read event alone
06:20 sri and just call $channel->attach($stream) and later $channel->detach($stream) or so
06:20 sri (detach when the channel gets upgraded to websocket)
06:28 Vandal joined #mojo
06:42 melo joined #mojo
06:58 marcus sri: I feel exactly like jberger.
07:08 Lee joined #mojo
07:08 marcus Interesting to read the perl6 DOM tests. I hadn't noticed that p6 lets you use '-' in variable names. That is pretty insane.
07:09 marcus Also seems github can't parse perl6 correctly. - $foo ='#bar'; < thinks # is a comment
07:20 marcus also qq:to/END/ o^O
07:23 marcus Zoffix: https://github.com/zoffixznet/perl6-DOM-Parser/blob/master/t/01-dom.t#L616 <- is there a typo in that line or just p6 fairy dust that I don't understand?
07:54 tempire joined #mojo
08:00 Lee_ joined #mojo
08:00 tempire joined #mojo
08:05 Lee joined #mojo
08:06 trone joined #mojo
08:14 jzawodn_ joined #mojo
08:15 AndrewIsh joined #mojo
08:17 eseyman_ joined #mojo
08:37 Lee joined #mojo
08:39 osfabibisi joined #mojo
08:41 odc joined #mojo
09:00 berov joined #mojo
09:36 jontaylor joined #mojo
10:00 meshl joined #mojo
10:22 tyldis joined #mojo
10:44 meshl joined #mojo
10:52 melo joined #mojo
10:52 dvinciguerra joined #mojo
10:53 Zoffix joined #mojo
10:55 Zoffix marcus, not a typo.  %hash<key>
10:55 Zoffix sub-that-returns-hash<key>
10:56 Zoffix The most striking difference I noticed is the hyper operator » https://github.com/zoffixznet/perl6-DOM-Parser/blob/master/t/01-dom.t#L207
10:56 Zoffix Calls .remove on each element of the array, and then you proceed to call .first on the array
10:58 Zoffix Apostrophes are also allowed in term names:  $ain't-that-awesome is a valid name
11:19 Lee_ joined #mojo
11:32 yoshi joined #mojo
11:42 marcus zoffix: I don't think I like this language :-/
11:43 marcus apostrophes are an alias for :: in perl5?
11:43 Zoffix Yeah
11:43 Zoffix marcus, then I probably shouldn't mention custom-defined operators and terms: https://github.com/zoffixznet/perl6-Acme-GiveUp
11:44 Zoffix You just can't not like a language the lets you write this sentence in the docs: "This module exports one term: (╯°□°)╯︵┻━┻"
11:44 neilhwatson joined #mojo
11:44 marcus Zoffix: yeah, I'm probably going to have to stab a perl6 programmer some day.
11:44 Zoffix ehehe
11:45 marcus Either that, or release a module that exports  ¯\_(ツ)_/¯
11:46 Zoffix <Zoffix>m: sub infix:<¯\_(ツ)_/¯> ($a, $b) { ($a, $b).pick };   say "Meh" ¯\_(ツ)_/¯ "Eh" <p6eval> rakudo-moar 9e53fa: OUTPUT«Meh␤»
11:46 Zoffix :)
11:47 marcus mm, tried it in perl5, perl -E'sub  ¯\_(ツ)_/¯ { say "whatever man"; } ;  ¯\_(ツ)_/¯' Illegal declaration of anonymous subroutine at -e line 1.
11:47 marcus clearly I need a better language
11:47 Zoffix you'd need -Mutf8 for start, and then only use \w chars :)
11:48 Zoffix perl -Mutf8 -wlE 'sub テスト{ say "テスト"; } テスト'
11:49 vytas joined #mojo
11:50 marcus works, but warns about wide character in say :)
11:52 pink_mist https://metacpan.org/pod/distribution/Acme-LookOfDisapproval/lib/Acme/o_o.pm
11:53 Zoffix pink_mist, well, that was anticlimatic: http://i.imgur.com/W0yLsWN.png
11:55 pink_mist not my fault your font doesn't support ಠ_ಠ :P http://puu.sh/lWlwk/66dcb8d4cb.png
12:31 berov1 joined #mojo
12:33 berov joined #mojo
12:55 hernan605 joined #mojo
13:26 jberger marcus: I feel just like batman
13:36 abra joined #mojo
13:45 avenj joined #mojo
14:09 marcus jberger: chilling out on vacation in Asia?
14:14 jberger I wish
14:32 batman ?
14:34 genio 3 more days and I'm on vacation!
14:34 * genio does a mental back-flip
14:34 batman jberger: what do i feel?
14:34 batman indestructible..?
14:34 batman ;)
15:00 asarch joined #mojo
15:03 kaare joined #mojo
15:20 PopeFelix joined #mojo
15:26 punter joined #mojo
15:31 jberger batman: marcus said he felt exactly like me. I thought it was a bit we were doing
15:32 hernan605 joined #mojo
15:40 sue joined #mojo
15:41 dvinciguerra joined #mojo
16:01 trone joined #mojo
16:05 lluad joined #mojo
16:07 voldemortensen joined #mojo
16:08 disputin joined #mojo
16:09 voldemortensen1 joined #mojo
16:23 gryphon joined #mojo
16:44 meshl joined #mojo
16:47 disputin joined #mojo
16:47 hernan605 joined #mojo
16:56 kaare joined #mojo
17:00 CandyAngel Can I try my hand at writing Mojo::Telnet?
17:10 sh4 joined #mojo
17:20 jberger CandyAngel: what would that be?
17:21 jberger Client + Expect?
17:21 jberger (its coming back to me now)
17:25 genio Expect?  eww.
17:45 PryMar56 joined #mojo
17:55 CandyAngel jberger: Just client stuff, like handling options and suboptions
17:56 CandyAngel I *think* I can do it pretty neatly (using emitted events and such)
18:01 jberger I think you're free to try, I don't especially think we need the namespace but sri or others might weigh in on that
18:01 sh4 joined #mojo
18:01 jberger otherwise, have fun
18:08 CandyAngel It doesn't have to be in that namespace
18:08 CandyAngel I can make it as Local::Telnet as a proof-of-concept
18:08 CandyAngel And then it if it any good, just change the namespace :P
18:16 * sri puts another item on the todo list https://github.com/kraih/mojo/issues/888
18:23 CandyAngel I had a little play earlier with it, just using Mojo::IOLoop::Client but the various ways of starting it meant I didn't have access to something
18:24 CandyAngel Mojo::IOLoop->client() meant emitting on the Stream object which seems.. wrong (client should be emitting option handling stuff as it should be stored in the client I think)
18:24 CandyAngel And Mojo::IOLoop::Client->new meant I didn't have access to the stream
18:27 trone joined #mojo
18:39 jberger CandyAngel: you need a connect method
18:42 CandyAngel Conenct method of handler of 'connect' event?
18:43 CandyAngel The latter doesn't get the stream, it gets the IO::Socket or something like that
18:44 jberger Mojo::Telnet::connect
18:45 CandyAngel Well, I was going to make Mojo::Telnet subclass Mojo::IOLoop::Client and add the extra attributes I need
18:45 jberger sub Mojo::Telnet::connect($self, ..., $cb) { $self->ioloop->connect(sub{ ... $cb->() }) }
18:45 CandyAngel Or I could delegate, whichever :)
18:45 jberger delegation++
18:45 CandyAngel okie, I'll go with delegation that
18:45 CandyAngel then*
18:47 CandyAngel I actually have a "wrapper" class around Mojo::Collection at work
18:47 CandyAngel So I can do $collection->flatten without it flattening the whole thing
18:47 CandyAngel Useful when the collection is a bunch of Tree::Simple objects :D
18:48 hshong joined #mojo
18:50 Mikey /win pre
18:54 CandyAngel I can make a start tomorrow I think, providing I don't get a bunch of stuff dropped on my desk :P
18:55 hshong I'd like to use 'hypnotoad' hot deployment in my application which uses websocket.
18:55 hshong but when i'm trying, it failed. cause maybe some 'WS' connections has still alive.
18:57 sri hshong: that wouldn't make it fail, the connections will be closed after a timeout
18:59 hshong yes, right. then didn't run a new process after timeout.
19:00 sri sounds unlikely
19:00 sri do you have a reproduceible test case?
19:01 hshong well, not now. i'll try
19:08 gabiruh joined #mojo
19:09 sri when you say "fail", do you mean you actually see a "Zero downtime software upgrade failed" message in the log?
19:09 hshong no
19:09 hshong i choose wrong word.
19:09 hshong it looks like 'Ubic::Service::Hypnotoad' problem, not 'hypnotoad'
19:10 hshong when i'm trying without Ubic::Service::Hypnotoad, it works.
19:10 sri ok
19:11 sri a big bug like that would have really surprised me, lots of people use zero downtime restarts in production all day long
19:14 hshong oh, sorry for that. i'm the one of the people. thanks.
19:37 hshong i found my fault > for hot deployment with Ubic::Service::Hypnotoad should use 'reload' command not 'restart'; $ ubic reload xxxx
19:37 hshong thank you for your help
19:37 jberger hshong: yikes
19:37 jberger that's quite a miss there :-P
19:38 hshong '-']/
19:59 voldemortensen joined #mojo
20:23 good_news_everyon joined #mojo
20:23 good_news_everyon [mojo] kraih pushed 1 new commit to master: http://git.io/v0r6J
20:23 good_news_everyon mojo/master e4e8165 Sebastian Riedel: mention subprotocol negotiation too
20:23 good_news_everyon left #mojo
20:29 trone_ joined #mojo
20:30 bpmedley joined #mojo
20:32 good_news_everyon joined #mojo
20:32 good_news_everyon [mojo] kraih pushed 1 new commit to master: http://git.io/v0rX2
20:32 good_news_everyon mojo/master cdbaceb Sebastian Riedel: slightly more consistent examples
20:32 good_news_everyon left #mojo
20:59 dvinciguerra joined #mojo
21:31 berov1 joined #mojo
21:31 berov1 Hi
21:32 berov1 Question about Mojo::mysql
21:32 berov1 I often get in my tests a warning...
21:33 berov1 (in cleanup) Can't call method "FETCH" on an undefined value at..Mojo/mysql.pm line 100 during global destruction
21:33 berov1 what is this?
21:34 berov1 I know something refers to $self which happens to be undefined already
21:34 berov1 but how this happens? What can be the root cause?
21:36 berov1 or may be $dbh
21:41 zacts joined #mojo
21:43 sri Mojo::mysql does not appear to be maintained very well
21:44 berov1 sri: any hint :)?
21:44 sri i don't use it
21:45 berov1 for me it means that $dbh is already out of scope and thus undefined
21:45 sri you might want to contact the author
21:45 genio isn't/wasn't that a batman module?
21:45 berov1 yes
21:45 sri he gave it up
21:45 genio ah
21:45 berov1 hoped to find him here...ah true
21:47 berov1 Svetoslav Naydenov
21:51 sri wow, absolutely nothing happened for websockets over http/2 yet :o
21:51 sri https://github.com/http2/http2-spec/issues/386#issuecomment-164894103
21:52 sri it's an odd situation, the hybi (websocket) working group is pretty much dead, so they will not working on it
21:52 sri and the http working group thinks it is out of scope for them
21:55 jberger yeah, because why would we want 2 way communication over these brilliant new http channels that we already have
21:55 jberger sigh
21:56 sri actually it's streams in http/2 :)
22:00 * jberger pukes
22:05 Adurah joined #mojo
22:06 sri it's so obvious that the cdns are in charge at the http wg now, they just don't care at all about websockets
22:07 jberger And yet Google is trying to kill flash too
22:08 jberger What are they going to fall back on after that?
22:08 Grinnz_ huh?
22:08 Grinnz_ Google doesn't need flash
22:09 jberger How are they doing push?
22:09 Grinnz_ are you talking about a different flash?
22:09 jberger They can't seriously be polling for all their push notifications?
22:09 sri i think he means for emulating websockets
22:09 jberger Yah
22:09 jberger Socket.io
22:09 sri ajax fallback should be fine
22:09 Grinnz_ I have flash blocked by default on most of my computers
22:10 jberger But you have websockets
22:10 Zoffix left #mojo
22:10 Grinnz_ if someone doesnt have websockets, they might as well poll
22:10 sri most browsers support websockets natively anyway
22:10 dvinciguerra joined #mojo
22:11 sri and the http/1 handshake is not going away, ever, i'm starting to think
22:11 Grinnz_ i'm pretty sure gmail just does polling anyway
22:13 sri jberger: got any more cleanups for me today? :)
22:13 meshl joined #mojo
22:15 jberger Still workday in the US
22:15 sri :,(
22:41 meshl joined #mojo
22:46 lluad joined #mojo
23:04 disputin joined #mojo
23:07 d4rkie joined #mojo
23:15 disputin joined #mojo
23:15 sue joined #mojo
23:24 harleypig I'm writing a helper that i want to log from. Using $app->log->debug works in the register subroutine, but not in the $app->helper(...) call.  I've also tried using the object passed to the anon sub but I'm not having any success there.
23:25 harleypig Any pointers on how to make the helper log what I want?
23:28 disputin joined #mojo
23:31 jberger harleypig: the only magic to the helpers is that they always get a controller
23:32 jberger so you want helper it_logs => sub { shift->app->log->debug('logged'); ... };
23:33 cpan_mojo Paws-0.21 by JLMARTIN https://metacpan.org/release/JLMARTIN/Paws-0.21
23:40 sri it would be kinda neat if we could use just one queue in Mojo::UserAgent
23:41 sri max_connections is currently applied to each queue individually
23:42 harleypig So, package MyApp::Plugin::MyPlugin; use M::B ' M::Plugin'; sub register { my ( $self, $app, $opts ) = @_; $app->log->debug( 'Registering MyPlugin' ); $app->helper( test => sub { $app->log->debug( 'helpertest' ) } ) }; ?
23:43 sri harleypig: that's literally in the rendering guide
23:43 harleypig ? I'll go look again ... but that's not logging anything.
23:44 sri http://mojolicio.us/perldoc/Mojolicious/Guides/Rendering#Helper-plugins
23:46 harleypig omg. I commented out the code that calls the helper in the controller and forgot to uncomment it.
23:46 * harleypig crawls back under his rock

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