00:49:01  * perezdjoined
01:13:35  * brsonquit (Ping timeout: 240 seconds)
01:18:40  <indutny>isaacs: heya
01:18:44  <indutny>isaacs: yt?
01:23:49  * dapquit (Quit: Leaving.)
01:25:04  * kohaiquit (Remote host closed the connection)
01:27:26  * kohaijoined
01:27:51  * pieternquit (Quit: pietern)
01:39:58  * orlandovftwquit (Ping timeout: 240 seconds)
01:55:44  <isaacs>igorzi: hey, you around?
01:55:47  <isaacs>igorzi: https://gist.github.com/de3e6a83c9ece4a3affb
01:58:34  <TooTallNate>isaacs: do you have 64-bit sdk installed?
01:58:43  <isaacs>TooTallNate: guess not maybe?
01:58:46  <isaacs>hmm...
01:58:51  <TooTallNate>bert told me that just express version doesn't come with 64-bit
01:59:03  <TooTallNate>but MSVC pro does
01:59:24  <isaacs>ugh.
01:59:25  <isaacs>ok
01:59:29  <TooTallNate>but he said that if you have express installed, then to install the Windows SDK on top of that
01:59:35  <TooTallNate>lol, i haven't tried it yet
01:59:40  <isaacs>where can you get that from?
02:00:02  <TooTallNate>i think http://msdn.microsoft.com/en-gb/windowsserver/bb980924
02:01:59  <isaacs>kewl, trying that...
02:03:55  <TooTallNate>isaacs: so was that a +1 on `pty: true`?
02:04:16  <isaacs>TooTallNate: not really... i mean, it's *not* a pty
02:04:39  <isaacs>unless you share fd0 with it, in which case, isatty() returns true anyway
02:04:49  <isaacs>it seems to me like tty.isatty() should tell the trueth
02:04:52  <isaacs>*truth
02:05:41  <isaacs>TooTallNate: ah, building x64
02:05:43  <isaacs>sweet
02:05:47  <isaacs>thanks
02:05:53  <TooTallNate>nice :)
02:06:46  * AvianFluquit (Quit: Leaving)
02:09:03  <TooTallNate>isaacs: i mean this is what we've been using: https://gist.github.com/1832530
02:09:08  <TooTallNate>:O
02:09:30  <isaacs>TooTallNate: why don't you just use require("tty").spawn?
02:09:39  <TooTallNate>do we have that?!?!
02:09:48  <mmalecki>we *do*?!
02:09:53  <isaacs>oh, because it doesn't exist any more, i guess :)
02:09:57  <TooTallNate>;)
02:10:00  <isaacs>JUST KIDDING!
02:11:01  <mmalecki>I wanted it so badly
02:15:41  <TooTallNate>isaacs: i would be fine with that api over pty:true fwiw :)
02:20:18  <isaacs>LINK : fatal error LNK1181: cannot open input file 'winmm.lib' [C:\node-v0.7.4\node.vcxproj]
02:20:20  <isaacs>igorzi: ^
02:20:36  * mikealquit (Quit: Leaving.)
02:23:18  * mmaleckichanged nick to mmalecki[zzz]
02:31:03  * isaacsquit (Remote host closed the connection)
02:31:58  * dshaw_quit (Ping timeout: 240 seconds)
02:43:42  * xaqjoined
03:02:47  * orlandovftwjoined
03:10:12  * isaacsjoined
03:17:21  * isaacsquit (Remote host closed the connection)
03:32:01  * TooTallNatequit (Quit: Linkinus - http://linkinus.com)
03:34:06  * orlandovftwquit (Ping timeout: 260 seconds)
03:34:34  * AvianFlujoined
04:03:20  * mikealjoined
04:26:02  * xaqquit (Remote host closed the connection)
04:40:46  * igorziquit (Ping timeout: 245 seconds)
04:52:17  * mikealquit (Quit: Leaving.)
04:54:53  * dshaw_joined
05:00:24  * xaqjoined
05:56:45  * indexzerojoined
06:02:37  * mikealjoined
06:10:05  * xaqquit (Remote host closed the connection)
06:12:17  * xaqjoined
06:13:34  * perezdquit (Quit: perezd)
06:48:04  * orlandovftwjoined
06:50:53  * mikealquit (Quit: Leaving.)
06:52:29  * mikealjoined
06:54:48  * mikealquit (Client Quit)
07:20:10  * xaqquit (Remote host closed the connection)
07:57:14  * mikealjoined
08:05:17  * paddybyersjoined
08:36:16  * indexzeroquit (Quit: indexzero)
09:23:05  * dshaw_quit (Quit: Leaving.)
09:52:14  * orlandovftwquit (Ping timeout: 248 seconds)
10:31:08  * AndreasMadsenjoined
11:16:04  * mmalecki[zzz]changed nick to mmalecki
12:18:53  * paddybyersquit (Quit: paddybyers)
12:30:08  <AndreasMadsen>indutny: I have read the sticky-session module you made, it is very simple but it use internal API and is in general hacky. I will think about how we could do something like that without adding complexity or hacks.
12:31:39  <indutny>AndreasMadsen: hi
12:31:46  <AndreasMadsen>yo
12:31:56  <indutny>AndreasMadsen: there're no hacks actually
12:32:10  <indutny>AndreasMadsen: if you read comments, you seen that it has strong logic behind it
12:32:11  <AndreasMadsen>indutny: no you just overwrite .listen :)
12:32:16  <indutny>AndreasMadsen: ah
12:32:19  <indutny>AndreasMadsen: that's for API
12:32:23  <indutny>AndreasMadsen: I can do it w/o it
12:32:28  <indutny>AndreasMadsen: but I like it more
12:33:58  <AndreasMadsen>indutny: I was thinking about allowing sending a TCP Server and Socket object using child.send('msg', obj), but I'm not sure how it should be handled in process.on('message')
12:34:47  <indutny>AndreasMadsen: hm
12:35:01  <indutny>AndreasMadsen: yeah, passing socket as a part of API
12:35:05  <indutny>looks like a good idea
12:35:17  <indutny>you can just check (socket instanceof net.Socket)
12:35:25  <indutny>and do stuff that I do in stick-sessions
12:38:11  <AndreasMadsen>indutny: yes, in the parent, it would check using instanceof, but how should it should be handled in the child? I would make sense if the handle object was a Server or Socket instance when sending one, but I'm not sure how to recognise the difference.
12:45:29  <indutny>AndreasMadsen: ah
12:45:33  <indutny>AndreasMadsen: hm...
12:45:46  <indutny>AndreasMadsen: you can't do this now
12:45:55  <indutny>AndreasMadsen: but server socket may be internal API
12:46:04  <indutny>AndreasMadsen: and it can get handle from Socket
12:46:10  <indutny>AndreasMadsen: what do you think?
12:46:13  <indutny>but that looks hacky
12:46:29  <indutny>w/o passing additional data
12:47:12  <AndreasMadsen>indutny: I'm not sure what your question is?
12:47:52  <AndreasMadsen>indutny: also when sending a Socket instance using child.send should the handler automatically be paused and closed, or should userland do that (if so that would also add more API).
12:48:54  <AndreasMadsen>hmm, there was an API request about this, from issacs I think ... searching
12:52:37  * paddybyersjoined
12:52:52  <AndreasMadsen>https://github.com/joyent/node/issues/2585
12:52:58  <AndreasMadsen>indutny: ^
12:55:08  <AndreasMadsen>indutny: an API with child.sendServer and child.sendSocket and process.on('server') and process.on('socket') would make it possible using the internalMessage event.
12:56:17  <AndreasMadsen>or simplify it down to child.sendHandle and process.on('handle') would work to.
12:58:55  <AndreasMadsen>actually process.send('msg', Socket) would work too, but allowing a message would just add a little complexity.
13:01:06  <AndreasMadsen>hehe you could have this API: net.createServer().listen(process) in
13:01:11  <AndreasMadsen>child
13:01:55  <AndreasMadsen>but perhaps this is confusing :/
13:02:55  * bnoordhuisjoined
13:03:02  <AndreasMadsen>yo
13:03:44  <bnoordhuis>oy
13:04:48  <mmalecki>function bnoordhuis(str) { return str.reverse(); }
13:04:57  <mmalecki>also, morning.
13:05:33  <bnoordhuis>gninrom, osla!
13:05:40  <bnoordhuis>hm, sounds polish
13:05:50  <mmalecki>bnoordhuis: I'll see if there's a possibility to make boundary go into node binding, but if there's no, can we merge this in today?
13:05:54  <mmalecki>lol
13:06:09  <mmalecki>"dzień dobry" is polish for "good morning"
13:06:19  * bentkusjoined
13:06:43  <bnoordhuis>i kind of knew that, it's similar to the czech equivalent
13:07:31  <bnoordhuis>mmalecki: i think peter griess doesn't like the patch
13:08:08  <mmalecki>bnoordhuis: he's fuding
13:08:56  <bnoordhuis>he has a point in that it's something of a single use case hack
13:09:36  <bnoordhuis>it could be generalized by having something like a marker field that you zero in on_message_begin and reading it back in on_headers_complete
13:10:13  <mmalecki>bnoordhuis: knowing headers boundary is not a single use case hack
13:10:26  <bnoordhuis>tell me why
13:11:17  <bnoordhuis>i like how rustc has a --time-passes switch
13:11:30  <bnoordhuis>they could have called it --profile-phases or something
13:11:39  <mmalecki>bnoordhuis: and how can you tell lenght of headers in on_headers_complete?
13:11:43  <mmalecki>*length
13:11:43  <bnoordhuis>but --time-passes is clever and funny
13:11:43  <kohai>but has -1 beer
13:11:54  <bnoordhuis>silly kohai bot
13:11:54  <kohai>'Bot' is a derogatory term, and I'm offended.
13:11:54  <mmalecki>I never liked but anyway
13:12:35  <bnoordhuis>mmalecki: reset the marker on the first header, read it back again in on_headers_complete?
13:12:55  * piscisaureus_joined
13:13:13  <mmalecki>bnoordhuis: you mean in the parser or in node?
13:14:31  <mmalecki>bnoordhuis: I can't see how'd you be able to do that on node's side.
13:14:53  <mmalecki>unless parser->nread doesn't get reset before that
13:15:02  <bnoordhuis>mmalecki: i mean in http_parser
13:15:04  <mmalecki>but nread is a private api, iirc
13:15:23  * bentkuschanged nick to txdv
13:16:11  <mmalecki>bnoordhuis: hm, it'd allow keep alive connections as well?
13:16:28  <mmalecki>I mean, headers after body?
13:17:11  <bnoordhuis>mmalecki: er/
13:17:16  <bnoordhuis>i mean: er?
13:19:27  <mmalecki>bnoordhuis: boundary will ignore headers after body rigth now
13:19:43  <bnoordhuis>mmalecki: you mean trailing http headers?
13:19:52  <mmalecki>bnoordhuis: yeah, that was the name
13:20:16  <bnoordhuis>aside, i've always felt they're a daft concept
13:20:38  <mmalecki>yeah >.<
13:21:00  <bnoordhuis>what is your question, maciej? do you need the trailers?
13:22:17  <bnoordhuis>the weather is so shite today
13:22:19  <mmalecki>bnoordhuis: I don't feel like your method is better than mine if it still "ignores" trailers. does it do that?
13:22:24  <bnoordhuis>and i still need to do the groceries...
13:22:39  <mmalecki>I'd be more comfortable with reading code :)
13:22:49  <mmalecki>and yeah, I have to leave too, I'm late, actually
13:22:55  * felixgejoined
13:22:55  * felixgequit (Changing host)
13:22:55  * felixgejoined
13:22:58  <bnoordhuis>mmalecki: okay, we'll discuss it later today
13:23:08  <felixge>bnoordhuis: > What would that approximately look like in Node, Felix?
13:23:15  <felixge>do you mean the JS API for execSync?
13:23:18  <bnoordhuis>felixge: yes
13:23:21  <felixge>or my sub-loop implementation of it?
13:23:25  <mmalecki>bnoordhuis: ok. see you later.
13:23:39  <felixge>well the API would be similar to spawn
13:23:43  <felixge>lets say:
13:24:03  <felixge>var result = child_process.execSync('program', args, options);
13:24:18  * mmaleckichanged nick to mmalecki[away]
13:24:20  <felixge>result = {stdout: '…', stderr: '…', exitCode: 0, exitSignal: null, ...}
13:24:23  <felixge>something like that
13:24:40  <felixge>s/similar to spawn/similar to execFile/
13:24:53  <bnoordhuis>okay, now i understand why waitpid() and friends are not an option
13:25:16  <bnoordhuis>yes, that would need to be fixed in libev
13:25:21  <piscisaureus_>bnoordhuis: felixge: https://github.com/piscisaureus/libuv/commit/844312c190b3acefcd95b48fde0c223475be030e
13:25:40  <piscisaureus_>^-- that was the prototype we did at jsconf.eu
13:26:02  <felixge>piscisaureus_: cool, you found it!
13:26:14  <felixge>piscisaureus_: but that would run into the same issue eventually. no?
13:26:17  <piscisaureus_>it is outdated though
13:26:24  <piscisaureus_>but the idea is there :-)
13:26:51  <felixge>piscisaureus_: well, I'm hoping I could tackle this on an even higher level
13:27:06  <felixge>that is: uv itself wouldn't even need to implement exec_sync
13:27:19  <piscisaureus_>felixge: yep, that was the idea
13:27:22  <felixge>I'd simply re-use the async one as well as the higher level stuff in child_process.js
13:27:54  <piscisaureus_>felixge: I don't think that is really doable unless you have a really good idea for it :-)
13:28:15  <felixge>piscisaureus_: what makes you think so?
13:28:25  <piscisaureus_>felixge: that said, it doesn't have to be in libuv itself since it uses only public libuv APIs
13:28:47  <bnoordhuis>there's still the signal delivery awkwardness
13:28:54  <piscisaureus_>yes, that needs to be fixed
13:28:56  <felixge>while running the sub-loop, all the events should work normally
13:29:12  <felixge>the only difference is that only events from the sub-loop would trigger callbacks in JS
13:29:28  <piscisaureus_>felixge: ah, okay, that makes sense
13:29:29  <felixge>and from an end-user perspective the execSync() call blocks
13:29:37  <piscisaureus_>felixge: although I am afraid of it :-)
13:29:43  <felixge>piscisaureus_: hah
13:29:49  <bnoordhuis>i can see a lot of problems with that approach
13:29:55  <felixge>I find it quite an elegant hack
13:30:00  <felixge>bnoordhuis: share them
13:30:20  <bnoordhuis>how would you stop thread pool callbacks in the main loop, for example?
13:30:37  <piscisaureus_>bnoordhuis: well, that is doable. the main thread is blocked so that should not be a problem
13:31:05  <bnoordhuis>yes, but can you block it for a long time?
13:31:10  <piscisaureus_>bnoordhuis: yes, why not
13:31:18  <felixge>piscisaureus_: this is my code so far: https://github.com/felixge/node/commit/8aa7a3c38ed860ebbe933e3a4c5bd66668babf7c
13:31:23  <piscisaureus_>bnoordhuis: stuff just gets queued up
13:31:24  <bnoordhuis>seems like a good way to lose events / let a ginormous backlog build up / etc.
13:31:42  <felixge>(I agree that execFileSync looks a little hackish, but otherwise I could sleep well with this
13:31:53  <felixge>bnoordhuis: this is meant to be used within a busy server
13:32:12  <piscisaureus_>felixge: but you would have to make sure that the child pipes are also attached to the subloop
13:32:16  <felixge>it's mostly to make node a more comfortable shell scripting language
13:32:25  <felixge>where you normally want everything to be sequential
13:32:28  <piscisaureus_>felixge: otherwise read and write events are not delivered in the subloop
13:32:33  <bnoordhuis>felixge: probably you mean "is meant not to be used"?
13:32:56  <felixge>piscisaureus_: the child would be started inside the sub loop, so all the pipes should be attached to the sub loop as well
13:33:07  <felixge>bnoordhuis: yes, sorry :)
13:33:47  <felixge>bnoordhuis: Also, no matter how this is implemented, stuff would queue up in the main loop.
13:34:05  <piscisaureus_>felixge: well the pipes are created here https://github.com/felixge/node/blob/8aa7a3c38ed860ebbe933e3a4c5bd66668babf7c/lib/child_process.js#L461
13:34:10  <felixge>We could revisit the discussion on whether we want execSync in core or not
13:34:23  <felixge>but I'm fairly comfortable with it
13:34:26  <felixge>so is isaac afai
13:34:28  <felixge>* afaik
13:34:38  <piscisaureus_>felixge: which means that the pipes are attached to the main loop
13:35:01  <felixge>piscisaureus_: thanks, good pointer
13:35:06  <felixge>piscisaureus_: but seems pretty fixable
13:35:37  <piscisaureus_>felixge: you know what. You implement it, then I will break it :-)
13:35:46  <felixge>piscisaureus_: deal
13:36:07  <piscisaureus_>felixge: I can't think of anything that makes it completely unfeasible right now, but I am about as worried as Ben
13:36:09  <felixge>piscisaureus_: except for the libev signal issue: https://github.com/joyent/node/issues/1167#issuecomment-3595353
13:36:18  <piscisaureus_>yes, we should fix that
13:36:23  <felixge>that's the one I feel rather unable to tackle
13:36:36  <piscisaureus_>felixge: it is really hairy :-)
13:36:52  <felixge>with that out of the way, I'm willing to go down the sub-loop road and fight the dragons there might be
13:36:53  <felixge>:)
13:36:57  <felixge>piscisaureus_: yeah
13:37:19  <felixge>piscisaureus_: however, I'd be ok with a partial solution
13:37:30  <felixge>I mean my sub-loop only needs one and only one child process
13:37:37  <felixge>and I only need one additional sub-loop
13:37:46  <felixge>not sure if that is any help, but it could limit the problem space
13:38:12  <piscisaureus_>felixge: well you only need it in a subloop... that might help
13:38:25  <piscisaureus_>there's no risk of race conditions with signal watcher management etc
13:38:26  <felixge>in fact, I'd also be ok with an exception that is triggered when trying to call execSync while there is still an async child process running
13:38:30  <felixge>people shouldn't be doing that anyway
13:39:00  <piscisaureus_>bnoordhuis: is signalfd an unix-only concept?
13:39:01  <felixge>piscisaureus_: or in other words: I need only one "active" loop
13:39:17  <bnoordhuis>bnoordhuis: it's a linux-only concept
13:39:34  <piscisaureus_>talking to yourselves aren't youy?
13:39:51  <felixge>: p
13:40:36  <felixge>I guess there are no frozen homeless people anymore to talk to (recalling a rather awkward conversation I saw in here a while ago) : )
13:40:59  <piscisaureus_>felixge: link?
13:41:02  <piscisaureus_>I don't recall
13:42:54  <piscisaureus_>felixge: http://piscisaureus.no.de/log/2012-02-03#23:08:49.296 ?
13:46:52  <felixge>piscisaureus_: yes :)
13:46:57  <felixge>I was a bit confused
13:46:59  <felixge>when reading that
13:47:08  <felixge>I guess it was just very black humor :)
13:48:45  <felixge>anyway, back to event loops for a second. piscisaureus_ would you volunteer to have a look at the libev limitation?
13:49:06  <piscisaureus_>felixge: I volunteer
13:49:33  <piscisaureus_>felixge: but I may not get there as this involves a lot of gory unix details
13:49:46  <felixge>piscisaureus_: heh, ok
13:49:55  <felixge>piscisaureus_: I guess just update the google groups thread when you have something to try out / or any other updates.
13:50:08  <felixge>I'll post a quick update there myself now
13:50:11  <piscisaureus_>felixge: ok, good
13:52:45  <felixge>piscisaureus_: awesome, thank you so much
14:12:05  <bnoordhuis>https://github.com/joyent/http-parser/pull/91 <- *sigh*
14:15:43  <wankdanker>bnoordhuis: ha. gotta do what you gotta do. i agree with you. strict and consistent. way to be.
14:24:55  <piscisaureus_>bnoordhuis: just don't attribute the patch to this guy, and land it under your own name. This is not a "creative work" in the sense of the Berne convention.
14:25:38  <bnoordhuis>piscisaureus_: joyent's legal department is rather insistent about it
14:26:06  <bnoordhuis>where it means 'signed CLAs'
14:27:19  <piscisaureus_>bnoordhuis: this is a nice way to fuck up node.
14:27:26  <piscisaureus_>bnoordhuis: submit a pull request
14:27:37  <piscisaureus_>that does something really obivous and also important
14:27:41  <piscisaureus_>bnoordhuis: then refuse to sign the CLA
14:27:49  <piscisaureus_>so we can never have that fix
14:28:01  <piscisaureus_>bnoordhuis: what will you do if someone else supplies the same patch?
14:28:21  <bnoordhuis>someone who has signed the CLA?
14:28:25  <piscisaureus_>yes
14:28:52  <bnoordhuis>i'll probably merge it, for better or worse
14:28:54  * wankdankerquit (Read error: Connection reset by peer)
14:35:24  * wankdankerjoined
14:38:55  * bnoordhu1sjoined
14:47:16  <felixge>bnoordhuis: seems like this problem really needs to be fixed on joyents end so
14:48:17  <felixge>it seems rather ridiculous to have to implement workaround procedures for changing 5 characters in node
14:48:22  <felixge>:)
15:16:35  <bnoordhuis>felixge: agreed
15:17:00  <bnoordhuis>i blame the USA's messed up copyright and patent laws
15:23:45  * isaacsjoined
15:34:04  <piscisaureus_>bnoordhuis:
15:34:05  <piscisaureus_>> process.env['=kaas'] = 'kaas'
15:34:05  <piscisaureus_>'kaas'
15:34:05  <piscisaureus_>> process.env['=kaas']
15:34:05  <piscisaureus_>undefined
15:34:08  <piscisaureus_>is this desirable?
15:34:32  <piscisaureus_>It should throw or ignore
15:36:53  <bnoordhuis>piscisaureus_: ignore what?
15:37:01  <bnoordhuis>oh, i see what you mean
15:37:20  <bnoordhuis>that's probably a feature of setenv()
15:37:37  <piscisaureus_>bnoordhuis: no we are just ignoring the return value of setenv
15:37:57  <bnoordhuis>yes
15:38:21  <bnoordhuis>rereading it again, i don't understand what you mean by ignore :)
15:38:47  <piscisaureus_>bnoordhuis: well (process.env['=kaas'] = 'hallo') == undefined
15:38:53  <piscisaureus_>whould probably be better
15:39:25  <piscisaureus_>bnoordhuis: but imho throwing would be even better :-)
15:40:08  <bnoordhuis>well, it's a one-liner patch
15:41:00  <bnoordhuis>piscisaureus_: https://gist.github.com/21a5bca23f3a9f9aa999
15:41:30  <piscisaureus_>bnoordhuis: or `return ThrowException(Exception::New("fubar"))
15:41:55  * paddybyersquit (Quit: paddybyers)
15:42:12  <bnoordhuis>piscisaureus_: yeah, i suppose
15:42:22  * bnoordhuisdoesn't really care either way
15:45:54  <isaacs>piscisaureus_: setters in JS always return the set value
15:46:00  <isaacs>piscisaureus_: even when they don't do anything
15:46:20  <piscisaureus_>isaacs: questionable. The setter function actually returns some value
15:46:39  <piscisaureus_>isaacs: or - you mean that is how it is supposed to be?
15:47:05  <isaacs>> function foo () {}
15:47:05  <isaacs>undefined
15:47:05  <isaacs>> foo
15:47:06  <isaacs>[Function: foo]
15:47:08  <isaacs>> foo.name = 'bar'
15:47:10  <isaacs>'bar'
15:47:12  <isaacs>> foo.name
15:47:14  <isaacs>'foo'
15:47:18  <piscisaureus_>aha
15:47:37  <isaacs>so, actually, (process.env['=kaas'] = 'hallo') == undefined would be surprising and wrong.
15:47:58  <isaacs>there's precedent for *throwing* which i'd probably be ok with
15:48:07  <isaacs>but the options are either what we have, or throw an error
15:48:16  <piscisaureus_>isaacs: ok, right
15:55:12  <bnoordhuis>piscisaureus_: https://github.com/bnoordhuis/node/commit/0685707 <- review
15:55:36  <piscisaureus_>bnoordhuis: yes indeed, lgtm
15:56:14  <CIA-99>node: Ben Noordhuis v0.6 * r0685707 / (src/pipe_wrap.cc src/tcp_wrap.cc):
15:56:14  <CIA-99>node: tcp, pipe: don't assert on uv_accept() errors
15:56:14  <CIA-99>node: It's possible for a new connection to be closed in the window between the
15:56:14  <CIA-99>node: accept() syscall and the call to uv_accept(). Deal with it and move on, don't
15:56:14  <CIA-99>node: assert. - http://git.io/_2BfSw
16:00:04  <bnoordhuis>isaacs, piscisaureus_: https://github.com/bnoordhuis/node/commit/62f82f0 <- review plz
16:00:18  <bnoordhuis>that's for master btw
16:00:55  <isaacs>lgtm
16:04:02  * travis-cijoined
16:04:02  <travis-ci>[travis-ci] joyent/node#418 (v0.6 - 0685707 : Ben Noordhuis): The build was broken.
16:04:02  <travis-ci>[travis-ci] Change view : https://github.com/joyent/node/compare/14b20ff...0685707
16:04:02  <travis-ci>[travis-ci] Build details : http://travis-ci.org/joyent/node/builds/682120
16:04:02  * travis-cipart
16:04:22  <bnoordhuis>^ broken? wut?
16:04:47  <CIA-99>node: Ben Noordhuis master * r6141386 / (lib/http.js test/simple/test-http-server-multiheaders.js): http: allow multiple WWW-Authenticate headers - http://git.io/fM-SVw
16:05:15  <indutny>hohoho
16:05:26  <indutny>sorry
16:05:30  <indutny>actually I'm away
16:05:35  * indutnychanged nick to indutny_away
16:05:37  * mmalecki[away]changed nick to mmalecki
16:06:45  <mmalecki>bnoordhuis: hello.
16:08:01  <bnoordhuis>mmalecki: olleh
16:12:09  <mmalecki>bnoordhuis: sorry, I noticed some conversation about homeless people, had to read it all
16:12:35  <mmalecki>bnoordhuis: so, you basically want to "emit" a boundary after each chunk of headers?
16:13:40  <mmalecki>bnoordhuis: seems like what substizzy wants as well. I've thought about it as a next step, tho.
16:19:28  <bnoordhuis>mmalecki: i was thinking of a counter that gets updated after each byte
16:19:40  <mmalecki>bnoordhuis: ugh. that's what we do.
16:19:52  <bnoordhuis>that would allow callbacks to track where exactly in the byte stream they are
16:19:52  <mmalecki>bnoordhuis: also, you realize that doing that in node will be slow?
16:19:59  <bnoordhuis>yes
16:20:04  <bnoordhuis>so i'm not proposing to do it in node
16:20:42  * travis-cijoined
16:20:42  <travis-ci>[travis-ci] joyent/node#419 (master - 6141386 : Ben Noordhuis): The build is still failing.
16:20:42  <travis-ci>[travis-ci] Change view : https://github.com/joyent/node/compare/9a0d907...6141386
16:20:42  <travis-ci>[travis-ci] Build details : http://travis-ci.org/joyent/node/builds/682160
16:20:42  * travis-cipart
16:20:47  <mmalecki>ok, so callbacks would "mark" boundaries?
16:20:54  <bnoordhuis>yes
16:21:19  <bnoordhuis>the callee would be free to reset the byte counter
16:21:31  <mmalecki>sounds sane-ish. mind if I bring in substack?
16:21:40  <mmalecki>if he's awake, of course
16:21:44  <bnoordhuis>sure
16:21:58  <bnoordhuis>one thing though, the counter would need to be 64 bits
16:22:12  <bnoordhuis>that's a considerable memory overhead so it would have to be a #ifdef feature
16:22:23  <mmalecki>and fb guy starts fuding again :)
16:22:35  <bnoordhuis>you mean peter griess?
16:22:39  <mmalecki>yes
16:22:43  * bnoordhuisdidn't know peter worked at facebook
16:23:06  * pksunkarajoined
16:23:12  <mmalecki>ok, so it'd be enabled on node?
16:23:18  <bnoordhuis>yes
16:23:32  <bnoordhuis>provided i see the use case :)
16:23:43  <mmalecki>you know the use case.
16:24:17  <bnoordhuis>well... i know *what* you want, i'm still a tad unclear on *why* you want it
16:24:38  <mmalecki>have you read that comment Charlie made?
16:25:05  <bnoordhuis>i never read comments, i don't want my judgment clouded by facts
16:25:22  <mmalecki>lol
16:25:57  <mmalecki>I thought https://github.com/joyent/http-parser/pull/89#issuecomment-3943603 explains it quite well
16:26:24  <mmalecki>mikeal: maybe you can add something about use cases here. not sure if you want it for proxying or not
16:28:22  <bnoordhuis>mmalecki: what does a boundary let you do that http.request() or http.Server doesn't let you do?
16:28:42  <bnoordhuis>i read it as: i want the headers and i want to modify them
16:30:12  <mmalecki>bnoordhuis: sec, looking for example code indexzero put together
16:31:20  <mmalecki>ok, I guess not.
16:31:36  <mmalecki>bnoordhuis: basically, we'll be able to just use net.Server
16:31:47  <bnoordhuis>okay, and that is good why?
16:34:16  <mmalecki>argh. it's faster, less cruft, etc. when you proxy, you don't really need all the things http.Server does
16:36:32  <bnoordhuis>cruft? aw
16:37:08  <mmalecki>bnoordhuis: no offense :)
16:37:25  <mmalecki>I just see net as a better solution for proxying
16:37:47  <bnoordhuis>i kind of see that
16:38:13  <mmalecki>I'm glad you do :)
16:38:17  <bnoordhuis>you realize that depending on the parser bindings is a dangerous thing to do right?
16:38:47  <mmalecki>bnoordhuis: we like living on the edge
16:39:08  <bnoordhuis>very brave
16:39:51  <bnoordhuis>mmalecki: question: why don't you bundle your own copy of http-parser?
16:39:52  <mmalecki>bnoordhuis: I can ask Charlie to talk to you later if you feel like. he probably has more to say than I do :)
16:39:59  <mmalecki>bnoordhuis: hm.
16:40:14  <bnoordhuis>then you won't have to get past me first :)
16:40:16  <mmalecki>bnoordhuis: if it doesn't work out, we will
16:40:33  <mmalecki>bnoordhuis: but seems like other people want it as well
16:40:43  <bnoordhuis>that last comment was tongue-in-cheek
16:40:45  <mmalecki>bnoordhuis: and I've heard this http-parser thing is open source, so
16:40:53  <bnoordhuis>but what i said about the parser bindings is serious
16:41:09  <bnoordhuis>if i can shave off 2% by chopping up the bindings, i will
16:41:15  <bnoordhuis>and without regret
16:41:42  <mmalecki>uhm, what?
16:41:50  <mmalecki>how'd you even do that?
16:41:59  <tjfontaine>removing exported bindings, if that saves 2% he will
16:42:21  <bnoordhuis>^ that
16:42:26  <mmalecki>I mean. that's just insane.
16:42:53  <tjfontaine>and that's why it's dangerous to rely on private apis :)
16:43:27  <bnoordhuis>the 2% i'm talking about is performance, not e.g. file size, but the point stands
16:43:40  <mmalecki>http.parsers is public, afaik
16:43:48  <bnoordhuis>nuh-uh
16:46:50  <mmalecki>bnoordhuis: oh well.
16:47:13  <mmalecki>bnoordhuis: bundling it is not a problem for me
16:48:56  <isaacs>if just read the scrollback here. yes, if there's a 2% performance win to be had, i 100% support bnoordhuis in doing what we need to in order to make that happen.
16:49:04  <isaacs>*i just read, not "if just read"
16:49:42  <mmalecki>I don't see how removing process.bindings would cause any performance win
16:50:00  <isaacs>mmalecki: it's more a principle.
16:50:08  <AvianFlu>mmalecki, they're warning us that if that ever happened to be the case, our use case wouldn't be their concern
16:50:13  <isaacs>process.binding is private.
16:50:19  <mmalecki>AvianFlu: yes, I'm aware :)
16:50:49  <isaacs>this use case is clearly relevant, since people *will* use node for http proxies. but rather than expose more of node's guts to make net.Server work as a proxy more effectively, i'd rather address whatever it is that makes http.Server an inadequate proxy.
16:51:40  <AvianFlu>isaacs, it's a question of parsing an http request, looking at it, and making a new http request to the destination, vs. piping a tcp stream
16:51:48  <isaacs>the nodejitsu http proxy is what happens when you start out using node's builtin http and hack around all the issues.
16:51:50  <AvianFlu>when we can make the latter work, it's way faster
16:52:11  <isaacs>AvianFlu: bottom line, you're parsing the incoming stream as http, and then translating it into an outgoing http stream.
16:52:52  <isaacs>and then taking the response, and translating it a little into the response to the original client.
16:53:16  <isaacs>it's not quite simply a matter of piping data. but, we should be able to make it that simple, i think.
16:53:39  <isaacs>bouncy is what happens when you decide to use node's net.Server directly, and parse http yourself.
16:54:01  <isaacs>now we're exploring using node's internals, and still using net.Server. i think we're missing an obvious solution, which is a bit more costly to implement, but better long-term.
16:55:01  <AvianFlu>the only thing that really draws us to net.Server is the complexity of the existing approach - so I'm inclined to agree with you, overall
16:56:23  * stephankjoined
16:56:34  <isaacs>another not-completely-insane idea is to move the http parser into JS, but it'd have to be much faster than parsley
16:57:18  <AvianFlu>isaacs, do you think the speed hit parsley takes is more from js or from implementation?
16:57:56  <AvianFlu>there are places where parsley can use faster js constructs, but I'm still skeptical a bit of doing that in js
16:57:57  <isaacs>AvianFlu: i think that a more straightforward C->JS transliteration of http_parser would be faster than parsley. but i am skeptical that it'd be faster than http_parser
16:58:33  <isaacs>parsley is built for extensibility and expressiveness. it's fast enough.
16:58:38  <isaacs>but not fast enough for node.
16:58:41  <AvianFlu>the big unknown, for me, is just how bad the c<->js boundary is
16:58:48  <AvianFlu>it's not somewhere I've had to tread yet
16:58:56  <txdv>why do you want to exchange http parser in node?
16:59:11  <AvianFlu>we're trying to make http proxying simpler and better
16:59:15  <AvianFlu>that's the really short answer
17:10:06  <AndreasMadsen>sorry for popping in, but the issue seams to be that request.pipe only pipe a body and not trailer header, and a boundary property would just be a work around. If the world was easy you could do: https://gist.github.com/1837361 - if I missed something I will just go again.
17:12:03  <isaacs>yeah, i mean, ideally ServerRequest.pipe(ClientRequest) and ClientResponse.pipe(ServerResponse) shoudl be smart enough to Just Work.
17:12:10  <isaacs>headers, trailers, et.
17:12:12  <isaacs>etc.
17:12:53  <mmalecki>not sure, but can't we just pipe sockets? req.socket.pipe(...)
17:13:14  <AndreasMadsen>mmalecki: there can be more that one HTTP request on one socket
17:13:45  <mmalecki>AndreasMadsen: it'd need some state then
17:14:12  * dapjoined
17:14:52  <AndreasMadsen>I have some old broken repo where I did http proxy before http-proxy-server existed, will go looking.
17:26:00  <AndreasMadsen>no to shitty, but looks funny, I did a regexp search for HTTP x/x in the TCP stream to split up and then using a regexp to find the hostname -> https://github.com/AndreasMadsen/WebNodes/blob/master/WebNodes%20Library/library/relay.js
17:26:12  <AndreasMadsen>But I like the https://gist.github.com/1837361 API way better
17:29:05  * orlandovftwjoined
17:30:19  * igorzijoined
17:30:27  * pieternjoined
17:37:14  <igorzi>isaacs: you're getting build errors trying to build x64 with vc express?
17:37:24  <isaacs>igorzi: yo
17:37:25  <isaacs>yes
17:37:49  <isaacs>igorzi: i installed the x64 windows sdk
17:37:51  <isaacs>that got me further.
17:37:54  <isaacs>still getting this, though:
17:37:56  <isaacs>LINK : fatal error LNK1181: cannot open input file 'winmm.lib' [C:\node-v0.7.4\
17:37:56  <isaacs>node.vcxproj]
17:38:24  <AndreasMadsen>request to improved HttpStream.pipe -> https://github.com/joyent/node/issues/2758
17:42:29  * mikealquit (Quit: Leaving.)
17:43:13  * mikealjoined
17:46:27  <igorzi>isaacs: ok..i'm trying to reproduce on a machine with just vc express
17:47:11  <isaacs>igorzi: great. that's the only thing blocking 0.7.4 right now. otherwise we're good to go
17:56:34  * dshaw_joined
18:01:45  * igorzi_joined
18:03:06  * igorziquit (Quit: Page closed)
18:08:34  * mikealquit (Quit: Leaving.)
18:10:59  * philipsquit (Excess Flood)
18:11:24  * mikealjoined
18:12:05  * philipsjoined
18:14:17  <mrb_bk>mikeal: cool article
18:14:22  <piscisaureus_>igorzi: DrPizza: do you guys think that child processes should inherit the current directory from the parent process?
18:14:34  * TooTallNatejoined
18:14:34  <piscisaureus_>that is, the current directory on other
18:14:46  <piscisaureus_>... drives than the current drive
18:15:01  <DrPizza>yes
18:15:22  <mikeal>thanks
18:15:58  <piscisaureus_>DrPizza: right now this isn't happening because we don't inherit" =D:" environment variables
18:16:12  <TooTallNate>piscisaureus_: igorzi_: what determines a managed build from an unmanaged one
18:16:33  <TooTallNate>i.e. node is unmanaged, but all the addons that gets build end up needing the .NET runtime installed
18:16:37  <DrPizza>piscisaureus_: yeah I was just thinking about that
18:16:37  <mrb_bk>mikeal: I think the first line might be clearer as "As a programmer, it is the abstraction you live in the most that you will perceive as the platform."
18:16:51  <DrPizza>piscisaureus_: they probably should be added to the list of "always-inherit" env vars
18:18:12  * orlandovftwquit (Ping timeout: 255 seconds)
18:19:15  <mikeal>thanks, that is better, stealing!
18:20:52  <mikeal>now we'll have to wait for amazon's CDN to propogate :)
18:21:23  * perezdjoined
18:28:30  <mrb_bk>i think you make some interesting points that i'd like to talk to you about in person sometime
18:39:08  <piscisaureus_>DrPizza: right
18:41:15  * txdvquit (Ping timeout: 248 seconds)
18:41:19  * AndreasMadsenquit (Remote host closed the connection)
18:45:57  <TooTallNate>piscisaureus_: did you see my question above?
18:46:28  <piscisaureus_>TooTallNate: it's just a switch
18:46:34  <piscisaureus_>let me see
18:46:36  * `3rdEdenjoined
18:47:10  <piscisaureus_>TooTallNate: you are just using common.gypi from node?
18:47:15  <piscisaureus_>and nothing else?
18:47:36  <TooTallNate>piscisaureus_: common.gypi and tools/addon.gypi
18:47:44  <TooTallNate>and then tools/gyp_addon invokes gyp itself
18:50:51  <piscisaureus_>TooTallNate: I don't know, it shouldn't happen
18:51:15  <piscisaureus_>TooTallNate: you should probably just open the .sln file in visual studio and browse through the project property pages
18:51:37  <piscisaureus_>TooTallNate: look for "common language runtime" related options
18:52:16  <igorzi_>TooTallNate: how do you know that the addon requires .NET? it won't load without .NET installed ?
18:52:43  <TooTallNate>igorzi_: right, on a vanilla windows install, node would load but that addon would not until the runtime was installed
18:52:56  * AvianFluquit (Quit: Leaving)
18:55:01  * xaqjoined
18:55:51  <isaacs>igorzi_: any idea on the x64 build with express?
18:56:05  <piscisaureus_>isaacs: you can't build x64 with express
18:56:10  <piscisaureus_>isaacs: you have to use the SDK
18:56:33  <isaacs>ok.. where does one get that?
18:56:53  <piscisaureus_>isaacs: I have never tried building with the SDK so probably there are some pain points :-)
18:57:03  <isaacs>i downloaded here: http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=6B6C21D2-2006-4AFA-9702-529FA782D63B
18:57:13  <piscisaureus_>isaacs: yes
18:57:14  <isaacs>which says that it's the x64 SDK
18:57:20  <piscisaureus_>isaacs: that's good
18:57:23  <isaacs>but the vcbuild.bat x64 release fails
18:57:33  <piscisaureus_>isaacs: what happens?
18:58:05  <isaacs>piscisaureus_: LINK : fatal error LNK1181: cannot open input file 'winmm.lib' [C:\node-v0.7.4\node.vcxproj]
18:58:31  <piscisaureus_>why do we need winmm anyway :-/
18:58:34  <piscisaureus_>must be v8
18:59:54  * igorzijoined
19:00:11  * xaqquit (Remote host closed the connection)
19:00:24  <igorzi>it's not v8
19:00:49  <piscisaureus_>igorzi: it must be - node and libuv are not using winmm afaik
19:00:57  * indutny_awaychanged nick to indutny
19:00:59  <igorzi>the issue is that the project is using the windows SDK that was installed with vc express, which points it to x86 libs
19:01:13  <piscisaureus_>aah, oh like that
19:01:21  <igorzi>piscisaureus_: yes, they are.. it's one of the default libs
19:01:35  <piscisaureus_>isaacs: is there a "Windows SDK command prompt" in your start menu
19:01:53  <piscisaureus_>isaacs: extra points if you can find one that explicitly says (x64)
19:02:04  <isaacs>yes, there is
19:02:14  <piscisaureus_>isaacs: open that
19:02:21  <isaacs>Targeting Windows 7 x64 Debug
19:02:23  <isaacs>nice
19:02:25  <isaacs>promising :)
19:02:25  <igorzi>i don't think that'll work
19:02:37  <piscisaureus_>igorzi: why not?
19:02:54  <igorzi>cause vcvarsall will override it most likely
19:03:30  * xaqjoined
19:03:31  <piscisaureus_>isaacs: try this:
19:03:40  <piscisaureus_>set VCINSTALLDIR=foo
19:03:47  <piscisaureus_>vcbuild release x64
19:04:02  <piscisaureus_>(from the sdk terminal)
19:04:44  <TooTallNate>piscisaureus_: igorzi: you think this is realted to my problem? http://msdn.microsoft.com/en-us/library/2kzt1wy3.aspx
19:04:49  <isaacs>vcbuild x64 nosnapshot <-- currently running
19:05:16  <piscisaureus_>isaacs: that generates a debug build ... but let's see how that works
19:05:55  <piscisaureus_>TooTallNate: probably not
19:06:02  <igorzi>TooTallNate: right, i don't think so either
19:06:34  <TooTallNate>ok thanks, i just don't get why they would be building as managed in the first place
19:06:44  <TooTallNate>since they don't use code that requires it and neither does node :\
19:06:56  * indutnychanged nick to indutny_sleeping
19:07:53  * orlandovftwjoined
19:07:58  * orlandovftwquit (Client Quit)
19:08:11  * orlandovftwjoined
19:08:14  <isaacs>piscisaureus_: indeed. debug build built fine. signtool failed, since release isn't there. building release now.
19:08:17  <isaacs>this is promising!
19:08:26  <isaacs>igorzi: ^
19:08:46  <piscisaureus_>igorzi_: we probably have to detect the SDK as well, and not invoke vcvarsall when we find it
19:08:54  <igorzi>isaacs: https://gist.github.com/1838218
19:09:02  <igorzi>piscisaureus_ --^
19:09:03  <kohai>piscisaureus_ has 4 beers
19:09:07  <igorzi>damn
19:09:09  <igorzi>piscisaureus_++
19:09:09  <kohai>piscisaureus_ has 5 beers
19:09:10  <igorzi>:)
19:09:27  <piscisaureus_>thanks, igorzi_:
19:09:31  <mmalecki>ok, I'm totally dealing with it in kohai refactor
19:09:48  <piscisaureus_>igorzi: what does the /p switch do? And will VC still work?
19:09:51  <piscisaureus_>er, VS
19:10:12  <isaacs>piscisaureus_, igorzi: i have no opinion about vcbuild.bat except that i'd prefer that it works :)
19:10:34  <isaacs>if you to come to agreement, feel free to land whatever fixes make that better and tell me what incantation to use to build it.
19:11:01  <igorzi>piscisaureus_: it sets msbuild project properties.. in vs this is set in project properties page
19:11:12  <igorzi>(which SDK you want to target)
19:12:38  <igorzi>piscisaureus_: i think it's better to go with /p:PlatformToolset=Windows7.1SDK, because the project will also build in vc express
19:12:56  <igorzi>isaacs: you're able to build release?
19:13:39  <piscisaureus_>igorzi: (1) where can I find this setting in the property pages? (2) I'm fine as long as it keeps working with VS-othereditions
19:13:54  <isaacs>yes, release x64 built
19:14:05  <isaacs>http://nodejs.org/dist/v0.7.4/node-x64.exe
19:14:09  <isaacs>check it out^
19:14:18  <CoverSlide>woo!
19:14:23  <isaacs>found a problem iwth the x86 exe, rebuilding that now.
19:14:28  <isaacs>forgot to disable snapshots in it
19:14:38  <TooTallNate>why are we disabling snapshots
19:14:53  <igorzi>piscisaureus_: general -> "platform toolset"
19:14:59  <piscisaureus_>isaacs: it is working nonetheless...
19:15:16  <piscisaureus_>isaacs: don't we disable snapshots by default?
19:15:17  <isaacs>TooTallNate: because that's the only way to avoid the DOS vulnerability with hash collisions
19:15:31  <piscisaureus_>oh wait - yes we need a snapshot-free build
19:15:36  <isaacs>piscisaureus_: i thought so, but then i saw it building the snapshot thing
19:15:44  <isaacs>we probably don't want to disable snapshots normally.
19:15:47  <isaacs>just for binary dists
19:16:02  <TooTallNate>makes sense
19:16:18  <piscisaureus_>isaacs: is node-x64.exe the final name?
19:16:21  <isaacs>*usually* they're better. but, someone can take the binary, figure out the hash salt, etc.
19:16:31  <isaacs>piscisaureus_: <shrug>
19:16:34  * brsonjoined
19:16:41  <piscisaureus_>isaacs: I haven't sorted out the dll lazy load hook yet so people will be unable to rename node.exe
19:16:47  <piscisaureus_>(or compiled extensions won't load)
19:16:49  <isaacs>piscisaureus_: maybe a x64 sub directory woudl be better?
19:16:55  <piscisaureus_>yeah
19:17:05  <isaacs>k, i'll do that. igorzi, opinions?
19:17:10  <isaacs>wanna splash some paint on this bikeshed?
19:17:10  <piscisaureus_>isaacs: at some point I will be able to fix it, after that it doesn't matter any more
19:17:11  <TooTallNate>that's what I was saying too :p
19:17:23  <igorzi>yep, probably the x64 dir is better
19:17:50  <igorzi>that way you could also put node.pdb and node.lib there (without appending '-x64' to everything
19:18:00  <isaacs>done: http://nodejs.org/dist/v0.7.4/x64/
19:18:08  <isaacs>d'oh, forgot node.pdb
19:18:11  <isaacs>ugh.
19:18:31  <isaacs>should've done this in two separate dirs :)
19:22:43  <TooTallNate>isaacs: btw you have any thoughts on this one? https://github.com/isaacs/npm/issues/2147
19:22:49  * `3rdEdenquit (Quit: Leaving...)
19:22:53  <TooTallNate>im probably doing something stupid on my end, but i don't see it
19:23:37  <isaacs>TooTallNate: it's a bug
19:23:39  <isaacs>in npm
19:23:57  <TooTallNate>ok thanks, at least its not me :P
19:25:44  * dshaw_quit (Quit: Leaving.)
19:27:18  <igorzi>TooTallNate: i don't see anything obvious for why addon projects would have .NET dependency
19:27:29  <igorzi>TooTallNate: they are not build with /clr switch
19:29:14  <igorzi>TooTallNate: i'll play with node_gyp later today or tomorrow, and i'll figure out what the issue is
19:31:12  * mikealquit (Quit: Leaving.)
19:33:09  <TooTallNate>igorzi: :)
19:34:11  * AndreasMadsenjoined
19:37:45  * xaqquit (Remote host closed the connection)
19:38:54  <CIA-99>node: isaacs master * rd653732 / (10 files in 7 dirs): Merge branch 'v0.7.4-release' - http://git.io/lIRNpw
19:38:55  <CIA-99>node: isaacs master * r6a2cb6c / src/node_version.h : Now working on 0.7.5 - http://git.io/ekG-QA
19:40:46  <igorzi>TooTallNate: actually, i think it's not .net dependency that addons need. looks like addons are being dynamically linked to CRT (node is statically linked to CRT)
19:41:08  <piscisaureus_>yeah, you should compile with /MT
19:41:22  <igorzi>TooTallNate: .NET installs VC runtime (so that's why those addons start working)
19:43:25  <TooTallNate>igorzi: piscisaureus_: yup that did it
19:43:27  <TooTallNate>:)
19:43:35  <TooTallNate>so it was the RuntimeLibrary afterall ;)
19:43:41  <igorzi>yep
19:44:23  <TooTallNate>but I should use a command-line argument as opposed to messing with gyp, ya?
19:47:41  <igorzi>TooTallNate: https://github.com/joyent/node/blob/master/common.gypi#L54
19:48:34  <TooTallNate>igorzi: :\ https://github.com/joyent/node/blob/master/tools/gyp_addon#L17
19:48:36  <igorzi>i think we either need to update common.gypi to include shared_library or to add that to addon.gypi
19:48:54  <igorzi>yep
19:49:01  <TooTallNate>i say fix common.gypi
19:49:31  <TooTallNate>should we just remove that conditional?
19:50:01  <igorzi>yeah, i think so.. just default to static linking CRT
19:50:01  * xaqjoined
19:50:25  <igorzi>also need to update that for debug builds
19:51:52  <TooTallNate>igorzi: isaacs: https://gist.github.com/1838508
19:52:45  * dshaw_joined
19:52:57  <benvie>interesting
19:53:32  <benvie>`module` is reserved in harmony mode in the newest v8
19:54:12  * `3rdEdenjoined
19:54:14  * travis-cijoined
19:54:14  <travis-ci>[travis-ci] joyent/node#420 (master - d653732 : isaacs): The build is still failing.
19:54:14  <travis-ci>[travis-ci] Change view : https://github.com/joyent/node/compare/6141386...d653732
19:54:14  <travis-ci>[travis-ci] Build details : http://travis-ci.org/joyent/node/builds/683591
19:54:14  * travis-cipart
19:54:45  <benvie>and js syntax errors on line 77 of node.js
19:54:47  <isaacs>benvie: are you f'ing kidding me?
19:54:47  <benvie>awesome
19:54:49  <benvie>no
19:54:50  <isaacs>jesus.
19:54:50  <benvie>wow
19:55:10  <isaacs>yeah, of course.
19:55:17  <isaacs>because module is used in every module everywhere.
19:55:18  <benvie>haha wow that's ridiculous
19:55:19  <isaacs>omg.
19:55:28  <mjr_>"harmony"
19:55:46  <isaacs>how does that work in browsers?
19:55:59  <benvie>let me see here
19:56:01  <isaacs>benvie: ohhh... wait a second. you're talkin gabout the crazy wackadoo es6 stuff, right?
19:56:10  <benvie>yeah well I mean
19:56:14  <tjfontaine>harmony now known as discord
19:56:14  <benvie>if you run node --harmony
19:56:17  <isaacs>not just the --harmony_weakmaps or --harmony_scoping thing
19:56:20  <benvie>it'll crash
19:56:23  <isaacs>right
19:56:36  * igorziquit (Ping timeout: 245 seconds)
19:56:37  <isaacs>node.js:77
19:56:38  <isaacs> var module = new Module('eval');
19:56:38  <isaacs> ^^^^^^
19:56:39  <isaacs>SyntaxError: Unexpected token module
19:56:43  <isaacs>awesome.
19:56:54  <benvie>let me see if it's a specific flag or any of them. I know they're uniting them basically
19:57:01  * igorzi_quit (Ping timeout: 245 seconds)
19:57:11  <benvie>there's 3 syntax modes: normal, strict, and harmony
19:57:28  <benvie>using a feature that's in harmony is supposed to opt you in automatically eventually
19:57:49  <isaacs>normal, strict, and introduces breaking syntax
19:57:55  <isaacs>calling that "harmony" is hilarious.
19:58:00  <benvie>ha
19:58:07  <TooTallNate>hah
19:58:19  <benvie>and yeah I don't understand this, I wasn't aware this was going to reserve new keywords
19:58:27  <isaacs>benvie: i guess you should probably not use the --harmony flag, then
19:58:28  <isaacs>:)
19:58:52  <mmalecki>but... proxies...
19:58:57  <isaacs>i mean, for any *valuable* features, you can just enable piecemeal
19:59:04  <isaacs>$ ./node --v8-options | grep harmony
19:59:04  <isaacs> --harmony_typeof (enable harmony semantics for typeof)
19:59:04  <isaacs> --harmony_scoping (enable harmony block scoping)
19:59:05  <isaacs> --harmony_modules (enable harmony modules)
19:59:07  <isaacs> --harmony_proxies (enable harmony proxies)
19:59:09  <isaacs> --harmony_collections (enable harmony collections (sets, maps, and weak maps))
19:59:11  <isaacs> --harmony (enable all harmony features (except typeof))
19:59:17  <isaacs>it's apparently --harmony_modules that breaks it
19:59:22  <benvie>oh
19:59:26  <benvie>yeah that's new
19:59:34  <benvie>so the --harmony flag is off limits now
19:59:40  <benvie>but the rest are fine individually I guess
19:59:41  <mmalecki>thankfully! modules are retarded anyway :)
19:59:58  * `3rdEdenquit (Quit: Leaving...)
20:00:19  <isaacs>it's odd that --harmony_typeof is omitted. that one is kind of nice.
20:00:28  <isaacs>just changes typeof null === 'null' instead of 'object'
20:00:37  <TooTallNate>and undefined == 'undefined'
20:01:04  <TooTallNate>isaacs: should i open a pull for that patch?
20:01:08  <benvie> --harmony_typeof --harmony_scoping --harmony_proxies --harmony_collections uhg
20:01:48  <isaacs>TooTallNate: the windows gyp thing? sure, if piscisaureus_ igorzi are ok with it, then i am.
20:05:52  <mjr_>All of this amazing new harmonious functionality, but no --harmony_int64 or --harmony_full_unicode_strings
20:06:10  <TooTallNate>mjr_: haha, if only...
20:06:33  <TooTallNate>isaacs: piscisaureus_: ok ready https://github.com/joyent/node/pull/2760
20:06:53  <benvie>eeventually
20:07:10  <benvie>not directly but
20:08:43  <benvie>quasis for unicode and binary data class/types are in es6
20:12:52  <benvie>damn it, and there isn't even any actual code supporting modules in. Just stubs. lose lose
20:20:45  <isaacs>mjr_: yes, it's almost as if when you get a bunch of language designers in discussion, they seem to prioritize language wankery over useful features.
20:21:08  <mjr_>Yeah, I wonder why that is.
20:21:15  <mjr_>Oh, because everybody else is doing real work.
20:22:46  <isaacs>i think be is actually one of the better ones in that group. but he's still too easily swayed by arguments of "this looks nicer" or "newcomers grok this more easily"
20:23:00  <piscisaureus_>isaacs:
20:23:01  <isaacs>rather than "this makes it impossible to handle real-world data in your programs"
20:23:01  <piscisaureus_>D:\node4>node
20:23:01  <piscisaureus_>> var a = { b: 3 }
20:23:01  <piscisaureus_>undefined
20:23:01  <piscisaureus_>> Object.freeze(a)
20:23:01  <piscisaureus_>{ b: 3 }
20:23:02  <piscisaureus_>> a.b
20:23:02  <piscisaureus_>3
20:23:02  <piscisaureus_>> a.b=4
20:23:03  <piscisaureus_>4
20:23:03  <piscisaureus_>> a
20:23:04  <piscisaureus_>{ b: 3 }
20:23:04  <piscisaureus_>> a.k = 4
20:23:04  <piscisaureus_>undefined
20:23:05  <piscisaureus_>> a
20:23:06  <piscisaureus_>{ b: 3 }
20:23:11  <isaacs>oh, werid
20:23:15  <isaacs>so the a.k returns undefined?
20:23:19  <piscisaureus_>yes
20:23:25  <piscisaureus_>funnyy eh
20:23:27  <isaacs>that's so wacky
20:23:34  <piscisaureus_>I wonder if there is an ecma spec about it
20:23:42  * AvianFlujoined
20:23:44  <isaacs>or maybe it's just a bug
20:23:52  <isaacs>or "undefined behavior"
20:24:11  <mmalecki>TooTallNate: hey, you figured out how to do this tty thing? or do you still use python wrapper?
20:24:22  <piscisaureus_>TooTallNate: yes, lgtm
20:24:44  <piscisaureus_>TooTallNate: too bad for people who want to build a node.dll :-)
20:24:51  <benvie>the amount of bikeshedding I've seen over the last few days on es-discuss is incredible
20:24:55  <isaacs>piscisaureus_: the weird bit is that the frozen property returns the value, but the sealed one doesn't.
20:25:08  <piscisaureus_>isaacs: yeeah
20:25:12  <benvie>like huge amounts of discussion about whether something should be named "remove" or "delete", just reams and reams
20:25:27  <isaacs>benvie: srsly
20:25:41  <isaacs>benvie: otoh, this is why node has been able to move so quickly.
20:25:47  <isaacs>the language craziness happens elsewhere.
20:26:03  <piscisaureus_>isaacs: so basically, for invalid process.env keys we should not throw - just ignore
20:26:10  <mjr_>Yes, I'm happy that language craziness happens elsewhere.
20:26:13  <piscisaureus_>isaacs: that's what I wanted to figure out
20:26:13  <isaacs>piscisaureus_: that would be my preference.
20:26:20  <benvie>yeah and there's no understating that as an advantage, because that's a different story in for example python
20:26:25  <mjr_>I just want to handle in64 and unicode data as native types.
20:26:28  <isaacs>piscisaureus_: but i could be convinced otherwise.
20:26:34  <benvie>they have to keep that bikeshed paint crew fueld 24/7
20:26:41  <isaacs>mjr_: you need to start trolling the es-discuss list.
20:26:41  <piscisaureus_>isaacs: No I have convinced myself
20:26:46  <isaacs>piscisaureus_: great :)
20:27:00  * mikealjoined
20:27:01  <piscisaureus_>isaacs: I also figured out that `delete o.propertythatdoesnotexist` returns true
20:27:03  <isaacs>mjr_: like, start telling them that this language is unusable, because there's no way to handle unicode.
20:27:05  <mjr_>isaacs: I know that's the next step, but the time commitment is awfully high for me right now.
20:27:10  <isaacs>mjr_: yeah.
20:27:21  <piscisaureus_>isaacs: whereas `delete process.env.keythatdoesnotexist` returns false
20:27:27  <piscisaureus_>isaacs: so that has to change as well
20:27:28  <mjr_>To make a cogent argument I feel like I'd need to first read up on all of the current proposals, etc.
20:27:37  <isaacs>piscisaureus_: not very important.
20:27:40  <isaacs>piscisaureus_: but ok.
20:27:44  <piscisaureus_>isaacs: I know :_)
20:28:01  <isaacs>piscisaureus_: afaik, "delete" should return true if it actually deleted something.
20:28:09  <benvie>even being up to date on it, there's just a huge amount of stuff posted on that list daily so it'd take a really dedicated troll to make a lasting impression
20:28:22  <piscisaureus_>isaacs: try this: `var a = {}`, `delete a.b`
20:28:24  <isaacs>piscisaureus_: or rather, delete should return "True" if the property is now not there.
20:28:34  <piscisaureus_>isaacs: ah - sure
20:28:36  <isaacs>piscisaureus_: right
20:28:54  <isaacs>piscisaureus_: so: x={y:"z"}; Object.freeze(x); delete x.y // false
20:29:02  <isaacs>but, delete x.z // true
20:29:09  <piscisaureus_>isaacs: yes, that's the correct semantic
20:29:17  <isaacs>becasue after the delete operation, false === x.hasOwnProperty("z")
20:29:25  <isaacs>nevermind that it didn't have it before, either :)
20:29:47  <piscisaureus_>isaacs: sure. But now that I am chopping it up anyway, I might as well do it right :-)
20:30:04  <isaacs>sure
20:30:24  * xaqquit (Remote host closed the connection)
20:34:14  <piscisaureus_>11.13.1 Simple Assignment ( = )
20:34:15  <piscisaureus_>The production AssignmentExpression : LeftHandSideExpression = AssignmentExpression is evaluated as follows:
20:34:15  <piscisaureus_>1. Let lref be the result of evaluating LeftHandSideExpression.
20:34:15  <piscisaureus_>2. Let rref be the result of evaluating AssignmentExpression.
20:34:15  <piscisaureus_>3. Let rval be GetValue(rref).
20:34:15  <piscisaureus_>4. Throw a SyntaxError exception if the following conditions are all true:
20:34:16  <piscisaureus_>• Type(lref) is Reference is true
20:34:16  <piscisaureus_>• IsStrictReference(lref) is true
20:34:17  <piscisaureus_>• Type(GetBase(lref)) is Enviroment Record
20:34:17  <piscisaureus_>• GetReferencedName(lref) is either "eval" or "arguments"
20:34:18  <piscisaureus_>5 .Call PutValue(lref, rval).
20:34:19  <piscisaureus_>6. Return rval.
20:34:25  <piscisaureus_>So probably we should just return rval
20:35:14  <piscisaureus_>Heh, lol
20:35:15  <piscisaureus_>NOTE When an assignment occurs within strict mode code, its LeftHandSide must not evaluate to an unresolvable reference. If it does a ReferenceError exception is thrown upon assignment. The LeftHandSide also may not be a reference to a data property with the attribute value {[[Writable]]:false}, to an accessor property with the attribute value {[[Set]]:undefined}, nor to a non-existent property of an object whose [[Extensible]] intern
20:35:34  <creationix>I wish there was a way to know when a function gets garbage collected
20:36:24  <mjr_>benvie: I know, the time it takes to make a significant change in a committee like that seems like roughly a full time job for someone, at least for a while.
20:36:55  <benvie>with `set` you pretty much just always want to return true
20:37:44  <benvie>I mean you can be honest...but it can throw in strict mode
20:39:23  <piscisaureus_>benvie: you're right, in strict mode setting a read-only property throws
20:39:55  <isaacs>piscisaureus_: yeah, just return the rval
20:40:07  <benvie>strict mode is stupid
20:40:10  <isaacs>if anyone complains, then we'll address it. but no one will complain.
20:40:14  <benvie>because of things like that
20:40:29  <isaacs>there are two kinds of people who prefer strict mode: people who don't fully understand it, and Mark Miller.
20:40:35  <benvie>HA
20:40:38  <benvie>so true
20:41:03  <benvie>I was looking through that Caja VM secure ecmascript loader thing
20:41:07  <benvie>holy shit
20:41:20  <isaacs>lol
20:41:22  <benvie>I learned more about hacking javascript inside out through that than anywhere else
20:41:34  <isaacs>yeah, that thing is nuts
20:41:41  <benvie>it hacks js inside out so that anything it loads can't
20:41:53  <isaacs>yeah
20:42:02  <isaacs>it's a very YO DAWG kind of program.
20:42:59  <benvie>yeah basically him and tv cutsem are the only people in this world besides be who actually know javascript and everyone else is just trying
20:43:37  <isaacs>no, lots of people know javascript
20:43:45  <isaacs>but none of them prefer strict mode except him, is the thing.
20:43:48  <benvie>but on es6, they need to just close that book because Proxies were the great victory and the rest of it is bikesheeding mostly
20:43:49  <isaacs>it's unnecessarily painful
20:43:52  <benvie>oh yeah
20:44:19  <benvie>he's definitely the grand champion of strict mode and I still don't get one anyone degends it
20:44:35  <benvie>defends it, since it adds so little and adds all this stupid bullshit
20:44:57  <CIA-99>node: Mark Nottingham master * r1e425e3 / (5 files in 3 dirs): Generate Date headers on responses when not already present. - http://git.io/EPy17Q
20:45:08  * xaqjoined
20:45:20  <benvie>if they're really going to make `module` a reserved keyword, that's going to suck ass
20:45:24  <benvie>eventually
20:46:26  <benvie>oh yeah, it's in the spec. http://wiki.ecmascript.org/doku.php?id=harmony:modules
20:46:52  <piscisaureus_>isaacs: I'm away for a while. After the break, env fixs
20:46:55  <benvie>ModuleDeclaration ::= "module" Id "at" String
20:46:56  <piscisaureus_>*fixes
20:47:17  <isaacs>piscisaureus_: great, thans
20:51:33  <TooTallNate>mmalecki: no nothing is possible in node yet, python hack for us still
20:51:38  <TooTallNate>creationix: node-weak ;)
20:51:58  <mmalecki>TooTallNate: can we, like, write a module?
20:52:18  <mmalecki>because I want to spawn vim from node!
20:52:22  <mmalecki>no matter what!
20:52:31  <TooTallNate>mmalecki: take a look at https://github.com/chjj/tty.js
20:52:32  * piscisaureus_quit (Ping timeout: 252 seconds)
20:52:37  <TooTallNate>he has some pty class that he made
20:52:45  <TooTallNate>but it's unix-only I think
20:53:03  <tjfontaine>it's actually acceptable for usage
20:53:12  <mmalecki>TooTallNate: meh on windows. I've seen that, it depends on socket.io, I got confused
20:53:33  <mmalecki>TooTallNate: I'll ask him to release pty itself, actually!
20:53:38  <TooTallNate>mmalecki: we he has it too coupled, yes
20:53:49  <TooTallNate>the pty module should be its own module
20:53:55  <TooTallNate>let's open an issue
20:54:04  <mmalecki>TooTallNate: meh. irc man
20:54:35  <benvie>needs a windows mode even though it doesn't exist on windows =(
20:54:57  <mmalecki>TooTallNate: obviously not around :). please open an issue
20:55:05  <mmalecki>TooTallNate: cc me in
20:58:25  * igorzijoined
21:01:28  * travis-cijoined
21:01:28  <travis-ci>[travis-ci] joyent/node#421 (master - 1e425e3 : Mark Nottingham): The build is still failing.
21:01:28  <travis-ci>[travis-ci] Change view : https://github.com/joyent/node/compare/d653732...1e425e3
21:01:28  <travis-ci>[travis-ci] Build details : http://travis-ci.org/joyent/node/builds/683874
21:01:28  * travis-cipart
21:05:19  * piscisaureus_joined
21:05:50  <igorzi>TooTallNate: that common.gypi change lgtm
21:06:28  <isaacs>igorzi: wanna land it?
21:10:05  <igorzi>isaacs: sure
21:13:44  <mmalecki>TooTallNate: lame, btw http://search.npmjs.org/#/pty
21:13:59  <mmalecki>github link is broken, project seems gone :/
21:14:24  <TooTallNate>oh yah, haha, i remember seeing that. you can 'npm install' it but I think there was nothing really interesting
21:15:30  <mmalecki>I don't trust libraries which were updated 305 days ago
21:16:00  <mmalecki>I think it's a valid concern XD
21:17:04  <TooTallNate>no i wouldn't trust it either :)
21:21:36  <mmalecki>TooTallNate: btw, what are you up to? why do you need it?
21:22:35  <TooTallNate>mmalecki: node-gyp could benefit from it. plus were working of a few new things in-house ;)
21:23:14  <mmalecki>TooTallNate: we == learnboost? nice
21:23:22  <TooTallNate>ya, learnboost
21:23:29  <mmalecki>TooTallNate: I'm writing my own shell :)
21:23:43  <TooTallNate>woah!
21:23:48  <TooTallNate>big undertaking :)
21:24:02  <mmalecki>I mean, zsh is slow
21:24:14  <mmalecki>bash is too normal
21:24:30  <tjfontaine>we see how powershell ended up
21:24:35  <mmalecki>so, yeah, broadway and some other stuff :)
21:33:41  <CIA-99>node: Nathan Rajlich master * r71e9756 / common.gypi : Default to static linking CRT on Windows. - http://git.io/DH-Bwg
21:34:05  <piscisaureus_>On unix, can you have emty-string env vars? Or does setting them to "" imply deleting them?
21:34:17  <isaacs>piscisaureus_: envs can be empty
21:34:19  <piscisaureus_>IOW, process.env.foo=""; process.env.foo
21:34:25  <isaacs>there's a unset command to unset them
21:34:35  <piscisaureus_>isaacs: ok, kewl
21:35:00  <isaacs>piscisaureus_: of course, in bash, "$FOO" is "" whether FOO is empty or unset
21:35:20  <piscisaureus_>isaacs: thanks
21:47:48  <benvie>node should use (non)enumerability more to hide non-public APIs
21:48:08  <benvie>the underscore doesn't seem to get the point across
21:48:50  <TooTallNate>benvie: where are you talking about specifically?
21:48:59  <piscisaureus_>benvie: it'll make it slower
21:49:03  <benvie>does it?
21:49:08  <benvie>interesting
21:49:26  <benvie>I just meant anywhere there's things that are supposed to be internal, but are still exposed on objects
21:49:27  <piscisaureus_>last time i checked it did
21:49:40  * travis-cijoined
21:49:40  <travis-ci>[travis-ci] joyent/node#422 (master - 71e9756 : Nathan Rajlich): The build is still failing.
21:49:40  <travis-ci>[travis-ci] Change view : https://github.com/joyent/node/compare/1e425e3...71e9756
21:49:40  <travis-ci>[travis-ci] Build details : http://travis-ci.org/joyent/node/builds/684097
21:49:40  * travis-cipart
21:50:46  <benvie>enumerability would influence two places: iteration over keys which probably isn't used in most of those places anyway, and in the REPL where people are debugging or learning
21:51:05  <benvie>maybe just if being used in the REPL which among people I know is a common place to explore and learn about what exists
21:52:06  <benvie>not a big deal but it's something I'd usually expect. Non-public things to be hidden from casual observance
21:54:03  <benvie>I'd imagine defining non-enumerable properties is slower since anything using descriptors has more overhead, but after I doubt it'd make a difference
21:55:51  <isaacs>benvie: a lot of javascript programs use _ to mark fields as internal.
21:56:49  <isaacs>benvie: any change to replace _property with Object.defineProperty(obj, "property", {enumerable:false,value:blah}) would have to come with a not-worse benchmark result
21:56:53  <benvie>sorry I was just trying to figure out what was the best color for this bikeshed
21:57:01  <isaacs>benvie: lol
21:59:15  <benvie>although on that last note, what the ideal what to do it is normal definition. And then a quick loop like var hidden = {enumerable: false}; Object.keys(o).forEach(key){ if (key[0] === '_') Object.defineProperty(o, k, hidden) });
21:59:22  <benvie>but again this is for my very best bikeshed
21:59:27  <benvie>so the color has to be perfect
22:00:22  <benvie>but yeah that's completely additional functionality so that's no possible way for it to be faster than just not doing it
22:00:34  <benvie>unless hiding the properties somehow makes up for it later which I doubt
22:02:35  <benvie>I also dress up my objects in pretty suits and make them dance and sing songs
22:03:20  * brsonquit (Quit: leaving)
22:04:05  * AndreasMadsenquit (Remote host closed the connection)
22:16:20  * perezdquit (Quit: perezd)
22:21:17  <isaacs>benvie: haha
22:21:22  <isaacs>benvie: that doesn't work, btw
22:21:36  <isaacs>benvie: you'd have to set it ot {value: o[k], enumerable: false}
22:22:06  <benvie>I messed up with `key` and `k`
22:22:25  <benvie>but when you use Object.defineProperty on an existing property it only updates the specified fields
22:23:52  <benvie>function hide(o){ var hidden = { enumerable: false }; Object.keys(o).forEach(function(key){ if (key[0] === '_') Object.defineProperty(o, key, hidden) }) };
22:23:57  <benvie>should work
22:30:14  <isaacs>oh, really?
22:30:20  <isaacs>i didn't know that!
22:30:31  <isaacs>i thought it clobbered the whole definition
22:30:33  <benvie>yeah I didn't either until recently
22:30:38  <isaacs>neat!
22:30:45  <benvie>you'd think, but no, it's actually useful ha
22:30:58  <benvie>a generalize function I use is something like
22:30:59  <benvie>function hideProperty(o,p){ if ({}.hasOwnProperty.call(o,p)) Object.defineProperty(o,p, { enumerable: false }) }
22:31:06  <TooTallNate>benvie: hey it works!
22:31:11  <TooTallNate>whatya know
22:32:37  <benvie>because if you do it to a property which doesn't exist then it'll define a property with a value of undefined that's non-writable and non-configurable
22:32:51  <benvie>way worse than when you began
22:33:36  * xaqquit (Remote host closed the connection)
22:35:02  * dshaw_1joined
22:35:05  * perezdjoined
22:37:12  * dshaw_quit (Ping timeout: 244 seconds)
22:51:29  <CIA-99>node: Bert Belder reviewme * ra59ac9e / src/node.cc : Windows: use unicode environment - http://git.io/-vKCFg
22:51:29  <CIA-99>node: Bert Belder reviewme * r1699fa1 / (lib/path.js src/node.cc): Windows: get rid of process._cwdForDrive() - http://git.io/Y9iQ3Q
22:51:41  <piscisaureus_>^-- igorzi, isaacs: review
22:52:05  <piscisaureus_>(isaacs: in particular, test if it doesn't break unix)
22:52:38  <isaacs>piscisaureus_: did you already land the unicode args?
22:52:47  <isaacs>piscisaureus_: that looked fairly straightforward
22:52:51  <isaacs>this is more involved, for sure
22:52:59  <piscisaureus_>isaacs: I believe I did - lemme check
22:53:19  <piscisaureus_>isaacs: yes, it was landed in 0.6
22:53:29  <piscisaureus_>isaacs: note that you need both to fix this npm issue
22:53:39  <isaacs>kewl
22:55:39  <isaacs>piscisaureus_: heading out for a little bit. i'll review this and if igorzi signs off, we can land it
22:55:55  <piscisaureus_>alright
22:55:55  * xaqjoined
22:55:55  <isaacs>i want to check unix, and also make sure it actually fixes the npm issue
22:56:10  <piscisaureus_>isaacs: right.
22:56:17  <piscisaureus_>isaacs: I am confident it does
22:56:46  <piscisaureus_>isaacs: you'll have to create an user on your windows machine with some weird character in it
22:57:10  <piscisaureus_>like ïsààçs
22:59:01  <isaacs>piscisaureus_: or just go into a directory with that name
22:59:04  <mmalecki>how'd I go about waiting for completion of all uv queued requests?
22:59:26  <piscisaureus_>mmalecki: uv_run() :-)
22:59:46  * xaqquit (Remote host closed the connection)
22:59:54  <mmalecki>piscisaureus_: what happens if I call it twice on the same loop?
22:59:56  <piscisaureus_>isaacs: possibly. you have to make sure to stress both the environment handling and the args handling
23:00:07  <isaacs>right
23:00:10  <piscisaureus_>mmalecki: well, it'll just continue
23:00:23  <mmalecki>piscisaureus_: act like nothing happened?
23:00:24  <isaacs>oh, process.cwd() doesn't get it out of the env?
23:00:29  <piscisaureus_>mmalecki: yep
23:00:30  * mralephjoined
23:00:38  <mmalecki>yeah, that's the problem :)
23:00:49  <mmalecki>I want something like eio_poll
23:00:49  <piscisaureus_>isaacs: not process.cwd. But process._cwdForDrive() did
23:01:10  <isaacs>oh, ok
23:01:14  <piscisaureus_>isaacs: it uses "hidden" environment variables
23:01:18  <isaacs>i see
23:01:25  <isaacs>windows you so crazy!
23:01:28  <isaacs>:)
23:02:07  <piscisaureus_>it's a mess. agreed
23:02:19  <isaacs>srsly, man, "=", really?
23:02:23  <isaacs>that means read-only?
23:02:24  <isaacs>that's wild.
23:02:28  <isaacs>ok, bbiab.
23:02:34  * isaacsquit (Remote host closed the connection)
23:02:52  <piscisaureus_>isaacs: it doesn't really mean read-only, but it means hidden. And we make it read only or the user can easily fuck up everything
23:03:11  * diogosnowsjoined
23:04:31  * felixgequit (Quit: felixge)
23:06:44  <mmalecki>piscisaureus_: so, is there a way to wait for completion on a already running loop?
23:07:24  * dshaw_joined
23:07:44  <piscisaureus_>mmalecki: why would you want to do that?
23:07:51  <piscisaureus_>uv_run() blocks until the loop completes
23:08:11  <piscisaureus_>mmalecki: I probably don't understand what you want to do
23:08:33  <piscisaureus_>igorzi: isaacs: oops, found a leak. Updating the reviewme branch in a minue
23:10:10  <mmalecki>piscisaureus_: I want to "empty" the thread pool before forking :)
23:11:30  * dshaw_1quit (Ping timeout: 260 seconds)
23:11:50  <piscisaureus_>mmalecki: aha
23:11:50  <CIA-99>node: Bert Belder reviewme * r077f9d7 / src/node.cc : Windows: use unicode environment - http://git.io/cR_zrQ
23:11:55  <CIA-99>node: Bert Belder reviewme * rd91bc7c / (lib/path.js src/node.cc): Windows: get rid of process._cwdForDrive() - http://git.io/_wG4ow
23:12:06  <piscisaureus_>mmalecki: stop doing the fork() crap :-)
23:12:32  <mmalecki>piscisaureus_: I thought we want process.daemonize?
23:12:49  <piscisaureus_>mmalecki: I don't think we want it with fork()
23:13:22  <mmalecki>piscisaureus_: is it possible otherwise?
23:13:26  <piscisaureus_>mmalecki: since callbacks could trigger new file io you would never be able to tell whether the thread pool is empty
23:14:10  <piscisaureus_>mmalecki: unless you create an uv_idle watcher and use some hack to count the work that's still busy in the thread pool
23:14:31  <piscisaureus_>mmalecki: of course - just add a --daemonize flag to node
23:15:02  <mmalecki>piscisaureus_: oh! it'd just fork at the beginning?
23:15:18  <piscisaureus_>mmalecki: yes. It needs to do a couple of things
23:15:29  <mmalecki>yeah
23:15:53  <piscisaureus_>but basically, it needs to replace all TTYs FDs by /dev/null, then fork and exit the parent
23:15:56  <piscisaureus_>much cleaner
23:16:07  <piscisaureus_>bnoordhuis: ^-- right?
23:16:17  <mmalecki>yeah, that sounds right
23:16:19  <piscisaureus_>bnoordhu1s: ^-- sic
23:16:23  <mmalecki>also, dup2 and things
23:16:30  <piscisaureus_>yeah
23:17:38  * travis-cijoined
23:17:38  <travis-ci>[travis-ci] joyent/node#423 (reviewme - 1699fa1 : Bert Belder): The build passed.
23:17:38  <travis-ci>[travis-ci] Change view : https://github.com/joyent/node/compare/a59ac9e^...1699fa1
23:17:38  <travis-ci>[travis-ci] Build details : http://travis-ci.org/joyent/node/builds/684518
23:17:38  * travis-cipart
23:17:54  * dshaw_1joined
23:18:32  * dshaw_quit (Ping timeout: 244 seconds)
23:18:59  <DrPizza>shouldn't all this environment stuff be in libuv? I thought the aim was to get node free of platform-specific code
23:19:02  <mmalecki>piscisaureus_: would it go to node or to libuv?
23:20:03  * travis-cijoined
23:20:03  <travis-ci>[travis-ci] joyent/node#424 (reviewme - d91bc7c : Bert Belder): The build passed.
23:20:03  <travis-ci>[travis-ci] Change view : https://github.com/joyent/node/compare/1699fa1...d91bc7c
23:20:03  <travis-ci>[travis-ci] Build details : http://travis-ci.org/joyent/node/builds/684647
23:20:03  * travis-cipart
23:20:47  <piscisaureus_>mmalecki: daemonize?
23:20:49  <piscisaureus_>hmm
23:21:00  <piscisaureus_>mmalecki: it could go in libuv
23:21:00  * isaacsjoined
23:21:14  <piscisaureus_>mmalecki: but if you can show a prototype in node I am already happy :-)
23:21:18  <CoverSlide>I agree. Next goal would be to remove all #ifdef statements
23:21:31  <piscisaureus_>mmalecki: if it goes into libuv it must be cross-platform
23:21:47  <piscisaureus_>mmalecki: but you cannot start a windows service with a command line flag
23:21:56  <mmalecki>piscisaureus_: uhm, any other way?
23:22:24  <piscisaureus_>mmalecki: the best we could do on windows is "run in the background, don't use a console windows"
23:22:31  <piscisaureus_>which might make sense
23:22:41  <bnoordhuis>piscisaureus_: yes
23:22:43  <mmalecki>piscisaureus_: but that doesn't actually daemonize, does it?
23:22:50  <CoverSlide>node needs its own gui
23:22:54  <piscisaureus_>mmalecki: define "deamonize"
23:23:12  <mmalecki>piscisaureus_: WELL. as in Unix :P
23:23:30  <CoverSlide>mebbe make a windows service
23:24:01  <isaacs>piscisaureus_: so... if process._getCwdForDrive() is gone, how DO you get the cwd on a different drive?
23:24:06  <isaacs>piscisaureus_: what's =resolveddevice?
23:24:15  * piscisaureus__joined
23:24:45  <piscisaureus__>mmalecki: "unix daemon" == "background process. no terminal. no parent"
23:24:50  <piscisaureus__>mmalecki: we can do that in windows
23:25:42  <mmalecki>piscisaureus__: awesome!
23:25:46  * bnoordhu1squit (Ping timeout: 244 seconds)
23:25:48  <mmalecki>piscisaureus__: I'll prototype it
23:26:48  <piscisaureus__>CoverSlide: a windows service works very differently. Windows services are started and stopped by the service manager. They are controlled via control messages (which are basically a special flavor of signals). The program uses a difference entry point (not main/WinMain but ServiceMain).
23:27:19  * piscisaureus_quit (Ping timeout: 244 seconds)
23:27:30  <mmalecki>^ why I love unix
23:27:48  <DrPizza>actually it's one of the reasons that unix sucks and Windows services are good
23:28:09  <DrPizza>there's a standardized way to tell a service how to start, pause/resume, stop
23:28:13  <DrPizza>and you can query a service's status
23:28:16  <piscisaureus__>In this case I agree with DrPizza (although, DrPizza, manually adding/removing services is way too difficult IMHO)
23:28:19  <DrPizza>ask it "have you started up now?"
23:28:30  <DrPizza>piscisaureus__: yes, that's true, since the SCM doesn't just read the registry each time, whch is annoying
23:28:33  <mmalecki>yes, you can do the same thing in Unix
23:28:37  <DrPizza>if you could just add/remove entries from the registry
23:28:43  <AvianFlu>mmalecki, not reliably inter-unix though
23:28:43  <mmalecki>there are just different managers
23:28:49  <mmalecki>yeah
23:28:58  <DrPizza>mmalecki: what is the standard way to ask a unix daemon "have you finished initializing and are running normally"?
23:29:12  <mmalecki>DrPizza: define "initializing"
23:29:29  <mmalecki>DrPizza: usually it creates a PID file tho
23:29:43  <piscisaureus__>mmalecki: a web server is done initializing when it starts accepting connections
23:31:09  <mmalecki>piscisaureus__: on unix it depends on a daemon
23:31:58  <DrPizza>ding ding
23:32:04  <TooTallNate>mmalecki: their point is that on windows this is standardized and on unix its up in the air
23:33:11  <mmalecki>TooTallNate: oh well. I like how it's "up in the air".
23:33:17  <isaacs>tbh, the windows services framework thing is basically what every unix os has had to develop for themselves.
23:33:37  <isaacs>smf, init.d, upstart, etc.
23:33:51  <mmalecki>I like system.d
23:33:58  <CoverSlide>true, just a matter of picking one
23:34:08  <CoverSlide>on unix you have "options"
23:34:11  <isaacs>ha
23:34:14  <piscisaureus__>ha
23:34:18  * piscisaureus__changed nick to piscisaureus
23:34:20  <isaacs>well, on any *specific* unix, youusually don't
23:34:26  * isaacsreally likes smf, despite the xml
23:34:26  <CoverSlide>true
23:34:46  <CoverSlide>but most are floss and portable
23:38:50  <isaacs>piscisaureus: looks good on unix.
23:38:51  <isaacs>(os x
23:39:59  * stephankquit (Quit: *Poof!*)
23:47:42  <piscisaureus>isaacs: now we have to check whether it fixes the env issues
23:47:47  <piscisaureus>er, the npm issues
23:47:57  <isaacs>yeah, building
23:48:13  <isaacs>slow cafe wifi
23:48:27  <isaacs>and just copying the folder from mac to win didn't work so well.
23:51:36  <isaacs>i would like windows 100% more if i could ssh into it from iterm, rather than using cmd.
23:51:50  <piscisaureus>hehe
23:52:13  <piscisaureus>isaacs: you could try winsshd
23:52:15  <TooTallNate>does there not exist a windows ssh server?
23:52:21  <TooTallNate>ahh ^
23:52:23  <isaacs>the builtin terms in linux and smartos are crap too, but at least you don't have to use them
23:52:33  <isaacs>piscisaureus: right, but that's not a valid test, is it?
23:52:35  <piscisaureus>isaacs: although I am not sure what shell it gives you, probably cmd
23:52:50  <benvie>amen to that, I just want xterm-256
23:52:52  <piscisaureus>isaacs: what is not a valid test?
23:52:53  * mralephquit (Quit: Leaving.)
23:52:59  <isaacs>piscisaureus: yeah, also, i'd want bash
23:53:11  <isaacs>rm !$ <-- "could not find the file specified"
23:53:14  <piscisaureus>isaacs: for that you'd have to use mingw or cygwin
23:53:18  <isaacs>ew.
23:53:26  <bnoordhuis>https://github.com/bnoordhuis/node/compare/fix-ssl <- thoughts, suggestions?
23:53:27  <isaacs>i can type "bash" into cmd, but it's.... different.
23:53:45  <bnoordhuis>first commit is a nice-to-have, second one is the 'thwart CI reneg attack' commit
23:53:46  <TooTallNate>when you install msysgit that comes with a Bash
23:54:20  <TooTallNate>isaacs: found this, haven't tried it: http://win-bash.sourceforge.net
23:54:26  <isaacs>bnoordhuis: if (~~flags) return flags; <-- why not if (typeof flags === 'number')?
23:54:26  <benvie>it's unfortunate how big a pain in the ass it is to get anything to act like a tty though
23:55:07  <bnoordhuis>isaacs: it's an "if zero" check
23:55:26  <bnoordhuis>that also works for things that are not numbers
23:55:45  <bnoordhuis>sorry, i mean "if not zero"
23:55:50  <isaacs>i see
23:56:00  <isaacs>so, if (flags && typeof flags === 'number') then?
23:56:07  <isaacs>~~ looks overclever.
23:56:21  <isaacs>i can see the rest of the function is all kinds of bitwise, though, so maybe it fits :)
23:56:22  <bnoordhuis>i wrote that yesterday and i don't recall why i used ~~
23:56:26  <bnoordhuis>but that's korsakov for you
23:56:32  <isaacs>probably just in bit mode.
23:56:37  <isaacs>seemed obvious :);
23:56:41  <piscisaureus>I like the ~~ operator
23:57:06  * xaqjoined
23:57:25  <isaacs>ok, reading for content now..
23:57:47  <piscisaureus>isaacs: ok, so igorzi ack'ed the unicode thing
23:58:01  <piscisaureus>isaacs: now we should just test if it fixes the npm issue
23:58:13  <isaacs>.yep
23:58:43  <isaacs>just got it checked out, finally. building/installing now
23:59:21  <bnoordhuis>on a side note, that first commit should probably go into master