Camelia, the Perl 6 bug

IRC log for #mojo, 2013-10-21

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

All times shown according to UTC.

Time Nick Message
00:00 saurabh_abhishek joined #mojo
00:09 saurabh_abhishek joined #mojo
00:09 good_news_everyone joined #mojo
00:09 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/PzfDZw
00:09 good_news_everyone mojo/master 6608fc3 Sebastian Riedel: slightly more consistent error handling
00:09 good_news_everyone left #mojo
00:16 saurabh_abhishek joined #mojo
00:37 saurabh_abhishek joined #mojo
00:51 bpmedley_ joined #mojo
00:53 phillipadsmith joined #mojo
01:03 laouji joined #mojo
01:58 d4rkie joined #mojo
02:12 hlin joined #mojo
02:27 KindOne joined #mojo
03:03 KindTwo joined #mojo
03:05 keedi joined #mojo
03:39 preflex_ joined #mojo
03:45 SmokeMachine joined #mojo
04:30 dqw18 joined #mojo
05:09 Eugene joined #mojo
05:11 tiejl joined #mojo
05:26 rem_lex joined #mojo
05:43 tiejl_ joined #mojo
06:03 tiejl joined #mojo
06:17 denis_boyun joined #mojo
06:18 Vandal joined #mojo
06:19 tiejl_ joined #mojo
06:26 dpetrov_ joined #mojo
06:52 alnewkirk joined #mojo
06:56 hrupp left #mojo
07:00 b_leroch joined #mojo
07:01 Eugene joined #mojo
07:09 Lee joined #mojo
07:13 alnewkirk joined #mojo
07:21 KindOne joined #mojo
07:26 tiejl_ joined #mojo
07:31 basiliscos joined #mojo
07:48 tianon joined #mojo
07:58 tiejl_ joined #mojo
07:58 trone joined #mojo
08:14 themage joined #mojo
08:16 iSlug joined #mojo
08:24 mire joined #mojo
08:52 highflying joined #mojo
09:16 basic6_ joined #mojo
09:28 jpn joined #mojo
09:36 ver joined #mojo
09:37 iSlug joined #mojo
09:44 dod joined #mojo
09:54 denisboyun joined #mojo
10:04 memowe_ joined #mojo
10:21 tianon joined #mojo
10:22 asarch joined #mojo
10:24 fhelmber_ joined #mojo
11:01 iSlug joined #mojo
11:16 * sri yawns
11:40 kmx joined #mojo
13:03 good_news_everyone joined #mojo
13:03 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/Llz6SQ
13:03 good_news_everyone mojo/master e675e01 Sebastian Riedel: better descriptions for route and bridge methods
13:03 good_news_everyone left #mojo
13:09 denisboyun joined #mojo
13:14 good_news_everyone joined #mojo
13:14 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/s6eGJw
13:14 good_news_everyone mojo/master 4610f77 Sebastian Riedel: no need to mention request methods in bridge description
13:14 good_news_everyone left #mojo
13:15 iSlug joined #mojo
13:18 dqw18 joined #mojo
13:21 gtodd joined #mojo
13:31 iSlug joined #mojo
13:37 btyler joined #mojo
13:46 bluescreen joined #mojo
13:50 andrefs joined #mojo
13:52 KindTwo joined #mojo
13:58 ryozi joined #mojo
14:09 saurabh_abhishek joined #mojo
14:28 denis_boyun joined #mojo
14:30 sh4 joined #mojo
14:34 bowtie_ joined #mojo
14:37 og01 left #mojo
15:05 gryphon joined #mojo
15:27 * marcus went and tried a Tesla Model S today. So in love.
15:40 * sri heard 6% of all cars in norway are teslas :o
15:42 denisboyun joined #mojo
15:44 saurabh_abhishek joined #mojo
15:45 dqw18 joined #mojo
15:52 marcus sri: no, 6% of all cars sold in September, probably
15:53 marcus The high performance Tesla S, which went on sale in Europe in August, had a market share in Norway of 5.1 percent last month, pushing the conventionally-powered Volkswagen Golf into second place with 4.6 percent, according to the latest official figures.
15:53 marcus but of course, august was the first month they shipped
15:53 marcus so they delivered all the pre-orders 3 years back...
15:54 marcus which inflates the numbers hugely
15:56 marcus but stepping on the gas in that thing is insane
16:14 dvinciguerra_ joined #mojo
16:17 odc joined #mojo
16:28 drift joined #mojo
16:41 basiliscos joined #mojo
16:47 jpn joined #mojo
16:49 fhelmber_ joined #mojo
17:07 mire joined #mojo
17:08 iSlug joined #mojo
17:37 entro joined #mojo
17:44 dod joined #mojo
18:13 D4RK-PH0ENiX joined #mojo
18:27 d4rkie joined #mojo
18:31 mire joined #mojo
18:46 mire joined #mojo
18:51 denis_boyun joined #mojo
18:57 bluescreen joined #mojo
19:16 Mike-PerlRecruiter_ joined #mojo
19:57 abhishekisnot joined #mojo
19:58 trone joined #mojo
20:04 tempire sri: Have you thought any more about a basic pub/sub thing for mojo?
20:05 sri tempire: like?
20:06 tempire You mentioned something that would fill the gap, so that someone wouldn't have to set up something like redis for simple things.
20:06 sri no idea what you're talking about
20:07 tempire k
20:21 dvinciguerra joined #mojo
20:25 * sri wonders what a method could be called that extracts interface information such as addresses and ports from an IO::Socket object
20:27 sri this code is duplicated in Mojo::UserAgent and Mojo::Server::Daemon... https://github.com/kraih/mojo/blob​/master/lib/Mojo/UserAgent.pm#L234
20:30 bluescreen joined #mojo
20:30 bluescreen joined #mojo
20:34 lukep joined #mojo
20:34 bpmedley tempire: Are you talking about an embeddable key/value store that can be used out-of-the-box easily with Mojolicious?
20:35 sri hmm, all the proxy and header stuff could be moved from Mojo::UserAgent to Mojo::UserAgent::Transactor too
20:35 sri bpmedley: i certainly never proposed such a thing
20:35 bpmedley sri: Sorry, I wasn't trying to infer you did.  Just asking for clarificaiton.
20:37 sri could deprecate http_proxy/https_proxy/no_prox​y/detect_proxy/need_proxy/name in Mojo::UserAgent and move them all
20:37 sri aside from having to type $ua->transactor->http_proxy(...) nothing would change and the code would be cleaner
20:38 sri and you have more control over transactions, since they get built right away with all information set
20:40 bpmedley Would you condier $ua->proxy(…) that configures proxy interactions?
20:41 sri please elaborate
20:41 bpmedley A lot of the $ua config options are one level from $ua.  Such as $ua->max_redirects; $ua->cookie_jar; and $ua->cert.
20:42 bpmedley If you move $ua->*proxy* to $ua->transactor, then it might look "weird".
20:42 sri and ->proxy() would solve that how?
20:43 bpmedley https://gist.github.com/brianmed/7090642
20:44 sri that doesn't answer the question
20:44 bpmedley I just updated the gist.
20:44 sri still doesn't
20:44 bpmedley Hrmm
20:45 sri i have no clue what it actually does
20:45 bpmedley Oh, one sec.
20:45 bpmedley I was thinking of having a "proxy settings hash" or somesuch.
20:45 sri ewww
20:46 bpmedley :)
20:46 sri i'm ok with one more level for proxy config if it makes the code cleaner
20:46 sri anyone who has something against it can help with the new design or shut up
20:48 sri Mojo::UserAgent needs to be split up... arguments like "it makes the api a little more verbose" are pretty much irrelevant
20:49 bpmedley I updated the gist; thoughts on using $ua->proxy instead of $ua->transactor?
20:49 sri have you actually looked at the code?
20:50 bpmedley I have not looked at the internals much.  I'm speaking from a user point of view.
20:50 sri you're trying to solve the wrong problem
20:51 bpmedley Moment
20:54 bpmedley https://github.com/kraih/mojo/blob​/master/lib/Mojo/UserAgent.pm#L394  <-- So, you would change these to $ua->transactor->http_proxy?    And "sub need_proxy" would goto the Mojo::UserAgent::Transactor module?
20:55 sri no, all proxy code would get moved
20:55 sri including those lines
20:56 bpmedley Hrmm, I'm not sure I have the internals of Mojo::UserAgent in my brain well enough to help much with that discussion.  I've merely used it some from the user api level.
20:58 basiliscos joined #mojo
21:01 sri is $ua->proxy->http() really so much better than $ua->http_proxy and $ua->transactor->http_proxy?
21:03 sri btw. the mismatch between $ua->proxy->without() and NO_PROXY is not very nice
21:04 bpmedley I wasn't aware of the ENV var.  Definitely don't want a mis-match there.
21:05 sri also what would the description of Mojo::UserAgent::Proxy say?
21:06 tianon "Proxies are some seriously useful and irritating software."
21:06 tianon "Avoid whenever possible."
21:06 * sri sets tianon on fire
21:06 sri (again)
21:06 bpmedley If you put all the proxy code in Mojo::UserAgent::Transactor, then seems to become a catch-all.  There is redirect, tx, upgrade, and then all the proxy methods.
21:06 tianon :)
21:07 * tianon burns (again)
21:07 bpmedley Maybe there's not enough code to warrant a Mojo::Useragent::Proxy.
21:11 sri for kicks i've just pasted all the code together http://pastie.org/8419688
21:20 denis_boyun joined #mojo
21:21 bpmedley https://gist.github.com/brianmed/7091198  <-- Then, at (https://github.com/kraih/mojo/blob​/master/lib/Mojo/UserAgent.pm#L385) maybe do $self->proxy->config($ua, $tx).
21:22 sri $ua as first argument is horrible
21:22 bpmedley I agree.  Hrmm.
21:22 sri and completely unnecessary
21:22 bpmedley How to fix?
21:24 sri fix what?
21:24 fhelmber_ joined #mojo
21:25 bpmedley Oh, you're right.  I didn't even use $ua.
21:26 sri it can work just fine, the question is if it should
21:26 bpmedley Updated gist: $self->proxy->config($tx)
21:26 sri i have a complete working patch with deprecations
21:28 sri but i'm not sure if this is a good idea
21:28 bpmedley It seems your main goal is to get code of Mojo::UserAgent to make cleaner?
21:29 bpmedley code *out of
21:40 bpmedley https://github.com/kraih/mojo/blob​/master/lib/Mojo/UserAgent.pm#L196  <-- Could this be moved into $self->proxy->start?
21:40 sri how?
21:41 sri it interacts with internals all over the place
21:43 sri oh shit
21:43 sri there's something i have not considered
21:43 sri this can't be done with deprecations
21:44 sri would have to hack around with a custom Mojo::UserAgent::new to catch attribute values passed to it
21:46 sri http://pastie.org/8419772 # full patch for future reference
21:47 sri something for 5.0
21:50 sri oops... and i lost Proxy.pm...
21:51 sri not my day
21:51 bpmedley https://gist.github.com/brianmed/7091198  <-- Thoughts?
21:51 bpmedley Sounds like the proxy got set on fire.. :)
21:52 sri why do you have inject and config?
21:52 bpmedley https://gist.github.com/brianmed/7091644  <-- Is that what you're looking for?
21:53 bpmedley Doh.  I'm a doofus.  My config is not needed.
21:53 sri no, i had a finished version that actually worked for everything
21:53 sri i don't understand the start sub
21:53 sri there is just no way it could work
21:54 bpmedley Oh, I see.  It references $old.  I missed that originally.
21:54 sri and $self->{connection} and _loop and and and
21:56 bpmedley https://gist.github.com/brianmed​/7091198#file-gistfile1-txt-L56  <-- If _connect_proxy is modified like so, then wouldn't it be passed the $self->{connection} and $self->_loop?
21:56 sri that's horrible
21:56 sri you don't poke into internals of other objects
21:57 bpmedley Hrmm
21:57 sri everything has to be done with public apis
21:58 sri and those apis can't suck
21:58 bpmedley Not even a _ method?
21:58 sri not even that
21:58 bpmedley That complicates things… :)
22:07 iSlug joined #mojo
22:17 sri ah, got Proxy.pm back
22:17 sri http://pastie.org/8419842 # patch
22:17 sri http://pastie.org/8419843 # Proxy.pm
22:18 sri all tests pass with those changes
22:32 sri bpmedley: but you have a point, one reason to have a Proxy module would be to have a target for potential proxy handlers after refactoring that part of the user agent
22:34 bpmedley sri: https://gist.github.com/brianmed/7092099  <-- :)
22:36 sri well, i kinda knew that already after all the tests passed :p
22:36 bpmedley lol.. Just letting you know that there is one more data pont.
22:37 sri sure, thanks
22:38 sri i might seem grumpy, but i'm grateful you keep poking me ;)
22:38 sri grumpyness is the result of me getting a headache thinking about future user agent refactorings :S
22:44 bpmedley No, you're protecting your baby.. :)   It makes me laugh more than anything.
22:44 bpmedley Laugh in a good natured way.. ;)
23:01 good_news_everyone joined #mojo
23:01 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/ZpI9Aw
23:01 good_news_everyone mojo/master 729f59c Sebastian Riedel: added module Mojo::UserAgent::Proxy
23:01 good_news_everyone left #mojo
23:01 sri bpmedley++ # :)
23:02 bpmedley Sweet!
23:02 sri quite a bit of deprecation hacks... but it works
23:03 sri it's not a big module, but i think it encapsulates enough functionality, and there's a good chance it will grow in the future
23:04 sri the no attribute name is a bit unfortunate... but i can't think of something better
23:04 bpmedley I was thinking the same thing; however, you would have to change ENV var to be consistent - that might be a bit much.
23:05 sri the env var is a standard
23:05 bpmedley You could always use a foreign language's "no".  Like German or somesuch.
23:06 sri $ua->proxy->nein(...)?
23:06 sri Oo
23:06 bpmedley lol
23:07 sri perhaps $ua->proxy->not(...)
23:10 bpmedley $ua->proxy->direct(…)?
23:11 good_news_everyone joined #mojo
23:11 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/u30tCA
23:11 good_news_everyone mojo/master df4cf4c Sebastian Riedel: renamed no to not
23:11 good_news_everyone left #mojo
23:12 sri bpmedley: don't let me keep you from finding more stuff to move to Proxy.pm :)
23:13 bpmedley Ok.  I will continue down that path eventually.  I'm doing some work on Sparky right now.
23:16 good_news_everyone joined #mojo
23:16 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/OxLbeg
23:16 good_news_everyone mojo/master b53e075 Sebastian Riedel: updated credits
23:16 good_news_everyone left #mojo
23:17 asarch joined #mojo
23:20 sri bpmedley++ # again
23:20 bpmedley Thanks!
23:21 * sri still has no clue what to call a method that covers these two lines https://github.com/kraih/mojo/blob​/master/lib/Mojo/UserAgent.pm#L268
23:21 sri $tx->from_socket($sock) seems silly
23:23 bpmedley $tx->parse_socket($sock)?
23:23 sri actually... getting anywhere near the transaction with a socket seems like a bad idea
23:23 sri but the code needs to be shared between Mojo::UserAgent and Mojo::Server::Daemon
23:24 sri hmmm
23:24 sri after all, in the future there should be yet another layer between transactions and sockets
23:33 good_news_everyone joined #mojo
23:33 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/6QRBjw
23:33 good_news_everyone mojo/master 29815df Sebastian Riedel: more tests for transactor
23:33 good_news_everyone left #mojo
23:36 good_news_everyone joined #mojo
23:36 good_news_everyone [mojo] kraih pushed 1 new commit to master: http://git.io/MOWXVg
23:36 good_news_everyone mojo/master 2529541 Sebastian Riedel: small optimization
23:36 good_news_everyone left #mojo
23:41 basic6_ joined #mojo
23:44 saurabh_abhishek joined #mojo

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