Camelia, the Perl 6 bug

IRC log for #mojo, 2011-06-22

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

All times shown according to UTC.

Time Nick Message
00:42 alnewkirk joined #mojo
00:46 alnewkirk|com left #mojo
00:46 alnewkirk is now known as alnewkirk|com
00:46 tempire left #mojo
00:47 tempire joined #mojo
00:52 alnewkirk|com left #mojo
00:54 alnewkirk|com joined #mojo
01:10 ndiewald left #mojo
01:46 Alias joined #mojo
01:53 shonorio left #mojo
02:45 perlrocks Twitter: "Train your brain with http://t.co/ILiiZZt powered my #perl #mojolicious #html5 #brain" --mkirank http://twitter.com/mkirank​/status/83364970871533568
02:48 sri heh, that looks fun
02:54 GitHub88 joined #mojo
02:54 GitHub88 [mojo] kraih pushed 1 new commit to master: http://bit.ly/iPKpD2
02:54 GitHub88 [mojo/master] removed Mojolicious::Plugin::AgentCondition and added its functionality to Mojolicious::Plugin::HeaderCondition - Sebastian Riedel
02:54 GitHub88 left #mojo
02:56 sri that's better
02:56 sri they should have used the same implementation from the start
03:06 GitHub29 joined #mojo
03:06 GitHub29 [mojo] kraih pushed 1 new commit to master: http://bit.ly/mb4VpB
03:06 GitHub29 [mojo/master] improved header condition documentation - Sebastian Riedel
03:06 GitHub29 left #mojo
03:16 GitHub43 joined #mojo
03:16 GitHub43 [mojo] kraih pushed 1 new commit to master: http://bit.ly/jKmMgd
03:16 GitHub43 [mojo/master] fixed typo - Sebastian Riedel
03:16 GitHub43 left #mojo
03:22 tempire hmm
03:22 tempire you're right, sri
03:22 * tempire fails
03:31 sri https://gist.github.com/1039455 # fast hello world hack
03:31 sri since we all need faster hello world apps all the time...
03:32 tempire google has http://www.mojolicious.org/perldo​c?Mojolicious%2FGuides%2FRouting indexed in their search results
03:32 tempire it serves a failraptor
03:32 sri \o/
03:36 * sri wonders why google ranks .org domains higher than .us
04:07 GitHub145 joined #mojo
04:07 GitHub145 [mojo] kraih pushed 1 new commit to master: http://bit.ly/kpZOx5
04:07 GitHub145 [mojo/master] added experimental host condition to Mojolicious::Plugin::HeaderCondition - Sebastian Riedel
04:07 GitHub145 left #mojo
04:12 jwang why don't you us a canonical fqdn and forward from one to the other?
04:12 jwang which ever one you want to be primary?
04:12 sri why would i?
04:12 jwang it could look like duplicate content, clone sites from google's perspective
04:13 sri i've linked them with the google webmaster tools
04:13 sri so google knows they are equal
04:13 d4rkie joined #mojo
04:14 sri last time i checked they had different pageranks though, not sure why
04:14 sri google ranks .com, .org and .net higher in general for some reason
04:15 sushi-foo joined #mojo
04:16 jwang which domain has more inbound links?
04:16 sri these days i think .us
04:19 jwang wow, quora is embedded right in google now
04:19 jwang they're really trying to make themselves more relevant
04:19 jwang social ;)
04:21 jwang sri: will you be at yapc::na?
04:21 sri nope
04:27 GitHub185 joined #mojo
04:27 GitHub185 [mojo] kraih pushed 1 new commit to master: http://bit.ly/kJBQPZ
04:27 GitHub185 [mojo/master] more documentation for conditions - Sebastian Riedel
04:27 GitHub185 left #mojo
04:28 sri hope that part about caching is easy enough to grok
04:35 sushi-foo does morbo/hypnotoad only watch certain failes? ... im wondering if the app is in a repo and i push the changes, will the manager recognize and restart
04:35 Alias left #mojo
04:35 sri hypnotoad does not watch any files, morbo behavior is mentioned in the documentation
04:36 GitHub49 joined #mojo
04:36 GitHub49 [mojo] kraih pushed 1 new commit to master: http://bit.ly/ioa9wq
04:36 GitHub49 [mojo/master] improved documentation for conditions again - Sebastian Riedel
04:36 GitHub49 left #mojo
04:37 sri i think even morbo --help has it
04:44 sri hmm, i wonder what's the better tradeoff, having route caching enabled by default and give most users more performance, or have it disabled and make all conditions just work
04:48 sri i guess keeping the current behavior is the best choice if nobody has an opinion :)
04:58 sushi-foo YES PLEASE
04:58 sushi-foo caching can really screw the pooch if you dont know its doing it
05:00 sri that's why it is now mentioned in the documentation
05:00 sri and so far it has bitten nobody at all
05:03 sri so far it's a pure theoretical problem, most of our users will never touch conditions, they are not a very popular feature
05:04 sri and more advanced features based on it like the mount plugin automatically disable caching anyway
05:06 sushi-foo i'd like to do the hot-swappable thing in production, ...
05:06 sushi-foo my own personal PaaS
05:07 sri then do it
05:07 purl hmmm... then do it is a fish.
05:08 * sri shakes purl
05:08 * purl shakes xantus
05:08 sri heh
05:09 sushi-foo sri, be nice if Mojolicious cool do it for me
05:09 sri sushi-foo: ?
05:10 sri http://mojolicio.us/perldoc/Mojol​icious/Guides/Cookbook#Hypnotoad
05:24 sri activestate is taking the personal cloud thing quite serious it seems, stackato could work out
05:26 sri reminds me so much of dotcloud, just in your own datacenter
05:36 koban joined #mojo
05:43 perlrocks Twitter: "Impressed with the first preview of #stackato, had a #mojolicious app running on a private cloud within 5 minutes. http://t.co/CWnUiqP #perl" --kraih http://twitter.com/kraih/status/83409830596972544
05:45 sushi-foo left #mojo
05:49 perlrocks Twitter: "It took longer to figure out how to install the #dotcloud client than to setup a whole #stackato private cloud. :) #perl #mojolicious" --kraih http://twitter.com/kraih/status/83411382611083264
05:51 tardisx I guess there is no hint of how much it might cost
05:52 sri i think they are not even sure if they are going to turn it into  a product
05:53 sri they also still have a lot of work to do
05:54 perlrocks Twitter: "♺ @kraih Impressed w/1st preview of #stackato, had a #mojolicious app running on a private #cloud within 5 minutes http://t.co/CWnUiqP #perl" --Metztli_IT http://twitter.com/Metztli_​IT/status/83412404939137024
05:54 tardisx I wonder how long before google stops saying "Did you mean 'staccato'?
05:57 tabbi joined #mojo
05:57 tabbi left #mojo
05:58 sri prolly a long time
06:18 perlrocks Twitter: "perl, Mojolicious and perlbrew:: Thanks to the Lite, the real work about five minutes (about 10 minutes waiting to build), made by hello world on http://localhost:3000/" (ja) --udzura http://twitter.com/udzura/status/83418622629916673
06:30 AmeliePoulain joined #mojo
06:33 sushi-foo joined #mojo
06:35 cosmincx joined #mojo
06:41 seb_ joined #mojo
06:41 seb_ left #mojo
07:22 crab hi.
07:25 sugar joined #mojo
07:45 marcus yo crab!
07:45 sri marcus: sparrow is too slow? Oo
07:46 marcus sri: Very slow when searching, sending, and checking for mail
07:46 sri what annoys me is that you can't change quoting behavior for quick answers
07:46 marcus sri: http://nordaaker.com/docs/skit​ch/Sparrow-20110622-094624.jpg
07:46 marcus I wrote that mail like 5 minutes ago.
07:46 sri never seen it take that long
07:47 sri never takes more than a second or two
07:47 marcus I've set it up with 3 gmail accounts tho. Maybe it doesn't like that
07:47 sri only one here
07:48 marcus ok, officially giving up on irc cloud. time to fire up znc again
07:49 marcus brb
07:49 marcus left #mojo
07:50 marcus joined #mojo
07:51 marcus much better!
07:54 crab what was wrong with irc cloud?
07:54 crab just out of curiosity
07:55 marcus buggy, and very slow to connect on high latency networks. Also, the pricing model is insane, so I would have to give it up once it's out of beta anyways
07:56 marcus they want 12 euros per month for more than 3 networks
07:56 marcus I'm connected to 5 networks.
08:01 GitHub110 joined #mojo
08:01 GitHub110 [mojo] kraih pushed 1 new commit to master: http://bit.ly/lS1wUE
08:01 GitHub110 [mojo/master] cleanup - Sebastian Riedel
08:01 GitHub110 left #mojo
08:13 sugar left #mojo
08:16 koban sri++ # for morbo
08:16 sri \o/
08:17 Sugar joined #mojo
08:17 spleenjack joined #mojo
08:20 arpadszasz joined #mojo
09:07 fifo joined #mojo
09:09 fmerges joined #mojo
09:11 fifo Hi. I am writing a Molicious:Liite application where I have a layout which contains a div for printing errors. They sometimes get passed via flash and sometimes via stash. Sometimes there aren't any errors. Is there a single-command to get both without having an uninitialized variable warning?
09:12 moritz % my $error = flash('error') // stash('error');
09:12 moritz if (defined $error) {
09:12 moritz ...
09:12 moritz }
09:12 moritz (infix // requires perl 5.10 or later, otherwise use || instead)
09:13 fifo Thank you! :)
09:14 moritz you're welcome
09:22 [R] is there any particular config file where I can put my options (like e.g. ldap auth server) in which I can then use in my webapp? or should I just use any other config package from cpan for such things?
09:23 sri we have two config plugins bundled
09:23 sri perl and json
09:23 sri yaml is on cpan
09:24 sri http://mojolicio.us/perldoc/Mojolicious#plugin
09:24 sri there is a list of plugins
09:25 [R] great, let me have a look into it
09:35 [R] sri: and is there already any guide on how to use mojo together with dbic?
09:36 sri not dbic specific no
09:37 sri generally you use it like you would in any other perl script
09:38 [R] hm ok
09:38 moritz [R]: I do something really simple, along the lines of:  use Mojolicious::Lite; use MySchema; my $schema = MySchema->connect; # and then I use $schema everywhere
09:39 sri i think someone was writing a plugin, but you really don't need it
09:39 moritz in a non-lite app you'd probably do that in start(), and stick it into $self somewhere
09:39 moritz where it = the schema
09:39 [R] moritz: how do you use ... that was exactly what I wanted to ask
09:39 [R] :-)
09:40 moritz [R]: but so far I haven't seen any need to move to a non-lite app
09:40 [R] because it would suck to do the connect in every handler
09:40 moritz most of the "interesting" code is part of the backend anyway, in my case
09:41 moritz or in tools that run outside of web app, and scrape other sites (or use their APIs)
09:41 Kulag left #mojo
09:42 [R] I think ::Lite is not what I'm looking for. I need to plan a huge webapp.
09:43 [R] and I cosider using mojo
09:43 sri the growing guide should give you a good overview
09:43 sri but do not skip the lite tutorial
09:44 sri it is a prerequisite
09:44 AmeliePoulain left #mojo
09:44 sri you have to start learning ::Lite
09:45 sri it's not wasted time though, since everything you learn can be applied to normal mojolicious as well
09:45 Kulag joined #mojo
09:46 sri (i emphasize because skipping the tutorial is a common mistake)
09:47 * sri really should explain that somewhere in the documentation :S
09:48 * moritz just thought the same
09:48 sri it just doesn't seem to fit in anywhere
09:49 sri FAQ is too far away from the main docs
09:49 [R] sri: hm. okay. thanks for the hint
09:49 moritz sri: put it in Mojolicious.pm
09:49 sri nobody reads Mojolicious.pm
09:50 moritz not even those who feel that Lite is below their enterprise-architecture?
09:50 sri maybe at the top of the routing guide =head1 STOP!!!
09:50 moritz sri: Nicholas would have said "you can shorten that to 'nobody reads'" :-)
09:50 sri :)
09:50 sri very true
09:51 sri if only i could add pictures to pod
09:51 Kulag left #mojo
09:51 Kulag joined #mojo
09:52 sri everything would be so much easier to explain with stick figures
09:55 sri "Almost everything you will learn in this tutorial can also be applied to normal L<Mojolicious> applications, and it is considered a prereqisite for the guides."
09:55 sri something like that maybe?
09:56 fifo left #mojo
09:56 marcus sri: can't do stick figure ascii art?
09:57 sri ascii art is hard!
09:57 marcus o <- your ass. ( ) <- your ass if you start with mojolicious instead of lite!
09:57 Foxcool left #mojo
09:57 sri eww
09:58 marcus sure to get some attention.
09:59 [R] what's the reason behind that? why do I *have* to start with the Lite stuff when I already know it will be a large app
09:59 sri a lot of stuff is easier to explain small scale
09:59 sushi-foo left #mojo
10:00 sri and the code that matters is almost equal in both
10:00 [R] are you even able to write tests in the Lite stuff?
10:00 sri of course
10:00 [R] okay
10:00 sri in fact, ::Lite is a wrapper around normal Mojolicious
10:00 [R] I think my manager will want my team do to TDD
10:00 sri you get *everything*
10:01 [R] s/do to/to do/
10:01 sri i think you want to read the growing guide
10:01 sri it covers that
10:01 [R] looking into it right now :-)
10:02 Kulag left #mojo
10:02 Kulag joined #mojo
10:09 GitHub147 joined #mojo
10:09 GitHub147 [mojo] kraih pushed 1 new commit to master: http://bit.ly/jP5z6W
10:09 GitHub147 [mojo/master] explain how tutorial and guides are connected - Sebastian Riedel
10:09 GitHub147 left #mojo
10:09 sri hope that makes it clear
10:10 marcus sri: lite is more
10:10 Sugar|2 joined #mojo
10:10 Kulag left #mojo
10:10 marcus :)
10:11 sri ironically yes :)
10:11 sri http://mojolicio.us/perldoc#TUTORIAL # looks ok?
10:11 Kulag joined #mojo
10:11 moritz sri: s/prereqisite/prerequisite/
10:12 Sugar left #mojo
10:12 marcus looks ok
10:12 sri :S
10:12 marcus prerequisite for a dream
10:13 sri also not sure about the "You should take a look!"... maybe it needs to be emphasized more "You should definitely take a look!"
10:13 Sugar|2 is now known as Sugar
10:13 sri "JUST FUCKING READ IT ALREADY!"
10:13 marcus 'read every single byte of it!'
10:13 moritz sri: there's a reason I usually stick to simple english when writing - I know all those fancy words, but often not (reliably) how to spell them :-)
10:16 GitHub184 joined #mojo
10:16 GitHub184 [mojo] kraih pushed 1 new commit to master: http://bit.ly/l0ulHo
10:16 GitHub184 [mojo/master] fixed typo and emphasize the importance of reading the tutorial - Sebastian Riedel
10:16 GitHub184 left #mojo
10:18 Sugar who updated ff to 5 version?
10:19 sri still undecided if the "definitely" is too much
10:19 * sri updated FF
10:19 sri i mostly test with FF 6 these days though
10:19 Sugar console.info() is working fine?
10:19 sri no idea
10:21 * sri is starting to hate chrome
10:22 Kulag left #mojo
10:22 Kulag joined #mojo
11:06 arpadszasz left #mojo
11:58 toebu joined #mojo
12:00 toebu question: I am using Mojolicious::Static to serve files ... if I file does not exist it seems that the route looks for an Epl template ... instead ... how do I make it so that there is a page not found error for nonexisting files ?
12:04 koban left #mojo
12:05 sri toebu: you're talking about render_static right?
12:06 koban joined #mojo
12:07 toebu no ... I am using an extra static renderer as I am not serving these files from public/
12:07 sri ok, then i have no idea
12:08 toebu ?
12:08 toebu looking at the code it seems that $static->dispatch($self) returns undef when it was sucessful
12:15 toebu found it ... if ($static->dispatch($self)){$self​->render(status=>404,text=>'not found);}
12:24 GitHub79 joined #mojo
12:24 GitHub79 [mojo] kraih pushed 1 new commit to master: http://bit.ly/kDBDJr
12:24 GitHub79 [mojo/master] fixed render_static return value - Sebastian Riedel
12:24 GitHub79 left #mojo
12:24 sri and i've fixed render_static to allow it too
12:25 phips joined #mojo
12:28 sri hmm, documentation for Mojolicious::Static is misleading
12:30 sri damn, i hate how it works
12:32 toebu is this a general idea to have 1 for faild and undef for success ... a bit 'shell-ish'
12:34 sri leftover from a different time
12:34 toebu grin
12:34 sri we used to return false, true and exception object
12:34 toebu does the return value of a route callback matter ?
12:35 sri if it's a bridge yes
12:35 toebu it is not ... just $r->get('...' => sub { ... });
12:36 sri hmm
12:36 sri i might actually break Mojoliicous::Static->dispatch for your use case i'm afraid
12:36 toebu :-(
12:36 sri i've looked around and the behavior is untested and undocumented
12:37 sri the documented behavior actually assumes true for success
12:37 toebu :-)
12:37 toebu no problem ...  will you switch it around ?
12:38 sri still looking if it's mentioned somewhere
12:38 sri if not i will
12:38 toebu grin ... somewhere meaning documentation ?
12:39 sri ye
12:39 toebu since 'the source' has been mojos documentation for quite some time this might produce some tears I suspect
12:39 sri documented or tested and it's a feature i can't just break
12:39 toebu ok tested sounds like a good argument :-)
12:40 sri well, all changes have side effects ;)
12:40 sri and we have rather good rules for what qualifies as a feature
12:43 shonorio joined #mojo
12:44 shonorio left #mojo
12:46 elb0w wonder how much he got http://phenona.com
12:47 GitHub196 joined #mojo
12:47 GitHub196 [mojo] kraih pushed 1 new commit to master: http://bit.ly/jiIZKV
12:47 GitHub196 [mojo/master] fixed dispatcher return values - Sebastian Riedel
12:47 GitHub196 left #mojo
12:47 koban there is no env var for debuggin routes now?
12:47 sri ok, static was untested, and nobody depends on the routes dispatcher
12:48 sri koban: no
12:48 koban what a pity :(
12:48 sri koban: i want to bring it back, but not sure yet in which form
12:48 sri toebu: i'll try to release soon, so you can depend on the behavior
12:49 sri toebu: just let me know if you need it urgently
12:49 ryanc left #mojo
12:49 ryanc joined #mojo
12:50 koban print in M::Roures->_walk_stack will help me, i guess
12:55 sri actually, i think we can push a release later today
12:55 toebu cool
12:55 toebu so will you flip it round ?
12:56 sri already done
12:56 toebu ok
12:59 mattastrophe left #mojo
12:59 GitHub13 joined #mojo
12:59 GitHub13 [mojo] kraih pushed 1 new commit to master: http://bit.ly/lkhqMQ
12:59 GitHub13 [mojo/master] release preparations - Sebastian Riedel
12:59 GitHub13 left #mojo
13:00 toebu if I write a plugin and I do NOT keep it in Mojolicious::Plugin ... the documentation suggestest that mojo would go looking for it the directories specified in namespaces ... this does not seem to work ... otoh if I use the full package name and it starts with a capital letter, the plugin gets loaded properly ...
13:01 toebu could I instanciate my plugin module and just hand over the  object pointer ?
13:01 sri the described behavior is unit tested, so it should work
13:03 sri does it really say directories?
13:03 sri it would obviously be namespaces
13:03 toebu yes ... it does not say directories
13:04 sri ok, good
13:04 perlrocks Twitter: "Mojolicious 1.47 by KRAIH - http://metacpan.org/releas​e/KRAIH/Mojolicious-1.47/" --cpan_new http://twitter.com/cpan_ne​w/status/83520726174408705
13:05 toebu the problem is that mojolicious dies as it tries to load the non existing plugin from the first namespace in the list ...
13:05 toebu $self->plugins->namespaces(['​Mojolicious::Plugin','EP']);
13:05 toebu $self->plugin('doc_plugin')
13:05 toebu Can't locate object method "new" via package "Mojolicious::Plugin::DocPlugin" at /home/oetiker/checkouts/extopus/so​ftware/backend/bin/../../thirdpart​y/lib/perl5/Mojolicious/Plugins.pm line 37.
13:06 toebu the plugin is EP::DocPlugin
13:06 sri wait, which version are you using?
13:06 sri "mojo version"
13:07 toebu what does work nicely is $self->plugin(EP::DocPlugin->new) but I think it is not in the documentation
13:08 sri you just encountered an already fixed bug
13:08 sri i think... because you didn't say what mojo version
13:09 toebu yep ... I was on 1.45 ... in 1.46 it work ...
13:09 toebu what about the ->new method ... is this 'allowed' ?
13:09 sri only if it's documented or tested
13:10 sri my first guess would be no, but i don't know for sure
13:10 toebu :-(
13:11 sri that really works?
13:11 toebu yep
13:11 moritz submit a unit test and documentation :-)
13:11 toebu wait ... maybe not
13:11 sri one hell of an accidental feature
13:12 toebu it does
13:12 toebu and I think it is nice thing on top of it :-)
13:12 elb0w anyone use CUDA?
13:12 sri wow, i can see why it works
13:12 sri that's really funny
13:13 sri so many little things working together
13:13 moritz .oO( Mojolicious is an emergent system! )
13:13 sri what are the odds!
13:13 toebu maybe the same reason $ENV{MOJO_APP} = EP::MojoApp->new;
13:13 toebu this works too ...
13:14 sri you're really pushing it there :)
13:15 toebu it's just that all that magic with loading stuff on the fly is a bit much for my perlsense
13:15 sri it's actually rather sane now
13:15 toebu I am quite fond of my 'use' statements and the fact that my program will dies violently right at the start
13:16 sri when we did reloading it was absolutely insane
13:18 Foxcool joined #mojo
13:20 sri but yea, if you want an accidental feature to keep working you better send a test/documentation patch
13:23 sri it doesn't *really* really work btw. it instantiates a new object based on the old one
13:28 toebu :-(
13:29 toebu it would be nice if  it did
13:29 toebu allowing me to configure the object before handing it over
13:32 sri we allow passing a hash to register
13:33 toebu yes I know :-)
13:33 toebu just trying to find a good reason ...
13:39 sri i can only think of reasons against it
13:39 crab hey. now that --reload has gone and isn't ever coming back (right?) i can get rid of some of my horrible hacks!
13:39 sri crab: YES!
13:42 sri moritz: btw. didn't you say something about a morbo bug?
13:43 moritz sri: yes, it worked fine, but when I killed it with Ctrl+C it gave me a usage message
13:44 moritz and only quit after that
13:44 sri makes no sense
13:44 moritz correct
13:44 sri with the latest version?
13:44 moritz a development version after 1.47
13:45 moritz v1.46-7-gee0b5cf
13:45 sri 1.47 was released a few minutes ago :O
13:45 moritz 'mojo version' says  Mojolicious (1.47, Smiling Face With Sunglasses)
13:45 moritz and then
13:45 moritz Thanks for testing a development release, you are awesome
13:45 sri can you replicate it with the latest one?
13:45 moritz so I assumed it's a git version after 1.47
13:46 moritz I'll try
13:46 sri some early 1.46 could have had a bug like that
13:47 mattastrophe joined #mojo
13:47 sri for the latest i can't really imagine a way to trigger that
13:50 moritz but it's still there
13:50 sri Oo
13:50 sri operating system?
13:50 purl somebody said operating system was generally only as good as the people who use it.
13:51 moritz debian stable
13:51 purl rumour has it debian stable is hopelessly broken wrt any software that does not have a separate "stable" (more like stale) bugfixing branch. This includes nearly 100% of CPAN
13:51 moritz on amd64
13:51 moritz with a perlbrew'ed perl 5.14.1
13:51 sri how did you start morbo?
13:51 moritz morbo web/quelology
13:52 moritz http://nopaste.snit.ch/53894
13:52 sri wow
13:52 crab doesn't happen for me with ubuntu 11.04 and perl 5.12.3 on x86_64
13:53 sri can't replicate on os x or ubuntu either
13:54 moritz just tried it with  perl -MCarp::Always `which morbo` web/quelology
13:54 moritz same thing, so no exceptions involved
13:55 sri maybe your computer is haunted or so
13:55 Akron joined #mojo
13:58 moritz weird: the usage message only occurs in a die()
13:58 moritz and if I just do perl -MCarp::Always -e 'die "foo\n"', it appends the line info
13:58 moritz hm... does morbo fork?
13:58 moritz or exec a new perl?
14:05 sri of course
14:06 moritz ah, that's where it loses the Carp::Always
14:06 D4RK-PH0ENiX joined #mojo
14:07 sri i don't see a connection
14:07 moritz if it starts a new perl, it won't have Carp::Always loaded
14:08 sri what would carp always tell us?
14:08 moritz the backtrace
14:08 purl the backtrace is not sufficient?
14:08 sri https://github.com/kraih/mojo/blob/m​aster/lib/Mojo/Server/Morbo.pm#L117
14:09 sri i don't see how a worker could get out of there
14:09 d4rkie left #mojo
14:09 sri basically your CORE::exit would have to be screwed
14:10 moritz dunno if DBIx::Class does that
14:10 moritz or there could be a DESTROY method that does something nasty, or an END block
14:10 sri https://github.com/kraih/mojo/blob/​master/lib/Mojo/Server/Morbo.pm#L35
14:10 sri manager can't get out either
14:10 moritz if I start with MORBO_DEBUG=1, I get a "WORKER STOPPED 7763" after the backtrace
14:11 sri smells like your code redefines CORE::exit
14:11 toebu left #mojo
14:12 sri or actually
14:12 sri your code does an exec
14:13 sri on $0
14:13 sri that's the only way to trigger the message
14:13 * moritz greps
14:13 sri https://github.com/kraih/mojo​/blob/master/script/morbo#L57
14:14 sri because that's where we are already
14:14 moritz oh, fun
14:14 sri morbo only forks, no exec
14:14 moritz I still have an old restart hack in my code
14:14 moritz $SIG{INT} = sub { $schema->storage->disconnect; exec $^X, $0, @ARGV };
14:15 sri lol
14:15 moritz that would explain it, no? :-)
14:15 sri ye
14:15 * sri pushes moritz into the alligator pit
14:15 moritz what's wrong? the documentation doesn't say you shouldn't write your own SIGINT handlers
14:16 sri well, *you* send a sigint when you hit ctrl-c
14:17 moritz so morbo's handler is never run?
14:17 sri nope, it's just a precaution
14:17 sri we stick with TERM
14:17 moritz ok
14:18 moritz with the hack removed, the usage message is gone too
14:18 perlrocks Twitter: "specifications changed so opposite MojoX return dispatcher mojolicious v1.47:: the updated Tusu # mojolicious" (ja) --jamadam http://twitter.com/jamadam​/status/83539308019064832
14:18 moritz still get the WORKER STOPPED, but I guess that's by design?
14:18 d4rkie joined #mojo
14:18 sri very much intended
14:18 moritz great
14:19 moritz what's the recommended way to terminate db connections in a lite app?
14:19 cosmincx left #mojo
14:19 sri DESTROY?
14:19 purl DESTROY is probably called by perl
14:20 cosmincx joined #mojo
14:20 * sri pats purl
14:20 * purl purrs
14:21 D4RK-PH0ENiX left #mojo
14:24 elb0w sri: wheres the raptor?
14:24 purl rumour has it the raptor is _really_ nice
14:24 elb0w for perl logo
14:24 sri https://github.com/kraih/perl-raptor
14:25 elb0w Hey we have a Raptor too! http://posterous.com/getfile/files.post​erous.com/temp-2011-02-27/HujcGbcigkGnh​vdesmEhzmophojlDIdJCHtAHaodIwnGyrCttcJs​yDdIcDjx/perl5logo.png.scaled1000.png
14:25 elb0w whoops wrong chan
14:25 elb0w haha
14:25 elb0w someones talkin ish on the camel
14:25 sri heh
14:26 elb0w think im gonna get a raptor logo for my macbook pro
14:27 sri reminds me to add stickers to the shop
14:27 elb0w ya decals
14:27 elb0w go go
14:28 sushi-foo joined #mojo
14:28 elb0w oh hekll yeah
14:28 elb0w im buying a perl 5 raptor hoody
14:28 elb0w oh
14:28 elb0w my god theres a fuckin timbuk2 bag
14:28 elb0w i just bought one
14:28 elb0w would of totally gotten this
14:29 elb0w sri wtf man, Y U NO TELL ME
14:29 elb0w :)
14:29 sri the hoody rocks, print quality is awesome
14:29 sri flock print
14:30 elb0w Get a US store
14:30 elb0w oh
14:30 elb0w there is one
14:30 elb0w aha
14:30 sri ;p
14:31 elb0w zipper hoody is nice
14:32 elb0w hows the laptop sleeve?
14:32 sri not seen one yet
14:32 elb0w gonna buy a t-shirt probably grab hoody when it gets cold
14:32 sri i just have a dozen t-shirts and hoodies
14:34 elb0w 24 dollars for a tshirt
14:34 elb0w my god
14:34 sri it's not cafepress garbage
14:34 elb0w haha
14:35 elb0w no worries
14:35 sri their selection is also not big
14:35 purl okay, sri.
14:35 sri but they have the best print quality by far
14:37 sri not even stickers in the us store
14:37 sri :S
14:37 sri but multiple bandanas
14:41 stephan48 left #mojo
14:41 stephan48 joined #mojo
14:42 sushi-foo left #mojo
14:50 koban left #mojo
14:57 ph1g joined #mojo
14:58 sherr_ left #mojo
15:00 ysyrota joined #mojo
15:01 metaperl joined #mojo
15:06 marcus sri: can you have more than one worker with morbo?
15:06 sri marcus: of course not
15:08 sri making that thing portable was enough trouble, i really don't want to maintain a production server for windows...
15:09 sri nobody should ever think about using morbo in production
15:10 kaare joined #mojo
15:14 marcus I've had the need a couple of times in development, for doing a request from a request.
15:14 marcus but it's easy enough to test with hypnotoad
15:15 cosmincx left #mojo
15:16 Sugar left #mojo
15:17 sri marcus: i'm not sure what you mean
15:17 marcus sri: if you have a single threaded server, and you do a request to another url on the same single threaded server from a request, it will stall
15:18 sri morbo is not some garbage hack like the catalyst dev server
15:18 sri it's just the same as the old dev server
15:18 marcus so you're saying it won't stall because of the ioloop?
15:19 sri even in hypnotoad you don't know which process will handle the second request
15:19 sri you could theoretically stall it too
15:19 sri i'm saying you should do it async
15:20 marcus sri: really? I thought it worked like a queue, with a free process picking the next one?
15:20 marcus like a fcgi daemon works..
15:20 sri nope
15:20 sri it's a pool of normal async daemons
15:21 sri the point is to work just like the normal daemon would, just scale better
15:22 sri if it worked like fcgi supporting websockets would be pretty fatal :)
15:23 sri however
15:24 sri marcus: you can tune hypnotoad to do that
15:24 sri http://mojolicio.us/perldoc/M​ojo/Server/Hypnotoad#clients
15:24 sri setting that to 1
15:25 sri will turn hypnotoad into an apache clone
15:28 kmx left #mojo
15:28 marcus sri: don't think I'll do that =)
15:29 marcus sri: but how are requests distributed to the pool?
15:29 sri there is a lock only one can have
15:30 sri requests are generally well distributed, but it is random
15:31 sri not totally random, but random enough to shoot yourself in the foot
15:31 sri the lock is actually not even necessary, we use it as an optimization
15:32 sri the operating system would be able to handle it too, but then the thundering herd problem can pop up
15:34 lammel joined #mojo
15:36 sri think it's called an accept mutex
15:36 Akron left #mojo
15:38 sri we do it much like nginx
15:42 sri http://imjustcreative.tumblr.com/post/675499825​1/sean-connery-responds-to-steve-jobs-by-letter # lol
15:51 marcus poor steve
15:59 marcus http://eremita.di.uminho.pt/~ambs/dancer/
15:59 marcus hmm, maybe I should check Mojolicious for kicks
16:04 sri sure
16:05 sri the whole commands stuff has no coverage though
16:05 marcus kinda hard to test it, I guess. or not very useful
16:06 marcus woot, devel::cover getting a ton of failures in mojo/template.t
16:06 sri :)
16:06 marcus online tests fail too, because of google.no vs google.de
16:06 sri testing the helper methods in Mojo::Command should be a good and rather easy start
16:07 sri yea, online tests are unreliable
16:07 marcus trusting google is seldom a good idea.
16:07 sri who can you trust online? ;p
16:08 sri ioloop online tests also fail sometimes due to very dynamic google dns
16:08 marcus nigerians :)
16:09 ysyrota left #mojo
16:09 sri sounds good
16:10 marcus http://paste.scsys.co.uk/115215 <- devel cover fuckups in template
16:11 sri ah, the new template name tests
16:11 marcus sri: http://nordaaker.com/docs/coverage.html
16:12 sri not bad
16:12 sri haha, Mojo::Asset is pretty much empty
16:12 marcus copied over the css file too to give more color
16:13 sri no big surprises
16:14 sri the optional ones and commands
16:14 sri some are weird though, like the plugins
16:14 sri they should have very good tests
16:18 sri btw. Mojo::Command tests have been started, if anyone feels like doing something useful
16:18 sri https://github.com/kraih/mojo​/blob/master/t/mojo/command.t
16:20 sri can get quite tricky though
16:21 fmerges left #mojo
16:23 kaare left #mojo
16:27 sri actually, i'll give it a shot
16:40 trone_ joined #mojo
16:41 marcus seen chansen?
16:41 purl chansen was last seen on #perl 4 days, 20 hours, 16 minutes and 32 seconds ago, saying: claes++  [Jun 17 20:25:10 2011]
16:42 marcus still recovering from NPW I guess =)
16:44 trone left #mojo
16:49 tempire huh
16:50 tempire the timbuk2 bag looks decent
16:50 tempire eck, only the europe one, though
16:51 tempire A blanket!
16:51 GitHub138 joined #mojo
16:51 GitHub138 [mojo] kraih pushed 1 new commit to master: http://bit.ly/isM4Qe
16:51 GitHub138 [mojo/master] added many Mojo::Command tests - Sebastian Riedel
16:51 GitHub138 left #mojo
16:51 sri that actually wasn't too bad
16:51 sri now they just have to work portably
16:52 sri just the actual commands left then
16:53 sri almost 1000 LoC more in t than in lib :)
16:54 elb0w sri: ever use voltdb?
16:55 sri i'm not much into sql anymore
16:55 elb0w KV?
16:55 purl KV is the right method to use to get all the key/value pairs, yes?
16:55 sri and document databases
16:56 sri if i touch sql it's usually postgresql
16:58 sri related quote "You know it's time for a vacation when you look at your kids and wonder if they'd fit better in MongoDB or MySQL."
16:58 Akron joined #mojo
17:01 sri https://github.com/blog/878​-announcing-github-for-mac # ooooooh
17:01 sri http://mac.github.com/
17:06 stephan48 hi Akron
17:06 Akron hi stephan48!
17:06 purl hi stephan48 is getting these errors when i try to install the current moose(during tests) http://abc123.pastebin.com/d273dfec0
17:06 stephan48 purl: forget hi stephan48
17:06 purl stephan48: I forgot hi stephan48
17:07 ph1g left #mojo
17:07 Akron Nice debugging policy - make purl forget about it.
17:08 sri https://www.dotcloud.com/pricing/ # wow, they are keeping a free plan
17:08 stephan48 yap
17:08 stephan48 what purl dont know isnt important...
17:09 sri hmm, from $0 to $99 is steep
17:09 stephan48 ye
17:11 moritz doesn't sound like you can do much with the free plan
17:12 moritz one programming language and 10MB of DB
17:12 moritz that#s probably a feature
17:15 sri beta testers get a free paid account, fun
17:15 moritz now I'm doubly crossed that I signed up, but never got an invitation
17:16 moritz anyway, time to cross the pouring rain to buy some food
17:17 sri you should have poked miyagawa
17:18 stephan48 sri: paid account? for how long?
17:18 sri don't ask me
17:21 sh9 joined #mojo
17:24 Kulag left #mojo
17:24 Kulag joined #mojo
17:30 Drossel joined #mojo
17:32 Kulag left #mojo
17:34 Drossel left #mojo
17:36 Kulag joined #mojo
17:37 ph1g joined #mojo
17:42 elb0w pretty sure no one uses volt db
17:54 Drossel joined #mojo
17:56 Akron left #mojo
17:57 Kulag left #mojo
18:02 Drossel left #mojo
18:02 Kulag joined #mojo
18:08 crab there's a lot of resistance to it?
18:08 crab maybe the current version is better
18:11 Drossel joined #mojo
18:13 Kulag left #mojo
18:17 Kulag joined #mojo
18:18 Drossel left #mojo
18:24 Kulag left #mojo
18:24 Kulag joined #mojo
18:36 Kulag left #mojo
19:00 Kulag joined #mojo
19:07 sh9 left #mojo
19:13 tabbi joined #mojo
19:13 tabbi left #mojo
19:24 sri marcus: have to agree about mac github, feels like a beta
19:27 elb0w I am against repo gui's
19:28 moritz is that, like, a mixture of a git gui and the github website?
19:33 elb0w sri: what kv do you favor?
19:37 trone_ is now known as trone
20:00 stephen left #mojo
20:02 stephen joined #mojo
20:22 ph1g left #mojo
20:23 arpadszasz joined #mojo
20:25 lammel left #mojo
20:27 spleenjack left #mojo
20:27 ph1g joined #mojo
20:45 shonorio joined #mojo
20:56 ph1g ls
20:58 robblahblah joined #mojo
21:00 robblahblah ... anticipating the upcoming book on mojolicious
21:01 tempire I read up on voltdb
21:01 tempire sounds horrible
21:01 tempire the worst of both worlds
21:01 metaperl lol
21:02 ph1g left #mojo
21:02 tempire who do we spam @ o'reilly to sponsor a mojolicious book?
21:04 robblahblah when you figure that out let me know, im in
21:05 tempire let's brainstorm on what would be in a book, so I can say we've started the process.
21:05 tempire brainstorm.
21:05 tempire go.
21:05 tempire *swoosh*
21:05 tempire *cerebellum thunder crash*
21:06 tempire actually, I guess a sponsor isn't really needed
21:06 tempire did chromatic have a sponsor?
21:07 metaperl ask Dave Rolsky
21:07 metaperl he wrote the Mason book
21:08 robblahblah chapter 1 - how mojolicious save my marriage
21:08 metaperl lol
21:10 tempire I'm not sure there's a need for a mojo book, on second thought.
21:10 tempire All the information is readily available.
21:10 tempire Maybe a cookbook.
21:10 tempire I suppose a book would help designate the order of the information, and back-contribute to the layout of the info on the website
21:10 robblahblah is now known as alnewkirk
21:11 tempire And mojo is cutting edge, so the book would have to be constantly updated
21:11 * tempire slices
21:11 alnewkirk Yup and yup
21:11 tempire Hmm
21:11 tempire the current docs and site are all in pod format.
21:12 tempire That could be refactored a bit & be exported into pdf for a different method of consumption
21:12 alnewkirk That bit is more truer than the oth ers
21:12 alnewkirk warmer
21:28 tempire woah
21:28 tempire github:mac
21:28 tempire neat
21:46 mattastrophe left #mojo
21:53 perlrocks Twitter: "For some reason looking at #Mojolicious::Lite just made me understand what people have been saying for so long: The Internet ≠ web pages." --hiremebcimsmart http://twitter.com/hiremebcims​mart/status/83653858861133824
22:04 alnewkirk left #mojo
22:05 D4RK-PH0ENiX joined #mojo
22:06 d4rkie left #mojo
22:15 shonorio left #mojo
22:27 marcus The internet is for porn!
22:31 d4rkie joined #mojo
22:34 D4RK-PH0ENiX left #mojo
22:43 metaperl left #mojo
23:08 metaperl joined #mojo
23:33 arpadszasz left #mojo
23:40 ashleydev left #mojo
23:51 jamesw joined #mojo
23:54 perlrocks Twitter: "Mojolicious Public website http://mojolicio.us/ framework for Perl" (ja) --PerlCafe http://twitter.com/PerlCaf​e/status/83684406342070273
23:56 xantus[] #!/usr/bin/perl
23:56 purl i think #!/usr/bin/perl is wrong
23:56 xantus[] use strict; use warnings;
23:56 xantus[] # git clone git://github.com/kraih/mojo.git
23:56 xantus[] use FindBin;
23:56 xantus[] use lib "$FindBin::Bin/mojo/lib";
23:56 xantus[] # http://mojolicio.us/
23:56 xantus[] use Mojo::UserAgent;
23:56 xantus[] use Data::Dumper;
23:56 xantus[] my $couch = 'http://127.0.0.1:5984/';
23:56 xantus[] my $ua = Mojo::UserAgent->new;
23:56 xantus[] my $json = $ua->get( $couch )->res->json;
23:56 xantus[] sub dumper { print Data::Dumper->new([@_])->Maxdept​h(4)->Indent(1)->Terse(1)->Dump };
23:56 xantus[] # db version
23:56 xantus[] dumper( $json );
23:56 xantus[] # create test db
23:56 xantus[] my $create = $ua->put( $couch.'/test' )->res->json;
23:56 xantus[] dumper( $create );
23:56 xantus[] my $doc = { foo => 'bar' };
23:56 xantus[] # put a doc into the test db
23:56 xantus[] my $r = $ua->post( $couch.'/test' => { 'Content-Type' => 'application/json' } => Mojo::JSON->encode($doc) )->res->json;
23:56 xantus[] dumper( $r );
23:57 xantus[] # success
23:57 xantus[] if ( $r->{_id} ) {
23:57 xantus[] # copy _id and _rev
23:57 xantus[] # the result has our _id auto generated for us
23:57 xantus[] @$doc{qw( _id _rev )} = @$r{qw( _id _rev )};
23:57 xantus[] $doc->{mojolicious} = 'awesome';
23:57 xantus[] # update the doc in the db
23:57 xantus[] $doc = $ua->post( $couch.'/test' => { 'Content-Type' => 'application/json' } => Mojo::JSON->encode($doc) )->res->json;
23:57 xantus[] dumper( $doc );
23:57 xantus[] # pull it back out
23:57 xantus[] $r = $ua->get( $couch.'/test/'.$doc->{_id} )->res->json;
23:57 xantus[] dumper( $r );
23:57 xantus[] }
23:57 xantus[] oh shit
23:57 xantus[] soooo sorry
23:57 xantus[] I meant to paste this: https://github.com/kraih/mojo/wiki/Using-couchdb
23:57 xantus[] I'm surprised irssi let me paste that

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