Camelia, the Perl 6 bug

IRC log for #mojo, 2013-04-06

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

All times shown according to UTC.

Time Nick Message
00:09 egopro joined #mojo
00:39 egopro joined #mojo
00:43 d4rkie joined #mojo
00:59 ka2u joined #mojo
01:07 sri hmm
01:08 sri if we ever decide to move to promises, this might be a sensible start http://pastie.org/7334735
01:08 sri perl -Ilib -Mojo -E 'Mojo::IOLoop->mojo::promise::client({address => "mojolicio.us", port => 80})->then(sub { say "1: $_[2]" })->then(sub { say "2: $_[2]"; Mojo::IOLoop->stop }); Mojo::IOLoop->start'
01:11 egopro joined #mojo
01:11 ka2u joined #mojo
01:12 sri biggest problem i see atm is the connection between appropriate event loop and promise constructor though
01:12 sri since it won't always be the global singleton
01:20 sri makes $promise->wait a bit tricky
01:21 sri as in Mojo::IOLoop->mojo::promise::c​lient()->then()->then()->wait;
01:24 sri or $ua->mojo::Promise::get('mo​jolicio.us')->then()->wait;
01:26 jberger have I created a monster?  :-P
01:26 jberger kidding, I blame mst
01:27 sri odds of me actually implementing it are small atm
01:27 sri but throwing around some ideas sure doesn't hurt
01:27 jberger absolutely
01:28 sri $ua->mojo::promise::get('mojolicio.us')->and($ua​->mojo::promise::get('perl.org'))->then()->wait;
01:38 sri maybe i've not seen the light yet, but promise chains are not very nice
01:39 sri you know, the usual, perform parallel get requests, perform post request based on the results, and then print something
01:41 sri basically, promises need to look better than this https://github.com/kraih/mango/​blob/master/t/connection.t#L65
01:42 kumogami joined #mojo
01:44 ka2u joined #mojo
01:45 jberger I actually really don't have an opinion on promises, and I have liked the concept of the delay/step stuff, but mostly I like the parser/dispatcher tricks :-D
01:45 jberger yeah, that looks really nice
01:46 sri promises get super cool when you have coroutines basically... you just go "my $tx = $ua->mojo::promise::get('mojolicious')->wait;" and it yields back into the event loop until your promise has a value
01:47 sri but without, they only seem more verbose so far
01:56 Meiermann joined #mojo
02:14 mike_ joined #mojo
02:26 jberger sri: opinions? http://stackoverflow.com/a/15845042/468327
02:27 sri that BOOM! looks familiar ;p
02:28 jberger that caught my eye too
02:29 jberger the discussion that I have most been just  a witness to these last few days has really helped me understand some of this more (I hope!)
02:29 sri the second example doesn't look very nice
02:30 jberger suggestions?
02:30 jberger I could just do the new begin->('foo') thing
02:31 jberger but I was trying to make a parallel with the ->end method the OP is expecting
02:31 sri naah, i hate the sub { ...->() } thing in general
02:32 jberger kinda hard to make a short meaningful example without it tho
02:32 sri yea
02:32 sri doesn't mean i have to like it ;p
02:33 jberger nope
02:33 jberger :-)
02:33 jberger well just thought I would ask
02:33 jberger I'm always trying to promote mojo, but I worry sometimes on things I'm not an expert in
02:34 jberger answering badly might be worse than not promoting sometimes
02:35 jberger I've taken to calling it the
02:35 jberger "Mojolicious suite" when not using it as a framework
02:35 jberger Mojo::UserAgent, Mojo::DOM etc
02:36 jberger otherwise I worry that people will ask "why are you having me install a web framework?"
02:37 sri "The Mojolicious Platform" :)
02:37 sri node.js calls itself a platform too (stole it from there)
02:38 jberger nice
02:40 jberger course that doesn't really mean anything, suite, or suite of tools I think probably conveys my meaning more
02:40 jberger Platform sounds kinda lingo-y
02:41 jberger oh just kill me now, all I do all day lately is make word choices and I do THIS when I'm on a break?!
02:42 ka2u joined #mojo
02:43 egopro joined #mojo
02:55 preflex_ joined #mojo
03:14 egopro joined #mojo
03:30 ispy_ joined #mojo
03:46 egopro joined #mojo
03:48 asarch joined #mojo
03:56 egopro joined #mojo
03:56 ka2u joined #mojo
04:44 ka2u joined #mojo
04:50 egopro joined #mojo
05:21 egopro joined #mojo
05:30 basiliscos joined #mojo
05:34 ispy_ joined #mojo
05:38 KindOne joined #mojo
06:11 komodo1 joined #mojo
06:14 ka2u joined #mojo
06:21 egopro joined #mojo
06:45 Vandal joined #mojo
06:46 mattastrophe joined #mojo
06:52 egopro joined #mojo
06:59 dod joined #mojo
07:00 mattastrophe joined #mojo
07:11 komodo joined #mojo
07:14 dod joined #mojo
07:54 jzawodn joined #mojo
08:01 laouji joined #mojo
08:01 laouji joined #mojo
08:23 egopro joined #mojo
08:27 sh3 joined #mojo
08:28 jamesw joined #mojo
08:36 d4rkie joined #mojo
08:47 laouji_ joined #mojo
08:56 denisboyun joined #mojo
09:00 rem_lex|pivo joined #mojo
09:26 egopro joined #mojo
10:00 egopro joined #mojo
10:12 kitt_vl joined #mojo
10:20 rihegher joined #mojo
10:33 egopro joined #mojo
10:39 Britzel_ joined #mojo
10:43 coff joined #mojo
11:06 egopro joined #mojo
11:20 ispy_ joined #mojo
11:29 basiliscos joined #mojo
11:39 egopro joined #mojo
11:40 ispy_ joined #mojo
12:05 ispy_ joined #mojo
12:10 egopro joined #mojo
12:32 mire joined #mojo
12:38 KindTwo joined #mojo
12:49 Kripton joined #mojo
12:56 snuffles joined #mojo
13:04 Kripton joined #mojo
13:06 mire joined #mojo
13:09 Kripton joined #mojo
13:12 egopro joined #mojo
13:16 bowtie joined #mojo
13:17 basic6 joined #mojo
13:17 ka2u joined #mojo
13:36 wingfold_ joined #mojo
13:43 egopro joined #mojo
13:45 basiliscos joined #mojo
14:15 rwstaune` joined #mojo
14:17 egopro joined #mojo
14:29 sh4 joined #mojo
14:48 egopro joined #mojo
15:18 egopro joined #mojo
15:33 rem_lex| joined #mojo
15:41 inokenty joined #mojo
15:45 asarch joined #mojo
15:47 moltar joined #mojo
15:49 egopro joined #mojo
16:11 ka2u joined #mojo
16:12 StylusEater joined #mojo
16:12 StylusEater does someone have a good link to a Plugin tutorial? I'm having an issue calling it from my template. The tutorial on the google groups site isn't very complete.
16:13 Britzel_ I used M::Plugin::I18N as a sample to make my own.
16:14 StylusEater I looked in the Mojolicious::Plugin::Config for an example ... I've written the one I want but I get an error saying it's an undefined subroutine
16:15 Britzel_ Time to start debugging.
16:21 egopro joined #mojo
16:39 sri StylusEater: http://mojolicio.us/perldoc/Mojolici​ous/Guides/Rendering#Helper_plugins
16:39 sri it's all in the guides (don't read them out of order though)
16:42 sri oh noes, google might buy whatsapp :o
16:46 StylusEater thx sri
16:49 StylusEater @sri: so the generate isn't like rails where I can generate a new controller and have it hook into my existing application ... seems like it generate an entire new directory structure
16:51 egopro joined #mojo
17:01 wingfold joined #mojo
17:09 denisboyun joined #mojo
17:19 heytrav joined #mojo
17:22 egopro joined #mojo
17:30 BeDa joined #mojo
17:53 egopro joined #mojo
18:25 asarch joined #mojo
18:29 egopro joined #mojo
18:29 wingfold joined #mojo
18:30 heytrav joined #mojo
18:46 sh3 joined #mojo
18:48 buu StylusEater: A new controller is like two lines of code =]
18:55 lammel2 joined #mojo
18:56 lammel2 joined #mojo
18:59 StylusEater buu: it was an example... :-) I was hoping the generate plugin would do something similar ...
18:59 egopro joined #mojo
18:59 buu I'm just trying to point out there's not much to generate
19:00 StylusEater buu: for a controller yes
19:01 StylusEater buu: still getting the feel for the framework ... I like it ... just breaking bad habits
19:02 lammel2 joined #mojo
19:03 zacts joined #mojo
19:05 rihegher joined #mojo
19:08 rihegher left #mojo
19:14 rem_lex|pivo joined #mojo
19:25 BeDa joined #mojo
19:30 egopro joined #mojo
20:01 egopro joined #mojo
20:16 sh4 joined #mojo
20:27 StylusEater buu: my problem seems to be related to the fact that I'm using MyApp::Plugin::PluginName and not Mojolicious::Plugin::PluginName. I populated namespaces and called register_plugin ... doesn't seem to be working ... fails with a helper method not recognized ... I assume $app isn't being passed
20:28 d4rkie joined #mojo
20:32 egopro joined #mojo
20:37 denisboyun joined #mojo
20:52 basiliscos joined #mojo
21:03 basiliscos joined #mojo
21:03 egopro joined #mojo
21:11 basiliscos joined #mojo
21:32 basiliscos joined #mojo
21:35 egopro joined #mojo
21:56 basiliscos joined #mojo
21:58 perlite_ joined #mojo
22:05 egopro joined #mojo
22:09 basiliscos joined #mojo
22:36 egopro joined #mojo
22:54 basiliscos joined #mojo
23:07 egopro joined #mojo
23:11 wingfold joined #mojo
23:16 hrupp_ joined #mojo
23:22 ka2u joined #mojo
23:30 basiliscos joined #mojo
23:34 basiliscos joined #mojo
23:39 egopro joined #mojo

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