Camelia, the Perl 6 bug

IRC log for #mojo, 2013-04-13

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

All times shown according to UTC.

Time Nick Message
00:16 jpn joined #mojo
00:24 jpn joined #mojo
00:39 good_news_everyone joined #mojo
00:39 good_news_everyone [mojo] kraih force-pushed master from 255f107 to 1fd66c3: http://git.io/BhzC7A
00:39 good_news_everyone mojo/master 1fd66c3 Sebastian Riedel: improved default descriptions in Test::Mojo
00:39 good_news_everyone left #mojo
00:41 sri http://starlogs.net/#kraih/mojo # muhahahahahahahaha
01:17 ZadYree I'm having a little routes problem using Mojolicious. One nested route works fine, the following one does not: http://i.imgur.com/FCN9ZOw.png?1
01:19 sri look closely at /findings
01:30 good_news_everyone joined #mojo
01:30 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/bOaWZw
01:30 good_news_everyone mojo/master 2963891 Sebastian Riedel: mention uWSGI instead of SCGI
01:30 good_news_everyone left #mojo
01:43 asarch joined #mojo
01:45 d4rkie joined #mojo
01:49 jb360 joined #mojo
01:57 Meiermann joined #mojo
02:34 jberger joined #mojo
02:34 jberger thesis sent!
02:34 jberger \o/
02:41 buu |
02:41 buu / \
02:41 buu Eek, his hips broke.
02:45 sri \o/
02:47 preflex_ joined #mojo
03:23 Akron joined #mojo
03:23 Akron Congratulation jberger!
03:25 GabrielVieira joined #mojo
03:37 jberger Akron: thanks!
04:05 basiliscos joined #mojo
04:13 d4rkie joined #mojo
05:09 ka2u joined #mojo
05:54 Vandal joined #mojo
06:24 Mike-PerlRecruiter_ joined #mojo
07:34 nic sri: I could look into SCRIPT_NAME handling (Tue or Wed) but I'd only be able to test under Apache+mod_perl2
07:35 nic not sure how useful the info will be
07:35 nic thus far, all I know is setting SCRIPT_NAME to '/' meant url_for etc worked for that particular app
07:36 nic I had intended to look into it more at the time
07:37 nic but currently my project intray has gone past 100 so things are manically busy most days
08:24 sh4 joined #mojo
08:48 dpetrov_ joined #mojo
09:03 mrphilov joined #mojo
09:13 d4rkie joined #mojo
09:34 basiliscos joined #mojo
09:38 denisboyun joined #mojo
09:41 dod joined #mojo
09:54 marty jberger:  congratulations and best of luck with your thesis.
10:09 dod joined #mojo
10:13 cstamas hi
10:13 cstamas how can I access a variable set via flash from a template?
10:25 denisboyun joined #mojo
10:39 Britzel_ joined #mojo
11:08 powerman1 joined #mojo
11:11 Vandal joined #mojo
11:19 powerman1 hi. sri, I'd like to ask what you think about two features for handling delayed responses more gracefully:
11:19 powerman1 1) provide a hook or event to run before timer/io callback with access to related M::Controller object (if any) - this is handy for ex. to configure log prefix using uri/path/route related to that req
11:19 powerman1 2) provide a similar hook (or extra param for event 'error') to run on unhandled exception in timer/io callback - this is handy to call render_exception() and get errors in browser for delayed responses too
11:23 powerman1 I'm currently implemented these by requiring user to create all callbacks with wrapper:
11:23 powerman1 Mojo::IOLoop->timer(3 => $c->proxy(sub{...}));
11:27 jpn joined #mojo
11:28 marty cstamas:  If I recall you can do something like %= flash 'foo'
11:28 cstamas marty: thx
11:29 cstamas marty: yes that is it, i found it out in the meanwhile...
11:50 chorny joined #mojo
12:00 jpn_ joined #mojo
12:34 bobkare joined #mojo
12:46 cy joined #mojo
12:48 powerman joined #mojo
13:03 sh4 joined #mojo
13:25 bowtie joined #mojo
13:29 cy joined #mojo
13:45 suy joined #mojo
13:46 sri nic: so it's not CGI, but a PSGI environment
13:48 sri only SCRIPT_NAME and PATH_INFO values matter
13:49 sri but i don't really see a reason to rewrite SCRIPT_NAME, unless your web server is configured wrong
13:49 asarch joined #mojo
13:50 * sri is now pretty sure there is no bug
13:59 shmuel joined #mojo
14:03 powerman Growing guide says "installable scripts can't `use lib` without breaking updated dual-life modules" - what's this about?
14:07 jb360 joined #mojo
14:15 sh3 joined #mojo
14:18 jberger powerman, the lib module is too smart for its own good
14:19 jberger never use it for modules that you mean to install
14:19 jberger its great for scripts
14:19 jberger but not for things that are going to go into your perl module tree
14:25 powerman I've checked lib module doc and source, and I didn't see how it 'too smart' - at a glance look only extra thing it does is handling arch/version dirs too, which looks safe
14:31 suy powerman: try correlating the commit that introduced that message and an issue in github. Or maybe even the dates. That arch extra directory seems it broke things in some seetups.
14:31 powerman nice
14:37 gryphon joined #mojo
14:53 cstamas I guess utf8 bit should be set for stash values
14:53 cstamas anyways stash values used in eprenderer seems to be encoded twice
14:54 cstamas (it can happen that I screw up something...)
14:56 cstamas okay it was sqlite3, sorry for the noise
14:56 cstamas $dbh->{sqlite_unicode} = 1; was missing
15:15 denisboyun joined #mojo
15:16 cy joined #mojo
15:27 shmuel joined #mojo
15:38 lammel2 joined #mojo
16:08 mire joined #mojo
16:12 mrphilov The most curious thing. Somehow I've made $self->redirect_to() silently fail. It just ignores that directive, even if I pull it out of all conditionals. Anyone seen anything like this before?
16:13 mrphilov More oddly, it was working earlier today, so I've done something in my code that makes it stop working.
16:14 denisboyun Hi guys maybe anybody know. Why doesn't stash  update when generates new post request on the same page?
16:17 dod1 joined #mojo
16:18 denisboyun For example I have a control which detect get/post on some page and when I'm taking get response I initializes stash on some data after that when I'm taking post response I initializes stash on some other data, but on html page is tha same data
16:21 denisboyun if ( $self->match()->{'method'} =~ "POST" ) {
16:21 denisboyun $self->session( phones => [@device_info] );
16:21 denisboyun }
16:21 denisboyun elsif ( $self->match()->{'method'} =~ "GET" ) {
16:21 denisboyun $self->stash(phones => [@device_info]);
16:21 denisboyun }
16:22 denisboyun *session -> stash
16:23 marty mrphilov:  Your log file should give you some info on what is going on.  You might also check `app routes`
16:23 marty denisboyun:  no pasting in the channel please.
16:25 marty denisboyun:  on the POST condition, where do you set a stash value?
16:27 marty Oh I see, typo.  ok
16:27 denisboyun I sets the data on POST and GET condition, because I wants on a different response different data
16:28 mrphilov marty: What is "check `app routes`"? You mean read documentation, or run a command that outputs the routes defined for my app? (I'm trying to do "$self->redirect_to('/'))
16:30 marty mrphilov:  I was thinking of checking your routes to see what is defined to see your redirect matches a defined route.
16:32 denisboyun marty: I sets the data on POST and GET condition, because I wants on a different response taken a different data
16:36 denisboyun marty: before  $self->stash;
16:46 marty deniseboyun:  I can only assume that @device_info is somehow set differently before the condition.   Your condition should match as far as I can tell
16:47 sri $self->match()->{'method'} this is extremely bad code
16:47 sri don't ever poke into private instance data
16:48 sri it's going to break, promised
16:48 denisboyun sri: And how to take current type of responce?
16:49 marty $self->req->method
16:49 marty I was going to mention that but I thought maybe I was missing something.   sri++
16:57 marty also, think you may want: $self->stash(phones => \@device_info);
17:27 mire joined #mojo
17:36 mire joined #mojo
17:37 jfuller joined #mojo
17:39 jfuller Good afternoon. I working on adding some oauth2 protected resources to an existing mojolicious app. And, I am trying to figure out where the best place to stick transaction specific data is. Right now, I have a helper setup, but it had to retrieve the user associated with the token each time I call it. Is there a good way to persistent this information?
17:58 asarch joined #mojo
18:00 sh3 joined #mojo
18:03 Mikey joined #mojo
18:26 Mike-PerlRecruiter_ joined #mojo
18:33 mrphilov In case anyone's reading scrollback, the answer is that in my Controller::Action() I need to do "$self->redirect_to('/'); return;" or logic continues in the Controller::Action() method. I guess this is the first time I've ever done a redirect in the middle of my Action method logic, so never needed to concerrn myself that execution continues after the redirect_to().
18:35 mrphilov When I look at examples here: http://mojolicio.us/perldoc/Mojolicious/Controller there's no explicit mention that logic continues after the redirect_to() either. I am not certain I found any example usage of redirect_to() that addresses the fact that execution continues, as maybe isn't necessary since maybe most would find this obvious. For whatever reason, I didn't find it obvious. :/
18:55 BeDa joined #mojo
18:57 moltar joined #mojo
19:02 sri mrphilov: what did you expect and why?
19:05 powerman what's the difference between bridge() and under() for non-M::Lite apps?
19:06 sri mrphilov: more specifically, why did you expect "magic" to happen and the absence of magic to be documented?
19:06 mrphilov I expected the $self->redirect_to('/') would stop execution at that point in the script. Why? Maybe because I'm slightly retarded. ;) But seriously, in retrospect, it seems obvious execution should continue.
19:06 sri mrphilov: have you ever used catalyst?
19:07 mrphilov I have. It was a while back.
19:07 sri maybe that's where you picked the idea up
19:08 * sri hates exceptions to control flow in catalyst
19:08 mrphilov Ah, in Catalyst, some magic did happen along those lines? I seem to recall there was a similar method of calling redirects at the time, but I don't specifically remember a redirect halting code execution.
19:13 powerman sri: routing guide under hooks mention special stash value 'exception', which isn't listed where all other special stash values listed (M::Controller#stash)
19:16 powerman it's set by M::Controller#render_exception, but doesn't mentioned in it doc too
19:17 powerman (or I should open issue on github for such a things?)
19:36 d4rkie joined #mojo
19:38 good_news_everyone joined #mojo
19:38 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/oPYP6A
19:38 good_news_everyone mojo/master 776ed11 Sebastian Riedel: better example for exception templates
19:38 good_news_everyone left #mojo
19:42 human39 joined #mojo
19:45 cy joined #mojo
19:50 good_news_everyone joined #mojo
19:50 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/uO429Q
19:50 good_news_everyone mojo/master f17c8b7 Sebastian Riedel: a few more exception tests
19:50 good_news_everyone left #mojo
19:57 cy joined #mojo
19:59 good_news_everyone joined #mojo
19:59 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/yXemJA
19:59 good_news_everyone mojo/master b1dfa58 Sebastian Riedel: slightly better exception template example
19:59 good_news_everyone left #mojo
20:12 two_tired joined #mojo
20:21 maxhq joined #mojo
20:31 moltar joined #mojo
20:53 two_tired joined #mojo
21:09 basiliscos joined #mojo
21:10 two_tired joined #mojo
21:23 basiliscos joined #mojo
21:33 basiliscos joined #mojo
21:33 denisboyun_ joined #mojo
21:39 basiliscos joined #mojo
21:40 powerman left #mojo
22:05 cy joined #mojo
22:07 two_tired joined #mojo
22:10 rem_lex| joined #mojo
22:12 rem_lex joined #mojo
22:25 rem_lex|pivo joined #mojo
23:17 hrupp_ joined #mojo
23:56 ka2u joined #mojo

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