Camelia, the Perl 6 bug

IRC log for #mojo, 2012-02-09

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

All times shown according to UTC.

Time Nick Message
00:01 al joined #mojo
00:10 al joined #mojo
00:11 abra_ joined #mojo
00:12 al joined #mojo
00:25 al joined #mojo
00:33 tty234 joined #mojo
01:01 elb0w_ joined #mojo
01:01 elb0w_ sri: That sc you gave out on the list, thats not mvim huh?
01:03 d4rkie joined #mojo
01:03 elb0w_ nvm see your twitpics
01:06 jwang joined #mojo
01:17 elb0w_ hmm, I recompiled with the drawer but I don't see how to use it
01:17 elb0w_ :/
01:18 scott joined #mojo
01:20 bird joined #mojo
01:20 hshong joined #mojo
01:41 vervain @tempire: Are you here?
01:41 purl Yes, I am, vervain.
02:05 amoore joined #mojo
02:22 amoore joined #mojo
02:23 jwang joined #mojo
02:26 kitt_vl joined #mojo
02:29 ZadYree Hypnotoad, in you we shall believe. Our faith in your overmighty insane wicked eyes has knows no limit.
02:29 sri jmhgtx: get_body_chunk is not part of the normal api, chances are you're doing something very wrong
02:30 ZadYree known
02:31 vervain Everyone should lick a toad every now and then. ;)
02:35 jnap joined #mojo
02:48 GitHub94 joined #mojo
02:48 GitHub94 [mojo] kraih pushed 1 new commit to master: http://git.io/7RpGuA
02:48 GitHub94 [mojo/master] fixed Hypnotoad HTTPS bug - Sebastian Riedel
02:48 GitHub94 left #mojo
02:55 sri tempire: just thought about the healthcare discussion from the other day… what about patents? Your government babysits intellectual property rights too, how can they be american then?
02:56 sri absolutely nobody seems to think of it as unamerican
02:59 vervain Not sure of the specifics of where you are going... but I'm not sure the is consensus on what is 'American' any more.
02:59 vervain Maybe there never was.
03:00 sri well, tempire argued that pubic healthcare is totally unamerican
03:01 vervain Ah... gotcha... Well I'm an ameican that thinks that anything but public healthcare is immoral.
03:01 sri :)
03:02 vervain But most members of the American public don't truly understand the value or repercussions of public healthcare.
03:02 vervain They just argue one way or the other.
03:05 vervain When the US was 'melding' there was a strong sense of 'survive on your own' but it's now maturing and has to realize that common good is in everyone's best interest.... but the US is basically an adolescent... It'll probably figure it out after a while.
03:06 sri funny
03:06 crab moo!
03:07 sri almost seems like those that believe in public healthcare think america is still young, while those that argue against it keep bringing up the fall of rome :)
03:07 vervain LOL... :-)
03:07 sri moo!
03:07 crab i've almost stopped reading the news, because of how much batshit insanity is in it all the time.
03:08 vervain Yup!
03:12 vervain I'm working through Guides::Growing and am getting this http://pastebin.com/i6P6MPUh with my tests right after conversion to a Mojolicious app... The app works as expected but my test no longer works.  any help?
03:16 crab vervain: what code is it complaining about?
03:16 GitHub80 joined #mojo
03:16 GitHub80 [mojo] kraih pushed 1 new commit to master: http://git.io/S6NdCQ
03:16 GitHub80 [mojo/master] do not mention obsolete problem in growing guide - Sebastian Riedel
03:16 GitHub80 left #mojo
03:16 crab i mean, i can see it started in M::UA::_connect, but how did that get called?
03:21 vervain http://pastebin.com/hBS4dGem
03:21 marty sri, vervain: the gist of what I (and I think, tempire) were saying about public healthcare, is that the constitution does not authorize it.  If public healthcare is a great idea we can vote to change the constitution, but we cannot just ignore it.  That's pretty much it.  :)
03:21 vervain Oh... and that's a very fair argument.
03:22 marty Put personally, I'd vote against modifying the constitution.  :)  I might for for modifying the preamble to "all people" rather than "all men". :)
03:22 vervain But... and it's a big BUTT... the US circumnavigates the constitution all the time.
03:22 sri marty: did i overlook the constitution part yesterday? Oo
03:22 mire joined #mojo
03:23 marty sir, I got a little off track the other day.  :)  vervain: I agree totally, but you know, two wrongs...  :)
03:24 vervain I may have missed something though... how can public healthcare be against the constitution?  Mandated insurance maybe... but gov provide healthcare I'm not sure would conflict with the Constitution.
03:24 sri that does seem like a sensible argument
03:25 marty I've read the constitution many time, I see no mention of healthcare in there.   "life, Liberty and the pursuit of happiness".
03:26 marty Don't get me wrong. If I thought our government could run a decent healthcare system AND we voted to change the Constitution to allow it, I'd be all for it.   But, look at social security etc...  Not a good track record.
03:28 marty And I think the current status of the US healthcare system is terrible.  I'm just not convinced getting the us government involved would solve any issues since many of the current issues are exasperated by the us government.
03:30 vervain It might be exactly what is required... since what we really need is a total meltdown to expose the players and problems (just like our recent mortgage meltdown)
03:31 marty I'd be all for that.  But, with big money in government, I'm not sure who would do the exposing.  If they appointed you and I, I'd  be all for it.  :)  We'd kick some ass!
03:31 sri marty: how are patents constitutional?
03:32 vervain My personal feeling is that community healthcare should be the pentacle of any civilized society.... otherwise what's the point of a society.
03:32 marty I would argue that they are not.  Just another example of how we have forsaken reason for profit in the US and ignored the lesson of the past.
03:32 vervain But ya - ROCK ON... let's take em' :-)
03:33 sri hmm
03:38 vervain Catch ya later folks... good to be back. :-)
03:38 marty Night vervain.  \o/
03:39 sri nn
03:41 * marty loves Wall-E
03:41 marty Just watched it again.  I love that movie!!! :)
03:41 * sri too
03:53 cstamas_ joined #mojo
03:53 y0j_- joined #mojo
03:53 sherr_ joined #mojo
03:54 ashleyde1 joined #mojo
03:54 elb0w__ joined #mojo
03:54 xxtjaxx__ joined #mojo
04:50 GitHub175 joined #mojo
04:50 GitHub175 [mojo] kraih pushed 1 new commit to master: http://git.io/kAY4dw
04:50 GitHub175 [mojo/master] rewrote FAQ answer - Sebastian Riedel
04:50 GitHub175 left #mojo
04:51 sri did i use the word "quest" right?
04:56 crab sure.
04:56 sri \o/
05:00 sri tempire: your latest blog post is doing pretty well on reddit btw http://www.reddit.com/r/perl/
05:03 scott_ joined #mojo
05:12 tempire sri: patents are a problem.  in fact, the us government goes against the constitution all the time.
05:12 tempire it's a rampant issue, and it's getting worse.
05:13 tempire going against the constitution is the reason behind the empire mindset.
05:13 tempire the whole point of the us, when instantiated, was to keep the federal government small
05:15 tempire the federal govt has no jurisdiction beyond managing contractual disagreements between states, providing a national defense, and to protect the rights of the people.
05:15 tempire that's it.
05:15 tempire many people, even those in office don't understand that point.
05:15 tempire so they just do whatever.
05:15 tempire who cares.
05:15 purl not me
05:16 tempire hmm.  all those up votes for corny!
05:16 tempire chorny, even
05:17 tempire I've never had this conversation with a european, though.  I'm not even sure where the common ground would be.
05:17 tempire I think my soap box doesn't do so well when crossing an ocean.
05:18 * tempire dissolves
05:27 mercutioviz joined #mojo
05:33 hshong joined #mojo
05:36 tempire lulz.  the post got 3 downvotes.
05:36 tempire .
05:37 sri that's extremely low
05:37 sri basically means it had no downvotes at all
05:37 sri since reddit autogenerates downvotes to fight vote manipulations
05:37 tempire ah
05:38 sri downvotes are usually 50% of upvotes
05:39 sri it's an interesting system, you never know the real numbers
05:39 sri basically just an indicator of popularity in context to other posts
05:40 tempire that hypnotoad bug is a pretty deal.  release soon?
05:40 tempire *big
05:41 sri if you think it's important, sure
05:42 sri but i doubt many would use hypnotoad+ssl in production
05:42 tempire I guess that's probably true.  hardly anyone ever talks about certificate auth in here.
05:43 sri i don't actually trust IO::Socket::SSL and Net::SSLeay very much
05:44 crab yeah
05:44 tempire I've gathered that.  I don't have a very good impression either, but I think my sole source of information is you.
05:44 crab it's a pity.
05:45 crab if i didn't have to worry about making a living and such, i would love to write a sane, sensibly-licensed, modern ssl library in C with a nice API and clean perl bindings.
05:46 sri that would be nice
05:46 crab with systematic side-channel resistance, too. not the somewhat arbitrary hodgepodge that openssl has. but the api is more important.
05:46 sri tempire: look through the Net::SSLeay code
05:47 crab ssleay bells ring, are you listening?
05:47 sri and i don't mean to bash the authors, those modules have clearly grown that way over many many years
05:48 * sri looks at Changes
05:48 sri 1996!
05:48 purl I don't like big numbers like that.
05:48 crab yes, and crypto/ssl is complex enough that nobody wants to reimplement it.
05:48 sri indeed
05:49 crab sri: do you write C? have you seen the openssl api?
05:50 sri i used to write more C, but not much in recent years
05:50 sri only briefly, but from what i heard the openssl api itself is a mess too
05:52 sri i remember the node.js folks tried gnutls first because of its nicer api, but it wasn't reliable enough or so
05:53 crab yeah.
05:54 sri have you considered applying for a tpf grant?
05:54 sri if a sensible ssl/tls module wasn't worthy i don't know what would
05:55 * sri has no idea how much work it would actually be though
05:58 elb0w joined #mojo
05:59 crab i had applied for a tpf grant years ago to build what was eventually built as Devel::NYTProf, and failed to complete the work (due to some personal complications). so now i feel too guilty to do something like that again.
06:00 sri well, i think 80% or all grants fail
06:00 sri s/or/of/
06:02 crab true
06:04 sri made me feel a bit better about delivering the results of mine late :)
06:08 crab what was yours?
06:09 Vandal joined #mojo
06:09 sri mojo docs ;)
06:42 sri tempire: release if you want to
06:51 tempire do you set the TEST_* env vars when testing for release?
06:53 sri not just for release, i regularly run all tests
06:54 sri the hypnotoad one can bug out though… and you have to kill the forked process yourself...
06:55 tempire no bugging here
06:55 sri it's random, fork tests in general are a pita
06:55 tempire I love writing fork tests.
07:03 marcus fork off
07:03 purl fork you.
07:06 david joined #mojo
07:07 david What is the correct method to send a JSON response  to a client using mojolicious lite?
07:09 tempire $self->render_json($thing)
07:10 tempire "Released #mojolicious 2.48 with doc improvements, and bug fixes for Hypnotoad and Mojo::Util. https://github.com/kraih/mojo/blob/49ee04e​c2c10888ff1cef22bb23d54751f7f34dc/Changes #perl"
07:10 david @tempire: You are a god amongst men, good sir.
07:13 sri http://mojolicio.us/perldoc/Mojolicious/G​uides/Rendering#Rendering_JSON_28_json_29
07:15 crab tempire: blog/v2.48/Changes works, btw.
07:15 crab er, blob
07:18 david I want to render a template that has some javascript(that requests the JSON response) and a table. render_json does exactly what it says, it renders the json but then I can't render my template... Any thoughts on how I could acomplish this?
07:19 sri tempire++
07:20 crab david: $self->render(..., json => $self->render_partial(json => $data))
07:21 crab and then use $json in your template
07:21 crab or something like that.
07:22 david @crab: Thank you, I will look into render_partial()
07:32 dpetrov_ joined #mojo
07:45 * sri wonders if we could hack Makefile.PL to set HARNESS_OPTIONS=j9 as default
07:45 tempire that would be wonderful
08:12 judofyr joined #mojo
08:23 batman joined #mojo
08:25 melmothX joined #mojo
08:33 berov joined #mojo
08:38 al joined #mojo
08:47 random joined #mojo
09:00 tempire so um.
09:00 tempire metacpan content
09:00 tempire *contest
09:01 tempire what the dilly
09:05 daxim joined #mojo
09:08 crab metacpan contest? what?
09:08 GitHub61 joined #mojo
09:08 GitHub61 [mojo] kraih pushed 1 new commit to master: http://git.io/m-FFQQ
09:08 GitHub61 [mojo/master] minor FAQ tweaks - Sebastian Riedel
09:08 GitHub61 left #mojo
09:09 sri tempire: looks like nobody cares :(
09:10 sri as far as i know not even the voting app exists yet
09:10 sri crab: http://contest.metacpan.org/
09:11 sri it ended a month ago
09:11 black joined #mojo
09:12 cosmincx joined #mojo
09:15 marcus there's an insane amount of crappy entries
09:16 sri well, which self respecting real designer would participate in such a contest ;p
09:17 sri worst imo is that not even the organizers care
09:25 judofyr sri: it's really annoying that Mojo::UserAgent absolutely tries to re-parse my URL…
09:25 judofyr sri: I'm generating this thingie: OB.%C3%9859%2F1917
09:26 sri judofyr: the fix is already on cpan
09:26 judofyr sri: no, but this is a plain string, not a Mojo::URL
09:26 purl okay, judofyr.
09:26 judofyr or did you fix that too?
09:26 sri then it's your fault ;p
09:27 judofyr but I'm generating a completely valid URL… Mojo::URL mangles it to: OB.%C3%9859
09:27 judofyr oops
09:27 judofyr OB.%C3%9859/1917
09:27 judofyr I just don't see *why* you're doing it
09:27 judofyr even for plain strings
09:27 sri historic reasons, can't change
09:28 sri but you're welcome to work out a deprecation path
09:29 judofyr sri: is there a way to create a Mojo::URL without automatic %2F-conversion?
09:29 ki0 joined #mojo
09:30 sri don't know
09:32 AmeliePoulain joined #mojo
09:35 sri and when i say that i mean i have no clue what you're talking about ;p
09:36 judofyr sri: the real problem is that Mojo::Path does url_unescape and *then* split on slash. if you split on slash first, then url_unescape the parts, then you'll get correct behaviour
09:38 sri we did that a long time ago, until someone realized that it's a bad idea to allow people to download arbitrary files from web servers… such as say /etc/passwd
09:38 judofyr hm? what exactly does that have to do with anything? :S
09:39 sri well, that's what will happen if you apply your change idea :)
09:39 judofyr that problem shouldn't be solved in the URL parser
09:40 sri patches welcome
09:40 purl patches welcome is always true or unless for search.cpan.org or swahili for "Put up or shut up."
09:41 sri that url parser is used on amy layers all over the place though
09:43 sri but yea, if you want something to change open a ticket and start a discussion, i'm often wrong
09:46 crab i think the real question is: wtf are you generating such horrible urls anyway?
09:49 crab encoded slashes in the path (*shudder*) have *always* been a problem of some sort.
09:49 sri yea, many servers decode %2F automatically before forwarding
09:49 crab if you're determined to do it, it doesn't seem unreasonable to dig into the Mojo::URL internals and construct exactly what you want.
09:50 judofyr crab: slashes are valid identifiers in this database. the API is REST-ish so we need to construct paths…
09:50 judofyr not much I can do to change this :/
09:50 crab why are you encoding the slashes?
09:51 sri the problem is not that you *have* to do it, but that you *want* it to be more pleasant
09:51 judofyr crab: because the API doesn't handle it otherwise
09:51 crab oh, the api is something external? i see.
09:52 judofyr sri: yeah, more pleasant than this: http://cl.ly/2D1y2x0j2O0Z1N0p3y02
09:52 sri doing something dangerous should be unpleasant
09:52 sri you should be frightened by %2F
09:52 crab very poor decision on the part of the api designers, imo. but just take your mojo::url and modify it to do what you want. it's a dirty hack, no point pretending otherwise.
09:52 crab sri: exactly
09:54 sri http://web.nvd.nist.gov/view/vu​ln/detail?vulnId=CVE-2011-1589
09:54 sri that's the bug btw
09:54 sri gives you an idea of how evil %2F really is
09:56 judofyr sri: I'd argue that's a bug in whatever is serving static files, but whatever
09:57 judofyr it seems that it's too much work to change it anyway. too much that depends on this behavior.
09:57 judofyr and most of the time you don't notice it
09:58 marcus just add $url->stfu_and_eat_my_literal_path('foo/bar');
09:58 * marcus should be an API designer.
09:58 crab it's more like 99.998% of the time someone does something like this, it's a horrible mistake
09:59 crab ->eat_my_shorts
10:15 xantus[] joined #mojo
10:15 xantus[] hey hey
10:17 xantus[] I'm sure you guys noticed that AMS had uploaded 2.47 to cpan
10:17 xantus[] I see tempire upped 2.48
10:17 * sri waves
10:18 xantus[] hi sri
10:18 sri yea, that's their job
10:19 sri where were you hiding?
10:28 GitHub57 joined #mojo
10:28 GitHub57 [mojo] kraih pushed 1 new commit to master: http://git.io/19gNVA
10:28 GitHub57 [mojo/master] made user agent recipes slightly more realistic - Sebastian Riedel
10:28 GitHub57 left #mojo
10:29 xantus[] here and there
10:31 judofyr btw, I'm pretty close to running Mojo apps on Heroku :)
10:32 sri heh
10:32 sri after seeing the lua example i was wondering if perl could work too :)
10:33 xantus[] I want to port mojo to node.js
10:34 judofyr I tried with ActivePerl first (because then I wouldn't have to compile it), but it doesn't work so well when the Perl-directory is renamed and moved all over the place
10:34 judofyr so I think I'll have to do perlbrew…
10:34 judofyr sri: is there a way to detect a Mojolicious app automatically?
10:35 xantus[] have you tried strawberry perl
10:35 judofyr as in, "is there a Mojo app in this dir" and "how do I run it"
10:35 judofyr nope
10:35 judofyr isn't that Windows only?
10:36 xantus[] sorry, I came in the middle of the conv
10:36 sri not that i know of
10:37 sri not like mojo apps have a static structure
10:37 judofyr sri: Makefile.PL maybe?
10:37 judofyr or, I should be able to get the name out of Makefile.PL
10:37 sri Makefile.PL is not a requirement
10:37 xantus[] I'm lost :)
10:38 sri there are also many different formats
10:38 judofyr no, but I need *something* for detection
10:38 judofyr and you need a Makefile.PL anyway if you want to install dependencies
10:38 sri ExtUtils::MakeMaker, Module::Build, Module::Install...
10:38 judofyr sri: maybe I'll just check for a file called "Perloku" or something, and runs that
10:39 sri yea, you can always extend it later
10:39 sri start with getting it to run :)
10:50 judofyr current status: compiling Perl on Heroku
10:59 GitHub170 joined #mojo
10:59 GitHub170 [mojo] kraih pushed 1 new commit to master: http://git.io/MJk8LQ
10:59 GitHub170 [mojo/master] mention %2F handling in Mojo::Path documentation - Sebastian Riedel
10:59 GitHub170 left #mojo
11:08 sri hmm
11:08 sri X-Purpose: Instant
11:09 sri guess google didn't get the memo about X-* being deprectaed ;p
11:13 marcus Too big for RFCs.
11:14 sri SO TRUE!
11:14 sri google is becoming so microsoft, it's scary
11:19 vervain Anyone have time to look at why I get http://pastebin.com/i6P6MPUh with git@github.com:wcravens/mojolicious-guides-growing.git when I try to run t/login.t
11:20 vervain I've tried to walk through the guide as best I can but this is proving to be hump
11:35 noganex joined #mojo
11:38 baton8 joined #mojo
11:45 vervain I seemed to need these changes to t/login.t while walking through MJ:Guides::Growing http://bit.ly/wZv6b9 ... is this correct or have I done something 'wrong' along the way?
11:51 cosmincx joined #mojo
11:51 briang joined #mojo
11:56 sri http://mojolicio.us/perldoc/Mojolici​ous/Guides/Growing#Simplified_tests # that's exactly what this part says
11:57 judofyr sri: http://evening-spring-9355.herokuapp.com/
11:57 sri judofyr: :O
11:57 sri \o/
11:57 sri will that thing stay up? can i tweet it? :)
11:58 judofyr it should stay up, yes
11:58 sri or will you tweet something?
11:59 judofyr nah
11:59 judofyr too cool for tweets
12:03 judofyr sri: oneliner for outputting the Perl version?
12:04 judofyr nevermind
12:10 sri judofyr: which server does it use?
12:10 judofyr sri: ./app.pl daemon
12:10 sri wow
12:11 sri that means all features work
12:11 judofyr sri: I couldn't find an easy easy way to choose port on the command line with hypnotoad
12:11 judofyr well, there's a proxy in front
12:11 sri oh
12:11 judofyr so there *might* be a 30-second timeout or something
12:11 judofyr not sure
12:11 sri proxy prevents websockets
12:11 sri or is it just tcp?
12:12 sri headers look original
12:12 judofyr I'm not sure. been a while since I've been playing with Heroku. but I think they fixed websockets when they implemented node.js support…
12:12 sri prolly just haproxy
12:13 MisterHatt heroku last I checked uses nginx and varnish
12:13 judofyr sri: is there a way to launch hypnotoad given on a specific port on the command line?
12:13 sri nope
12:13 sri http://mojolicio.us/perldoc/Mojol​icious/Guides/Cookbook#Hypnotoad
12:13 sri but you can select a port from the app
12:14 judofyr Heroku chooses the port
12:14 sri if it's an env var you can just use that
12:14 judofyr web: ./app.pl daemon --listen http://*:$PORT
12:14 sri $ENV{PORT}
12:14 judofyr ah, of course
12:14 judofyr silly me
12:15 sri http://mojolicio.us/perldoc/Mojolicious​/Guides/Cookbook#WebSocket_web_service
12:15 sri if you feel like testing websockets
12:23 judofyr sri: no websockets: http://cold-leaf-2852.herokuapp.com/ :/
12:26 sri aww
12:46 judofyr sri: https://github.com/judofyr/perloku
12:47 GitHub164 joined #mojo
12:47 GitHub164 [mojo] kraih pushed 2 new commits to master: http://git.io/vqlLww
12:47 GitHub164 [mojo/master] Remove depricated use of max_redirects from Growing.pod - Wes Cravens
12:47 GitHub164 [mojo/master] Merge pull request #283 from wcravens/depricated_max_re​directs_in_Guides_Growing - Sebastian Riedel
12:47 GitHub164 left #mojo
12:48 sri judofyr++
12:49 judofyr https://twitter.com/#!/judof​yr/status/167590901626044416
12:49 sri retweeted
12:52 sri http://hackerne.ws/item?id=3570894 # i accidentally to hackernews ;p
12:53 judofyr :)
12:57 sri upvote!
12:58 * sri pokes crab, marcus, tempire, DaTa, memowe, xantus[], rhaen, marty, diegok and everyone else who might be awake
12:58 diegok ack
12:58 sri http://hackerne.ws/item?id=3570894 # UPVOTE!
13:00 sri and frontpaged :)
13:00 sri everyone++
13:01 diegok judofyr++
13:04 DaTa narf, i hate openid
13:04 sri who doesn't?
13:04 purl And I'm proud of it!
13:10 sri judofyr: and #1 ;p
13:33 Netfeed judofyr: cool
13:38 crab this should be the new mojo mascot: http://toroid.org/misc/fm.jpg
13:40 * sri is scared
13:43 elb0w__ Why do you need to make  Makefile.PL for Heroku?
13:43 * elb0w__ knows 0 about Heroku
13:44 sri deps
13:44 elb0w__ I guess thats something for heroku then?
13:44 elb0w__ I dont know how it works, ill read
13:46 jnap joined #mojo
13:49 judofyr elb0w__: nah, Perloku uses it in the compile-phrase to build in deps
13:50 elb0w__ ah ok
13:50 elb0w__ yeah I keep hearing about heroku
13:50 judofyr elb0w__: Heroku needs all your files in the compile-phrase. then it deploys it on several machines.
13:50 elb0w__ I should probably look into it
13:50 elb0w__ ahhh
13:50 elb0w__ interesting
13:50 judofyr anyway, gotta go
13:56 sri what's interesting about heroku is that they make it easy for you to run your own server
13:56 sri dotcloud uses uwsgi and psgi
13:57 sri so with heroku you could theoretically get all mojolicious features if they stop filtering out websockets
13:59 elb0w__ ive turned off websockets
13:59 elb0w__ until they get standardized
14:00 sri they are
14:00 sri rfc 6455
14:01 sri mozilla and chrome already use the final version
14:07 memowe I feel poked!
14:08 sri you might want to get your reflexes checked
14:09 memowe Will do that after I got my brain ... who are all these people?
14:33 amoore joined #mojo
14:52 cosmincx joined #mojo
14:53 d4rkie joined #mojo
15:01 d4rkie joined #mojo
15:05 osprey_ joined #mojo
15:09 tty234 joined #mojo
15:13 grim_fandango joined #mojo
15:14 grim_fandango left #mojo
15:24 GeorgeJetson joined #mojo
15:24 GeorgeJetson left #mojo
15:39 abra joined #mojo
15:51 kaare joined #mojo
16:06 federated_life joined #mojo
16:32 osprey_ left #mojo
16:35 Akron joined #mojo
16:43 jmhgtx I've got a route  $acct = $r->bridge('/account/:id')->to('account#read');  which is followed by $acct_base->route('/users')->vi​a('get')->to('account#users');   So, I'm chaining /account/:id/users.   Is users the end point in that chain? That is, is the data returned coming from users()?
16:46 dlyke joined #mojo
16:49 xaka joined #mojo
17:00 crab i don't understand this question.
17:00 crab what is acct_base?
17:00 crab if you mean $acct, then the answer is probably yes. assuming account#read returns true.
17:06 jmhgtx $acct_base is the first part of the chained route.
17:16 crab what is $acct then?
17:17 GabrielVieira joined #mojo
17:20 jmhgtx $acct is the route to a function that returns the information for an account object. If I just call /account/:id I get a hash of account data.  /account/:id/users gets the the users function but I can never return anything different than what I'm getting back from /account/:id
17:27 crab jmhgtx: don't render your account data, put it into the stash
17:28 Akron xantus[]: Just saw you started following eschnou/node-ostatus on github, maybe Akron/Sojolicious is of interest for you (OStatus for mojo). #ad
17:28 jmhgtx So, I need to find out if '/users' is on the route and if it is just stash as opposed to rendering?
17:29 crab jmhgtx: do you need to access /accounts/:id directly too?
17:29 crab i.e. make http requests to it?
17:29 jmhgtx Yes
17:30 crab then don't try to do that in the bridge function. make accounts#read ALWAYS stash, and add a / route under it that just renders from the stash
17:33 jmhgtx I don't understand what you mean by that second part.  If I make /account/:id always stash I need to get that but I'm not sure what you mean by add a / route under it.
17:38 jmhgtx So, I need to stash anything that could be part of  a chain and just have a default route that just renders what is left in the stash?
17:40 crab jmhgtx: i'm still confused about your using $acct in one place and $acct_base in another, but here's what i mean:
17:40 crab $things = $r->bridge->to('things#read');
17:40 crab $things->get('/')->to('things#index');
17:41 crab $things->get('/warts')->to('things#warts');
17:42 crab sorry, bridge('/things/:id')->to, i meant on the first line. so things#read would take id and read that thing and store the object in the stash, and things#index would take that object and render it in some form, while things#warts would render something else.
17:43 jnap joined #mojo
17:43 jmhgtx Oh wow. Sorry about that. I didn't realize that I'd made that mistake.  $acct_base == $acct.
17:45 jmhgtx crab:  Cool, that makes sense.  Thanks a lot for your help. I'll try this out.
17:51 federated_life joined #mojo
18:00 mire joined #mojo
18:01 vervain joined #mojo
18:19 batman joined #mojo
18:31 rhaen joined #mojo
18:45 federated_life joined #mojo
18:53 tempire look at that!
18:54 tempire 87 points on hackernews!
18:54 tempire judofyr++
18:54 tempire alright
18:54 tempire so who's making the deployment command?
18:54 tempire ./myapp herokify
18:55 tempire GO GO GO!
18:55 vervain I'd have though judofyr would be a top contender for that nomination ;-)
18:56 tempire the first person to do it gets the fame
18:56 rhaen joined #mojo
18:57 vervain I'm gonna live forever... I'm gonna learn how to fly... FAME
19:04 tempire why do all perl framework discussions have to be a battle between the different ones?
19:05 tempire do rails and sinatra battle so much?
19:37 tempire hmm.  trying heroku.  have no idea what I'm doing
19:37 tempire Y U NO RUNNING
19:37 mercutioviz joined #mojo
19:50 tempire ack
19:51 * tempire gives up
19:54 al joined #mojo
20:07 al joined #mojo
20:07 al joined #mojo
20:41 jnap_ joined #mojo
20:45 lukep joined #mojo
21:07 jnap joined #mojo
21:42 jnap joined #mojo
22:37 lukep joined #mojo
22:43 federated_life joined #mojo
22:52 batman joined #mojo
22:54 batman joined #mojo
23:07 lukep joined #mojo
23:10 mire joined #mojo
23:21 tempire I think we need to make more use of screenr
23:21 tempire to show simple examples of stuff.
23:22 tempire once a week, post a thing.
23:22 tempire it doesn't matter what it is.  just for exposure.
23:23 vervain Apparently I'm 'Missing Plug-in'... but nothing more helpful than that. :-/
23:27 tempire it's a java thing.  that's the only help I can be.
23:28 vervain Weird... it looks they are surving through flash... but my Chrome on winders doesn't like it at all... Chrome in Debian is fine though.
23:28 vervain And FF on window is good.
23:28 vervain windows
23:30 rhaen joined #mojo
23:31 vervain Very odd... no time to debug their stuff though
23:47 vervain GGgrrrr... typing 'makefile.pl' into the location bar of chrome doesn't do a search... because of some scumbag squatting the domain.
23:52 batman joined #mojo
23:57 smellycat joined #mojo

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