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

IRC log for #mojo, 2016-08-20

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

All times shown according to UTC.

Time Nick Message
00:33 sri here's an idea for a mojolicious plugin https://github.com/RafalWilinski/express-status-monitor#express-status-monitor
00:42 Kripton joined #mojo
01:14 Pierre joined #mojo
01:21 Pierre joined #mojo
01:25 Grinnz just thinking of making that cross-platform makes me wince
01:59 cpan_mojo Mojolicious-Plugin-LocaleTextDomainOO-0.04 by CLICKTX https://metacpan.org/release/CLICKTX/Mojolicious-Plugin-LocaleTextDomainOO-0.04
02:12 noganex_ joined #mojo
02:55 jberger Grinnz: I'm sure there are cpan modules for data like that
03:05 jberger although that rps metric seems pretty hard to believe
03:06 jberger unless node apps are single process
03:23 Pierre joined #mojo
03:28 jberger zomg, does everyone know about this and I'm just finding out?
03:28 jberger http://supermariobroscrossover.com/resources/super-mario-bros-crossover.84/
03:35 PryMar56 joined #mojo
05:10 laidback_01 joined #mojo
06:13 Vandal joined #mojo
06:23 Pierre joined #mojo
06:41 dod joined #mojo
06:47 dod joined #mojo
07:11 prajith joined #mojo
07:19 Pierre joined #mojo
07:35 Pierre joined #mojo
07:52 Pierre joined #mojo
07:57 Pierre joined #mojo
08:11 abra joined #mojo
08:18 Pierre joined #mojo
08:31 jontaylor joined #mojo
09:03 nic Grinnz++  # SetUserGroup problem-free
09:05 nic thanks for making that work with morbo
09:49 tim joined #mojo
09:54 nic Apologies, that's wrong, and now very misleading.  How embarrassing
09:54 tim Hi, this simple script fails with error "Can't use an undefined value as a subroutine reference at Mojo/UserAgent.pm line 247" https://nopaste.me/view/cf8eb645
09:54 tim here is the full DEBUG output: https://nopaste.me/view/4af8ba31
09:56 tim Perl (v5.23.1, darwin); Mojolicious (7.03, Doughnut)
09:57 nic On the flip-side, I'm getting clues why morbo fails when running as root (distinct from the target user).  The child morbo process dies.  Serves a single request then floomp.  Gone to the angels
10:07 Pierre joined #mojo
10:12 nic the child executes the whole of _setusergroup, serves one request-response, then dies
10:13 nic Could it be the parent-child communication appears broken (perhaps due to permissions) and so the parent kills it?
10:13 nic just pondering if morbo parent-child logic assumes both processes are running as the same user
10:17 batman tim: are you sure that's the actual script you're running?
10:20 * batman don't think so
10:27 ladnaV joined #mojo
10:28 tim joined #mojo
10:29 nic tim: Did you see batman's q?
10:29 batman tim: are you sure that's the actual script you're running?
10:30 tim joined #mojo
10:31 batman hm... wonder why i don't see the quit messages :/
10:31 * batman writes a test
10:31 nic they're visible here (on a different client)
10:32 batman nic: ":tim!5490811f@m-b.clients.kiwiirc.com QUIT :" <-- need to fix my parsing i gues
10:32 batman tim: fix your connection
10:33 batman impossible to help you when you're dropping out all the time
10:34 tim yes that's the script
10:34 tim sometimes I have to run it several times to get the error
10:35 batman so where does www.bzzs.me come from?
10:35 tim location http header
10:35 batman oh.
10:35 tim you can see it in the debug output
10:35 batman which version of mojo? (run mojo version)
10:36 tim Perl (v5.23.1, darwin); Mojolicious (7.03, Doughnut)
10:37 nic tim: just curious, why are you using v5.23?
10:38 tim have not updated my perlbrew for some time
10:40 mvorg joined #mojo
10:41 batman i don't understand the proxy code, so i think sri need to take a look...
10:41 batman but from the code: https://github.com/kraih/mojo/blob/master/lib/Mojo/UserAgent.pm#L242
10:42 batman it says that "CONNECT requests always have a follow-up request". maybe there's something weird happening with the proxy server...
10:43 batman or maybe there's something going wrong when $res->is_status_class(400)
10:43 batman i'm not even sure if "HTTP/1.1 409 Conflict" triggers line 244 or not :/
10:44 batman sorry i can't help you
10:45 tim the error only occurs with 2 successively requests to https://www.google.com
10:45 batman what is that 409 conflict then?
10:49 nic tim: I haven't looked at the detail of the discussion, but does your agent manage cookies?
10:50 nic my own experience with www.google.com is they're pretty quick to spot bots and block them with a "prove you're human" form
10:50 tim nope it is this simple script: https://nopaste.me/view/cf8eb645
10:51 nic a workaround is to have a browser session log in to gmail for example and then export your cookies to the agent
10:51 nic the agent then gets seen as that human (assuming you've set a good agent string)
10:51 tim the error also occurs with other https://* sites
10:52 nic ah, ok, so not google specific
10:53 batman tim: looks to me as you discovered a bug, but i think sri or jberger need to check it out before i can say anything for sure
10:54 nic but the principle still applies.  sites are increasingly keen and smart at breaking naive bot conversations
10:54 tim batman: ok, thanks
10:54 nic tim: Have you tried this without a proxy?
10:55 * sri doesn't have time to check anything today
10:56 tim without proxy or without https everything is fine
10:56 nic ah, ok, I understand the focus then
11:04 jontaylor joined #mojo
11:24 nic right, with morbo it's the "kill 0, $manager" that prevents us having the worker be a less privileged user than the manager
11:27 nic we just need to know if the $manager process exists.  i don't think privileges are something we care about at that line
11:49 cafe joined #mojo
12:07 cpan_mojo Mojolicious-Plugin-OpenAPI-0.14 by JHTHORSEN https://metacpan.org/release/JHTHORSEN/Mojolicious-Plugin-OpenAPI-0.14
12:17 nic I can't think of a proper solution, but the horrible hack works fine here: just comment-out the "kill 0" line in Morbo.pm  :D
12:18 nic I'm guessing in the past there were reports of the manager terminating without killing the worker.  Without that scenario I'm thinking you don't need that line
12:19 nic So now I have morbo manager running as root and morbo worker running unprivileged
13:07 dod joined #mojo
13:19 prajith joined #mojo
14:00 batman joined #mojo
14:26 prajith joined #mojo
14:26 lluad joined #mojo
14:40 Kripton joined #mojo
15:02 tchaves joined #mojo
15:13 Pierre joined #mojo
15:16 AirDisa joined #mojo
15:26 kes joined #mojo
15:49 cuechan joined #mojo
16:31 PryMar56 joined #mojo
16:31 Grinnz nic, i already added to the documentation not to let it change credentials with morbo. the server cannot send a "kill" to the manager process to check if it's alive after changing
16:32 Grinnz https://v1.metacpan.org/pod/Mojolicious::Plugin::SetUserGroup#DESCRIPTION
16:34 Grinnz imo morbo should always be started as the user you want it to run as. there is no reason to start it as root
17:05 itaipu joined #mojo
17:15 jontaylor joined #mojo
17:18 dod joined #mojo
17:41 tim joined #mojo
18:19 cafe joined #mojo
18:34 nugged joined #mojo
19:06 asarch joined #mojo
19:30 nugged joined #mojo
19:57 asarch joined #mojo
20:00 batman joined #mojo
20:08 itaipu joined #mojo
20:15 Adura joined #mojo
20:25 preaction from what i remember, while morbo may try to protect you from doing stupid things while running it as root, it's the official policy that morbo is not to be used in production
20:42 marcus joined #mojo
20:48 itaipu joined #mojo
20:49 nic that's all true and I don't mean to confuse anyone who isn't aware of that
20:55 mvorg joined #mojo
20:56 nugged joined #mojo
21:14 nugged joined #mojo
21:32 nugged joined #mojo
21:32 nugged joined #mojo
21:43 nugged joined #mojo
21:55 nugged joined #mojo
22:07 nugged joined #mojo
22:11 itaipu joined #mojo
22:12 meshl joined #mojo
22:27 cafe joined #mojo
22:29 nugged joined #mojo
22:30 nugged joined #mojo
22:34 cuechan_ joined #mojo
22:35 nugged joined #mojo
22:49 nugged joined #mojo
22:49 meshl joined #mojo
23:37 Kripton joined #mojo
23:48 meshl joined #mojo
23:51 nugged joined #mojo

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