Camelia, the Perl 6 bug

IRC log for #mojo, 2010-09-11

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

All times shown according to UTC.

Time Nick Message
00:03 keith left #mojo
00:56 Alias__ sri: The desire for a version is basically do "use Mojolicious::Lite 1.23;" works as intended
00:57 Alias__ That not only lets code confirm it's not loading the module from a wrong stale @INC location, but also lets automated dependency scanners discover the relationship
00:57 Alias__ M:I for example can automatically pick up the dep if you have a use Foo 1.23
00:58 Alias__ So any module in a distro you expect people to use XXX directly should have a version
00:59 Alias__ Downside of ditching the Mojo version is that existing code will have dependencies on it
00:59 Alias__ Since you previous HAD to set up deps on that module (because there's no version in the others)
00:59 Alias__ Finally, why do you think the newbie review of Mojo is flawed?
01:14 stephen left #mojo
02:23 keith joined #mojo
02:26 Kulag left #mojo
02:27 Kulag joined #mojo
02:31 Drossel joined #mojo
02:33 Kulag left #mojo
02:35 janus left #mojo
02:38 Kulag joined #mojo
02:41 Drossel left #mojo
02:48 janus joined #mojo
03:46 MojoGuest707 joined #mojo
03:46 MojoGuest707 From: http://www.google.com/url?sa=t&source=web&​amp;cd=5&sqi=2&ved=0CDAQFjAE&url=h​ttp%3A%2F%2Fdev.xantus.org%2F&rct=j&q=​websocket%20demo&ei=hvuKTImXPIegsQOAoomfBA​&usg=AFQjCNGw6nZv0wO42uzUnHhWcD0vcKNULg&am​p;sig2=Shixqga1RcpyiIexkICrcA&cad=rja (1 hits)
03:46 MojoGuest707 ghjkl;'
03:47 MojoGuest707 left #mojo
04:03 MojoGuest486 joined #mojo
04:03 MojoGuest486 From: http://www.google.co.in/search?hl=en&client=​firefox-a&hs=umH&rls=org.mozilla%3Aen-US​%3Aofficial&q=websocket+demo&aq=0&aq​i=g1&aql=&oq=websocket+dem&gs_rfai= (1 hits)
04:03 MojoGuest486 test
04:03 MojoGuest486 amazing demo
04:04 MojoGuest486 left #mojo
04:06 MojoGuest954 joined #mojo
04:06 MojoGuest954 From: http://news.ycombinator.com/item?id=1277067 (61 hits)
04:07 MojoGuest954 left #mojo
04:17 MojoGuest348 joined #mojo
04:17 MojoGuest348 left #mojo
04:44 yakudzo joined #mojo
05:09 Kulag left #mojo
05:12 Kulag joined #mojo
05:19 Kulag left #mojo
05:19 Kulag joined #mojo
06:32 MojoGuest465 joined #mojo
06:32 MojoGuest465 From: http://www.google.co.in/search?hl=en&client=​firefox-a&hs=umH&rls=org.mozilla%3Aen-US​%3Aofficial&q=websocket+demo&aq=0&aq​i=g1&aql=&oq=websocket+dem&gs_rfai= (2 hits)
06:32 MojoGuest465 holla
06:33 MojoGuest465 234
06:34 MojoGuest465 left #mojo
06:41 awnstudio left #mojo
06:41 awnstudio joined #mojo
07:00 awnstudio left #mojo
07:13 MojoGuest89 joined #mojo
07:13 MojoGuest89 From: http://www.google.com/search?client=safari&r​ls=en&q=html5+irc&ie=UTF-8&oe=UTF-8 (1 hits)
07:13 MojoGuest89 left #mojo
07:17 janus moin
07:43 ptomli joined #mojo
07:44 ptomli morning
07:52 ashleydev left #mojo
07:57 ashleydev_logbot left #mojo
07:59 ashleydev joined #mojo
08:05 ashleydev_logbot joined #mojo
08:17 ptomli left #mojo
08:19 ptomli joined #mojo
08:33 marcus sri:  http://www.couch.io/get#mac
08:33 marcus sri: they didn't rename the binary yet tho
08:36 ptomli marcus: is he alive yet?
08:37 marcus ptomli: unlikely
09:08 MojoGuest205 joined #mojo
09:10 MojoGuest205 left #mojo
09:10 ptomli http://github.com/kraih/mojo/issues/issue/15
09:22 ashleydev left #mojo
09:25 Alias_ left #mojo
09:27 ashleydev_logbot left #mojo
09:27 ashleydev_logbot joined #mojo
09:28 ashleydev joined #mojo
10:00 esskar__ joined #mojo
10:03 esskar_ left #mojo
10:04 esskar__ is now known as esskar_
10:13 esskar__ joined #mojo
10:18 esskar_ left #mojo
10:19 esskar__ is now known as esskar_
10:19 sri ptomli: oh, you should have just asked here instead of writing it all up
10:20 sri ptomli: changing the behavior is not possible, too many apps depend on it
10:20 ptomli it was very quiet, i though it would be easier to get a coherent thought across
10:20 sri it is also the perlish way to handle it
10:20 MojoGuest277 joined #mojo
10:20 MojoGuest277 From: http://www.google.com/url?sa=t&source=we​b&cd=3&ved=0CCIQFjAC&url=http%3A​%2F%2Fdev.xantus.org%2F&rct=j&q=webs​ocket%20demo&ei=41eLTLX7IZ-J4ga4y-27Cg&a​mp;usg=AFQjCNGw6nZv0wO42uzUnHhWcD0vcKNULg&am​p;sig2=Mcj63oYY8XiiLYdlWrkAVg&cad=rja (1 hits)
10:21 MojoGuest277 left #mojo
10:21 MojoGuest277 joined #mojo
10:21 MojoGuest277 From: http://www.google.com/url?sa=t&source=we​b&cd=3&ved=0CCIQFjAC&url=http%3A​%2F%2Fdev.xantus.org%2F&rct=j&q=webs​ocket%20demo&ei=41eLTLX7IZ-J4ga4y-27Cg&a​mp;usg=AFQjCNGw6nZv0wO42uzUnHhWcD0vcKNULg&am​p;sig2=Mcj63oYY8XiiLYdlWrkAVg&cad=rja (2 hits)
10:21 MojoGuest277 left #mojo
10:21 sri foo_bar = FooBar, foo-bar = Foo::Bar
10:22 ptomli like i said in the proposal, i don' t think that's helpful for urls though
10:22 sri this goes very deep, commands, plugins and basically everything using the camelizer use the convention
10:22 sri ptomli: it is used by many people already
10:24 ptomli i'm only talking about mapping url segments to controller names, not everything in bytestream
10:24 sri i know what you mean
10:24 sri and it is used heavily out there
10:24 ptomli example?
10:24 sri people depend on foo-bar mapping to Foo::Bar
10:25 sri example?
10:25 sri i know because i recommended it often
10:25 ptomli i'm trying to think of a case where that would be TWIM
10:25 ptomli DWIM
10:25 sri MyApp::Controller::Foo::Bar
10:26 ptomli in terms of urls
10:26 * sri can't follow
10:26 ptomli /my_app-controller-foo-bar ??
10:26 ptomli sensible looking url?
10:27 sri if you want placeholder routes to pick it up
10:27 sri you can always have more specific routes without placeholders
10:27 sri what do you propose to generate Foo::Bar?
10:28 ptomli /foo/bar ideally, but that complicates handling :action
10:28 sri thats not possible
10:28 ptomli route('/account')->to(namespace => 'Account')
10:28 sri thats not automatic
10:29 ptomli as i said, the existing mechanisms are not ideal
10:29 sri yet you can't come up with a better one :)
10:30 ptomli you think it's more normal for people to want foo-bar to map to Foo::Bar than they are to want foo-bar to map to FooBar
10:30 ptomli i can propose /foo/bar, but you say it's impossible
10:30 sri it is impossible
10:31 ptomli ok, look at it the other way..
10:31 ptomli what's more obtuse, currently trying to work around the hyphen handling, or putting waypoints to map to namespace
10:31 marcus ptomli: changing this now would break too much, for too little benefit
10:32 sri if you really want to change it, you would have to come up with a good alternative and it would have to be implemented with a 6 month deprecation period
10:32 ptomli i think the benifit, for those that want this handling (which i think would be more than you expect) is great
10:33 ptomli an alternative would be to allow _generate_class and _generate_method to use a plugin/hook/whatever to do the formatting
10:34 sri that does sound more sensible
10:34 sri requires just a clean implementation that fits in
10:35 sri making both methods public to allow overloading might be enough
10:36 sri oh and tons of unit tests would be required of course
10:37 ptomli i think if the _generate_class method called another method, instead of b(..)->camelize... that would at least make it possible in a sensible way
10:38 ptomli but would lead to the concept of people creating custom dispatchers (subclassing), which may or may not be a good idea
10:38 ptomli but works for me
10:39 ptomli or there could be a 'formatter' interface attribute that is delegated to for controller/method munging
10:42 ptomli http://pastie.org/1151841
10:43 sri object instantiation is too expensive for something so small
10:43 ptomli class method?
10:43 sri dyamic loading is required too
10:44 sri expensive
10:44 sri and it doesn't fit into the whole api
10:44 ptomli how so?
10:45 sri because it's the only one of its kind
10:45 ptomli it's to enable extension.. to allow people to decide their own mapping of url to controller/action naming
10:45 ptomli your chosen method is very expensive to work around, for those that don't want it
10:46 sri ok, but that api is not the way to deal with it
10:48 sri using a whole class just for that doesn't make any sense
10:48 sri it could have just as well been a callback
10:49 ptomli for every single route that includes hyphen? that requires individual routes per controller that matches
10:49 sri ?
10:49 ptomli or did i misunderstand, where would you have used a cb?
10:50 sri app->routes->format_controller_cb(sub {...});
10:51 ptomli ahh, i see
10:51 ptomli yes, that's better, more perl-ish ;)
10:51 sri (not that i'm convinced this is the way to go)
10:52 sri but yes, it's more perlish
10:52 * marcus just bought scfi/fantasy books for $50
10:52 marcus now I'm ready for a week offline.
10:52 omega have fun marcus :)
10:52 marcus omega: thanks. You too :)
10:53 omega marcus: I'll do my best!
10:53 omega considering food by phone for tonight :p
10:53 sri offline? Oo
10:53 marcus omega: I recommend knife and fork instad.
10:53 marcus instead
10:53 marcus sri: It's called vacation, you should try it some time.
10:53 omega well, yeah, once they deliver it :p
10:54 sri never heard of it
10:54 ptomli MojoX::Dispatcher::Routes determines what to dispatch to, so somewhere in there it needs to translate URI to perl names
10:54 ptomli i see [subclassing | delegate | callback | ..? ]
10:54 marcus sri: we've rented a small apartment in the north-east of sardinia
10:59 sri marcus: nice
11:04 sri ptomli: considering you are the first to ever request this i tend towards simple subclassing
11:06 marcus sri: action mapping isn't affected by _ / - right?
11:06 sri isn't
11:07 sri the whole thing makes me feel very uncomfortable, since it affects so much
11:07 marcus so, I don't see this as a big issue. I think in most cases where you use - in the way ptomli describes, it's the action name.
11:08 sri ->route('/foo')->to('cont-roller#action') that will also change behavior
11:08 ptomli sri: no...
11:08 sri no?
11:08 ptomli using _ will still work as expected
11:09 sri ?
11:09 ptomli marcus: the use case i have uses hyphens in controller names too, it's a bit of a problem for me right now
11:09 ptomli sri: no, i see what you're saying there
11:10 marcus ptomli: what is the url you want to dispatch to?
11:10 marcus urls even
11:10 ptomli eg: /credit/buy/first-transaction
11:10 ptomli Credit::Buy::FirstTransaction->form
11:11 ptomli just to make life interesting, i'm wanting to map GET/POST to different methods
11:12 sri there is no way to make that mapping automatic with placeholders
11:12 sri unless Credit::Buy is you app name, is it?
11:12 ptomli no
11:12 sri missing the point then, that example is impossible to generate
11:13 marcus so you probably mean MyApp::Credit::Buy::FirstTransaction->form
11:13 sri you would have to go with specific routes anyway
11:13 ptomli i was hoping to (later) see if i can get the routes to default to method names for various http methods
11:14 sri ok, time to step back then :)
11:14 ptomli i have to duck out for a while.. i guess i ought to better produce an example of what i'm trying to achive and why
11:14 sri i think what you really want is a layer above routes
11:14 sri that simply generates routes for you
11:15 * marcus heads to the airport.
11:15 sri marcus: have fun
11:15 marcus sri: don't offend the rest of the perl community while I'm gone ;-)
11:16 ptomli sri: probably
11:16 sri marcus: will try
11:16 ptomli ok, i'm outta here, play nice, i'll not be arguing for a while :P
11:16 sri :)
13:11 al left #mojo
13:12 al joined #mojo
13:47 jawnsy left #mojo
13:55 jawnsy joined #mojo
14:42 cognominal left #mojo
14:42 MojoGuest340 joined #mojo
14:42 MojoGuest340 From: http://news.ycombinator.com/item?id=1277067 (62 hits)
14:42 cognominal joined #mojo
14:42 MojoGuest340 left #mojo
14:43 MojoGuest999 joined #mojo
14:43 MojoGuest999 From: http://news.ycombinator.com/item?id=1277067 (63 hits)
14:43 MojoGuest999 left #mojo
14:46 MojoGuest762 joined #mojo
14:46 MojoGuest762 From: http://news.ycombinator.com/item?id=1277067 (64 hits)
14:48 MojoGuest762 left #mojo
14:53 awnstudio joined #mojo
15:10 awnstudio left #mojo
15:11 awnstudio joined #mojo
15:16 sri anyone encountered any weirs errors with the latest version of Mojo::Client?
15:16 sri *weird
15:18 sri i've got a strange report, the guy is even fiddling with Mojo::Client internals, so it's likely nothing unless someone else can confirm it
15:26 sri http://www.youtube.com/watch?v=hh2nLWYnxkM # WANT!
15:41 awnstudio left #mojo
15:46 tempire sri: In Mojo::DOM, you're using arrays of arrays to hold nodes.  Did you opt for them (instead of blessed objects) for performance, or just because it's what occurred to you at the time?
15:46 sri tempire: bless would be insanely expensive
15:47 sri what would be the point anyway?
15:47 tempire the code would be easier to follow, is all.
15:47 tempire I wasn't aware bless was all the expensive, though.
15:48 sri instantiating objects is sadly pretty damn expensive usually
15:48 sri and costs extra memory
15:49 sri and then you would add method calls to the mix i guess?
15:49 sri cost explosion :)
15:50 tempire Would it matter, really, since you have a blessed array for Mojo::DOM::Collection?
15:50 sri thats created on demand
15:51 sri i would rather make Mojo::DOM faster
15:52 sri recursive regex should be nice once we have 5.10
16:09 GitHub71 joined #mojo
16:09 GitHub71 mojo: master Sebastian Riedel * 607a140 (1 files in 1 dirs): show operating system in version command - http://bit.ly/aGiW9J
16:09 GitHub71 left #mojo
16:11 tempire I'm excited about hypnotoad, so I can make the ec2 plugin.
16:15 sri :)
19:06 esskar_ is there a way to extend parsing "%<some perl>" to "<spaces>%<some perl>" in templates
19:06 esskar_ or does it does mess up too much?
19:07 sri i've actually thought about that :)
19:07 sri it shouldn't mess up too much, but there is a risk that it might break apps
19:07 sri it should be actually a rather simple change
19:08 sri you got the idea from mako right? :)
19:09 esskar_ nope
19:09 esskar_ just humbeled over it
19:09 sri http://www.makotemplates.org/
19:09 esskar_ hehe
19:09 esskar_ no
19:10 esskar_ i just indend html code, and like to line up the code as well
19:12 sri i'm unsure about it, no line would be allowed to start with %
19:18 esskar_ make it an option maybe?
19:18 esskar_ that is turned on by default
19:18 esskar_ so people can turn it off, when it crushes something
19:19 esskar_ what i learned in my first real job
19:19 sri oh, that would be a very hard change
19:19 esskar_ make everything an option
19:20 esskar_ and never remove a feature, just because somebody says so; just make it an optional feature that can be turned on again ;)
19:20 sri i don't agree with that ;p
19:22 esskar_ well, depends
19:25 esskar_ .oO( will miss free home delivery from places like burger king, subway, pizza hut, .... )
19:26 sri returning to germany?
19:26 esskar_ probably
19:26 sri yea, delivery sucks here :(
19:29 esskar_ it could order just a cheeseburger, and they would bring it here
19:40 Rhaen_ joined #mojo
19:42 und3f[A] left #mojo
19:45 Rhaen left #mojo
19:45 Rhaen_ is now known as Rhaen
20:07 sri esskar: i guess we could try it
20:08 sri if people complain i'll remove it or make it optional
20:08 sri right now it even simplifies the parser :)
20:09 sri oh, and in turn we get % my $block = begin
20:09 sri % end
20:10 sri should be very pleasant to type
20:18 awnstudio joined #mojo
20:52 awnstudio left #mojo
21:03 awnstudio joined #mojo
21:11 sri esskar: it simplifies a lot :o
22:15 GitHub29 joined #mojo
22:15 GitHub29 mojo: master Sebastian Riedel * e4ed340 (8 files in 5 dirs): added experimental support for indented Perl lines in Mojo::Template - http://bit.ly/aFDBVD
22:15 GitHub29 left #mojo
22:16 sri it looks really good
22:21 perlrocks joined #mojo
22:22 perlrocks Twitter: "Added experimental support for indented perl lines in #mojolicious templates today. :) http://bit.ly/b5eGLF #perl" --kraih http://twitter.com/kraih/status/24230305107
22:31 GitHub69 joined #mojo
22:31 GitHub69 mojo: master Sebastian Riedel * 24fb7db (1 files in 1 dirs): improved test - http://bit.ly/aSEYL0
22:31 GitHub69 left #mojo
22:44 GitHub163 joined #mojo
22:44 GitHub163 mojo: master Sebastian Riedel * a865a60 (3 files in 3 dirs): improved newline handling - http://bit.ly/bG8QHk
22:44 GitHub163 left #mojo
22:50 perlrocks Twitter: "RT @kraih: Added experimental support for indented perl lines in #mojolicious templates today. :) http://bit.ly/b5eGLF #perl" --insurgentsoft http://twitter.com/insurge​ntsoft/status/24231982196
22:57 esskar_ ++
23:07 sri nice sideeffect is that begin/end now also work for perl lines
23:07 sri http://github.com/kraih/mojo/commit/e4ed34​0658a2fc0f9e68d909fda6e759c31e70de#L1R608

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