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

IRC log for #mojo, 2014-11-23

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

All times shown according to UTC.

Time Nick Message
00:16 bobkare joined #mojo
00:50 woz joined #mojo
01:23 bpmedley_ joined #mojo
01:42 human39 joined #mojo
02:09 d4rkie joined #mojo
02:10 good_news_everyon joined #mojo
02:10 good_news_everyon [mojo] kraih tagged v5.64 at eaa04d0: http://git.io/m36Igg
02:10 good_news_everyon left #mojo
02:12 good_news_everyon joined #mojo
02:12 good_news_everyon [mojo] kraih pushed 1 new commit to master: http://git.io/nED06Q
02:12 good_news_everyon mojo/master 2777b65 Sebastian Riedel: bump version
02:12 good_news_everyon left #mojo
02:17 klapperl joined #mojo
02:30 ceej__ joined #mojo
02:39 woz joined #mojo
02:50 KCL_ joined #mojo
03:10 woz joined #mojo
03:35 zivester joined #mojo
03:40 bobkare joined #mojo
03:48 sri tempire: apple did pirate flags too ;p http://www.theverge.com/2014/11/22/7268621/macintosh-designer-is-selling-1900-replicas-of-apples-legendary
03:56 zivester joined #mojo
04:00 AndroUser joined #mojo
04:03 inokenty_a joined #mojo
04:04 basic6_ joined #mojo
04:05 tempire
04:27 zivester joined #mojo
04:32 jberger sri: guess you are on the bleeding edge of style
04:34 sri pirate flags are going to be all the rage next conference season :o
06:32 woz joined #mojo
07:20 rem_lex| joined #mojo
07:30 marmez joined #mojo
08:21 woz joined #mojo
09:00 Vandal joined #mojo
09:42 hesperaux joined #mojo
10:07 denis_boyun joined #mojo
10:10 woz joined #mojo
10:31 basiliscos joined #mojo
11:08 dod joined #mojo
11:22 sugar joined #mojo
11:27 sugar joined #mojo
11:59 woz joined #mojo
12:17 sh4 joined #mojo
13:08 KCL joined #mojo
13:23 denis_boyun joined #mojo
13:28 marty_ joined #mojo
13:48 woz joined #mojo
13:59 inokenty_a joined #mojo
14:42 circ-user-Bfgje joined #mojo
14:43 circ-user-Bfgje nick
15:34 sh4 joined #mojo
15:36 woz joined #mojo
15:38 zivester joined #mojo
15:52 denis_boyun joined #mojo
16:01 sri tempire: i guess nyanclouds would work too, if you want something more your style ;p
16:03 sri 8-bit rainbow and our normal cloud logo
16:04 sri and the 8-bit stars in the background
16:08 crab you need only three bits for a rainbow!
16:08 * crab compresses all his rainbows forthwith
16:10 sri ok, i guess nyan cloud doesn't work so well ;p http://i.imgur.com/bdN1Fcr.png
16:11 sugar_ joined #mojo
16:12 crab eek
16:18 sri pixelated is better http://i.imgur.com/QEF1hgy.png
16:19 crab so it's true, more pixels is always better? :-)
16:21 sugar__ joined #mojo
16:26 sri and with text it's not too bad actually :) http://i.imgur.com/QGRXHWQ.png
16:29 sri of course the edges of the cloud and text would have to be sharper
16:29 sri but you get the idea
16:35 crab wow. http://tanzer.io
16:37 jberger I'm still waiting for the web framework in assembly
16:37 jberger http://i.imgur.com/INBvStO.png
16:55 zivester joined #mojo
17:01 jberger sri: should hypnotoad use #!perl ?
17:04 berov joined #mojo
17:16 basiliscos joined #mojo
17:25 jberger the reason being is that 'carton exec hypnotoad scriptname' might use env perl rather than the perl that installed hypnotoad, which means rather than getting the carton library and the carton perl you might get a weird combo
17:25 jberger this is for FWBM
17:25 jberger I'm now testing this:
17:25 woz joined #mojo
17:26 jberger HYPNOTOAD=$( ${PERL_HOME}/bin/carton exec which hypnotoad ); ${PERL_HOME}/bin/carton exec ${PERL_HOME}/bin/perl ${HYPNOTOAD} ${TROOT}/app.pl
17:26 jberger and that just seems a little silly
17:29 crab i have encountered that same problem.
17:37 jberger damn, even that didn't work: https://api.travis-ci.org/jobs/41886255/log.txt?deansi=true
17:38 jberger Successfully installed JSON-XS-3.01
17:38 jberger Can't locate JSON/XS.pm in @INC
17:38 tencendur joined #mojo
17:38 jberger oh well, time to hang xmas lights
17:48 bobkare joined #mojo
17:56 sri jberger: either it's all consistent or we don't change it
17:56 sri this has been discussed so often before, i'm not sure there is much of a point bringing it up again
17:57 sri if you're sure you want to change it make a pull request and explain the up and downsides
17:59 sri btw. https://github.com/Perl-Toolchain-Gang/ExtUtils-MakeMaker/issues/58
18:00 sri jberger: you did actually +1 that in 2013
18:00 * sri sets jberger on fire
18:06 jamesaxl joined #mojo
18:13 bobkare joined #mojo
18:27 yko joined #mojo
18:28 yko good evening ladies and gentlemen
18:52 sri o/
19:06 sri jberger: one argument in favor, we've removed the use lib stuff from all scripts too
19:08 sri jberger: however, you will have to find a convention for documentatione examples, and possibly make all examples ugly
19:08 sri "$ ./myapp.pl foo bar" is all over the place
19:09 sri and other variants, with script/*
19:14 woz joined #mojo
19:27 Grinnz_ joined #mojo
19:32 Grinnz joined #mojo
20:00 marty_ joined #mojo
20:03 dod joined #mojo
20:07 dod joined #mojo
20:51 thowe joined #mojo
20:51 thowe I may be going about my under route wrong...
20:51 thowe I have "my $root = $r->under('/')->to('example#base');  $root->get('example')->to('example#welcome');"
20:52 thowe /example works fine, and I have an extra thing I add to stash to prove I've been there.
20:53 thowe but how do I make a call to just "/" render a default template?  Do I need to redirect it to something as default or something?  Er, wait...  I probably need to specify what to render don't I?
20:54 dod joined #mojo
20:54 sri http://mojolicio.us/perldoc/Mojolicious/Guides/Routing#Nested-routes
20:58 thowe so, with /foo/bar how do you make /foo go to something other than 404?
21:01 thowe In a Lite app I was able to have /priv/something with /priv as an under route and still go to "/priv" by defining "/" under "priv".  I'm trying to fogure out how to do that for "/"
21:02 thowe Ultimately I want / to check I'm logged in.
21:03 woz joined #mojo
21:04 sri what gave you the impression full apps work differently than lite apps?
21:06 thowe I wasn't under the impression they worked differently, per se.  I'm confused by my inability to make them work the same.  But the key difference here is I am trying to define everything as under "/" instead of just some things under /priv.  I was able to say "/" under "/priv" does something so that I could go to "/priv" in a lite app.
21:07 thowe But I don't know how to define things under "/" and also have just "/" do something in a full app.
21:08 thowe my $root = $r->under('/')->to('example#base');   but what do I do in sub base so that it renders on its own?
21:09 thowe That nested documentation seems to want me to think it can't be done.
21:10 thowe "A route with children can't match on its own though, only the actual endpoints of these nested routes can."  Do I need to define "/" under "/"?
21:11 meredith i think you just need to define a simple any() route for /, not under()?
21:14 meredith ah wait i see what you're looking for
21:16 meredith taking that "under" route then making a '/' route off it to define a behavior at its top level is what you want to to, i think
21:16 thowe Yeah, trying that...  I think I am almost there.
21:17 good_news_everyon joined #mojo
21:17 good_news_everyon [mojo] kraih pushed 1 new commit to master: http://git.io/4poZlg
21:17 good_news_everyon mojo/master 058c294 Sebastian Riedel: more diverse examples for nested routes
21:17 good_news_everyon left #mojo
21:17 thowe OK, I just had to figure the syntax out right....  \o/
21:18 thowe The answer was in front of me the whole time, my brain was just walking face first into the door frame of the answer...
21:22 sri marcus: i want to yell at him that signatures on cpan don't work, but i don't think that would help the situation :(
21:24 sri miyagawa made me look into Module::Signature recently... CANNOT UNSEE!!!!1
21:36 rem_lex|pivo joined #mojo
22:12 absolut_todd joined #mojo
22:15 absolut__ joined #mojo
22:28 Grinnz sri, thanks for the example updates. that confused me as well in the docs.
22:29 sri \o/
22:49 thowe example updates?
22:50 Grinnz [16:17:16] <good_news_everyon> [mojo] kraih pushed 1 new commit to master: http://git.io/4poZlg
22:51 thowe Ah, yeah.  Easier to comprehend by far.
22:52 woz joined #mojo
22:52 Averna joined #mojo
23:22 franzkafka joined #mojo
23:23 franzkafka Hey all, kind of an off-topic question: I've put together a database that I'd like to share. What is the best way to share the database? What is the best way to host a simple interface to the database to show what it contains? E.g., type in a zip code and see what information is contained about the zip code.
23:23 franzkafka I'd like to be able to easily push changes to the database repository, or whatever is hosting it.
23:24 franzkafka And I'd like people to be able to dump all the data, etc... full access to the data, not an API.
23:24 franzkafka Hm, maybe an API would be good too actually.
23:24 Grinnz well, dumping all the data and hosting an interface to the data are two different things.
23:25 Grinnz CSV is usually the most commonly recognized database dump formats, though it isn't particularly "standardized"
23:25 franzkafka True, so for the first one I'd like to host a database and give anyone access to be able to dump the data. For the second one, I'd like to create a simple API that they can use.
23:25 preaction that sounds exactly like a REST API. type in /zip/60653 and get the data the zip contains. type in "PUT /zip/60643" and update the data
23:25 preaction don't give them the database. give them the API
23:25 preaction if you give them direct access to the database, you can never change the database, ever
23:25 franzkafka preaction, in that situation what if they want everything in the database?
23:26 preaction "GET /zip HTTP/1.1"
23:26 franzkafka They get it through API calls?
23:26 preaction yes
23:26 franzkafka Hrm, OK, good idea. I like it.
23:26 davido_lt joined #mojo
23:26 franzkafka Thanks :D
23:26 preaction never, ever, ever, EVER give people direct access to a database. that is the story of 80% of all the problems i've ever had to deal with
23:26 franzkafka Is there a free place to host something like this? I could host the dump files on Github, but not sure about an API.
23:26 Grinnz and you can also then add an API endpoint that just returns a CSV of the whole database, if you so wish
23:27 Grinnz (or whatever)
23:27 preaction GET /zip HTTP/1.1\r\nAccept: text/csv\r\n\r\n
23:27 Grinnz free? not likely
23:27 preaction heroku
23:27 Grinnz digital ocean has $5 a month vpses
23:27 franzkafka Ah, that's fine then. I'll just create a droplet on DigitalOcean for it.
23:28 preaction heroku can do mojolicious, jberger did one once
23:28 franzkafka I was amazed at how difficult it has been to find a good source of data that is updated for cities, postal codes, etc.
23:28 preaction google's geolocation database? openstreetmap's database?
23:28 franzkafka preaction, yeah, I wrote a mojolicious buildpack for heroku and hosted it somewhere in Github at one time.
23:29 franzkafka Google's geoloc API has limits A, and the data is not completely accurate.
23:29 preaction and yours is?
23:29 jberger mongohq would be useful to store data (using say mango)
23:30 jberger heroku works for webhost
23:30 franzkafka Well, I've sourced the data from many, many places, and I've validated it against USPS (I am now banned from their site).
23:30 jberger I've been working on a module for FreeGeoIP
23:30 franzkafka The only possibility is that I am missing postal codes.
23:31 jb360 joined #mojo
23:31 franzkafka I've checked much of Stack Exchange and people recommend using geonames, but their data is outdated.
23:31 franzkafka E.g., 97003 is missing from their data, and Google doesn't even know what city it is (though they do have boundaries for it).
23:32 franzkafka I guess 97003 is missing from OpenStreetMap as well
23:34 franzkafka I have one use with giving API PUT access, and that is that people can make incorrect changes... Hm, not sure what to do there, but I do know that I'd like for it to be community maintained.
23:34 franzkafka But yeah, I've used at least 20 sources to build this data, and checked everything against USPS.
23:35 franzkafka The other thing I did, though I'm not sure how worthwhile this is, was that I mapped every city in the US to a metro area.
23:36 franzkafka I think I have about 300 metro areas, and every city belongs to one (though there is the possibility for them to belong to many, e.g., San Jose -> Bay Area, San Jose -> San Jose area).
23:36 franzkafka preaction, Are you saying that my work is already pretty much out there? That it's not really worthwhile to share it?
23:37 franzkafka preaction, Or that possibly there may be better things to do with what I have (e.g., contribute to already existing projects)?
23:37 preaction i'm saying that openstreetmap is an open database that you can edit, and google maps's database is, afaik, also editable
23:37 franzkafka Yeah, Google Geocoding API is editable as well.
23:38 franzkafka The problem I have is that I see sites selling this data, and I'd rather people not pay for it and just have it for free.
23:38 franzkafka Especially since it's the basis for many webapps. And the answers on gis.stackexchange.com either point to data that is for sale, or outdated stuff (e.g., geonames, maxmind, etc).
23:39 franzkafka I'm not sure how one goes about grabbing all postalcodes from Google's Places/Geocoding APIs either, other than to try all permutations of 5 digits and see what it responds with.
23:39 preaction openstreetmap is open, and free, free enough that apple used it all for their maps app
23:42 preaction also, if you got all this data, are you sure you're allowed to redistribute it?
23:49 franzkafka USPS has some sort of copyright on their data, they don't share it.
23:49 franzkafka I doubt I'm allowed ot
23:52 franzkafka It might be bad that I don't care about that
23:52 franzkafka I guess if I throw it into openstreetmap then it doesn't really matter
23:53 dvinciguerra joined #mojo
23:53 preaction it will to them
23:55 franzkafka Seriously, the USPS sucks. At least Royal Mail makes this data publicly available.
23:56 franzkafka I just checked the legal on Free The Postcode and it says " PLEASE ONLY ENTER DATA YOU YOURSELF HAVE COLLECTED WITH A GPS OR DERIVED FROM COPYRIGHT-FREE DATA."
23:56 franzkafka bleh
23:56 franzkafka Well, I'm going to make this data publicly available somehow
23:56 firnsy i don't see how you own zip code to city translation data
23:56 sri hahaha, now i'm just messing with the heckler on twitter

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