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

IRC log for #mojo, 2014-08-25

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

All times shown according to UTC.

Time Nick Message
00:07 d4rkie joined #mojo
00:07 woz joined #mojo
00:07 woz_ joined #mojo
00:11 Averna joined #mojo
00:21 jberger I would prefer to have plugable meta handlers
00:23 jberger maybe it could iterate through handler classes until it find one that reports that it found its meta properties
00:23 d4rkie joined #mojo
00:39 woz joined #mojo
00:43 woz_ joined #mojo
00:50 disputin joined #mojo
01:04 laouji joined #mojo
01:06 aramisf joined #mojo
01:14 woz joined #mojo
01:15 woz_ joined #mojo
01:16 laouji_ joined #mojo
01:33 klapperl joined #mojo
01:37 aramisf joined #mojo
01:42 bodgix joined #mojo
01:46 woz joined #mojo
01:46 woz_ joined #mojo
02:19 woz joined #mojo
02:22 woz_ joined #mojo
02:39 noganex joined #mojo
02:53 woz joined #mojo
02:54 woz_ joined #mojo
03:22 jberger batman: a version with pluggable meta handlers: https://github.com/jberger/mojolicious-plugin-linkembedder/compare/meta_plugin
03:24 woz joined #mojo
03:25 woz_ joined #mojo
03:33 sri every time i read something about chicago on my twitter stream i keep thinking... jberger should better get out of there
03:33 tempire What's going on in chicago?
03:33 sri https://twitter.com/PzFeed/status/503743825182199810
03:33 * tempire likes chicago
03:34 sri on the plus side, at least you broke a record
03:34 tempire they were probably divergents
03:34 jberger yeah, we pretty much stay in "duck and cover" position
03:34 tempire protect the system!
03:34 jberger actually, the violence is limited to a rather small area, quite far from me
03:36 jberger but thanks for looking out for me
03:36 jberger :-)
03:37 davido_ I don't know much about Chicago.  Los Angeles, where I lived for about ten years, is a big sprawl of trouble, with nice neighborhoods sandwiched between the "average".
03:37 jberger The odd thing is that shooting almost always track with temperature
03:37 jberger number of shootings, that is
03:37 davido_ Warm = more?
03:37 jberger yea
03:38 jberger and today was a hot one
03:38 davido_ Yeah, same with places like miami.
03:38 sri maybe we should do a crowdtilt to get jberger some kevlar, just to be sure
03:38 davido_ Crime, in general, uptrends in warmer weather.
03:38 jberger there are some pretty nasty neighborhoods on the west and south sides
03:38 jberger I'm in the Northwest suburbs
03:39 * jberger would carry a tazer though, cause, tazer!
03:39 davido_ I remember a road-biking guide I had for LA... said, (approximately) "There are thousands of miles of roads in Los Angeles that are great for biking. None of them will take you through xxxxx." (I won't name the part of town)
03:40 davido_ don't taze me bro.
03:41 jberger I'm sure that bikes stay away from those neighborhoods in Chicago too
03:46 jberger I don't know what can be done for those neighborhoods though, its getting pretty bad there
03:56 woz joined #mojo
03:57 woz_ joined #mojo
03:57 * jberger sends purl to the corner of Western & Monroe
03:58 jberger that'll show him for mouthing off yesterday!
04:09 jberger People might be dropping like flies in Chicago, but you forgot to tell me about THIS!
04:09 jberger https://twitter.com/PzFeed/status/503657841501429761
04:09 * jberger loses hope
04:12 jberger and hey, at least in Chicago, the ground stays where you put it!
04:30 woz joined #mojo
04:35 irq joined #mojo
04:45 sklukin joined #mojo
04:59 laouji joined #mojo
05:00 woz joined #mojo
05:01 woz_ joined #mojo
05:12 irq joined #mojo
05:32 woz joined #mojo
05:33 woz_ joined #mojo
05:52 Nei joined #mojo
05:53 Nei stephan48: if you're curious -- http://anti.teamidiot.de/static/nei/*/Code/Irssi/teddy.tar.gz (proof of concept state)
06:04 woz joined #mojo
06:05 woz_ joined #mojo
06:06 dp_ joined #mojo
06:20 jamesaxl joined #mojo
06:35 woz joined #mojo
06:36 woz_ joined #mojo
06:40 KCL_ joined #mojo
07:01 sujithm joined #mojo
07:02 _eugen joined #mojo
07:04 sujithm joined #mojo
07:07 woz joined #mojo
07:08 woz joined #mojo
07:17 rawler joined #mojo
07:21 Vandal joined #mojo
07:23 batman sri: i don't mind you dissecting the design. i appreciate it. i hope my comments in github doesn't sound like i don't like it :(
07:25 batman jberger: https://github.com/jhthorsen/mojolicious-plugin-linkembedder/tree/feature/open-graph # i've already started. please give me pro/con on your vs mine solution
07:39 woz joined #mojo
07:40 woz_ joined #mojo
07:41 ichesnokov joined #mojo
07:57 irq joined #mojo
07:59 arthas joined #mojo
08:00 dzirtik joined #mojo
08:08 Dandre joined #mojo
08:10 woz joined #mojo
08:11 woz_ joined #mojo
08:21 noganex mh... is there a simple way to get $app->mode inside a template? or do i have to stash it
08:22 tianon can't you $c->app->mode or something?
08:22 tianon or do templates just have $app ?  I can't remember now
08:22 tianon the docs should say
08:23 tianon there's an app helper
08:23 tianon it's just app
08:23 tianon so app->mode
08:23 noganex oh. i didn't know about $c. thanks. :)
08:23 tianon http://mojolicio.us/perldoc/Mojolicious/Plugin/DefaultHelpers#app
08:23 tianon %= app->mode
08:30 noganex works fine. thanks tianon. :)
08:30 tianon :)
08:42 woz joined #mojo
08:43 woz_ joined #mojo
08:55 woz joined #mojo
09:08 d4rkie joined #mojo
09:10 sujithm joined #mojo
09:26 d4rkie joined #mojo
09:50 basiliscos joined #mojo
10:08 edestler joined #mojo
10:47 Kripton joined #mojo
10:48 dzirtik joined #mojo
10:55 Nei what's the proper way to ignore this warning: Write failed: Can't call method "_write" on an undefined value at Mojo/IOLoop/Stream.pm line 53. ?
11:05 woz joined #mojo
11:27 Nei aha, note the importance of "  && $self->{io}{$fd}; "
11:27 woz joined #mojo
11:28 Nei the read event can cancel the cb so _write mustnt be called anymore
11:32 Zx3 joined #mojo
11:44 jberger batman: i think we are going down the same path
11:45 jberger Mine does a couple things, it allows for multiple meta implementations
11:46 jberger And it falls through to the Link class when it can't find any meta info
11:49 jberger My first cut looked very much like yours
11:49 jberger But then i started thinking about how i could also add the twitter card stuff
11:50 jberger In my last branch adding twitter would be easy
11:51 jberger Also, all original tests pass in unmodified
11:54 rofl_ is there any initscript examples in contrib or smth?
12:19 sri batman: don't worry, i don't know how and patches welcome are perfectly fine responses
12:23 sri btw. the biggest problem with trying to tweak the ui is that i don't know how to run a local version
12:23 sri not very keen on setting up redis and stuff
12:26 batman jberger: i will also support twitter "stuff", it's just that i don't want to reflect that in the API. not sure why i want to know if it's a twitter card, open graph or something else (twitter_title, og_title, title,...)
12:27 batman sri: just set CONVOS_REDIS_URL=1.2.3.4:4567/14 and run bash script/test-convos-backend.sh
12:29 batman where 1.2.3.4 is URL to some free resource like http://redislabs.com/pricing
12:30 batman jberger: how do you find the correct class..?
12:34 neilhwatson joined #mojo
12:38 dod joined #mojo
12:39 sri interesting, so this will finally be in core https://metacpan.org/pod/release/PEVANS/Scalar-List-Utils-1.39_001/lib/Scalar/Util.pm#code-set_subname-name-code
12:43 sri batman: i might give it a try
12:45 sri batman: btw. another solution for the gray boxes would be to hide join/part messages by default. just like the channel log does http://irclog.perlgeek.de/mojo/2014-08-25#i_9237984
12:46 sri no need to make the text extremely gray then
12:46 jberger_ batman: did you look at the second link i sent?
12:47 jberger_ The meta_plugin branch
12:48 sri but i really don't think join/part messages need to be particularly readable, you want to notice if someone you're talking to left, but that's about it
12:50 sri haha, maybe make it smart, and only show join/part events for people that have been talking in the currently visible buffer ;p
12:52 Nei smart filter arriving in convos;)?
13:01 batman Nei: what's that?
13:01 purl that is probably what is biting you.
13:03 batman jberger_: i consider html to be a Link::Text:HTML object. not FromMetaTag. and i also want to default to fetching <title>...</title> if everything fails
13:03 Nei batman: it's a concept present in most irc clients "smart filter"
13:03 Nei about intelligently hiding joins/parts and other noise
13:03 Nei of course the web clients have yet to catch up to the traditional ones ;)))
13:03 batman sri, Nei: not sure why you want to hide part/join messages...
13:03 Nei that inevitably means you need to reinvent a lot of wheels
13:03 batman i like to know if the person i'm talking to is still in the channel
13:04 Nei they usually clutter the channel, there are better ways to convey that information
13:04 Nei many channels consist only of joins/parts obstructing the text
13:04 lipizzan joined #mojo
13:05 batman jberger_: i think your solution is too complicated. it's a design for things i don't think we need. (imo)
13:06 batman and why do you need to get() the link again? we already have the tx object from the first request (just change head() to get())
13:07 batman marcus: do you have any inputs on https://github.com/jberger/mojolicious-plugin-linkembedder/compare/meta_plugin ?
13:08 batman jberger_: i'm also not sure how the Meta classes fit into the existing hierachy :(
13:08 sri batman: THAT'S THE POINT!
13:09 batman sri: which point? (what are you referring to?)
13:09 sri batman: you only get to know if a person you are talking to leaves, but not for anyone not participating
13:09 batman i don't get it ^
13:12 batman sri: sorry for being slow. can you describe it again what the present behavior is that you want to change into...?
13:12 batman from what i read, it sounds like you want to hide the join/quit/part events
13:20 jberger_ batman: how can you know to convert to a get req before you know that you need it?
13:21 jberger_ The Meta classes are the "plugins" that know how to handle each type of meta tag
13:21 batman jberger_: oh! that's right. if i do get() before checking the response type, i might download big files...
13:21 batman i guess i need to do head() first then :/
13:22 jberger_ That's why head exists
13:22 batman but i still don't get why you need so many classes just to extract meta, title, whatever
13:22 batman but you're right about head v.s. get and the additional get
13:23 jberger_ Then one you have the dom it can delegate to each meta handler class until it finds one that reports that it can handle the data
13:23 jberger_ *once
13:23 batman i understand that. but why?
13:23 jberger_ Easy to write more handlers
13:23 batman why not just extract -whatever- in the Text/HTML.pm module?
13:24 batman i don't get how that's easier :(
13:24 batman i feel you're designing a rocket when we need a bicycle
13:26 batman i'm _not_ trying to come out as a complete tool -- i simply don't get it...
13:26 jberger_ If you just have a title extraction method and you want to extend it for another possible property, how do you do it?
13:26 batman are you asking me or some random user for LinkEmbedder?
13:27 batman i would add functionality to HTML.pm
13:27 batman if i'm a random user, i would open a ticket
13:27 jberger_ I think it become more and more complex for you and it is impossible for users
13:27 batman but why not solve it then, instead of now? in my head, it's very easy now: extract the tags that give me what i want, and store them in generic attributes
13:28 batman that means that $link->title; will hold either the value from og:title, twitter:title or the title tag
13:30 jberger_ Ok so i see you point and i think you see mine and we disagree
13:30 batman we can agree on that :)
13:30 jberger_ Guess we should wait for more input
13:30 batman i think you're trying to make this super pluggable. i'm trying to make it as simple as possible..?
13:31 jberger_ But the rest of the module is more or less pluggable right?
13:31 batman is it..?
13:31 batman i want to make something that just works. adding a bunch of if-else-when-maybe, makes it harder to maintain imo
13:31 jberger_ A handler per site?
13:32 jberger_ Become a handler per protocol
13:32 batman a handler = a class?
13:32 jberger_ Sure
13:32 batman protocol..? is og:foo and twitter:foo a protocol..?
13:33 jberger_ Yes
13:33 batman i wouldn't call it a protocol... they should provide the same type of information.
13:33 jberger_ Open graph protocol
13:33 batman if i favor og: infront of twitter:, then it shouldn't matter for the user for LinkEmbedder
13:33 batman they -should- contain the same information
13:34 jberger_ Maybe they provide the same, maybe they don't
13:34 batman no idea why twitter decided to make its own :(
13:34 batman but how will you decide which to use?
13:34 batman LinkEmbedder need to be smart, so you don't have to
13:34 jberger_ Doesn't google have one too?
13:35 batman so if you got og:video and twitter:image, but no twitter:video, then we should provide you with the best merge of all the data we can find in a given document
13:35 batman could be, then we'll just scan for those tags as well, and merge it all.
13:35 batman in a prioritized order
13:35 GabrielVieira joined #mojo
13:35 jberger_ You give it a search order, it walks them until it finds one that reports handled
13:36 jberger_ Mine is in a protected
13:36 jberger_ Grrrr
13:36 batman http://www.iacquire.com/blog/18-meta-tags-every-webpage-should-have-in-2013 <-- i would scan for something like this
13:36 jberger_ Mine is in a prioritized order
13:36 batman but you got sooo many classes and so much code. i'm don't want to maintain it all :(
13:38 jberger_ How is that not what linkembedder did for per site handling?
13:39 jberger_ A class per site
13:39 batman i got per site, because they have different content. with this i might be able to kill off some classes if they provide og:, twitter: or something similar
13:39 marcus Man you guys write a lot.
13:39 batman marcus: yeah :(
13:39 marcus Finally managed to catch up with scrollback :)
13:40 jberger_ Btw did you know i work on the same street as Wayne Enterprises?
13:40 batman jberger_: i guess i will kill your Imgur.pm module when we (i) get this og: support in place
13:40 marcus Btw, I think I agree with jberger. More pluggable is better.
13:41 batman jberger_: no, i didn't
13:41 batman marcus: for who?
13:41 purl for fun.
13:41 batman and i don't care who agree with who, i need to know which solution the super-complex code solve.
13:41 marcus batman: for users of link embedder.
13:42 marcus I don't see how it's so super-complex compared to the rest of the module.
13:42 batman if you two agree, then i guess i'm wrong. so what i need then is that you actually finish off and give it a /good/ test coverage.
13:43 batman i don't have time to maintain that code :(
13:43 jberger_ http://imgur.com/Er6SGmN
13:44 batman jberger_: i wish i had gone the way you do with delegation though.
13:45 batman not for a Link object, but for the actual LinkEmbedder module
13:46 jberger_ http://imgur.com/gfy6t43
13:49 sri you write too much
13:50 sri either convos gets a way to tell me where the new stuff starts or you need to write less ;p
13:50 batman i agree on both
13:51 sri funny thing is, you have a new message count already, not sure why you can't draw a line in front of the first
13:52 Kripton I have a problem with ordering data on a JSON output
13:53 Kripton my $data = $sth->fetchall_arrayref({}); $self->render(json => $data,status => 200);
13:53 Kripton the json output is out of order, or at least different from the sql order
13:53 Kripton there is anyway to make "order by" on the json output, or keep the same order that was on array ?
13:56 Kripton I couldn't find any clues on the documentation
13:56 sri actually, ignore my design nitpicks for now... the design is clean enough... better do real features first :)
13:57 sri maybe i'll get around to proposing a few design tweaks anyway
14:03 sri everybody +1 this issue!!!1 https://github.com/Nordaaker/convos/issues/56
14:03 sri with so many core devs using convos now, we need those markers to make sure they can keep up with the backlog :)
14:04 batman sri: i still don't understand when to clear the backlog bookmark
14:05 sri only when focus is lost again imo
14:05 woz joined #mojo
14:06 batman :wq
14:06 batman oops! :D
14:10 sri batman: added another comment https://github.com/Nordaaker/convos/issues/56#issuecomment-53268266
14:11 batman see it...
14:11 purl well, see it is REALY small
14:12 bodgix joined #mojo
14:14 sri it sounds rather minor, but helps sooo much with keeping track of the backlog, suddenly you don't have to think about where you left off
14:27 * sri stops pointing a gun at jberger
14:28 * batman starts running
14:28 batman like...i'm going running now *bbl*
14:45 woz joined #mojo
14:51 doby joined #mojo
14:57 * sri just got back from running
15:03 sri guess i won :)
15:16 woz joined #mojo
15:17 sh4 joined #mojo
15:19 dotan_dimet joined #mojo
15:20 * jberger_ lowers his point-ed stick
15:24 mr-foobar joined #mojo
15:25 * sri opens another convos issue :o
15:27 sri batman: something like this https://botbot.me/freenode/django/2014-08-25/?tz=Europe/Berlin
15:33 woz joined #mojo
15:47 basiliscos joined #mojo
15:50 sri (not the sidebar, i mean the line and date between the messages)
16:00 GabrielV_ joined #mojo
16:00 disputin joined #mojo
16:04 Gedge joined #mojo
16:09 d4rkie joined #mojo
16:19 stephan48 Nei: thanks!
16:32 irq joined #mojo
16:42 basiliscos joined #mojo
16:55 Nei enjoy;-)
17:03 jamesaxl joined #mojo
17:12 sri guess it's time to update the feature list a bit
17:13 sri "Very clean, portable and Object Oriented pure-Perl API without any hidden magic and no requirements besides Perl 5.18.0 (versions as old as 5.10.1 can be used, but may require additional CPAN modules to be installed)"
17:13 sri maybe something like that is in order now?
17:15 sri it's currently "Very clean, portable and Object Oriented pure-Perl API without any hidden magic and no requirements besides Perl 5.10.1 (although 5.18+ is recommended, and optional CPAN modules will be used to provide advanced functionality if they are installed)."
17:23 sri *crickets*
17:23 jzawodn +1
17:23 purl 1
17:24 sri i suspect that may at some point say 5.20.0, and older versions will require the signatures module from CPAN :)
17:25 jzawodn signatures++
17:30 sri it doesn't look too good anymore though... the current maintainers of signatures don't seem particularly motivated to make it happen :/
17:37 preaction joined #mojo
17:37 good_news_everyon joined #mojo
17:37 good_news_everyon [mojo] kraih pushed 1 new commit to master: http://git.io/s-zrXw
17:37 good_news_everyon mojo/master bd5b564 Sebastian Riedel: older versions of Perl now require additional CPAN modules to be installed
17:37 good_news_everyon left #mojo
17:37 basiliscos joined #mojo
17:42 dod joined #mojo
18:04 woz joined #mojo
18:08 punter joined #mojo
18:13 rwf joined #mojo
18:18 Kripton joined #mojo
18:34 woz joined #mojo
18:38 marcus +1
18:38 purl 1
18:39 marcus purl: die in a fire.
18:39 purl HALP
18:39 marcus No you're not halping.
18:39 sri botsnack
18:39 purl :)
18:39 * sri just learnd that duckduckgo has an official onion address
18:40 sri HTTP_PROXY=socks://127.0.0.1:9050 perl -Mojo -E 'say g("http://api.3g2upl4pq6kufc4m.onion/?q=mojolicious&amp;format=json")->json("/Abstract")'
18:40 marcus mojolicious on TOR
18:40 marcus finally I can shop drugs at the Silk Road in style.
18:40 sri \o/
18:42 KCL joined #mojo
18:42 disputin joined #mojo
18:44 sri the fact that a big german newspaper uses a mojolicious app for their whistleblower dead drop made me very happy
18:47 marcus yeah, that's rock and roll!
18:47 stephan48 cool
19:07 good_news_everyon joined #mojo
19:07 good_news_everyon [mojo] kraih pushed 1 new commit to master: http://git.io/x6O-Xg
19:07 good_news_everyon mojo/master 50319ad Sebastian Riedel: another Tor example
19:07 good_news_everyon left #mojo
19:08 sri the synopsis doesn't have a proxy example yet, and that one is kinda fun
19:21 dzirtik joined #mojo
19:23 basiliscos joined #mojo
19:30 dexteruk_ joined #mojo
19:30 jnbek so... since y'all are back to the frequent release cycle again, before i update my PKGBUILD, are y'all going to be releasing a version in say... the next cpl hours?
19:33 sri no plans, but you never know ;p
19:33 jnbek aye :)
19:33 jnbek last cpl times, I've updated my PKGBUILD
19:34 jnbek then in Recent on Metacpan, lol.... I see a new release
19:34 jnbek fig'd I'd dbl check and save myself some effort :-P
19:46 woz joined #mojo
20:04 sri only one feature i have currently planned, and that will be set_subname support for monkey_patch
20:05 marcus jnbek: Lots of <3 <3 <3 for the packaging work.
20:05 sri <3 <3 <3
20:06 bodgix joined #mojo
20:31 punter joined #mojo
20:34 stephan48 sri++
20:34 stephan48 i really like that example
20:46 disputin joined #mojo
20:47 woz joined #mojo
20:53 dexteruk joined #mojo
20:54 jnbek sri, sounds good
20:54 jnbek marcus: :D
20:58 batman jnbek++
21:01 batman All I want to do is hack on convos, but it looks like there won't be any hacking until Wednesday :/
21:01 batman I want so badly to make a new connection manager
21:02 batman Pease out.
21:02 batman Zzz
21:18 woz joined #mojo
21:18 neyasov joined #mojo
21:55 dexteruk joined #mojo
22:00 dexteruk joined #mojo
22:05 dexteruk joined #mojo
22:07 disputin joined #mojo
22:08 basiliscos joined #mojo
22:12 dexteruk joined #mojo
22:15 neyasov joined #mojo
22:20 woz joined #mojo
22:33 dexteruk joined #mojo
22:36 disputin joined #mojo
22:38 jberger_ "Very clean, portable and Object Oriented pure-Perl API without any hidden magic. On Perl 5.18.0 it has no requirements, versions as old as 5.10.1are supported but may require additional CPAN modules to be installed"
22:40 firnsy s/without any/with no/
22:41 dexteruk joined #mojo
22:46 neyasov joined #mojo
22:47 sri jberger_: but 5.10.1 is not "supported"
22:48 neyasov_ joined #mojo
22:49 sri "with no" does sound better though
22:49 sri even in the current version
22:49 sri "with no hidden magic and no requirements besides Perl 5.18.0"
22:51 good_news_everyon joined #mojo
22:51 good_news_everyon [mojo] kraih pushed 1 new commit to master: http://git.io/55bPOg
22:51 good_news_everyon mojo/master 41abd0f Sebastian Riedel: slightly better feature description
22:51 good_news_everyon left #mojo
22:53 sri hmm
22:53 sri batman: i didn't see a quit message for the github bot
22:54 Nei maybe it's already smart filtering
23:02 neyasov_ joined #mojo
23:03 disputin joined #mojo
23:22 d4rkie joined #mojo
23:24 woz joined #mojo
23:38 d4rkie joined #mojo
23:46 disputin joined #mojo

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