Camelia, the Perl 6 bug

IRC log for #mojo, 2012-06-28

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

All times shown according to UTC.

Time Nick Message
00:54 laouji joined #mojo
01:15 scott_ joined #mojo
01:48 d4rkie joined #mojo
02:15 diegok When I Mount another app all its statics get prefixed which is nice, but url_for() is not taking that into account. Is that ok or I'm doing something wrong?
02:34 jnap joined #mojo
02:59 CromeDome joined #mojo
03:06 BlueT_ joined #mojo
03:42 sri diegok: url_for can only see the current app
03:58 Leandr joined #mojo
04:24 venkatk_ joined #mojo
04:32 xaka joined #mojo
04:58 sri marty: just looked at your css/js patch, i think the json version is the important one
04:59 sri afair st2 has tools to convert the json version to xml
05:06 Leandr joined #mojo
05:32 laouji joined #mojo
05:37 vishwanathms joined #mojo
05:37 vishwanathms_ joined #mojo
05:44 CromeDome joined #mojo
06:02 Foxcool joined #mojo
06:03 ovnimancer joined #mojo
06:37 fhelmber_ joined #mojo
06:46 bjoernfan So, I turned off that 'svn update; hypnotoad ./server/myapp' cronjob yesterday, the one that only segfaulted each time (but seamingly worked). Today, no new sessions could be created until I restarted myapp again.
06:47 bjoernfan Sessions are stored in a psql table, maybe the connection dropped or something.
06:47 bjoernfan (thinking out loud)
06:48 bc547 is there a way to have some perl code executed on regular base (say once each minute). the goal is to do some background database maintenance at regular intervals in the background without needing to configure a cronjob
06:50 vishwanathms left #mojo
06:58 memowe joined #mojo
07:01 vishwanathms joined #mojo
07:01 vishwanathms_ joined #mojo
07:03 laouji joined #mojo
07:07 tempire bc547: I'm sure there are plenty of ways, but cron is the easiest
07:11 bc547 tempire: i'm trying to avoid cron. I was hoping to get a subroutine hooked in e.g. IOLoop or something
07:11 tempire you could use a timer.  but it's quite complicated in comparison to cron.
07:11 Vandal joined #mojo
07:25 arpadszasz joined #mojo
07:29 AmeliePoulain joined #mojo
07:29 AmeliePoulain joined #mojo
07:30 venkatk_ joined #mojo
07:30 pau4o joined #mojo
07:30 i_am_batman joined #mojo
07:45 spleenjack joined #mojo
07:53 venkatk_ joined #mojo
07:54 marcus bjoernfan: no errors in the log?
08:07 bird joined #mojo
08:09 bjoernfan marcus: I think it's me relying on MojoX::Session->load to load the right cookie after server restart that's the problem. Not really sure of how it works though. I think I want to store the MojoX::Session ID in a "regular" mojolicious cookie and specifically load that MojoX::Session session instead. (This might be the only sane way of doing it anyway)
08:11 marcus bjoernfan: sorry, I'm not using MojoX::Session, I use the built in session system.
08:18 crab isn't MojoX::Session old and broken and abandoned?
08:20 marcus likely
08:20 bjoernfan Maybe I missed something, what can I use instead? Due to certain things a 4096 byte cookie isn't enough for me for the moment.
08:21 marcus can't you just store whatever you store in the cookie in the db instead?
08:21 marcus (it's actually stored there now, just a bit scrambled, innit?)
08:22 marcus crab: actually seems vti updated it this year to work with recent mojos, but it's not beeing well maintained.
08:22 marcus bjoernfan: MojoX:: namespace itself has been discouraged for the last few years, so it's a sign of an old module.
08:23 bjoernfan Thanks for the info.
08:25 bjoernfan Sure, maybe I can store it "manually", but it would be nice to have it made transparently. As with MojoX::Session.
08:29 bjoernfan Is there something like under for non-lite apps? I have a hard time translating lite to full quite often... :/
08:32 marcus bjoernfan: bridges?
08:32 marcus I believe you can use under in non lite apps too now, btw.
08:32 nic joined #mojo
08:33 marcus bjoernfan: http://mojolicio.us/perldoc/Mojolicious​/Guides/Routing#More_convenient_routes see 3. exmple
08:33 marcus example
08:48 mire joined #mojo
08:52 GitHub44 joined #mojo
08:52 GitHub44 [mojo] kraih pushed 1 new commit to master: http://git.io/QIZKJw
08:52 GitHub44 [mojo/master] added file upload test example - Sebastian Riedel
08:52 GitHub44 left #mojo
08:59 GitHub54 joined #mojo
08:59 GitHub54 [mojo] kraih pushed 1 new commit to master: http://git.io/O-rfmA
08:59 GitHub54 [mojo/master] mention that under generates bridge routes in tutorial - Sebastian Riedel
08:59 GitHub54 left #mojo
08:59 sri that should help in the future
09:09 GitHub163 joined #mojo
09:09 GitHub163 [mojo] kraih pushed 1 new commit to master: http://git.io/vRw9VA
09:09 GitHub163 [mojo/master] fixed typo in test example - Sebastian Riedel
09:09 GitHub163 left #mojo
09:11 spleenjack joined #mojo
09:20 nic You may need to "unset MOJO_LOG_LEVEL" before installing Mojolicious Rainbow
09:20 nic cos it can break the build tests
09:21 marcus sri: can't you start helping in the past instead?
09:21 marcus ;-)
09:21 sri marcus: nope
09:22 marcus I will not rest until you invent time travel!
09:30 Andrei666 joined #mojo
09:31 Andrei666 hey guys, if I have a bridge route, to an action that checks if and admin, is authenticated, doesn't that mean, that if the authentication fails
09:31 Andrei666 anything under the bridge will not execute?
09:32 marcus yes, if it returns false if you're not admin.
09:34 Andrei666 right...but..under the bridge I have a route that deletes something from a mysql table, and if I don't log in, and I call that route...it still executes the delete
09:34 Andrei666 what am I doing wrong?
09:35 marcus Andrei666: I'm pretty sure we had the opposite problem of this yesterday? :)
09:35 marcus where you could not execute things under your bridge because you returned false...
09:37 Andrei666 marcus: yes I remember..the thing is, that yesterday, inside the if that checked for the admin name in the session, I didn't returned 1, it just returned...
09:37 Andrei666 but now, outside that if, the last line from the #auth action is
09:37 Andrei666 $self->redirect_to('/login');
09:38 Andrei666 in case I'm not loged in, I should be redirected to the login page..wich it does...
09:38 marcus add a return 0;
09:38 marcus after the redirect
09:38 marcus Andrei666: perl has implicit returns
09:39 Andrei666 oh, i thought if it redirects, it won't execute...anything else ...
09:40 Andrei666 yes, I guess I have to learn more perl, than more mojo....
09:40 Andrei666 exactly what we've talked yesterday..
09:40 Andrei666 :p
09:41 Andrei666 marcus: big thank you...again :)
09:45 marcus Andrei666: np :)
09:48 diegok sri: oh!, that makes mounting a bit broken, right?. Is there something you can think about I can do to fix this situation?. It would be great if mounted app can be informed it's being prefixed...
09:50 diegok I can only think about setting a default stash value an make all my "can be mounted" apps aware of it...
09:51 diegok but I feel this should be solved from the mount plugin as it's a very common issue..
09:53 bjoernfan 11:22       @marcus | I will not rest until you invent time travel!
09:53 bjoernfan There is no future in timetravel.
09:55 sri diegok: no, that means mount works perfectly, apps are not supposed to know about each other by default
09:55 i_am_batman my nephew is working on a hadron collidor, so maybe he can invent a time machine when he's finished...
09:56 sri diegok: *inside* a mounted app url_for will do the right thing, just not outside
09:57 diegok sri: ok, right. But once an app is mounted no link_to, javascript, etc will work
09:57 sri diegok: i think you're misunderstanding something
09:57 diegok sri: probably :-/
09:57 sri it works perfectly
09:58 sri you just can't generate links from one app to another
09:58 diegok sri: nono, I don't need to generate from one to the other...
09:59 sri then everything is fine
09:59 diegok I have one app that works stand-alone. It has internal links and load some js and css
09:59 diegok then I mount that app on another one with '/prefix'
10:00 diegok and I go to route /prefix/old/route
10:00 diegok but all my css and js is not loaded, because what was in /js/* is now in /prefix/js/*
10:01 diegok ... and, I didn't checked, but I guess all may links will be broken.
10:02 sri "... and, i didn't checked..." <- so why the noise!?
10:02 sri now i looked up the test case for nothing :S
10:02 sri https://github.com/kraih/mojo/blob/maste​r/t/mojolicious/embedded_lite_app.t#L203
10:02 diegok because the statics :)
10:03 diegok I will check links. I'm concerning about statics that I've checked :)
10:04 diegok hey!, I'm not making noise for nothing. I want to solve the statics part...
10:04 mire joined #mojo
10:08 diegok sri: this test is fine, it's what I have. All my statics are mounted like that. But url_for('/index.html') won't point to that file anymore once it's mounted :-/
10:09 daxim joined #mojo
10:22 diegok :(
10:24 mire joined #mojo
10:30 andrefs joined #mojo
10:31 Akron joined #mojo
11:34 xaka joined #mojo
11:57 Grauwolf joined #mojo
11:58 Grauwolf hi! i already read that some people having "troubles" with $FindBin::Bin and morbo. any suggestions on what to use instead?
12:06 memowe Grauwolf: I use this: https://github.com/memowe/contenticious/blo​b/master/lib/Contenticious/Generator.pm#L50
12:07 memowe Wow, githubs syntax highlighting is awesome.
12:07 Grauwolf memowe, so line 54 to 58?
12:07 memowe Grauwolf: yep
12:07 Grauwolf memowe, thanks a lot
12:08 memowe I stole it from the original mojo scripts. :)
12:09 Grauwolf :)
12:11 memowe Grauwolf: https://github.com/kraih/mojo/blob/master/l​ib/Mojolicious/Command/generate/app.pm#L53
12:17 athenot joined #mojo
12:26 arpadszasz joined #mojo
12:43 bjoernfan morbo and hypnotoad are supposed to act exactly the same, right?
12:48 GitHub125 joined #mojo
12:48 GitHub125 [mojo] kraih pushed 1 new commit to master: http://git.io/RHnZ_g
12:48 GitHub125 [mojo/master] better form generator examples - Sebastian Riedel
12:48 GitHub125 left #mojo
12:54 jnap joined #mojo
13:10 Psyche^ joined #mojo
13:22 bjoernfan I'm getting the feeling MojoX::Session doesn't do well with multiple workers.
14:04 i_am_batman joined #mojo
14:15 alester joined #mojo
14:21 rem_lex|pivo joined #mojo
14:28 Leandr joined #mojo
14:32 inokenty joined #mojo
14:34 d4rkie joined #mojo
14:47 Andrei666 $self->quit
14:47 Andrei666 exit
14:55 daniel_ joined #mojo
15:10 Mad_Dud joined #mojo
15:22 brambles joined #mojo
15:28 brambles_ joined #mojo
16:16 pau4o left #mojo
16:52 andrefs joined #mojo
17:02 marty sri:  Thank you for the advice on my css/js patch for st2.  I have not heard back from the author yet but I'll offer to patch the JSON file also.
17:04 marty bjoernfan:  Most plugins in the MojoX namespace are abandoned or very very old.
17:05 * marty is still trying to completely understand M:P:Authentication and how best to use it.
17:10 nic marty: In a Lite app or non-Lite?
17:11 nic (I have a Lite example I could send your way; it authenticates against ActiveDirectory, but it's easy to ignore that :) )
17:11 marty I'm using it in a non-lite app.
17:12 nic ah, I'm thinking my example won't help much
17:12 marty I apprecitate the offer though.  I'll puruse the examples in the distribution and keep working on it.   :)
17:58 rwstauner joined #mojo
18:18 mire joined #mojo
18:58 brambles joined #mojo
19:03 athenot joined #mojo
19:03 tempire hrm
19:03 tempire pixelmator doesn't have cmyk support
19:03 tempire :(
19:15 noganex joined #mojo
19:30 andrefs joined #mojo
19:34 rwstauner joined #mojo
19:53 jnap joined #mojo
20:01 noganex_ joined #mojo
20:05 andrefs joined #mojo
20:32 pbaker_ joined #mojo
20:36 andrefs joined #mojo
20:37 CromeDome joined #mojo
20:39 tempire marcus
20:39 daniel_ joined #mojo
20:42 mire joined #mojo
20:49 tempire hmm
20:49 tempire seems to me that $r->get should also support the format parameter, just like $r->route does
20:57 tempire indeed, this looks like a bug
21:01 tempire ah, I see.  $r->get works just like lite: $r->get('/hello' => [format => 'css'])
21:03 lammel2 joined #mojo
21:04 tempire wonder if/how it's best to include that differentiation in the docs
21:04 lammel2 joined #mojo
21:38 marty Should I be using the included osx terminal or something else?
21:48 spaceships joined #mojo
21:51 perlite_ joined #mojo
21:55 daniel_ joined #mojo
22:02 tempire it's either included osx terminal or iterm2
22:02 tempire osx terminal is perfect since they added tabs
22:11 andrefs joined #mojo
23:02 daniel_ joined #mojo
23:48 daniel_ joined #mojo

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