Camelia, the Perl 6 bug

IRC log for #mojo, 2012-01-23

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

All times shown according to UTC.

Time Nick Message
00:03 wjh joined #mojo
00:05 j3nnn1_ joined #mojo
00:22 wjh joined #mojo
00:22 jnap joined #mojo
00:23 Alias joined #mojo
00:30 buu joined #mojo
00:30 buu So, um. Guys.
00:42 buu Oh, before I forget.
00:43 buu I'm trying to use Mojo::DOM->text to retrieve the text from a block, and it doesn't give me any output, unless I change $recurse to 1
00:43 buu Then it works great
00:43 buu Is there some way to uh deal with that?
00:43 buu I mean
00:43 buu you call ->text which calls ->_text which has a $recurse option
00:43 buu Which defaults to 0
00:43 buu And I need it to be 1
00:50 tempire buu: post a minimal example in a gist
00:57 buu tempire: I don't really have a useful minimal example, what I did was copy the function out, call it, see what happened, then changed $recurse to 1
00:57 buu tempire: Look at: 297   return $self->_text($self->tree, 0, defined $trim ? $trim : 1);
00:58 buu If you change that call to _text( $self->tree, 1, ... ) it does what I mean.
01:10 gabriel joined #mojo
01:13 sri http://mojolicio.us/perldoc/Mojo/DOM#all_text
01:16 wjh joined #mojo
01:20 jnap joined #mojo
01:24 buu Boy I feel dumb. Thanks sri.
01:34 wjh joined #mojo
01:41 vlixes joined #mojo
01:42 D4RK-PH0ENiX joined #mojo
01:50 mire joined #mojo
01:52 wjh joined #mojo
01:58 diegok Hi, What can I'm doing wrong to get "deep recursion" when using url_for with named routes in controller?
02:02 diegok same call to url_for on templates is doing well...
02:10 wjh joined #mojo
02:18 wjh| joined #mojo
02:19 wjh- joined #mojo
02:28 GitHub70 joined #mojo
02:28 GitHub70 [mojo] kraih pushed 2 new commits to master: http://git.io/wjyPEg
02:28 GitHub70 [mojo/master] Parse HTML attributes without a value. - Douglas Christopher Wilson
02:28 GitHub70 [mojo/master] Merge pull request #268 from dougwilson/feature/parse-h​tml-empty-attribute-value - Sebastian Riedel
02:28 GitHub70 left #mojo
02:30 wjh joined #mojo
02:53 wjh joined #mojo
02:57 wjh| joined #mojo
02:57 wjh- joined #mojo
03:03 hshong joined #mojo
03:05 hshong joined #mojo
03:06 mars joined #mojo
03:06 mars hi
03:06 purl hi, mars.
03:07 mars I'm a relatively inexperienced perl programmer.
03:07 mars heard from a perlmonk that mojolicious was awesome.
03:07 mars So I'm just joining the chat as I work through the basics.
03:10 mars What is the difference between #mojo and #mojomojo?
03:13 mars Is there a current consensus on what's the best document to start reading at?
03:13 mars I'm looking at Marcus Ramberg's presentation on slideshare.
03:14 wjh joined #mojo
03:14 alnewkirk mars: mojocast.com
03:15 alnewkirk mars: mojocasts.com
03:15 purl it has been said that mojocasts.com is a lite app, and it's really easy to manage with just one file
03:15 mars That sounds awesome. Thank you.
03:15 alnewkirk also, mojomojo is a wiki built with "Catalyst" (i believe)
03:16 mars Has anyone here used Dancer?
03:16 mars Not to sound like a turncoat or something, I'm just looking at both simultaneously.
03:16 mars this music rocks
03:17 alnewkirk I
03:17 alnewkirk Dancer is very nice also if you're partial to procedural programming
03:18 mars What is procedural programming?
03:19 alnewkirk google it
03:21 abra_ joined #mojo
03:27 wjh joined #mojo
03:30 vlixes left #mojo
03:38 Psyche^ joined #mojo
03:42 jnap joined #mojo
03:42 jnap left #mojo
04:30 GitHub154 joined #mojo
04:30 GitHub154 [mojo] kraih pushed 1 new commit to master: http://git.io/i1bwbg
04:30 GitHub154 [mojo/master] updated Changes - Sebastian Riedel
04:30 GitHub154 left #mojo
04:33 hshong joined #mojo
04:58 ccushing joined #mojo
05:45 bvierra joined #mojo
06:04 elb0w_ joined #mojo
06:09 alnewkirk joined #mojo
06:21 koban joined #mojo
06:32 AmeliePoulain joined #mojo
06:33 batman joined #mojo
06:41 migo joined #mojo
06:51 ysyrota joined #mojo
06:57 AmeliePoulain joined #mojo
07:03 spleenjack joined #mojo
07:20 batman joined #mojo
07:30 cosmincx joined #mojo
07:37 y0j_ joined #mojo
07:45 ki0 joined #mojo
08:03 Vandal joined #mojo
08:23 mars This is a fantastic series of videos (the mojocasts).
08:23 mars Thanks for recommending.
08:23 mars Do you-all have a suggestion as to where I should go to learn jquery / html 5 / nicelooking browser stuff?
08:23 Vandal link plz
08:24 mars Vandal: link to what?
08:24 Vandal series of videos
08:24 mars mojocasts.com
08:24 purl mojocasts.com is a lite app, and it's really easy to manage with just one file
08:24 Vandal thx
08:24 mars np, the others told me about it just a couple hours ago
08:32 Topic for #mojo is now Mojolicious real-time web framework 🍃  http://mojolicio.us/ 🍃 http://irclog.perlgeek.de/mojo/today 🍃  Prepare for Mojocalypse
08:33 bvierra left #mojo
08:40 berov joined #mojo
09:02 baton8 joined #mojo
09:37 gabriel joined #mojo
09:42 memowe mars: learning html5, jquery (javascript), css, perl, mojolicious and how it all works together is a pretty big thing.
09:58 olav joined #mojo
10:06 crab yeah. really big, especially with all the changes around html5 that are happening.
10:08 olav Is there a nice way to set mojolicous up as perl handler on an Apache2 server, so that it can resolve rest-like urls?
10:14 perlite joined #mojo
10:15 metaperl joined #mojo
10:16 spleenjack joined #mojo
10:16 gabriel joined #mojo
10:19 noganex joined #mojo
10:36 fhelmber_ joined #mojo
10:58 jwang joined #mojo
11:19 kitt_vl joined #mojo
11:22 cosmincx joined #mojo
11:22 briang joined #mojo
11:38 hide joined #mojo
11:55 cosmincx joined #mojo
12:04 marty joined #mojo
12:15 judofyr joined #mojo
12:15 koban joined #mojo
13:00 jnap joined #mojo
13:20 noganex_ joined #mojo
13:30 noganex joined #mojo
13:55 jnap joined #mojo
13:56 alnewkirk joined #mojo
14:02 inokenty joined #mojo
14:08 koban left #mojo
14:17 Alias_ joined #mojo
14:25 amoore joined #mojo
14:31 marty joined #mojo
14:52 metaperl joined #mojo
15:17 herrclark joined #mojo
15:18 noganex_ joined #mojo
15:34 judofyr how can I catch an error?
15:34 judofyr that happens inside a controller
15:34 judofyr it seems that I can listen to the logger
15:35 judofyr but it doesn't seem to be a way to get the request that exception was attached to…
15:37 judofyr sri: ?
15:43 abra joined #mojo
16:00 d4rkie joined #mojo
16:04 kaare joined #mojo
16:06 D4RK-PH0ENiX joined #mojo
16:08 crab it's hard to make syswrite fail
16:12 sri crab: if you can't trigger it why have the exception?
16:13 sri pull request neither has a unit test or very good explanation for why it is necessary
16:13 cosmincx joined #mojo
16:18 sri especially since his motivation is consistency
16:18 sri how do you know it's consistent if you don't test it?
16:20 tholen joined #mojo
16:20 kitt_vl joined #mojo
16:21 judofyr is there any connection between a request and a Mojo::Exception-object?
16:22 judofyr (I'm writing a plugin for http://airbrakeapp.com/pages/home)
16:33 judofyr hm… $c->stash('exception') is undef even if mojo.exeception is 1
16:39 judofyr sri: why do you do this? % my $e = delete $self->stash->{'exception'};
16:39 judofyr https://github.com/kraih/mojo/blob/master/lib/Moj​olicious/templates/exception.development.html.ep
16:42 GabrielVieira joined #mojo
16:42 crab sri: i wasn't disagreeing, it was just an observation
16:42 crab judofyr: to avoid recursion
16:43 judofyr crab: nope. there's another mojo.exception stash-variable for that
16:44 crab sri: i suspect a lot of new(-ish) users submit patches to things that don't really matter just to get a toe-hold with a patch or two accepted
16:44 d4rkie joined #mojo
16:44 crab sri: (as distinct from people who run into some odd special-case error and submit a one-line patch, in which context there's usually some explanation/justification)
16:47 crab just speculation, not connected with accepting or rejecting the patch.
16:50 crab i don't think there's any sane way to test that change, or even justify it.
16:50 crab yet it's hard to think of it as harmful either.
16:55 sri crab: all unnecessary code is harmful
16:55 sri it needs to be maintained
16:58 judofyr blah. I give up…
17:00 judofyr EXCEPTION; WHY U NO GIVE REQUEST? well, or the other way around :(
17:03 GabrielVieira joined #mojo
17:12 judofyr :(
17:27 sri i'm starting to hate the fork and edit feature on github… nobody cares about tests anymore… and i'll be the bad guy for pointing it out
17:32 xaka joined #mojo
17:38 cosmincx joined #mojo
17:39 noganex joined #mojo
17:41 grim_fandango joined #mojo
17:47 bvierra joined #mojo
17:52 marcus Greetings.
17:52 purl Greetings. is anyone awake?
17:52 * marcus is back in his native homelands.
17:54 gabriel joined #mojo
17:56 marcus Sri: needs moar tests is an acceptable response to a pull request, imo.
17:57 marcus Judofyr: airbrakeapp seems nice!
18:00 crab marcus: how are you?
18:01 ki0_ joined #mojo
18:01 marty Welcome home, marcus
18:03 * sri waves at marcus and hides behind crab to avoid getting hit by the lasers
18:04 marty I've heard that sending a pull request for mojolicous with no tests is like playing in the alligator pit.  :P
18:05 sri i think no tests might be acceptable in this case, finding a portable test case is extremely hard and full disk not uncommon
18:05 sri in fact, making all uses of syswrite more defensive might be a good idea
18:06 marty TDD is still new to me.  I'm still trying to figure out the best time to create tests when you are blindly coding and have no idea where you are going to end up.
18:07 sri don't aim for 100% test coverage
18:08 sri hmm
18:08 sri there are 5 places that might benefit from a syswrite exception
18:09 burk joined #mojo
18:14 GitHub61 joined #mojo
18:14 GitHub61 [mojo] kraih pushed 1 new commit to master: http://git.io/F0iFZw
18:14 GitHub61 [mojo/master] added experimental test_after/text_before methods to Mojo::DOM and made all uses of syswrite more defensive - Sebastian Riedel
18:14 GitHub61 left #mojo
18:19 sri https://github.com/kraih/mojo/commit/def94​d090b34880b82d3a06e7b08fea8996c7f33#L4R667
18:19 sri those should be rather useful for when you want to render html/xml into something else
18:24 mercutioviz joined #mojo
18:28 GitHub195 joined #mojo
18:28 GitHub195 [mojo] kraih pushed 1 new commit to master: http://git.io/GpHgcA
18:28 GitHub195 [mojo/master] fixed a few small typos - Sebastian Riedel
18:28 GitHub195 left #mojo
18:30 tempire marty: write tests once you have a general idea of what the final design will be
18:30 tempire the tests will refine whatever design you already have in your head
18:35 tempire sri: you can split the bad guy WRITE TESTS response with me
18:35 tempire I have no problem with it
18:35 sri tempire: \o/
18:36 sri not sure yet if making all uses of syswrite more defensive was good or bad
18:37 sri but "disk full" is something that happens
18:51 mire joined #mojo
18:59 sri hmm
18:59 sri just thought about just using autodie
18:59 sri but damn… that thing loads slow
19:00 sri unti tests went from 19 seconds to 42!
19:01 sri and that was with j9
19:03 sri j1 goes from 55 seconds to 2 minutes :S
19:10 Foxcool joined #mojo
19:14 sri actually… not a single one of our "Can't open…" exceptions is tested
19:14 sri maybe that's a gsoc task
19:16 sri or get it covered with autodie
19:17 sri in case the performance issues are fixable
19:28 marcus Crab: getting better.
19:32 sri http://www.explosm.net/comics/938/ # don't remember if someone linked this already or not :)
19:33 sri we better kill marcus while he's still weakened
19:44 senf_statt_oel joined #mojo
19:47 marcus Sri: I linked it on saturday or so :)
19:47 * marcus looks forward to mutant powers.
19:47 sri oh noes
20:02 senf_statt_oel left #mojo
20:22 gabriel_ joined #mojo
20:43 sri interesting
20:44 sri for some reason there's no recursion error anymore when i keep the exception around after rendering
20:45 lukep joined #mojo
20:48 metaperl joined #mojo
20:48 GitHub5 joined #mojo
20:48 GitHub5 [mojo] kraih pushed 1 new commit to master: http://git.io/4rYR1A
20:48 GitHub5 [mojo/master] made exceptions a little more reusable - Sebastian Riedel
20:48 GitHub5 left #mojo
21:01 marcus sri: that's what the guy said in response to your comments on the previous pull request as well :)
21:01 sri marcus: it was actually still throwing errors then
21:01 marcus hmm
21:02 sri i'm not sure what changed
21:03 marcus anyways, glad it's sorted, looking forward to judofyr's airbrake plugin.
21:03 marcus guess this will make it easier for weirdos wanting json exceptions as well :)
21:04 sri he still didn't give me any feedback on request_timeout :(
21:04 marcus sri: I'll hunt him down tomorrow
21:05 sri !
21:05 marcus now it's time to inject some lovely antibiotics to my eyes and let them rest for a bit.
21:05 sri get well soon
21:10 * sri will listen to the bsg soundtrack now and hack some more
21:53 fibo joined #mojo
22:19 fibo_ joined #mojo
22:51 jnap joined #mojo
23:18 mire joined #mojo
23:20 GitHub21 joined #mojo
23:20 GitHub21 [mojo] kraih pushed 1 new commit to master: http://git.io/fxHp4w
23:20 GitHub21 [mojo/master] fixed small trim bug in Mojo::DOM - Sebastian Riedel
23:20 GitHub21 left #mojo
23:23 gabriel_ joined #mojo

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