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

IRC log for #mojo, 2017-10-17

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

All times shown according to UTC.

Time Nick Message
00:20 zach_ joined #mojo
00:21 gryphon joined #mojo
00:21 [1]mohawk joined #mojo
00:21 hernan605 joined #mojo
00:22 perlpilot_ joined #mojo
01:00 bwf joined #mojo
01:25 aborazmeh joined #mojo
02:29 noganex_ joined #mojo
02:32 bwf joined #mojo
04:04 dboehmer joined #mojo
04:07 inokenty-w joined #mojo
04:12 bwf joined #mojo
04:22 simcop2387 joined #mojo
05:43 dod joined #mojo
05:50 dod joined #mojo
06:26 rba_ joined #mojo
06:42 AndrewIsh joined #mojo
06:57 aborazmeh joined #mojo
07:04 dod joined #mojo
07:13 karjala_ joined #mojo
07:17 mib_woyery joined #mojo
07:35 petru joined #mojo
07:37 trone joined #mojo
07:47 rba joined #mojo
07:55 dod joined #mojo
08:04 rba_ joined #mojo
08:05 rba__ joined #mojo
08:08 sri last episode of discovery felt more like star trek, still very dark though
08:10 tianon joined #mojo
08:16 Jonis not seen it yet, maybe I'll have time on Thursday :)
08:17 Jonis oh nice, season 2 of glitch
08:28 rba joined #mojo
08:58 petru joined #mojo
09:19 CandyAngel Okay, my coding is *definitely* getting better
09:21 CandyAngel I think I got some function from like.. 15 lines to 4
09:21 CandyAngel With some help from Mojo::Collection :)
09:41 jabberwok joined #mojo
09:44 iamb joined #mojo
09:46 sri yea, always feels great to end up doing more with less code :)
09:53 rshadow joined #mojo
09:57 rba joined #mojo
09:58 CandyAngel Not just line count.. each line is really compact and neat in itself
09:58 CandyAngel Like before, I had maybe 2 or 3 if's
09:58 CandyAngel Now I have 0
09:59 CandyAngel Such neat, much happy
10:05 Vandal joined #mojo
10:14 rba_ joined #mojo
10:34 margeas joined #mojo
10:54 tchaves joined #mojo
10:55 petru_ joined #mojo
11:08 rba joined #mojo
11:44 ashimema joined #mojo
12:38 rba_ joined #mojo
12:53 rba joined #mojo
13:00 clueless joined #mojo
13:01 clueless I'm clueless! Best way to persist larger data structures between sessions?
13:02 sri database
13:02 purl database is my job queue
13:02 * sri pats purl
13:02 * purl stabs
13:02 clueless Looked at MojoX::Session.
13:05 clueless Isn't that the purpose of MojoX::Session?
13:05 VVelox_ joined #mojo
13:05 bc547_ joined #mojo
13:06 esh_ joined #mojo
13:08 kivilahtio_ joined #mojo
13:08 karjala__ joined #mojo
13:08 stryx`_ joined #mojo
13:08 mdom joined #mojo
13:08 klapperl_ joined #mojo
13:08 stephanj joined #mojo
13:09 matt joined #mojo
13:09 firnsy_ joined #mojo
13:09 coolo joined #mojo
13:09 dboehmer joined #mojo
13:09 iamb joined #mojo
13:09 Phil21_ joined #mojo
13:09 rshadow1 joined #mojo
13:09 mattp_ joined #mojo
13:11 kamyl_ joined #mojo
13:11 alilles joined #mojo
13:11 Zx3 joined #mojo
13:11 sjn joined #mojo
13:11 Peppard joined #mojo
13:11 spicyjack joined #mojo
13:11 Sebbe joined #mojo
13:11 litwol_ joined #mojo
13:11 pink_mist joined #mojo
13:11 hesperaux joined #mojo
13:11 Lee joined #mojo
13:11 stein joined #mojo
13:11 suede joined #mojo
13:12 bobkare joined #mojo
13:12 hesperaux joined #mojo
13:12 eseyman joined #mojo
13:12 tyldis joined #mojo
13:13 wouter_ joined #mojo
13:14 tardisx_ joined #mojo
13:14 jantore_ joined #mojo
13:15 caeles_ joined #mojo
13:16 saki joined #mojo
13:16 Vandal joined #mojo
13:16 ranguard joined #mojo
13:16 mudler joined #mojo
13:16 sivoais_ joined #mojo
13:16 michael joined #mojo
13:16 eday joined #mojo
13:16 perlpilot_ joined #mojo
13:16 mtths joined #mojo
13:16 trippeh joined #mojo
13:16 dustinm joined #mojo
13:16 Armen joined #mojo
13:16 Jonis joined #mojo
13:16 romel joined #mojo
13:16 a6502 joined #mojo
13:17 mtj joined #mojo
13:17 ashimema joined #mojo
13:17 augensalat joined #mojo
13:17 cosimo joined #mojo
13:17 tempire joined #mojo
13:17 [0xAF] joined #mojo
13:18 vicash joined #mojo
13:19 Bender joined #mojo
13:19 crab joined #mojo
13:19 Andreas2 joined #mojo
13:19 hesco joined #mojo
13:19 chandwki joined #mojo
13:20 mtths joined #mojo
13:21 gizmomathboy joined #mojo
13:22 trone joined #mojo
13:31 litwol_ left #mojo
13:32 nicomen joined #mojo
13:38 go|dfish joined #mojo
13:42 Pyritic joined #mojo
13:49 genio sri: How's your C/XS knowledge? Would you be able to review the current state of UV in git and maybe help figure out where we're going wrong with the closing of UV Handles as leont pointed out?
13:53 ChmEarl joined #mojo
13:53 jamesaxl joined #mojo
14:36 dotan_convos joined #mojo
14:36 gizmomathboy joined #mojo
15:01 karjala__ Is the way to get a stash value in a template this, or is there some shortcut I don't know about? <%= stash('the_name') %>
15:04 pink_mist <%= $the_name %>
15:04 pink_mist will likely work
15:04 pink_mist but your version is in a way safer, especially if you forgot to give the template that stash value
15:05 karjala__ it worked!
15:05 purl What do you mean it worked? Did it run to completion? Did it bomb out early? Did it finish the job early? Did it tell your girlfriend "let's just be friends"? Be specific!
15:06 maschine you can also do something like % if (my $name = stash 'value') { <%= $name %> etc.... }
15:07 karjala__ kewl
15:07 maschine I don't usually use stash values directly because of what happens if the value is missing for some reason, your way looks good too (I haven't tried that yet!)
15:07 petru joined #mojo
15:08 karjala__ When I do: $self->render('template_name', var1 => 'world'); am I really setting stash('var1' => 'world) ?
15:09 pink_mist yes
15:10 gizmomathboy joined #mojo
15:12 karjala__ brilliant
15:12 purl coincidentally, I had beans for breakfast
15:13 sri genio: not good enough
15:13 purl somebody said not good enough was http://www.shadowcat.co.uk/archive/conference-video/yapc-eu-2008/you-arent-good-enough/
15:22 gizmomathboy joined #mojo
15:35 Pyritic joined #mojo
16:11 bwf joined #mojo
16:12 rba joined #mojo
16:18 sh14 joined #mojo
16:23 Vandal wtf with purl today?:)
16:26 mohawk why does the "accept" method ignore Accept: headers with more than one thing?
16:27 sri accepts?
16:27 purl accepts is implemented on Sub, yes.
16:27 sri purl: shut up
16:27 * purl goes on and on about how much shutting up she's doing
16:28 mohawk sri, https://metacpan.org/source/ETJ/Mojolicious-Plugin-GraphQL-0.02/lib/Mojolicious/Plugin/GraphQL.pm#L58-59
16:28 mohawk yes, accepts - sorry :-)
16:28 sri because browsers suck
16:29 mohawk does that not mean the "accepts" method doesn't really function?
16:29 sri historically browsers have sent garbage Accept headers
16:29 mohawk ok
16:29 mohawk that sort of sounds like a "yes" though :-(
16:30 sri the real world required adjustments
16:30 mohawk pesky real world
16:30 mohawk ruining everything
16:31 Vandal if not for real world we would not be needing to write so much tests :(
16:32 mohawk Mojolicious::Plugin::ValidateMoose is listed on wiki but now not exist?
16:32 mohawk 404: https://metacpan.org/pod/Mojolicious::Plugin::ValidateMoose
16:36 Grinnz looks like it's batmans but was deleted https://metacpan.org/release/JHTHORSEN/Mojolicious-Plugin-ValidateMoose-0.02
16:40 gizmomathboy joined #mojo
16:46 rshadow joined #mojo
16:48 elik joined #mojo
16:54 sri mohawk: re Accept, app->types->detect(..., 1) works the way you want
16:55 sri it's just the lower level version
16:56 mohawk sri, thanks! will take a look
17:18 petru_ joined #mojo
17:24 jamesaxl joined #mojo
17:46 batman Why was it listed..?
17:47 Grinnz looks like its in https://github.com/kraih/mojo/wiki/Plugins-on-cpan
18:29 gizmomathboy joined #mojo
19:09 dod joined #mojo
19:37 jamesaxl joined #mojo
19:41 ghenry joined #mojo
19:43 ghenry Hi all, what's the best way to provide wss:// around Mojo::Transaction::WebSocket as per http://mojolicious.org/perldoc/Mojolicious/Guides/Cookbook#WebSocket-web-service
19:43 ghenry http://mojolicious.org/perldoc/Mojolicious/Guides/Cookbook#Nginx ?
19:45 pink_mist what do you mean by "provide wss://"? that's up to your SSL endpoint, which ... seems to be nginx? it ... should do it just fine?
19:46 ghenry So just proxy it up like http://mojolicious.org/perldoc/Mojolicious/Guides/Cookbook#Nginx with SSL trimmings and point wss:// at it client side
19:46 pink_mist sure
19:46 ghenry thanks.
19:50 maschine Mojolicious::Plugin::Blog is also a broken link on https://github.com/kraih/mojo/wiki/Plugins-on-cpan
20:10 itaipu joined #mojo
20:13 sri ghenry: url_for will know to generate wss too if you set up the proxy headers right
20:13 ghenry great, thanks
20:14 ghenry was just redaing http://nginx.org/en/docs/http/websocket.html and https://moduscreate.com/fast-polling-vs-websockets-2/
20:29 petru_ joined #mojo
20:54 simbabque joined #mojo
20:54 simbabque can I access the Mojo::DOM inside $t from Test::Mojo directly?
20:55 simbabque I want to check if a text exists inside a specific element, and $t->content_like is too broad because the same text can exist in different places
20:56 simbabque ah found it in the docs
20:59 rba joined #mojo
21:05 jamesaxl joined #mojo
21:12 jamesaxl joined #mojo
21:13 batman simbabque: $t->tx->res->dom
21:20 petru_ joined #mojo
21:23 jamesaxl joined #mojo
21:35 rba joined #mojo
22:01 CandyAngel So, I'm curious.. do people tend to use tag helpers or just write out the HTML in their templates?
22:02 jamesaxl joined #mojo
22:05 maschine I like to use tag helpers for forms, since mojo will pick up the form data and refill it for me automatically
22:05 maschine sometimes there's not a big difference but where it makes sense..
22:08 jberger CandyAngel: I used to use the to an excessive degree, mostly because it reminded me more closely of LaTeX than HTML does
22:08 jberger but I've swung back to what I think the norm is of only using them where needed
22:09 jberger stuff like this: https://github.com/jberger/Galileo/blob/master/lib/Galileo/files/templates/admin/users.html.ep
22:10 jberger (which I think still has a certain elegance, but yeah, better to be standard)
22:11 maschine problem I see with that if you have a lot of things like <tr><td></td></tr>, you can have a lot of %end's and you might not be sure which tag it's referencing
22:12 maschine that's a nice clean example though!
22:13 sri i use tag helpers when they add some value, like forms getting filled out automatically
22:13 sri otherwise i prefer plain html
22:13 sri emmet makes typing html tags very easy in vscode
22:36 Ralesk joined #mojo
22:59 CandyAngel I pretty much only use them for forms, tags with classes and anchors
23:05 CandyAngel Huh.. weird
23:09 CandyAngel Nevermind, found the proper way of doing it :P
23:29 gizmomathboy joined #mojo
23:54 mohawk jberger, sweet code!
23:56 CandyAngel I'm surprised to see <table> and co.. I thought jberger would have been shunned off the web for using those :P
23:56 jberger hey, I was young and impressionable, I was starstruck by the glory that is LaTeX
23:56 jberger (ok, ok I still am, but I can contain myself better now)

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