[00:00] mandric has joined the channel [00:00] wdbl: is anyone doing entire apps with just node.js? Or is everyone mostly using it to do realtime stuff like chat with websockets? I am looking at Express.js with MongoDB right now. Am I on the right path? [00:00] fbartho: bnoordhuis: That adds an event to node's event loop no? Waking it up if necessary, queuing if not? [00:01] allanca has joined the channel [00:01] bnoordhuis: fbartho: oh sure, you can - but the overhead will probably kill you [00:01] bnoordhuis: then again... if you want fast, you probably wouldn't write a fuse fs to begin with [00:02] davidsklar has joined the channel [00:03] wdbl: (I meant "entire sites" not "entire apps") [00:03] fbartho: bnoordhuis: Fuse filesystems are inherently going to be slower. But I get the chance to leverage the power of node. I want to build a distributed network that does terrain generation, and exposes the results via FUSE so that the game (Minecraft) can run unmodified on top of this. [00:04] josephboyle1 has joined the channel [00:05] wdbl: nvm found this, thx - https://github.com/joyent/node/wiki/Projects,-Applications,-and-Companies-Using-Node [00:05] bnoordhuis: fbartho: okay, in that case use ev_async (uv_async in 0.5.x) [00:05] jtrudeau has joined the channel [00:05] fbartho: bnoordhuis: The constructs that will be distributed are sort of meta-level constructs like Mountains, streets, cities, buildings, objects. The mapfile format is just a binary blob of data that describes every cube within the block of space. [00:06] kdng-devrim has joined the channel [00:06] joshgillies: has anyone got an example of interacting with an external application through child_process and routing the output to a web frontend? [00:07] errordeveloper: joshgillies: good question, +1 [00:08] fbartho: bnoordhuis: So uv_async wakes up node, but how do I hook into the event loop so that native code can tick once per node-event-loop tick? [00:08] JakeyChan has joined the channel [00:08] joshgillies: I've looked over the node_chat code to see if I can't gather something from there [00:08] joshgillies: But my brain isn't yet tuned into the node way of writing applications [00:08] fbartho: do I just permanently have the native instance queue a uv_async_send(process_fuse_loop) at the end of the process_fuse_loop command? [00:09] joshgillies: #soon [00:09] neurodrone has joined the channel [00:09] hernan: joshgillies: you call exec with a handler, the handler gets three params, err, stdout and stderr. [00:09] bnoordhuis: fbartho: you can use ev_feed_event() for that [00:10] joshgillies: ok let me recap, I've a working program that can be ran through he command line [00:10] fbartho: is ev completely replaced with uv in 5.x? [00:10] fbartho: so uv_feed_event? [00:10] davidbanham has joined the channel [00:10] bnoordhuis: fbartho: oh wait, you mean after the event loop wakes up for whatever reason? [00:10] joshgillies: it'll take input and produce correct output [00:10] joshgillies: jsut needing the get an idea for the transport between the app and a fronend [00:11] __main__ has joined the channel [00:11] fbartho: bnoordhuis: I mean that when a filesystem is active, I want to tick once per node event loop and process pending fuse events [00:12] CarterL has joined the channel [00:12] fbartho: bnoordhuis: basically FUSE has a while(true) loop that ticks regularly and just calls "fuse_loop" instead of calling that while loop, I want to tick once per node event loop [00:12] replore has joined the channel [00:12] replore_ has joined the channel [00:14] shipit has joined the channel [00:16] replore has joined the channel [00:16] replore_ has joined the channel [00:16] bnoordhuis: fbartho: you probably want a ev_prepare or ev_check watcher [00:18] WarheadsSE: anyone have any idea why I might be transmitting something other/more than the bytes from a Buffer(200) via socket.write ? see http://groups.google.com/group/growl-for-windows/browse_thread/thread/ed04f73595280fb8/500f4635a44f88cd#500f4635a44f88cd [00:18] fbartho: bnoordhuis: is libev deprecated in favor of libuv? Is there a wiki somewhere describing libuv's api? or libev still around and still right for my purposes? [00:20] bnoordhuis: fbartho: libev is deprecated in 0.5.x yes [00:21] bnoordhuis: it's not thoroughly documented yet but you can pick it up from the source and the tests for now [00:21] fbartho: kk [00:21] fbartho: thanks [00:22] jerkelens has joined the channel [00:23] rchavik has joined the channel [00:24] amigojapan has joined the channel [00:25] willwhite has joined the channel [00:25] fbartho: What's the most stable 5.x branch currently? I see 5.9 was added in the last couple days... [00:26] postwait has joined the channel [00:27] CIA-48: libuv: 03Ben Noordhuis 07 * re0a4e72 10/ (src/unix/sunos.c test/test-get-memory.c): sunos: look up free memory with sysconf(_SC_AVPHYS_PAGES) - http://git.io/gWY_Yg [00:28] bnoordhuis: fbartho: master - we're in bug fixing mode for 0.6 now [00:28] neoesque has joined the channel [00:29] jomoho has joined the channel [00:30] JaKWaC has joined the channel [00:32] Aikar: bnoordhuis: so how about this bug :( https://github.com/joyent/node/issues/1863 [00:32] tylerstalder has joined the channel [00:34] jarek has joined the channel [00:34] jarek has joined the channel [00:34] illumina has joined the channel [00:35] illumina: Trying to use Browserify with socket.io and it's not working. People seem to be experiencing similar issues on google, have a fix for an older version of socket, that doesn't seem to be working. [00:36] freshmilk: can someone tell me what [00:37] freshmilk: prototype.js does [00:37] Aikar: someone please ban him [00:37] illumina: lol [00:37] tjholowaychuk: Aikar++ [00:37] Aikar: damn i want a beer, where is the bot ;( [00:38] halfhalo: bot got drunk and left [00:39] JakeyChan has joined the channel [00:44] bnoordhuis: Aikar: i prefer standalone test cases [00:44] shykes_ has joined the channel [00:45] brianseeders has joined the channel [00:45] tjholowaychuk: bnoordhuis do you think a response "header" event would be out of the question? [00:45] tjholowaychuk: optional maybe [00:45] tjholowaychuk: not really a core thing [00:45] tjholowaychuk: but it would be handy [00:46] bnoordhuis: tjholowaychuk: probably not, we're actually trying to cut all the fat from the http parser [00:46] tjholowaychuk: fair enough [00:47] jhurliman: has anyone written connect middleware that prints out server stats in nginx status format? [00:47] jhurliman: seems like it would be a small piece of middleware to write but i don't want to reinvent the wheel [00:48] tjholowaychuk: jhurliman link? [00:48] tjholowaychuk: might be interested in having that [00:48] dynacker has joined the channel [00:50] jacobolus has joined the channel [00:54] piscisaureus has joined the channel [00:55] rmzg has joined the channel [00:55] enmand_ has left the channel [00:55] jhurliman: tjholowaychuk, http://wiki.nginx.org/HttpStubStatusModule [00:56] enmand has joined the channel [00:57] tjholowaychuk: jhurliman hmm [00:57] tjholowaychuk: does it just periodically dump info? [00:57] tjholowaychuk: doesn't really need to be middleware [00:58] jhurliman: it's an endpoint (like /nginx-status) that you can poll periodically with something like collectd [00:58] tjholowaychuk: ah [00:58] tjholowaychuk: gotcha [00:58] tjholowaychuk: cool [00:58] tjholowaychuk: im down [00:58] jhurliman: i was thinking it needed to be middleware to hook into the events for each request and accumulate the counters [00:58] tjholowaychuk: im just finishing the gzip one [00:58] tjholowaychuk: ill look at that in a minute [00:59] jhurliman: cool [01:00] Aikar: bnoordhuis: https://github.com/joyent/node/pull/1864 [01:01] josephboyle1 has joined the channel [01:01] bnoordhuis: Aikar: interesting [01:01] Aikar: this is the work i mentioned earlier today :P [01:01] bnoordhuis: out of curiosity, did you test it with jsonBuffer.split("\n")? [01:02] Aikar: dont believe i did, but that gets tricker to parse to determine is the last chunk complete or not? [01:02] Aikar: youd have to see if a blank entry exists after the one your processing [01:04] Aikar: and yes ive done the legal work etc, i'm already in authors file :P [01:05] jhurliman: tjholowaychuk, while you are here, how in the world can i get express+cluster+http+https all playing nicely together? [01:05] bnoordhuis: Aikar: okay, good catch [01:06] bnoordhuis: do you have a test case / benchmark we can try out (or even better: include) [01:06] jhurliman: the example programming model for cluster says to wrap your http server code in a file and set module.exports = theserver; but what if i want to listen on port 80 + port 443 with ssl enabled? [01:06] Aikar: I linked a single file benchmark [01:06] adriftatsea has joined the channel [01:06] tjholowaychuk: jhurliman cluster is really just designed for one http.Server [01:06] Aikar: the testperf.js [01:06] jhurliman: ah, that's what i was thinking [01:06] tjholowaychuk: jhurliman yeah, not quite ideal [01:07] c4milo1 has joined the channel [01:07] bnoordhuis: Aikar: right, i was looking at the patch [01:08] SubStack: illumina: I'm working on that bug right now in fact [01:08] Aikar: bnoordhuis: the main change being if you have say 50 small 'messages' in 1 buffer, the current node code will call slice 50 times to shift off the processed data. my change makes it call it once everything 'complete' in the buffer is parsed [01:08] SubStack: socket.io expects that objects it puts on window will resolve as lexicals >_< [01:08] SubStack: and assigns to module.parent >_< [01:09] Aikar: i tested with and withut the patch twice, results were consistent [01:09] freshmilk: WHAT THE HELL IS PROTOTYPE.JS [01:09] Aikar: (well, within 10-15%) [01:09] Aikar: freshmilk: YOURMOM [01:09] freshmilk: someone tell me [01:09] Aikar: google.com [01:10] Aikar: bnoordhuis: can you ban him please. hes mega trolling [01:10] Aikar: just /lastlog freshmilk [01:10] dthompso99: http://tinyurl.com/5vn2enl [01:10] freshmilk: how am i megatroling [01:10] freshmilk: i am asking [01:11] freshmilk: for real [01:11] Aikar: ask google [01:11] Aikar: or your wife who makes 50k/year that your so stoked about [01:11] bnoordhuis: hah, silly chanserv - i can ban but i'm not allowed to mute :/ [01:11] Aikar: lol [01:12] AvianFlu: don't ban. Take it from me, /mode +q #channel nick is way more fun [01:12] Aikar: do it manually? +b ~q: [01:12] Aikar: oh its +q here? [01:12] AvianFlu: yeah, it's +q [01:12] freshmilk: Aikar, girlfriend [01:12] freshmilk: Aikar, how much do u make? U have a girl? [01:12] AvianFlu: I have a trigger set for it in kohai [01:12] bnoordhuis: err [01:12] Aikar: that didnt work [01:13] Aikar: its /mode #node.js +q freshmilk [01:13] Aikar: channel comes first [01:13] Aikar: or most clients its just /mode +q freshmilk [01:13] AvianFlu: yeah channel comes first, that was my bad [01:13] errordeveloper: i actually did /ignore freshmilk like an hour ago :) [01:13] Aikar: lol [01:13] bnoordhuis: typing -g instead of -q doesn't help either :/ [01:14] T0aD: someone still speaking to him ? [01:14] bnoordhuis: i should practice this stuff more often [01:14] Aikar: T0aD: he just resurfaced about prototype this time [01:14] AvianFlu: bnoordhuis, bot commands are better, then you don't have to remember [01:14] T0aD: Aikar, is it a collection of scripts ? [01:14] T0aD: :) [01:14] Aikar: T0aD: i think it might be in the case of prototype :P [01:15] T0aD: 'dont speak to morons, its educating them' [01:15] Aikar: i wonder whats the performance diffs of substr vs splice [01:16] T0aD: who gave pquerna op ! [01:16] errordeveloper: we should make up a faq with wrong answers to stupid questions .. [01:16] abraxas has joined the channel [01:16] Aikar: i think hes had it since the start of ry gaining access to the channel? [01:16] vidi has joined the channel [01:16] mikeric has joined the channel [01:16] T0aD: ry ? [01:17] bnoordhuis: yep [01:18] T0aD: ah ok ryah [01:18] errordeveloper: I guess, that once Node becomes more popular there gonna be more and more crazy trolls like we just seen [01:18] Sorella_ has joined the channel [01:19] errordeveloper: i.e. cause Node take a somewhat unusual approach, many people just want get what it is really [01:20] k1ttty has joined the channel [01:20] Aikar: ry should try to get a custom nodejs/ vanity host on freenode for users... D: [01:21] Aikar: id much rather have aikar@nodejs/aikar than my @wikia/aikar :( [01:21] catb0t has joined the channel [01:21] jarek__ has joined the channel [01:21] MooGoo: .. 5+5 [01:21] catb0t: 10 [01:21] errordeveloper: though the analogy with engine/car/driver is quite good I suppose, and putting that before people ask, with a link to a more geeky explanation would be a good idea .. wouldn't it? [01:22] Aikar: errordeveloper: well you generally dont need to explain v8's relation to node every day... most people sorta unstand it [01:22] briandh has joined the channel [01:22] CIA-48: libuv: 03Igor Zinkovsky 07 * r72fb469 10/ src/win/fs.c : windows: check for fd==-1 in uv_fs functions - http://git.io/8yaXug [01:23] Aikar: PHP has a bad rep mainly due to the sheer mass of the horrible code written for it. id rather not try to attract those type of 'wannabe programmers' [01:24] errordeveloper: Aikar: most people by now, but the community is growing quite rappidly as I see [01:24] mbrevoort has joined the channel [01:24] Aikar: yes, and those people who cant figure out what v8 is need to go back to PHP :P [01:24] eee_c has joined the channel [01:25] EyePulp has joined the channel [01:25] JakeyChan has joined the channel [01:26] zackattack has joined the channel [01:28] ditesh|cassini has joined the channel [01:28] CIA-48: node: 03Igor Zinkovsky 07 * rf164704 10/ doc/api/fs.markdown : fs.watch documentation - http://git.io/LFy42g [01:29] abraxas: hmmm, those API changes seem to affect the way multi-node and cluster operate... [01:29] Aikar: yep [01:29] abraxas: well, i guess those are well maintained [01:29] shedinja_ has joined the channel [01:31] MooGoo: I wonder if TheJH [01:31] MooGoo: is here [01:32] sid3k: is there anyone who created a test server for swank js? [01:33] nibblebot has joined the channel [01:33] sid3k: I run swank in a remote machine and can connect it with emacs. but when I try to open the required url (x.x.x.x:8009) I'm getting unable to forward the request error [01:33] sid3k: any ideas? [01:34] fennec has joined the channel [01:36] gxdssoft has joined the channel [01:37] shenlok has joined the channel [01:38] Brian` has joined the channel [01:38] catb0t has joined the channel [01:41] dthompso99: how well does node run on embeded devices? no problem i assume, or is it a pretty large footprint [01:42] CIA-48: libuv: 03Ben Noordhuis 07 * r014394d 10/ uv.gyp : build: compile all targets with large file support - http://git.io/M2rfpw [01:43] bnoordhuis: dthompso99: define 'embedded' [01:43] bnoordhuis: my 1 GB home router runs node just fine [01:43] dthompso99: arm processor... say cell phone, or perhaps even a router [01:44] bnoordhuis: should work, it does for me [01:45] dthompso99: cool... i may have a cool idea then [01:45] Aria has joined the channel [01:45] kersny has joined the channel [01:48] socketio\test\05 has joined the channel [01:54] kersny has joined the channel [01:56] dthompso99: any way to attach a debugger to c++ addons? [01:56] gavin_huang has joined the channel [01:56] tylerstalder has joined the channel [01:57] slifty has joined the channel [01:57] dthompso99: nm, scratch that... didnt read the last paragraph about the google debugger [02:00] errordeveloper: dthompso99: I had the same question earlier .. and at the end I concluded that I should test it myself :) [02:00] jarek__ has joined the channel [02:01] errordeveloper: dthompso99: I have PogoPlug to test it with .. however, I need a Jtag adaptor to get going ;( [02:02] darinc has joined the channel [02:04] errordeveloper: dthompso99: well, my hopes are that it will run fine on something which is 300MHz or faster and has 128MB of ram or higer .. provided that the application is not terribly complex and doesn't serve huge number of network connections + i/o [02:04] darinc1 has joined the channel [02:05] joeyang has joined the channel [02:06] broofa has joined the channel [02:07] a_suenami has joined the channel [02:07] yankov has joined the channel [02:07] errordeveloper: dthompso99: checkout this `node --v8-options` and grep for 'size' and 'limit' [02:08] CIA-48: libuv: 03Ben Noordhuis 07 * r721ad8c 10/ (4 files in 2 dirs): sunos: implement uv_fs_futime() - http://git.io/-bpsiQ [02:09] errordeveloper: actually I wonder if there any other hard limit that could be define at compile time ... hm ? [02:13] markdaws has joined the channel [02:13] thisandagain has joined the channel [02:15] avih has joined the channel [02:16] blueadept: anyone got an invite prospect for dribbble? [02:17] issackelly_ has joined the channel [02:23] crunchmaster has joined the channel [02:24] ceej has joined the channel [02:24] airportyh has joined the channel [02:25] kersny has joined the channel [02:25] CarterL has joined the channel [02:26] stelcheck1 has joined the channel [02:30] thisandagain has joined the channel [02:31] dshaw_ has joined the channel [02:31] icewhite has joined the channel [02:32] jacobolus has joined the channel [02:32] Emmanuel` has joined the channel [02:33] josephboyle1 has joined the channel [02:38] gimpygoo has joined the channel [02:38] noodlehaus has joined the channel [02:38] noodlehaus: hi guys, anyone using riak-js? [02:39] Ned_: if I have npm 0.2.19 (installed with Oneiric), is there a way to get it to upgrade itself ot the latest version ? [02:39] Ned_: or is it simply too old ? [02:40] noodlehaus: do a sudo npm -g update npm [02:40] Vennril2 has joined the channel [02:40] Ned_: noodlehaus: heh, that just prints out the help ;_) [02:41] Ned_: if I drop the -g [02:41] Ned_: it says don't run as root [02:41] Ned_: if I drop the sudo [02:41] Ned_: it just says "npm ok" [02:41] noodlehaus: oh, i'm not so sure then, i started with npm 1.0.x [02:42] Ned_: heh [02:42] Ned_: I think this might just be _too_ broken ... [02:43] Ned_: nothing's ever easy :-( [02:44] sh1mmer has joined the channel [02:44] tokuz has joined the channel [02:45] Aria: Yeah, you need to install fresh. [02:45] Aria: The oneliner from npmjs.org will do it. [02:45] jtsnow has joined the channel [02:45] paulwe has joined the channel [02:49] mbrevoort has joined the channel [02:52] elliottcable: Aria! [02:52] elliottcable: hi. [02:52] Aria: 'allo! [02:52] elliottcable: everyone: anybody know of a contributor’s guide somewhere [02:53] elliottcable: i.e. things to do before comitting, how to run whatever tests there are, coding styles preferred, anything necessary for pull requests to be accepted … etc. [02:54] Aria: I wish! [02:55] crunchmaster has joined the channel [02:55] asobrasil has joined the channel [02:55] asobrasil has left the channel [02:55] harthur has joined the channel [02:57] sub_pop has joined the channel [02:59] foobarfighter has joined the channel [02:59] matyr has joined the channel [03:00] EyePulp has joined the channel [03:02] elliottcable: If I’m going to start mucking with stuff, and intending to submit a patch, which branch should it be against? [03:02] githogori has joined the channel [03:02] elliottcable: current HEAD is fine? [03:03] bradleymeck has joined the channel [03:03] cjm has joined the channel [03:04] elliottcable: http://twitter.com/jack/status/123956953507573760 [03:04] elliottcable: oh my god I want one of those at home [03:05] SomeoneWeird has joined the channel [03:06] elliottcable: er, wrong room. [03:06] CarterL has joined the channel [03:06] mikeric has joined the channel [03:06] Lorentz: What if I wanted chilled AND sparkling water. [03:06] vidi has joined the channel [03:07] Guest25624 has joined the channel [03:08] infynyxx has joined the channel [03:11] dreamdust has joined the channel [03:13] dilvie has joined the channel [03:15] gravity13 has joined the channel [03:16] JaKWaC has joined the channel [03:17] avih has joined the channel [03:21] ninjapig has joined the channel [03:21] dhasenan_: Lorentz, put some warm sodium on a block of ice? [03:22] mbrevoort has joined the channel [03:26] cliffano has joined the channel [03:27] elliottcable: ugh, I have to disable my firewall before I can `make test` [03:27] elliottcable: ACTION rage [03:27] boehm has joined the channel [03:28] cliffano: what shell does child_process.spawn use? is it whatever the node program is run on? or is it always /bin/sh ? [03:29] elliottcable: okay, what. ಠ_ಠ [03:29] elliottcable: so I cloned up to latest Node, git-clean’d and checked out and whatnot, and `make test`’d [03:29] elliottcable: fifteen minutes later … “make: *** [test] Error 1” [03:30] dhasenan_: If your unittests take 15 minutes to run, you aren't running them all on each commit. Sad but true. [03:30] dhasenan_: Try a release version. [03:30] Aria: So very true. [03:30] elliottcable: really? [03:30] elliottcable: ugh, that’s horrible practice, but okay [03:31] Aria: Which? Fast tests? [03:31] elliottcable: so it’s probably really broken at that commit, and not me messing up whatever should be done to test the code I’ve cloned? [03:31] elliottcable: is anybody here actively dev’ing on Node’s C++ sources at the moment, and cares to quickly outline their development cycle to me? [03:31] Aria: master worked for me; if this is something you'd builti n the past, make distclean on it [03:31] elliottcable: Aria › I just `git clean -dxf`’d [03:31] elliottcable: er, df’d [03:32] jacobolu_ has joined the channel [03:32] elliottcable: which removes everything that isn’t from the upstream that I just checked out, so I *know* there’s no cruft … [03:32] elliottcable: Aria › just `./configure && make test`, yes? [03:32] Aria: Yeah. [03:32] Aria: Though I haven't actually run make test. [03:32] elliottcable: er, huh? [03:33] elliottcable: and you’re against f164704, yes? [03:33] elliottcable: it compiles for me; the failure was in the test phase [03:33] Aria: (I haven't run the tests.) [03:33] Aria: 24dabec was the last I built. [03:33] Aria: What error in the tests? [03:33] bulatshakirzyano has joined the channel [03:33] elliottcable: https://gist.github.com/10156e063bcbb0bab3d4 [03:34] Aria: Interesting. I've not heard people yelling about it. [03:34] zackattack has joined the channel [03:34] Aria: But it happens for me too. [03:34] elliottcable: okay, that’s good. Not my fault then D: [03:35] elliottcable: so, are there any tests in C++? or are they all written in JS? [03:35] elliottcable: and should I prefer to write my tests in JS if possible, if so? [03:35] Aria: Most everything possible is in JS. [03:37] elliottcable: is there any way to force a partial rebuild? I don’t know if that’s something waf can handle, but I’d prefer not to rebuild 15 minutes of stuff for a few lines’ change. [03:37] Aria: tests aren't builds. [03:37] Aria: So no. But you can re-run the single test that failed I bet. I've not done it. [03:38] mikeric has joined the channel [03:38] elliottcable: no, I can do that by hand [03:38] dguttman has joined the channel [03:38] elliottcable: I’m changing C++ though; I won’t be getting to the JS written to test it for a while [03:38] dshaw_ has joined the channel [03:38] Aria: Ah, regular ol' make does it. [03:38] elliottcable: so just `make` without `git clean` inbetween? [03:38] Aria: Yeah. [03:38] elliottcable: I always assumed that was a bad idea. [03:38] Aria: Why not? [03:38] elliottcable: *shrug* [03:39] Aria: No, you just have to understand the dependencies. Or not screw with them in complicated ways. [03:39] elliottcable: I always thought a dirty tree was a great way to mess things up; I wasn’t aware `make` could handle stuff intelligently like that [03:39] Spion_ has joined the channel [03:39] elliottcable: what does it use, file modification times or something? [03:39] Aria: No magic. The build system just doesn't grok the whole dependency graph. But single files should be fiiine. [03:39] Aria: Yeah. [03:39] Aria: That's the whole point of make over a shell script ;-) [03:39] elliottcable: m’kay [03:39] elliottcable: well, that explains a lot [03:39] elliottcable: I fucking *hate* make, and could never understand why anybody would foist it upon their users [03:40] elliottcable: but if it can do that, that’s acutally a tiny little bit useful [03:40] Aria: Hehe. [03:40] Aria: I happen to love it but hate what people do with it. [03:40] elliottcable: Aria › high-five, thanks for the help, now go fucking sleep. ಠ_ಠ [03:40] Aria: Hehe. [03:40] Aria: When I get my C++ compiling ;-) [03:41] gravity13_ has joined the channel [03:43] slloyd_ has joined the channel [03:43] bartt has joined the channel [03:44] chance- has joined the channel [03:45] chance-: is it possible to have a single nested object with a schema already defined or is it possible to apply plugins somehow to on the fly nested objects? [03:45] Aria: Schema? [03:46] sub_pop has joined the channel [03:47] amigojapan has joined the channel [03:47] cjheath has joined the channel [03:47] chance-: ? [03:48] chance-: was that to me? [03:48] pizthewiz has joined the channel [03:49] chance-: Aria: if it was : https://gist.github.com/1280216 [03:50] Aria: It was. [03:50] Aria: What is this Schema function? [03:50] chance-: Aria : ah [03:50] chance-: it's mongoose [03:50] Aria: That's not a node.js thing. [03:50] Aria: Aaah. [03:51] chance-: indirectly, yes :) [03:51] Aria: now that I have NO idea. I've not used it. [03:51] jsemar has joined the channel [03:51] chance-: Aria : no worries, thanks anyway :) [03:52] davidascher has joined the channel [03:58] cloudhea1 has joined the channel [03:58] vquaiato has joined the channel [03:59] mikeric has joined the channel [03:59] paul_k has joined the channel [04:00] zmbmartin has joined the channel [04:03] _th_n_ has joined the channel [04:07] sub_pop has joined the channel [04:08] gerard0 has joined the channel [04:14] _th_n_ has joined the channel [04:15] keey has joined the channel [04:16] bartt has joined the channel [04:16] keey: hi,how to use the node.exe on window [04:16] abraxas has joined the channel [04:17] keey: hmmm...is any body here? [04:17] jerrysv has joined the channel [04:17] slickplaid: nope [04:18] dexter_e has joined the channel [04:18] elliottcable: “Modifying builtins like Object.prototype and Array.prototype are strictly forbidden. Modifying other builtins like Function.prototype is less dangerous but still leads to hard to debug issues in production and should be avoided.” [04:18] elliottcable: wat [04:19] elliottcable: why is modifying Function.prototype any less ‘dangerous’ (which it’s not. ಠ_ಠ) than the other two? [04:19] keey: puzzled...build the node.js with cygwin,after all steps ,enter the node -- version,throw error [04:19] Kolbsoft has joined the channel [04:19] elliottcable: every single entry save one or two in this Google Style Guide is driving me nuts [04:20] Aria: Because modifying arrays and objects throws EVERYONE for a loop. [04:20] Aria: So few people rely on any property of Function.prototype. [04:20] elliottcable: ಠ_ಠ [04:21] Yuezi has joined the channel [04:21] Aria: That said, if they're non-iterable, it's not so bad. [04:21] Aria: But that's a new feature, and not generally cross-browser. [04:21] elliottcable: it shouldn’t matter, because code *should* be using properly-written loops that check the prototype tree; and that’s all sandboxed *anyway* [04:22] elliottcable: or are the “commonJS modules” still using the same global context? [04:22] elliottcable: I can’t remember if that ever got changed… [04:22] elliottcable: Aria › yeah, makes sense. I forgot that Function’s stuff was generally left alone by comparison. ^‿^ [04:22] dguttman has joined the channel [04:22] OmidRaha has joined the channel [04:22] Aria: global is shared. [04:23] Aria: And checking the prototype tree is expensive. [04:23] jamescarr has joined the channel [04:23] dthompso99: ... pondering a use for extending function.... [04:23] elliottcable: So, I have to mangle all of my code and avoid writing pretty APIs, for the sole case of people trying to write fist code for shitty/out-of-date browsers? [04:23] fairwinds has joined the channel [04:24] elliottcable: I think not. [04:24] elliottcable: dthompso99 › I‘ve done it half a dozen times or so, probably. Not exactly *often*, but still. [04:24] Aria: Know your audience ;-) [04:24] Aria: If you can forgo IE, go you. If you're writing just for V8, so much the better. [04:24] jamescarr: had some require.paths.unshift BS hidden in my codebase [04:24] elliottcable: ACTION nods [04:24] jamescarr: forgot all about it [04:25] elliottcable: Aria › point being, you can still write clean code (i.e. non-enumerable properties *and* proper loops with hasOwnProperty), and then optimize for performance based on a version check *where necessary* [04:25] elliottcable: no premature optimization, and no “OHMIGOD MODIFYING PROPERTIES IS SOOO EVIL” F.U.D. either. [04:25] djbell has joined the channel [04:25] Aria: Sure. .oO(I really don't want that crap in my loops.) [04:25] elliottcable: Aria › then don’t use JavaScript? [04:26] Aria: Or expect people do not do dumb shit. ;-) [04:26] elliottcable: it’s just like needing semicolons in surprising places … or the horrid syntax … the verbose closure declarations … the exquisitely-painfully-and-terribly-designed `new` keyword and related psuedo-classist-inheritance semantics … [04:26] elliottcable: it’s something that just comes with the language. [04:27] elliottcable: ACTION shrugs [04:27] elliottcable: Aria › are you calling not-using-proper-iterators, or modifying prototypes, “dumb shit?” [04:27] shanebo: hey guys what method should I use to get the contents from an rss feed via an external url? [04:27] Aria: I'm saying making stuff iterable in prototypes of iterable objects is bad. [04:28] franciscallo has joined the channel [04:29] elliottcable: ಠ_ಠ [04:30] elliottcable: anyway, age-old argument, not worth having in public [04:30] elliottcable: ACTION goes back to reading this terrible ‘style guide’ [04:31] Aria: More "I know modifying Object is tempting. Shit breaks. Don't". The rest, I'm all for. [04:31] elliottcable: that’s the part I disagree with [04:31] elliottcable: “shit breaks” only if it is, well, shit. [04:31] elliottcable: if you’re, for whatever reason, messing around in a global namespace where people might have to write shitty code … well, just be aware of that, and make your decision accordingly. [04:32] Aria: Nah, it's just that object literals are so convenient. The WHOLE language gets a ton more verbose if people start mucking with that. [04:32] elliottcable: (and no, that decision is *not* always going to be ‘don’t touch the prototype.’) [04:32] ryah: object literals++ [04:32] elliottcable: what am I missing here, then [04:32] elliottcable: if you set a property in an object literal, having other things on the prototype doesn’t affect that. [04:33] elliottcable: I mean, that’s obvious, so I’m assuming I’m missing your point … [04:33] elliottcable: ACTION nods at ryah [04:33] blueadept: is this for real? https://gist.github.com/1277224 [04:33] blueadept: its the dart compile [04:33] elliottcable: ryah › still trying to fix that issue I brought to you a week or two back; just now back at the computer, and I’m reading all the C++/JS style guides, trying to write some code you’d accept in a patch to make vm use the passed context-object as the *actual context* in-situ instead of copying properties back and forth [04:34] Aria: elliottcable: for(var k in {foo: 'bar'}) ... and finding non-foo in k is bad. [04:35] elliottcable: so it was exactly what I thought … oh my god, no offense, but that is terrible code o_o [04:36] elliottcable: but, *shrug*; I’m sure you’d say that about every line of code *I’ve* ever written, so I’ll just leave it and go back to reading. [04:36] elliottcable: closing point I think being that “none of this matters if your code is sandboxed.” [04:37] elliottcable: hopefully that will apply soon for Node, if ryah flips the big lever [04:37] HT has joined the channel [04:37] elliottcable: and it’s certainly already true in the browser (to an extent; of course, there’s issues when you’re bringing multiple sources of code into a single page or similar, but it’s just Something More to Be Aware Of.) [04:37] ryah: elliottcable: there's a js lint program in the node tree [04:38] elliottcable: ryah › yah, so I saw; `make jslint` yes? [04:38] ryah: somethign like that [04:38] elliottcable: but running any linter on elliottcable’s code by default usually either crashes it or produces unintelligible output /= [04:38] elliottcable: so I have to start with something ‘reasonable’ by the project’s standards. Which is fine by me, just needs a little preperation. [04:39] eee_c has joined the channel [04:40] patcito has joined the channel [04:41] bradleymeck has joined the channel [04:43] eee_c1 has joined the channel [04:44] Aria: Night, all [04:44] dthompso99: Night Aria [04:46] slifty has joined the channel [04:47] bombworm has joined the channel [04:48] shanebo: anyone know how to open a url as if it were a file? [04:49] pongwon has joined the channel [04:50] mike5w3c_ has joined the channel [04:52] paul_k has joined the channel [04:52] fangel has joined the channel [04:55] matyr has joined the channel [04:56] fbartho has joined the channel [04:57] jhurliman has joined the channel [04:59] ambroff has joined the channel [04:59] JakeyChan_ has joined the channel [05:01] joeyang has joined the channel [05:02] _th_n_ has joined the channel [05:02] tilgovi has joined the channel [05:02] tilgovi has joined the channel [05:07] jetienne has joined the channel [05:08] stagas has joined the channel [05:10] jhurliman has joined the channel [05:14] bartt has joined the channel [05:16] elliottcable: README says to follow Google’s JavaScript style-guide conventions [05:16] elliottcable: it talks a lot about commentary and JSDoc declarations [05:17] elliottcable: does anything in the Node.js project use JSDoc? Do I need to worry about JSDoc’in my comments? [05:18] jetienne: elliottcable: which README ? [05:19] jetienne: elliottcable: for sure you arent required to do so [05:19] elliottcable: er, wrong words [05:19] elliottcable: https://github.com/joyent/node/wiki/Contributing [05:19] elliottcable: that’s what I meant [05:19] elliottcable: the README links to that, and that says it. Heh. [05:19] bartt has joined the channel [05:19] elliottcable: jetienne › no JSDoc? Good. [05:19] elliottcable: jetienne › well, you *are* required to do so, at least to some extent. [05:19] smathy has joined the channel [05:20] elliottcable: last time I wrote any Node-related code, I believe ryah’s words were “took one look, then didn’t bother to read it.” [05:20] elliottcable: lol [05:20] Corren has joined the channel [05:20] jetienne: elliottcable: you want to contribute or to write code on your own ? [05:20] elliottcable: jetienne › contribute, hence why I’m exploring all of this [05:21] elliottcable: need to make some modifications to the C++ v8 interface behind the `vm` module [05:21] jetienne: elliottcable: oh this is different then. yep you should follow all the advices in there [05:21] jetienne: elliottcable: misunderstanding due to the README word [05:21] elliottcable: jetienne › it’s okay ^‿^ [05:22] jetienne: elliottcable: those are busy people. they cant try to adapt to all contributions specificities [05:22] stagas has joined the channel [05:23] isaacs has joined the channel [05:25] dexter_e has joined the channel [05:29] _th_n_ has joined the channel [05:30] boaz has joined the channel [05:32] kdng-devrim has joined the channel [05:33] xsyn: I'm trying to save an image to couchdb using formidable, but I'm just not getting it right [05:33] xsyn: please look at https://gist.github.com/1280374 [05:33] xsyn: and tell me how I'm messing it up [05:33] xsyn: I want to save it as an attachment [05:34] xsyn: if I comment out line 201 it works [05:34] xsyn: and the error I get is [05:34] xsyn: node.js:116 [05:34] xsyn: throw e; // process.nextTick error, or 'error' event on first tick [05:34] xsyn: ^ [05:34] xsyn: TypeError: Cannot call method 'emit' of undefined [05:34] xsyn: at Socket. (http.js:1171:9) [05:34] xsyn: at Socket.emit (events.js:42:17) [05:34] xsyn: at Array. (net.js:799:27) [05:34] xsyn: at EventEmitter._tickCallback (node.js:108:26) [05:35] jldbasa_ has joined the channel [05:36] rchavik has joined the channel [05:39] cjheath_ has joined the channel [05:40] SamuraiJack has joined the channel [05:40] CIA-48: node: 03Ryan Dahl 07 * r2b46959 10/ (benchmark/throughput-child.js benchmark/throughput.js): Add throughput benchmark - http://git.io/JjD_1A [05:40] tokuz has joined the channel [05:40] FireCat has joined the channel [05:41] k1ttty has joined the channel [05:42] broofa has joined the channel [05:43] ninjapig has joined the channel [05:43] jakehow has joined the channel [05:49] kickingvegas has joined the channel [05:51] CIA-48: node: 03Igor Zinkovsky 07 * r99757cb 10/ test/simple/test-fs-utimes.js : fix simple/test-fs-utimes.js on windows - http://git.io/d4v44g [05:52] matyr has joined the channel [05:52] FireCat has joined the channel [05:53] dexter_e has joined the channel [05:54] JakeyChan has joined the channel [05:59] tylerstalder has joined the channel [06:01] AvianFlu has joined the channel [06:04] bEEEviz has joined the channel [06:04] mikeric has joined the channel [06:04] pid_ has joined the channel [06:05] jacobolus has joined the channel [06:09] tlrobinson has joined the channel [06:10] ivanfi has joined the channel [06:10] fairwinds has joined the channel [06:10] dreamdust has joined the channel [06:11] FireCat has joined the channel [06:12] matyr has joined the channel [06:13] TomY has joined the channel [06:18] dexter_e has joined the channel [06:19] smtlaissezfaire has joined the channel [06:23] mikeric has left the channel [06:23] wbw72 has joined the channel [06:25] navaru has joined the channel [06:25] navaru has left the channel [06:26] magnetik has joined the channel [06:27] mraleph has joined the channel [06:30] boltR has joined the channel [06:32] sub_pop has joined the channel [06:32] wbw72 has joined the channel [06:33] shykes_ has joined the channel [06:34] dreamdust: How can I check if some middleware is being used in Connect? Is there a property or method I can use to access the middleware being used? [06:36] SubStack: dreamdust: server.stack or some such [06:37] Margle has joined the channel [06:38] dreamdust: SubStack: Awesome. Thank you. [06:39] raphdg has joined the channel [06:40] fairwinds has joined the channel [06:40] joshgillies has joined the channel [06:43] dilvie has joined the channel [06:44] louissmit has joined the channel [06:44] `3rdEden has joined the channel [06:45] Metal3d has joined the channel [06:46] jimt has joined the channel [06:47] versicolor has joined the channel [06:49] groom has joined the channel [06:50] simenbrekken has joined the channel [06:51] abraxas has joined the channel [06:51] luke` has joined the channel [06:53] dshaw_ has joined the channel [06:54] ninjapig has joined the channel [06:57] emattias has joined the channel [06:58] kickingvegas has left the channel [06:58] fangel has joined the channel [07:01] Ang3 has joined the channel [07:01] Morkel has joined the channel [07:04] ddollar has joined the channel [07:08] Aiden has joined the channel [07:12] perezd has joined the channel [07:12] Wizek-other has joined the channel [07:12] davidbanham has joined the channel [07:13] Twelve-60 has joined the channel [07:13] ayaz has joined the channel [07:15] __tosh has joined the channel [07:17] lunetics has joined the channel [07:17] ablomen has joined the channel [07:19] guidocalvano has joined the channel [07:21] [AD]Turbo has joined the channel [07:22] [AD]Turbo: hi there [07:22] Manuel_ has joined the channel [07:23] mytrile has joined the channel [07:23] briemens has joined the channel [07:23] skm has joined the channel [07:24] ph^ has joined the channel [07:25] gut4 has joined the channel [07:25] jhurliman has joined the channel [07:26] __doc__ has joined the channel [07:27] dgathright has joined the channel [07:30] ph^ has joined the channel [07:30] Xano has joined the channel [07:31] Aiden has joined the channel [07:35] barodeur has joined the channel [07:35] Ang3: o/ [07:36] socketio\test\18 has joined the channel [07:36] nyrb has joined the channel [07:40] ph^ has joined the channel [07:41] seebees has joined the channel [07:42] djcoin has joined the channel [07:43] jbpros has joined the channel [07:44] dubenstein has joined the channel [07:46] topaxi has joined the channel [07:48] cosmincx has joined the channel [07:51] gut4 has joined the channel [07:52] bergelmir has joined the channel [07:52] bergelmir has joined the channel [07:53] stagas has joined the channel [07:56] jacobolus has joined the channel [07:56] meso has joined the channel [07:56] aaronmcadam has joined the channel [07:57] cyberhus has joined the channel [07:58] kodekaran has joined the channel [07:58] Circlefusion has joined the channel [08:00] [AD]Turbo has joined the channel [08:00] robhawkes has joined the channel [08:00] louissmit has joined the channel [08:00] cyberhus: Hey, [08:01] Polysics has joined the channel [08:01] Polysics: hello [08:01] mpavel has joined the channel [08:01] cyberhus: I am running Ubuntu 10.04 and just finished installing nodejs and nowjs [08:02] replor___ has joined the channel [08:02] replore__ has joined the channel [08:02] cyberhus: but I have a hard time figuring out where to place the files [08:02] Polysics: why is npm installing packages in the current directory? [08:03] mpavel has left the channel [08:03] Polysics: i would like to have packages in a centralized place [08:03] neekers: Polysics: are you using express? [08:04] Polysics: express, socket.io and mysql [08:04] uchuff has joined the channel [08:04] neekers: express should be creating your project/file structure [08:04] cyberhus: Where should I place main.js, settings.js, etc ? [08:05] neekers: express creates a file called app.js [08:05] Polysics: i just include express, it has worked so far [08:05] Polysics: it's a websocket app + a REST API for posting events [08:05] Polysics: there are no views or stuff [08:05] neekers: from the command line type, express mynewproject [08:05] Polysics: but still, why isn't npm install just putting files where they should? [08:06] neekers: it does [08:07] Polysics: i was missing the -g switch, it seems [08:08] cyberhus: should the files be placed in the folder where I installed nodejs? [08:08] dean[w] has left the channel [08:09] alphahydrae has joined the channel [08:09] aliem has joined the channel [08:09] neekers: no [08:09] neekers: probably in your users directory [08:10] wbednars_ has joined the channel [08:10] markwubben has joined the channel [08:11] cyberhus: so there is no set predefined place where files should be placed [08:12] neekers: in your users directory, type express testproject [08:12] cyberhus: what is this express you mentioned? [08:12] cyberhus: i did , it said command not found [08:13] neekers: try npm install express first then [08:13] cyberhus: ok [08:14] neekers: did that work? [08:14] cyberhus: express@2.4.7 ./node_modules/express [08:14] cyberhus: ├── mkdirp@0.0.7 [08:14] cyberhus: ├── mime@1.2.4 [08:14] cyberhus: ├── qs@0.3.1 [08:14] cyberhus: └── connect@1.7.1 [08:14] cyberhus: cyberhus@Mialyhne:~$ express mynewproject [08:14] cyberhus: express: command not found [08:14] cyberhus: doesn't seem so [08:15] neekers: npm -g install express [08:15] mixin has joined the channel [08:17] neekers: did it work with the global switch? [08:17] neekers: -g [08:17] cyberhus: yes it did~$ express mynewproject [08:17] cyberhus: create : mynewproject [08:17] cyberhus: create : mynewproject/package.json [08:17] cyberhus: create : mynewproject/app.js [08:17] cyberhus: create : mynewproject/views [08:17] cyberhus: create : mynewproject/views/layout.jade [08:17] cyberhus: create : mynewproject/views/index.jade [08:17] cyberhus: create : mynewproject/public/javascripts [08:17] cyberhus: create : mynewproject/public/stylesheets [08:17] cyberhus: create : mynewproject/public/stylesheets/style.css [08:17] neekers: ok, you dont need to paste all that [08:17] cyberhus: create : mynewproject/public/images [08:17] skm has joined the channel [08:18] cyberhus: sorry :d [08:18] neekers: use pastebin.com if you need to show us something [08:18] neekers: or gist [08:18] neekers: cd into mynewproject [08:18] vguerra has joined the channel [08:18] cyberhus: yes [08:19] neekers: and type, npm install socket.io [08:19] TomY has joined the channel [08:19] felixhummel has joined the channel [08:20] neekers: after that type npm install jade [08:20] cyberhus: ok [08:20] herbySk has joined the channel [08:21] cyberhus: ok [08:21] neekers: then lastly type npm install -d [08:21] neekers: i'm pretty much a beginner but this is what i did to get the project working [08:22] cyberhus: and the files I mentioned before, should be in mynewproject folder? [08:22] neekers: you need to open up app.js and change app.listen(3000) to the port you want to use [08:22] cyberhus: I see [08:23] neekers: after that type node app.js [08:23] ditesh|cassini has joined the channel [08:24] cyberhus: ok [08:24] arcanis has joined the channel [08:24] neekers: and you should see a message saying express server running on port... [08:25] cyberhus: it does say so [08:25] neekers: so open your browser and go to that url [08:26] cyberhus: and when I try localhost:3000, it said welcome to express [08:26] neekers: localhost:8080 or what ever you changed it to [08:26] neekers: yes, so now you havre node.js working with socket.io [08:26] Polysics: why is express installing connnect 1.0.1, which gives it problems? [08:26] Polysics: i uninstalled connect and express [08:27] Polysics: installed connect 0.5.6 then express 1.0.7 [08:27] Polysics: i though it would not install connect 1.0.1 [08:27] eldios has joined the channel [08:27] ph^_ has joined the channel [08:29] Aiden has joined the channel [08:29] dexter_e has joined the channel [08:30] robhawkes has joined the channel [08:31] JSManiacs has joined the channel [08:31] cyberhus: what does the jade plugin do? [08:31] neekers: something to do with templates [08:33] cyberhus: I have a drupal 7 module that is supposed to load a chat app made with node and now js [08:34] Lemon_BE2 has joined the channel [08:36] vineyard has joined the channel [08:37] dsirijus has joined the channel [08:37] burningdog has joined the channel [08:37] k1ttty has joined the channel [08:39] sfoster has joined the channel [08:40] _kud has joined the channel [08:40] cyberhus: i have to figure out where to put the files the developer supplied [08:40] avih has joined the channel [08:40] robhawkes has joined the channel [08:41] joshgillies has joined the channel [08:42] neekers: i would probably put them in the public directory [08:43] cyberhus: i will try to test [08:44] cyberhus: thanks for the help [08:44] cyberhus: much appreciated :) [08:45] mc_greeny has joined the channel [08:48] nicferrier has joined the channel [08:50] replore has joined the channel [08:50] replore_ has joined the channel [08:50] davidbanham has joined the channel [08:51] adambeynon has joined the channel [08:51] jbpros_ has joined the channel [08:51] eldios has joined the channel [08:54] icebox has joined the channel [08:54] hellp has joined the channel [08:55] flimmern has joined the channel [08:56] flimmern has joined the channel [08:56] flimmern has left the channel [08:58] k1ttty has joined the channel [08:58] kulor-uk has joined the channel [08:58] cosmincx has joined the channel [08:59] nicferrier: can we talk npm here? or is there another place? [08:59] riven` has joined the channel [09:01] digman543 has joined the channel [09:02] icebox: nicferrier: what is the question? [09:03] nicferrier: I want to know if it's possible to make virtual package stores with npm [09:04] icebox: nicferrier: like a link? or what? [09:04] nicferrier: well, I'd like to tell node and npm where to put and look for modules [09:05] nicferrier: so I could build completly project based "virtual" installs [09:05] nicferrier: I don't really understand how npm fits together [09:05] nicferrier: I made a module directory [09:05] nicferrier: and put the pg module in it [09:05] icebox: nicferrier: ok [09:05] nicferrier: but I have to specify that as a requirement in the package script before npm "sees" it at build time [09:06] icebox: nicferrier: it seems correct... then npm install my/path/module [09:06] whitman has joined the channel [09:06] nicferrier: no, that installs into the global context doesn't it? [09:06] icebox: nicferrier: is dependency not enough? [09:06] Nuck: So, I need to load a var_dump'd string that got barfed out by PHP into my lovely JS. [09:07] Nuck: Any advice? [09:07] ayaz has joined the channel [09:07] icebox: nicferrier: I mean dependencies property in package.json [09:07] bzinger has joined the channel [09:07] nicferrier: icebox: not really if I want to virtualize it [09:07] Polysics: aside from stay as far away from PHP as physically possible? [09:07] nicferrier: if I want to install multiple copies of the same package (for testing say) [09:07] nicferrier: I can't do that [09:07] Nuck: Polysics: I'd love to, but I can't be assed to rewrite this entire chatbot in NodeJS ;P [09:07] Polysics: var_dump's format does not look like anything js can take and use [09:08] Nuck: And it's spitting configs in var_dump [09:08] Nuck: Polysics: With string parsing, it's possible, of course [09:08] Nuck: I wonder if I could magick it into a JSON object with some little hacks >_> [09:08] icebox: nicferrier: no... in local [09:09] markwubben has joined the channel [09:09] nicferrier: icebox: so I make myproject and I put pg in it [09:09] nicferrier: icebox: and resolve the dependancy [09:09] icebox: nicferrier: correct [09:09] nicferrier: icebox: now I want to install myproject [09:09] nicferrier: I install it [09:09] nicferrier: but I have to install it globally [09:09] nicferrier: I can't install it into a virtual root [09:09] nicferrier: and tell node to look in there can I? [09:09] icebox: icebox: there will be a node_modules directory inside the project and one for "live" env [09:10] nicferrier: right [09:10] aron_ has joined the channel [09:10] icebox: nicferrier: usually I have only npm installed globally [09:10] gut4 has joined the channel [09:11] nicferrier: it doesn't really matter whether npm is installed globally or not [09:11] nicferrier: where npm installs modules to globally and where node looks for them is really the issue [09:11] icebox: nicferrier: I said that because I don't need to install modules globally [09:11] nicferrier: it would be nice to virtualize that [09:11] nicferrier: icebox: ok [09:11] svnlto has joined the channel [09:12] nicferrier: so if I make a myproject module [09:12] icebox: nicferrier: npm installs the packages locally and globally [09:12] nicferrier: how do I use it from node? [09:12] icebox: nicferrier: npm install -g vs. npm install [09:12] nicferrier: because require("myproject") only looks in the global space [09:12] Polysics: Nuck, if the input is predictable (ie. has always the same structure) it looks easy-ish to massage it into JSON [09:12] icebox: nicferrier: no [09:13] nicferrier: icebox: ok. so if I have a directory with myproject in it [09:13] Nuck: Polysics: That's what I'm figuring. A bit of magickal regex and I can prolly have it to JSON [09:13] nicferrier: I can tell node to look in there? [09:13] icebox: nicferrier: correct [09:13] nicferrier: icebox: how? [09:13] Polysics: i gather you can't change PHP to encode output in JSON instead of var_dump'ing it [09:14] icebox: nicferrier: npm install myDependencyModuleForMyProject [09:14] Twelve-60: Question: It is possible to see whats on the event loop? [09:14] icebox: nicferrier: or if you haev been developing the module yourself: npm install my/module/path [09:14] nicferrier: icebox: I think I am not explaining myself very well [09:15] nicferrier: icebox: I make a module [09:15] simenbrekken: Is there a clever way to track down stray listeners in node.js? I'm running automated tests on an HTTPServer and it after 11 listen/close it complains about memory leak caused by 11 listeners that were added. [09:15] nicferrier: in a directory [09:15] icebox: nicferrier: no... np... maybe it is my fault :) [09:15] nicferrier: now I want to test it [09:15] nicferrier: I want to load it in node [09:15] nicferrier: I have to install it to ~/node_modules before I can do that. right? [09:15] nicferrier: I can't install it to ~/nicsnodeprojects/node_modules [09:16] nicferrier: and then tell node to look in ~/nicsnodeprojects/node_modules [09:16] nicferrier: because node doesn't seem to let me do that [09:16] icebox: nicferrier: I try to explain my lifecycle modules [09:17] icebox: nicferrier: with npm ls -g I see only npm module (and his dependecies) [09:17] c4milo1 has joined the channel [09:17] icebox: nicferrier: with npm ls I see the modules of my projects [09:18] nicferrier: but you have one set of projects [09:18] nicferrier: you can't make multiple sets [09:18] icebox: nicferrier: the root of my projects is, for instance, "dev" [09:18] nicferrier: icebox: ok. go on. [09:19] jldbasa has joined the channel [09:19] icebox: nicferrier: with npm install mymodule mymodule is installed locally in dev/node_modules [09:19] cdarne has joined the channel [09:19] icebox: nicferrier: when I need to test a new version of mymodule... [09:20] icebox: nicferrier: I change package.json version and I execute npm uninstall mymodule and then npm install my/module/path [09:20] bartt has joined the channel [09:20] icebox: nicferrier: now npm ls gives me the testing version of my module [09:20] nicferrier: ok. what if you had 2 projects [09:20] nail_: slightly off topic - what do you guys use for _functional_ web monitoring? [09:20] nicferrier: in your "dev" [09:20] nicferrier: and one of them depended on the other [09:21] icebox: nicferrier: ok [09:21] nicferrier: now what happens when you update one of them? [09:21] wbw721 has joined the channel [09:21] nicferrier: it might break the one that depends on it [09:22] iFire has joined the channel [09:22] icebox: nicferrier: if I don't use that broken module, I can temprary ignore it, otherwise you need to update that module too [09:22] torsd has joined the channel [09:22] nicferrier: icebox: exactly [09:22] nicferrier: that's what I'm looking for [09:22] nicferrier: a way to do that [09:22] icebox: nicferrier: I update the modules in the same way I explained [09:23] icebox: nicferrier: ah ok... I see the point [09:23] nicferrier: right [09:23] nicferrier: I want multiple "dev"s [09:23] icebox: nicferrier: I try to explain it... if I understood correctly [09:23] icebox: nicferrier: a module A and his dep B [09:24] icebox: nicferrier: you need to test B [09:24] icebox: nicferrier: but B is a dep of A [09:24] nicferrier: right [09:24] nicferrier: not so much test [09:24] icebox: nicferrier: ok... uninstall B and A, install new B, install lA [09:24] nicferrier: you need to change B i a way that will break A [09:25] icebox: nicferrier: if you install firstly new B, when you install A, the old dep is not loaded [09:25] nicferrier: but I can't fix A right now [09:25] nicferrier: I can't change A to cope with the change in B [09:25] bzinger has joined the channel [09:26] irahgel has joined the channel [09:26] bartt has joined the channel [09:26] icebox: nicferrier: Do you need to test A or B? [09:26] nicferrier: B is a new version [09:26] nicferrier: it breaks A [09:26] nicferrier: I don't have time to fix A for the change in B [09:26] icebox: nicferrier: but you need to test B [09:26] nicferrier: I need them both to work [09:26] nicferrier: A on the old version of B [09:26] icebox: nicferrier: ok [09:26] nicferrier: and B (the new one) [09:27] ppcano has joined the channel [09:27] nicferrier: if I install B (the old one) locally in A [09:27] rendar has joined the channel [09:27] icebox: nicferrier: ok... install A (with old B) and install new B [09:27] nicferrier: and then go and update B [09:27] ppcano has joined the channel [09:27] nicferrier: right [09:27] nicferrier: so it does give me some separation [09:27] nicferrier: but I have to do *everything* with modules [09:27] nicferrier: ok. [09:27] ppcano has joined the channel [09:27] icebox: nicferrier: well... I do that usually [09:28] nicferrier: and I can pin B to a version in A [09:28] nicferrier: and that will be fine [09:28] ppcano has joined the channel [09:28] nicferrier: ok. cool. [09:28] nicferrier: it kinda works then, thanks. [09:28] icebox: nicferrier: you see with npm ls two B: one below A, as dep, and another one, new B, alone [09:28] ppcano_ has joined the channel [09:28] NinjaFox has joined the channel [09:30] icebox: nicferrier: you can make require('B') and it will be loaded the new one [09:30] icebox: nicferrier: you can make require('A') and old B is loaded [09:31] nicferrier: icebox: through A. right. [09:31] ppcano has joined the channel [09:32] ppcano has joined the channel [09:32] nicferrier: oh [09:32] ppcano has joined the channel [09:32] nicferrier: I see that you can kinda do what I want anyway [09:32] ppcano has joined the channel [09:33] nicferrier: because you can alter require.paths inside node [09:33] darinc has joined the channel [09:33] nicferrier: but using npm in the way we're discussing seems like it will work [09:33] nicferrier: so I'll try that [09:33] icebox: nicferrier: maybe... usually I don't touch require.paths [09:33] ppcano has joined the channel [09:33] ppcano_ has joined the channel [09:33] icebox: nicferrier: it should work out-of-shell [09:34] T-Co has joined the channel [09:35] nicferrier: so npm link [09:35] nicferrier: if I'm developing a module [09:35] nicferrier: I can make a module directory [09:35] ppcano has joined the channel [09:35] ppcano has joined the channel [09:35] simenbrekken: I actually found an actual bug in node.js that isn't tributed to my noobiness! [09:35] nicferrier: and make a package.json with a version and a pointer to a main file [09:35] Cope has left the channel [09:35] icebox: nicferrier: I need B and old B only when I need to compare the behaviours... otherwise I install new B, then A and Itry to work with the new B [09:35] nicferrier: and then I go npm link mymodule [09:35] burningdog has joined the channel [09:36] ppcano has joined the channel [09:36] icebox: nicferrier: I don't use npm link [09:36] nicferrier: ok. it seems like it could be fast [09:36] nicferrier: and he says it's cool [09:36] nicferrier: I just don't see how to use it [09:36] icebox: nicferrier: :) [09:36] T-Co: Does anyone have ideas why npm install fails: http://pastebin.com/DAYztb9Y [09:37] Raul_ has joined the channel [09:37] Raul_: Hello [09:38] Raul_: i am havin some problems installing npm on my ubuntu 11.04 [09:38] Raul_: the curl command doesnt seem to be working [09:39] T-Co: :D [09:39] Raul_: I have tried googling for solutions [09:40] Raul_: and have been unable to work around it [09:40] T-Co: I also tried to make from sources: http://pastebin.com/LsHXxnx5 [09:40] T-Co: I'm on debian squeeze [09:40] Raul_: Oh ohk [09:41] guidocalvano has joined the channel [09:42] Raul_: On trying the simple curl command mentioned, i end up with a "gzip: stdin: unexpected end of file" [09:42] k1ttty has joined the channel [09:42] Raul_: error [09:42] Raul_: on trying to git clone the source and then make install [09:43] FireCat has joined the channel [09:43] Raul_: Clone of 'https://github.com/isaacs/abbrev-js.git' into submodule path 'node-modules/abbrev' failed. [09:43] Raul_: error pops up [09:44] Raul_: Any body has any idea of what could be going wrong with these installations. [09:44] Raul_: I have already spent about 10 hrs tryin to find a work around but to no avail [09:44] Raul_: any help would be greatly appreciated [09:45] adambeynon has joined the channel [09:46] T-Co: It's annoying that everywhere it is assumed that you have npm installed and working... What is the way of installing a module without npm? [09:46] T-Co: I have the package so what do I do? [09:46] metellus has joined the channel [09:46] T-Co: Nothing apparently :( [09:46] T-Co: :) [09:47] NinjaFox has left the channel [09:47] Raul_: I am also new to irc channels [09:47] Raul_: Does one actually get any help over here? [09:47] nicferrier: Raul_: you do, but remember no one is paid to do this... so be nice [09:48] nicferrier: and maybe no one is around right now to answer your question [09:48] icebox: T-Co: you may copy to node_modules directory [09:48] nicferrier: T-Co: I think using npm is advisable [09:48] T-Co: icebox, Yeah. Error: Cannot find module 'socket.io-client' :) [09:48] Raul_: Oh @nicferrier: Thanks for the response [09:48] T-Co: nicferrier, It would be, and I would very much like to use npm, but it wont install... [09:49] icebox: T-Co: check your NODE_PATH [09:49] [AD]Turbo has joined the channel [09:49] T-Co: icebox, What should it be? [09:49] T-Co: (it's empty atm) [09:49] icebox: T-Co: where have you the node_modules directory? [09:50] T-Co: icebox, I think I need more modules than just the socket.io basic package. I can nest the modules right? So just have node_modules directory inside the socke.io package and so on? [09:50] icebox: icebox: int the home directory? [09:50] T-Co: icebox, In pwd [09:50] beevi7: http://nodejs.org/logo.png [09:50] beevi7: is this the "official" node.js logo? [09:50] icebox: T-Co: it depends on the dependencies of the module [09:51] icebox: T-Co: do you start the node instance in pwd? [09:51] kodekaran has joined the channel [09:51] T-Co: icebox, Well, if I'm reading correctly: Error: Cannot find module 'socket.io-client' I think I need that... [09:51] T-Co: icebox, Yes [09:51] icebox: T-Co: correct [09:51] T-Co: The question was just that can I nest them [09:52] icebox: T-Co: no problem... you can install at same nesting level [09:52] Raul_: T-Co: wont it be better if you installed npm first . WOuld save you a much of hassling? [09:53] JakeyChan has joined the channel [09:53] predat0r has joined the channel [09:53] pickels has joined the channel [09:54] T-Co: Raul_, How many times do I have to say that it wont install :D [09:54] admin-_ has joined the channel [09:58] nicferrier: Raul_'s won't install either [09:59] CIA-48: node: 03Ryan Dahl 07 * r87339a2 10/ (lib/net.js src/node.cc src/node.js lib/cluster.js): introduce node cluster - http://git.io/06OXxQ [09:59] nicferrier: so can you pastebin what's happening? [09:59] nicferrier: either of you? [09:59] nicferrier: sounds like you both have the same kinds of problems [09:59] nicferrier: I am a node newbie [09:59] nicferrier: but I can try and help [10:00] Raul_: Written by John Gilmore and Jay Fenlason. fetching: gzip: stdin: unexpected end of file /bin/tar: Child returned status 1 /bin/tar: Error is not recoverable: exiting now It failed [10:00] T-Co: nicferrier, if you can see my pastebin links from backlog [10:00] Raul_: This happens when i run the curl command [10:00] T-Co: http://pastebin.com/DAYztb9Y and I also tried to make from sources: http://pastebin.com/LsHXxnx5 [10:01] nicferrier: T-Co: I think the whole session would be good to see... can I see what the command you typed is for example [10:01] nicferrier: also what systems are you on? [10:01] T-Co: debian squeeze [10:01] T-Co: The first one is the curl install | sh magic spell [10:02] T-Co: and the other on is "make" after configure in git cloned source dir [10:02] Raul_: T-Co: which version of node are you using if i may ask? [10:02] Raul_: anything below 0.4 wont work [10:02] T-Co: Raul_, I'm now compiling stable, I had the current master before [10:02] jimt_ has joined the channel [10:03] Raul_: T-Co : oh ohk [10:03] nicferrier: I just installed both from git [10:03] nicferrier: if you could make clean [10:03] nicferrier: and then do the whole thing again [10:03] nicferrier: including configure [10:03] T-Co: I coulnd't.. the same error [10:03] nicferrier: and capture that in the pastebin [10:03] T-Co: (with make clean) [10:03] nicferrier: that would be really useful [10:03] nicferrier: ok [10:03] Raul_: Me 2 [10:03] nicferrier: how about blowing it away and pulling from git again? [10:03] T-Co: Just a sec, I will try to install npm with the stable [10:03] Raul_: i have tried various version installation [10:04] nicferrier: so I have v0.4.9-pre [10:04] nicferrier: of node [10:04] T-Co: Works with stable [10:04] T-Co: It was 0.5.somtehing-pre [10:04] fermion has joined the channel [10:04] nicferrier: and 1.0.94 [10:04] nicferrier: of npm [10:04] T-Co: yup [10:05] T-Co: Now it installed just fine [10:05] T-Co: The master didn't work for some reason [10:05] Raul_: O.o [10:05] nicferrier: ok. are you good then? [10:05] T-Co: With npm [10:05] T-Co: I'm good now [10:05] nicferrier: cool. [10:05] Raul_: Lucky ! [10:05] nicferrier: what about you Raul_? [10:05] T-Co: Just FYI that the npm install script might not work with the current master [10:05] nicferrier: the current master of npm? [10:05] nicferrier: or node? [10:05] T-Co: node [10:06] nicferrier: got it. [10:06] Raul_: No , actually i tried the stable versions of both [10:06] nicferrier: I wouldn't use a dev version [10:06] nicferrier: ok Raul_ [10:06] nicferrier: I would go back to that [10:06] briandh has left the channel [10:06] nicferrier: pull git stable of node [10:06] Raul_: Lemme try fetching the npm stable again from git [10:06] nicferrier: or reinstall git stable [10:06] nicferrier: the install line for npm should work [10:06] nicferrier: but pulling both repos can't be a bad thing if you intend to play with it a lot [10:07] Raul_: Oh ohk [10:07] Raul_: i ll try that again [10:07] Raul_: and let you know [10:07] Raul_: when i am done [10:07] nicferrier: cool [10:07] Raul_: Thanks a lot for all the help [10:07] nicferrier: I'll be here [10:07] Raul_: :) [10:08] Raul_: I love the coding communtiy [10:08] Raul_: *community [10:08] mikeal has joined the channel [10:08] jetienne has joined the channel [10:08] nicferrier: yes, when everyone helps it's good. [10:09] piscisaureus has joined the channel [10:09] syrio has joined the channel [10:11] meso has joined the channel [10:12] ayaz has joined the channel [10:12] Wizek has joined the channel [10:13] jldbasa has joined the channel [10:14] sirdancealot has joined the channel [10:15] riven has joined the channel [10:15] riven has joined the channel [10:17] Wizek-other has joined the channel [10:18] NetRoY has joined the channel [10:18] amigojapan has joined the channel [10:21] agnat has joined the channel [10:26] fly-away has joined the channel [10:27] polyrhythmic has joined the channel [10:27] stagas has joined the channel [10:33] matyr has joined the channel [10:35] cjheath has joined the channel [10:36] ninjapig has joined the channel [10:39] gavin_huang1 has joined the channel [10:39] alphahydrae: Hi. I'm using express with sass and I noticed that in production mode (NODE_ENV=production), if I change a sass file, it is recompiled when I reload the page in my browser, and I can see the change. I couldn't find the documentation about this. Are the files recompiled only when they have changed, or are they recompiled for every request even in production? [10:40] ayaz` has joined the channel [10:42] stagas has joined the channel [10:43] ayaz has joined the channel [10:44] shortone has joined the channel [10:48] c__ has joined the channel [10:48] Anatol has joined the channel [10:48] Anatol has joined the channel [10:48] Anatol has joined the channel [10:48] Anatol has joined the channel [10:49] socketio\test\76 has joined the channel [10:50] YamahaAlex has joined the channel [10:51] davidbanham has joined the channel [10:51] bshumate has joined the channel [10:51] bshumate has joined the channel [10:54] luke` has joined the channel [10:55] __tosh has joined the channel [10:55] luke` has joined the channel [10:55] chiggy has joined the channel [10:56] nforgerit has joined the channel [10:58] mike5w3c has joined the channel [10:58] HardPhuc has joined the channel [11:00] blup has joined the channel [11:01] slifty has joined the channel [11:05] vineyard has joined the channel [11:06] bzinger has joined the channel [11:07] joshgillies has left the channel [11:07] paul_k has joined the channel [11:07] stagas has joined the channel [11:08] mmalecki has joined the channel [11:09] joshgillies has joined the channel [11:10] jimt has joined the channel [11:12] toopay has joined the channel [11:15] gut4 has joined the channel [11:17] ditesh|cassini has joined the channel [11:17] stagas_ has joined the channel [11:19] alphahydrae: What is the default behavior of express.compiler in production mode? Does it compile the files for every request or only once? [11:21] bergie has joined the channel [11:23] Frippe has joined the channel [11:24] flexd has joined the channel [11:27] k1ttty has joined the channel [11:28] skm has joined the channel [11:28] eee_c has joined the channel [11:29] okuryu has joined the channel [11:30] Poetro has joined the channel [11:30] flexd has joined the channel [11:31] swick has joined the channel [11:33] fairwinds has joined the channel [11:36] stagas_ has joined the channel [11:36] cgfuh has joined the channel [11:38] aliem has joined the channel [11:39] chiggy has joined the channel [11:40] matyr has joined the channel [11:41] mraleph1 has joined the channel [11:41] uchuff has joined the channel [11:41] jerkelens has joined the channel [11:42] cde has joined the channel [11:42] __tosh has joined the channel [11:46] guidocalvano: morning! [11:49] _th_n_ has joined the channel [11:49] Casan has joined the channel [11:50] scott_gonzalez has joined the channel [11:50] mekwall has joined the channel [11:52] guidocalvano: anyone know how you can get requirejs to put third party scripts in an object? [11:52] guidocalvano: for example: right now I'd really like to use qunit [11:52] stagas has joined the channel [11:53] guidocalvano: but I'd like to load qunit in a var qunit inside the function my script for testing passes to define [11:53] gut4 has joined the channel [11:54] guidocalvano: unfortunately all functions in define are functions defined in the global scope, with easily name clashed names such as 'test'.... [11:55] guidocalvano: *unfortunately all functions in qunit are functions defined in the global scope, with easily name clashed names such as 'test'.... [11:55] DennisRasmussen has joined the channel [11:56] koo6 has joined the channel [11:58] _kud has joined the channel [12:00] ph^ has joined the channel [12:00] kawaz_home has joined the channel [12:00] mandric has joined the channel [12:01] Guest___ has joined the channel [12:02] piscisaureus has joined the channel [12:07] jbpros has joined the channel [12:08] baudehlo has joined the channel [12:09] nicferrier: guidocalvano: that's a nightmare [12:09] nicferrier: not sure how you fix that [12:10] Raul_: Hello everyone [12:10] Raul_: Hi nicferrier [12:11] nicferrier: hi [12:11] Raul_: Well i am having a problem installing npm on my ubuntu 11.04 [12:11] ayaz has joined the channel [12:11] Raul_: i have node version 0.4.11 installed and it works like a charm [12:11] OneOfOne: guidocalvano: *untested* but try : var tmp = globals; globals = {}; var qunit = require('qunit'), quint_globals = globals; globals = tmp; [12:12] Raul_: but when i try installing npm using the curl command, this is what i get http://pastebin.com/qbHJ2RfB [12:12] matyr has joined the channel [12:13] cjm has joined the channel [12:13] Raul_: I did try finding solutions online which suggested me to try installing from source but then i get this http://pastebin.com/KMsSrcCH [12:13] Raul_: Any help would be great! [12:13] nicferrier: looks like you have something wrong with gzip? [12:14] Raul_: i thought so too [12:14] OneOfOne: Raul_: try wget -O - http://npmjs.org/install.sh | bash [12:14] OneOfOne: i think ubuntu uses a weird shell for sh, not very sure [12:15] nicferrier: or curl http://npmjs.org/install.sh | bash [12:15] Raul_: @OneOfOne: Same error [12:15] nicferrier: if that's the case [12:15] nicferrier: I think ubuntu uses bash tho [12:15] nicferrier: or zsh [12:15] AaronMT has joined the channel [12:15] mehtryx has joined the channel [12:15] Raul_: @nicferrier : same error repeats [12:15] nicferrier: try pastebining the output of [12:16] nicferrier: curl http://npmjs.org/install.sh | bash -x [12:16] OneOfOne: Raul_: you can always install it from git, although that is pretty weird [12:17] OneOfOne: Raul_: git clone https://github.com/isaacs/npm.git && cd npm && sudo make install [12:17] whitman: curl http://npmjs.org/install.sh | sudo sh <-- need to be root to install, might help [12:17] OneOfOne: https://github.com/isaacs/npm [12:17] nicferrier: OneOfOne: he's having similar problems installing from git [12:17] CarterL has joined the channel [12:17] OneOfOne: nicferrier: oh oops missed that [12:17] nicferrier: history from this morning [12:17] nicferrier: :-) [12:17] Raul_: @OneOfOne; http://pastebin.com/KMsSrcCH my [pstebin when i try from source [12:18] Raul_: @nicferrier: http://pastebin.com/KRT225sy here's the pastebin [12:18] OneOfOne: error: Couldn't resolve host 'github.com' while accessing https://github.com/isaacs/abbrev-js.git/info/refs [12:18] Raul_: exactly [12:19] nicferrier: Raul_: in that from source thing... don't you have to configure && make [12:19] nicferrier: ? [12:19] OneOfOne: nicferrier: it auto fetches submodules [12:19] Raul_: i though we just had to sudo make install [12:19] OneOfOne: and it looks like you got disconnected in the middle [12:19] OneOfOne: Raul_: try again the git install [12:20] Raul_: Sure [12:20] nicferrier: l109 looks suspicious to me [12:20] nicferrier: like it's not fetching anything [12:21] bzinger has joined the channel [12:21] Wizek-other has joined the channel [12:21] paul_k has joined the channel [12:21] OneOfOne: nicferrier: Raul_ i wanna say your internet is messed up or something [12:21] OmidRaha has joined the channel [12:22] Raul_: @OneOfOne: Erm.. i am behind a proxy in my uni.. [12:22] syrio has joined the channel [12:23] OneOfOne: Raul_: i called it! you have http_proxy & https_proxy set? [12:23] Raul_: erm in my .bash rc, right? [12:23] OneOfOne: Raul_: and did sudo make install work this time? [12:23] OneOfOne: yes [12:24] Raul_: No sudo make install got the same err [12:24] Raul_: yeah i think i have hhtp_proxy [12:24] Raul_: not sure about https [12:24] Raul_: *http [12:24] fumanchu182 has joined the channel [12:24] Riton has joined the channel [12:24] Riton: hi guys [12:25] OneOfOne: hello [12:25] Riton: I got a problem when trying to install npm with the 1-line commande "curl http://npmjs.org/install.sh | sh" [12:25] Riton: I get this error : [12:25] Riton: node.js:202 throw e; // process.nextTick error, or 'error' event on first tick [12:25] Riton: any ideas ? [12:25] OneOfOne: need the line after that [12:26] Riton: Error: No such module at Object. (/tmp/npm.8516/package/lib/utils/config-defs.js:5:21) [12:26] OneOfOne: your proxy is doing something weird [12:27] Riton: I don't have a proxy [12:27] nicferrier: ahhh [12:27] OneOfOne: Riton: Raul_ https://github.com/isaacs/abbrev-js/tarball/master and try to install from that tarball (tar xzf blah && cd blah && sudo make install) [12:27] Riton: ok [12:27] nicferrier: this is why it's important to get full logs [12:27] nicferrier: :-) [12:27] nicferrier: I bet it's your proxy [12:27] nicferrier: can you avoid the proxy Raul_? [12:27] Raul_: @ OneOfOne: i have [12:27] Raul_: export http_proxy=http://username:password@proxyserver.net:port/ export ftp_proxy=http://username:password@proxyserver.netport/ [12:27] Raul_: in my /etc/bash.bashrc file [12:27] OneOfOne: actually Raul_ try http://github.com/isaacs/abbrev-js/tarball/master [12:28] OneOfOne: i think your proxy is messing up with https [12:28] Raul_: oh ohk [12:29] piscisaureus has joined the channel [12:29] Raul_: But are you sure, because you are referring to a master which might not be stable? [12:30] OneOfOne: Raul_: http://github.com/isaacs/abbrev-js/tarball/v1.0.2 [12:30] OneOfOne: rt [12:30] OneOfOne: ignore that [12:30] tisba has joined the channel [12:30] OneOfOne: wrong package [12:30] Raul_: ignore the v1.0.2 or the master? [12:31] Riton: "< OneOfOne> Riton: Raul_ https://github.com/isaacs/abbrev-js/tarball/master" <= that's not npm ? [12:31] OneOfOne: Raul_: http://github.com/isaacs/npm/tarball/v1.0.94 [12:31] Riton: ah [12:31] Riton: thks [12:31] OneOfOne: Riton: Raul_yes sorry, had the wrong thing open [12:31] OneOfOne: Raul_: both [12:31] N0va` has joined the channel [12:31] OneOfOne: Raul_: http://github.com/isaacs/npm/tarball/v1.0.94 [12:31] Raul_: Ohk [12:32] Riton: Error: Cannot find module 'graceful-fs' [12:32] Riton: to install the module manager, I have ton install a module first ? ;( [12:32] Riton: (when I make install) [12:32] erichynds has joined the channel [12:32] OneOfOne: lol [12:33] enmand has joined the channel [12:33] hoodow has joined the channel [12:33] hoodow has joined the channel [12:33] OneOfOne: i'm about to give up [12:33] Raul_: :( [12:33] Raul_: I get the same err [12:34] torsd has joined the channel [12:34] slifty has joined the channel [12:34] hernan has joined the channel [12:34] OneOfOne: Riton: Raul_ ok one last idea, download the git repo, before sudo make install, open .gitmodules in your favorite editor and replace all https:// with http:// [12:34] replore has joined the channel [12:34] replore_ has joined the channel [12:34] Raul_: Oh yes btw if we read the installation read me [12:34] Raul_: isaacs does mention that [12:34] Raul_: you have to download the submodules [12:34] Raul_: a list is provided in the .gitmodules [12:34] Raul_: in the downloaded folder [12:35] OneOfOne: Raul_: i know, switch all the https:// with http:// [12:35] Raul_: Oh ohk [12:35] Riton: I'm not behind a proxy, should change anything [12:35] Riton: *shouldn't [12:35] OneOfOne: sed -i 's/https:/http:/g' .gitmodules [12:35] OneOfOne: Riton: what distro [12:35] Riton: ubuntu [12:35] Raul_: Btw OneOfOne: is there anything i can add directly in the .bashrc itself? [12:35] OneOfOne: ubuntu is racist against npm [12:35] Riton: ;/ [12:35] Raul_: i mean to work around https [12:36] OneOfOne: Raul_: i've never had that problem, i bet good money it's either your proxy or ubuntu's ssl libaries are broken [12:36] OneOfOne: Raul_: no, just gotta edit the .gitmodules file [12:36] OneOfOne: and it'll use http instead [12:36] jamescarr: OneOfOne, that is a lie [12:36] mAritz has joined the channel [12:36] jamescarr: I've been using node since the 0.1 releases on ubuntu [12:36] alphahydrae: Does anyone know anything about the express compiler for sass and such? I'd like to know when it recompiles the sass files to css, especially in production mode. Does it recompile every file for every request or only when the files have changed? I found no documentation about this. [12:36] jamescarr: and been using npm since it was competing with kiwi [12:36] OneOfOne: jamescarr: don't tell me that, tell their ubuntus :P [12:36] Wizek has joined the channel [12:37] jamescarr: ubuntu plays fine with npm, it's a user problem :) [12:37] OneOfOne: jamescarr: 2 people with different connections having the same problems installing npm [12:37] Esteb has joined the channel [12:37] erichynds has joined the channel [12:37] jamescarr: always works fine for me :) [12:37] mraleph has joined the channel [12:37] Raul_: A stupid question to save time: how long does the make install take [12:38] Riton: is npm compatible with v0.5.10-pre ? [12:38] Shrink has joined the channel [12:38] Shrink has joined the channel [12:38] jamescarr: but then again, I curl and wget like a mother F'er on a regular basis [12:38] OneOfOne: Raul_: as fast as your connection can download the needed modules [12:38] Raul_: ohk [12:38] Raul_: mine is stuck with this on screen [12:38] Raul_: rahul@android:~/Downloads/isaacs-npm-2430880$ sudo make install ! [ -d .git ] || git submodule update --init --recursive scripts/doc-build.sh doc/api/install.md man/man3/install.3 [12:38] vguerra has joined the channel [12:39] Riton: Raul_: alomost same screen (outdated instead of install.3) [12:39] Riton: and stuck too [12:39] OneOfOne: i'm out of ideas [12:39] OneOfOne: jamescarr: have a go at it [12:39] Riton: \o/ jamescarr our savior [12:39] Raul_: :') [12:40] elliottcable: “Damn, I broke sqlite. Someone call an ambulance. And find my pants.” [12:40] elliottcable: hahahahaha best quote this year [12:41] jamescarr: elliottcable, har har har [12:41] elliottcable: jamescarr › nou [12:42] Raul_: I am unable to come to terms with the fact that its now 2 days that i have spent just tryin to install a module. [12:42] jamescarr: Raul_, npm installed successfully? [12:42] TomY has joined the channel [12:42] jamescarr: Raul_, what is the output when you do something like npm install -g coffee-script? [12:42] Raul_: @jamescarr: sorry to disappoint, no [12:43] jamescarr: ah [12:43] jetienne has joined the channel [12:43] Raul_: No its not yet installed [12:43] Raul_: :( [12:43] Raul_: Sigh [12:43] jamescarr: can you run "curl http://npmjs.org/install.sh | sudo sh" and gist the output? [12:43] Raul_: http://pastebin.com/qbHJ2RfB [12:43] Raul_: here it is [12:44] Raul_: i get the same output with sudo too [12:44] jamescarr: your tar version is broken [12:44] darinc has joined the channel [12:44] jamescarr: I saw this issue on github [12:44] Riton: https://gist.github.com/1281140 [12:45] patrickgamer has joined the channel [12:46] TomY has joined the channel [12:46] patrickgamer has left the channel [12:46] Raul_: @Jamescarr : but i am able to untar other "normal" files [12:46] Raul_: how do i check if my tar is the root cause of the problems [12:46] Raul_: ? [12:47] Sami_ZzZ has joined the channel [12:47] paul_k has joined the channel [12:47] jamescarr: Raul_, one sec, looking through the issues on github [12:47] jamescarr: sorry [12:47] jamescarr: I might have to jet before helping you out [12:48] Raul_: Oh ohk. I am here for another 45 minutes though [12:48] jamescarr: best guess: sudo apt-get update and sudo apt-get install tar [12:48] Sorella has joined the channel [12:49] jomoho has joined the channel [12:50] Raul_: #doing that now. but somehow i have a hunch that the problem doesnt lie there [12:50] Metal3d has joined the channel [12:50] jamescarr: Raul_, or zlib [12:51] jamescarr: but yeah, I cannot find the issue... someone reported the exact same problem on github and a solution was posted [12:52] gooseus has joined the channel [12:52] Raul_: I did encounter similar porblems as mine [12:52] Raul_: but then they were told to try installin from source and somehow it worked for them [12:52] Raul_: Mines is a differnet story.. [12:53] lv has joined the channel [12:53] lv: how to test whether socket.io installed properly? [12:54] dthompso99 has left the channel [12:55] OneOfOne: lv: http://socket.io/ [12:55] Raul_: or this : http://stackoverflow.com/questions/4410214/installing-setting-up-socket-io-on-my-server [12:56] mraleph1 has joined the channel [12:57] deedubs has joined the channel [12:57] Raul_: I am so glad that people try to help [12:57] Raul_: :) [12:58] lv: $ git clone git://github.com/LearnBoost/Socket.IO-node.git socket.io-node --recursive && cd socket.io-node/example/ when i try this i got " could not find repository LearnBoost/Socket.IO-node" error [12:58] `3rdEden: thats because it's socket.io [12:58] `3rdEden: .. /learnboost/socket.io [12:58] catb0t: SyntaxError: Invalid flags supplied to RegExp constructor 'socket' [12:58] `3rdEden: ACTION slaps catb0t [12:59] `3rdEden: and iv just install it using npm [12:59] `3rdEden: as you need to install a shitload of dependecies as well [12:59] Raul_: truckload he means [12:59] davidsklar has joined the channel [13:02] bnoordhuis has joined the channel [13:02] lv: i installed using "$ npm install socket.io" after that "$ git clone git://github.com/LearnBoost/Socket.IO-node.git socket.io-node --recursive && cd socket.io-node/example/" [13:03] OneOfOne has left the channel [13:03] lv: i got " could not find repository LearnBoost/Socket.IO-node" error [13:03] OneOfOne has joined the channel [13:03] mraleph has joined the channel [13:04] JakeyChan has joined the channel [13:04] __tosh has joined the channel [13:04] lazyshot has joined the channel [13:05] `10`: any thoughts on why express might be passing a null request object? [13:05] darinc has joined the channel [13:06] ayaz has joined the channel [13:06] shanebo has joined the channel [13:06] vineyard: Does anyone know about a WolframAlpha API wrapper for node.js? [13:08] JasonJS has joined the channel [13:10] joshkehn has joined the channel [13:11] djazz has joined the channel [13:12] nicferrier: so Raul_ are you sorted now? [13:12] _kud_ has joined the channel [13:12] nicferrier: or it's still broken? [13:12] Raul_: @nicferrier.. well its still broken atm [13:13] nicferrier: hum [13:13] jorenl_ has joined the channel [13:13] nicferrier: so concentrating on the curl | sh trick [13:13] nicferrier: that looked like the script just wasn't downloading properly [13:13] Wizek has joined the channel [13:14] Raul_: yeah that or the tar thing [13:14] Raul_: might be broken which i doubt though [13:14] nicferrier: ok [13:14] nicferrier: so how about this [13:14] kriszyp has joined the channel [13:14] nicferrier: curl the script > theinstallscript [13:14] Raul_: http://pastebin.com/qbHJ2RfB [13:14] Raul_: this is the pastebin again [13:14] nicferrier: and then shell theinstallscript [13:14] nicferrier: fixing the problems as they come up? [13:14] EyePulp has joined the channel [13:15] nicferrier: so if you curl the script and save it [13:15] darinc has joined the channel [13:15] jorenl_: Hey, does socket.io have a client side disconnect event? [13:15] nicferrier: we can then run the script repeatedly with bash -x [13:15] HardPhuck has joined the channel [13:16] nicferrier: Raul_: any good? [13:16] Raul_: I am still exec the commnd you gave me [13:17] nicferrier: hum, well that was sketchy [13:17] JasonJS: jorenl_: It's the standard socket 'disconnect' - both sides get it [13:17] nicferrier: it should be [13:17] jorenl_: JasonJS: thanks. [13:17] nicferrier: curl http://npmjs.org/install.sh > npminstall.sh [13:17] nicferrier: yes? [13:17] JasonJS: jorenl_: Depending on what your socket timeout it set to it make take a while to actually fire though [13:17] Raul_: yes done [13:18] Raul_: and then? [13:18] nicferrier: now [13:18] nicferrier: bash -x npminstall.sh [13:18] nicferrier: and we'll see where it breaks [13:18] _kud has joined the channel [13:18] nicferrier: and then we'll hand fix the script [13:18] nicferrier: or something [13:19] piscisaureus has joined the channel [13:19] Raul_: #postin the pastebin in a second [13:19] _kud has joined the channel [13:20] eee_c has joined the channel [13:20] Raul_: Well nicferrier: http://pastebin.com/2hYazxkd [13:20] joshkehn has left the channel [13:20] Kunda has joined the channel [13:23] miccolis_ has joined the channel [13:23] _kud has joined the channel [13:23] nicferrier: Raul_: 2 seconds [13:24] Raul_: Oh ohk [13:24] nicferrier: sry, was in the loo [13:24] nicferrier: looking now [13:24] dthompso99 has joined the channel [13:24] nnisi has joined the channel [13:25] nicferrier: this: curl -SsL --cacert /tmp/npm.11764/cafile.crt https://registry.npmjs.org/npm/latest | sed -e 's/^.*tarball":"//' -e 's/".*$//' [13:25] nicferrier: is failing [13:25] nicferrier: trying to see why [13:25] nicferrier: do you still have this file? /tmp/npm.11764/cafile.crt on your system? [13:26] darinc has joined the channel [13:26] Aikar: why are you doing that anyways [13:26] nnisi has joined the channel [13:26] nicferrier: Aikar: trying to debug a problem installing npm [13:26] Raul_: Yes i Do [13:26] nicferrier: ok [13:26] nicferrier: so now try this [13:27] nicferrier: curl -SsL --cacert /tmp/npm.11764/cafile.crt https://registry.npmjs.org/npm/latest [13:27] nicferrier: and pastebin the output? [13:27] jerkelens has joined the channel [13:27] nicferrier: or gist or whatever you're comfortable with [13:27] cruxst has joined the channel [13:27] Raul_: no output to report [13:27] Raul_: Oh that worked just fine [13:28] nicferrier: no output tho? [13:28] Raul_: None at all [13:28] Riton: found the solution ? [13:29] jorenl_: JasonJS: I can see it loses connection to the server in the firebug console, then the event gets triggered 23 seconds after. Pffff [13:29] nicferrier: Raul_: because I got this http://pastebin.com/5TEReTbK [13:29] nicferrier: so that's where it's all going wrong [13:29] `10`: getting a weird behavior with express: with a function(req, res) { console.log(req); console.log(res); } it's looking like req = null and res is the request object [13:29] nicferrier: Raul_: have you checked curl versions etc...? [13:29] Raul_: 7.21.3 the version [13:30] k1ttty has joined the channel [13:30] stagas has joined the channel [13:30] nicferrier: I have 7.21.7 [13:30] nicferrier: but I can't imagine that's the problem [13:30] JasonJS: jorenl_: Yeah - the only way to address that is to reduce the keep-alive duration. The issue is that it isn't actively polling the connection but rather waiting for network traffic. Until traffic arrives or it misses an expected packet you're out of luck :( [13:30] catshirt has joined the channel [13:31] nicferrier: Raul_: can you decontaminate your curlrc and pastebin that? [13:31] nicferrier: don't leave passwords in! [13:31] Raul_: :') [13:31] nicferrier: i don't have a .curlrc btw [13:31] Raul_: you ll have to break that for me please [13:31] nicferrier: ? [13:31] mendel_ has joined the channel [13:32] localhost has joined the channel [13:32] Raul_: deconctaminate your curlrc? [13:32] nicferrier: remove passwords and other secure information from it [13:32] nicferrier: something else you can try [13:32] nicferrier: visit https://registry.npmjs.org/npm/latest [13:32] nicferrier: in a browser [13:32] nicferrier: can you see it? [13:33] nicferrier: I think you're having trouble with https, curl and the certificate not being a real one somehow [13:33] nicferrier: in fact [13:33] Raul_: oh i think it might be that [13:33] paul0 has joined the channel [13:33] Raul_: when i try it in my browser [13:33] Raul_: it says that the certi is untrusted [13:33] nicferrier: yes [13:33] nicferrier: that's why they supply the cert file [13:33] Raul_: SSL err [13:34] Raul_: oh ohk [13:34] nicferrier: do this: curl -SsL --cacert /tmp/npm.11764/cafile.crt https://registry.npmjs.org/npm/latest && echo $? [13:34] Raul_: :') [13:34] lv: should i install NPM and Socket.io in node foler itself or out side of it? in this link http://www.giantflyingsaucer.com/blog/?p=1688 authot says 'Now you can grab NPM and install it (I moved out of the node folder first):'any suggetions? [13:34] Raul_: It executed [13:34] Raul_: without any problem [13:34] Raul_: but no output again [13:34] nicferrier: ??? [13:35] Aikar: lv what does `which node` output? [13:35] Aikar: is it installed globally to the system or to your local user? [13:35] thomblake has joined the channel [13:35] nicferrier: Raul_: ok. [13:35] nicferrier: curl -SsL --cacert [13:35] nicferrier: /tmp/npm.11764/cafile.crt [13:35] nicferrier: https://registry.npmjs.org/npm/latest [13:35] Raul_: the curl -SsL that you told me to try [13:35] thomblake has left the channel [13:35] nicferrier: and THEN echo $? [13:35] Raul_: didnt give any output [13:35] nicferrier: I'm trying to see what the error code from curl is [13:36] nicferrier: echo $? [13:36] nicferrier: should be put in directly after the curl command finishes [13:37] Venom_X has joined the channel [13:37] Raul_: 56 [13:37] Raul_: nicferrier: 56 [13:37] nicferrier: aha! [13:38] Raul_: do you get it ? [13:38] vquaiato has joined the channel [13:38] nicferrier: curl error 56 Failure in receiving network data. [13:38] lv: while installinng nodejs before ./configure i moved to cd node v0.4.12 [13:38] nicferrier: so something *is* going wrong with that curl [13:38] Raul_: nicferrier you rock :) [13:38] nicferrier: so a possible fix is this [13:39] nicferrier: use your browser to download that url [13:39] stagas has joined the channel [13:39] nicferrier: save it to a file [13:39] Aikar: lv: it doesnt matter what dir you installed it from, it matters if you used a --prefix=/blah flag on ./configure and whether you needed sudo or not [13:39] nicferrier: and then change l96 in this pastebin http://pastebin.com/2hYazxkd [13:39] nicferrier: to read [13:39] _kud has joined the channel [13:39] nicferrier: cat thefilenameIsavedthatdataas [13:39] nicferrier: hmmm [13:39] nicferrier: wait [13:39] gut4 has joined the channel [13:39] Aikar: lv: if you left defaults and used sudo, itll be installed globally, and then npm will also be installed globally (requiring sudo to install) [13:40] Aikar: then when you -g instal la module, itll also require sudo [13:40] nicferrier: Raul_: pastebin the file npminstall that we made [13:40] Aikar: but if you local installed, itll just all go to that local folder [13:40] Aikar: but all NORMAL npm installs goes to your CURRENT directory [13:40] Aikar: ie `npm install socket.io` will go into current dir [13:40] micrypt has joined the channel [13:40] Aikar: regardless of where npm is installed [13:41] micrypt: nicferrier: Hola [13:41] nicferrier: micrypt: hola dude [13:41] Aikar: and lv that article is really old [13:41] nicferrier: micrypt: you heard me all the way over in twitter land? impressive [13:41] Raul_: nicferrier [13:42] Aikar: node is about to be on .6 [13:42] Raul_: i have to jet now [13:42] Aikar: that is targetting .2 [13:42] micrypt: nicferrier: Yup. :) How's the veh port coming along? [13:42] nicferrier: micrypt: lol. I'm trying to beat npm into submission [13:42] Raul_: i ll try your solution asap when i get back in like an hour [13:42] nicferrier: I think it makes sense [13:42] vipaca has joined the channel [13:42] vipaca has joined the channel [13:42] nicferrier: Raul_: paste me the npminstall file [13:42] nicferrier: I have to run out too [13:43] lv: yes will it be a problem? [13:43] Raul_: how do i do that if u are offline? [13:43] lv: So after $ npm install socket.io I gave $ git clone git://github.com/LearnBoost/Socket.IO-node.git socket.io-node --recursive && cd socket.io-node/example/ and I got 'could not find repository LearnBoost/Socket.IO-node' error [13:43] nicferrier: I won't be offline [13:43] Raul_: #new to irc [13:43] Raul_: oh ohk [13:43] nicferrier: I'll just be away [13:43] Raul_: sure then [13:43] Raul_: :) [13:43] ayaz has joined the channel [13:43] Raul_: bbye for now [13:43] Aikar: lv why the git clone? [13:43] `3rdEden: iv [13:43] `3rdEden: go to [13:43] Aikar: lv: is node and npm installed successfully? [13:43] `3rdEden: github.com/learnboost/socket.io-node [13:43] Aikar: if so, cd ~/projectyouwanttoinstallsocketioto [13:43] `3rdEden: read it [13:44] Aikar: then npm install socket.io [13:44] lv: yes [13:44] `3rdEden: github.com/learnboost/socket.io-node lv read the read me. [13:44] Kunda: looks like homebrew on my MACOS10.6.8 is downloading version node-v0.2.2.tar.gz when i use "brew install node" [13:44] lv: then how should i run chat example to test socket.io? [13:44] DanoManion has left the channel [13:45] stagas has joined the channel [13:45] darinc1 has joined the channel [13:45] lv: i installed socket.io to as $ npm install socket.io [13:46] jscheel has joined the channel [13:46] Aikar: `3rdEden: i can has http:// prefix?! [13:47] AphelionZ has joined the channel [13:47] Aikar: and `3rdEden fail on link that just tells you to go elsewhere :P [13:47] `3rdEden: :$ [13:47] Aikar: lv: when you npm install a module, itll be in ./node_modules/socket.io [13:48] Aikar: https://github.com/LearnBoost/socket.io/blob/master/Readme.md [13:48] CIA-48: node: 03Ben Noordhuis 07 * r752571c 10/ src/node.cc : Remove --use-legacy switch from --help section. - http://git.io/5IklsA [13:48] adambeynon_ has joined the channel [13:49] magnetik_ has joined the channel [13:50] lv: i checked socket.io is there in ./node_modules [13:50] colinclark has joined the channel [13:51] aron_ has joined the channel [13:52] syrio has joined the channel [13:52] DarkGrey has joined the channel [13:52] NetRoY has joined the channel [13:52] OmidRaha has joined the channel [13:52] Aikar: lv: and thats how node modules work. you install 'tools' globally (npm), then using modules in your app, you cd to your apps folder and run npm install [13:52] Aikar: if you have 5 projects that use socket.io, youll install socket.io into all 5 of thems folder [13:53] stagas has joined the channel [13:54] Aikar: or if your really doing things locally only for the sake of playing with no intent to deploy to another server, you can bypass isaacs hiding of global modules with this :P [13:54] arcanis has joined the channel [13:54] Aikar: mv /usr/local/lib/node_modules/* /usr/local/lib/node/ && rm -rf /usr/local/lib/node_modules && ln -s /usr/local/lib/node/ /usr/local/lib/node_modules [13:55] Aikar: then you can `npm install socket.io -g` and then every project on your system will have access to it, but dont do that for stuff outside of prototyping! [13:56] darinc has joined the channel [13:56] trose: if I create a server with socket.io is it possible to receive signals with a client written in a different language? i.e. if my client is running in c++ or java. Forgive me if this is a dumb question. I'm new to networking [13:56] Aikar: trose: if you implement the websocket protocol and the socket.io protocol, sure [13:57] lv: what if i uninstall npm socket.io and install them in node-v0.4.12 folder? [13:57] Aikar: lv: theres no point of that [13:57] Aikar: you dont install stuff into the SOUCE folder [13:57] Aikar: you can delete the node-v0.4.12 folder now that its installed [13:58] trose: Aikar, cool I've been working with vanilla node.js and i'm having problems sending information back to the client. Basically I'm getting a socket.on('end'... then processing the information and i want to send it back but i can't reference the socket from within the callback [13:58] Aikar: id recommend `npm install n -g` [13:58] trose: that's a net.Socket btw... [13:58] Aikar: then you can switch node versions easy with `n latest` or `n 0.4.13` [13:58] eee_c has joined the channel [13:59] eee_c has joined the channel [13:59] _jhs has joined the channel [14:00] Aikar: ryah bnoordhuis: can you guys look into this https://github.com/joyent/node/issues/1863 [14:00] mandric has joined the channel [14:00] Aikar: about to try the test on my work pc too [14:01] Croms has joined the channel [14:02] stagas has joined the channel [14:02] d0k has joined the channel [14:02] Nuck|CrapOS has joined the channel [14:04] bradleymeck has joined the channel [14:05] jorenl_: shouldn't process.on('uncaughtException', function(err) {console.log(err); }); actually show some error message? [14:05] jorenl_: I always just get {} in my console. [14:06] willwhite has joined the channel [14:06] Poetro has joined the channel [14:06] darinc has joined the channel [14:07] crunchmaster has joined the channel [14:08] darinc has joined the channel [14:10] ceej has joined the channel [14:10] Aikar: how do you compile node in 32bit mode on an x64 system? [14:10] zmbmartin has joined the channel [14:10] `3rdEden: Aikar 0.4 uses the V8 crankshaft engine [14:11] `3rdEden: so your js code might un optimized ;O? [14:11] `3rdEden: 0.5* [14:11] chrischris has joined the channel [14:11] Aikar: `3rdEden: im trying to test if its an x64 problem [14:11] Aikar: and node itself experiences this issue [14:11] Aikar: I wrote a baseline benchmark that just uses the .fork() stuff in 0.5 and its also affected [14:12] `3rdEden: k [14:12] edwardmsmith has joined the channel [14:12] ivanfi has left the channel [14:12] Aikar: i want to see what the numbers are under x86 though [14:12] chrischris has joined the channel [14:13] linusoleander has joined the channel [14:14] _th_n_ has joined the channel [14:14] vicapow has joined the channel [14:15] colinclark has joined the channel [14:16] Aikar: well found --dest-cpu option but it wont compile under that [14:16] OmidRaha has joined the channel [14:18] TheJH has joined the channel [14:18] linusoleander: How can I use jasmine.js to test my node.js/express application? [14:19] jimt_ has joined the channel [14:21] deedubs: linusoleander: http://lmgtfy.com/?q=jasmine+node [14:21] linusoleander: deedubs: I can't find anything useful [14:21] igl1 has joined the channel [14:22] deedubs: what's wrong with the first link? https://github.com/mhevery/jasmine-node [14:22] linusoleander: I'm using jasmin-node atm [14:22] linusoleander: The problem is that I can't simulate a request agains the server [14:23] heavysixer has joined the channel [14:23] tekky has joined the channel [14:23] linusoleander: I want to do something like [14:23] linusoleander: get("/") [14:23] linusoleander: expect(page.content).toMatch(/random/) [14:24] deedubs: http://zombie.labnotes.org/ [14:24] Aikar: linusoleander: look at Sinon.JS [14:24] Aikar: or Zombie has those specific features [14:24] trose: using socket.io if i have my client do something like emit('data', {data: data_var}) will that go to my server socket as one piece of information or will I have to catch it as packets and aggregate? [14:24] stagas_ has joined the channel [14:25] `3rdEden: trose one piece [14:25] zmbmartin has left the channel [14:25] trose: `3rdEden, awesome [14:27] jimt has joined the channel [14:27] linusoleander: Aikar, deedubs: But I want to use Jasmine [14:28] bartt has joined the channel [14:28] Aikar: linusoleander: why if it doesnt meet your needs? [14:29] FireCat has joined the channel [14:29] tjholowaychuk has joined the channel [14:29] arcanis has joined the channel [14:30] jorenl_: Someone please, how do I properly log node error messages in my console? [14:30] tjholowaychuk has joined the channel [14:30] chrischris has joined the channel [14:30] JasonJS: jorenl_: What do you mean? [14:31] Aikar: man jasmines source is silly [14:31] chrischris has left the channel [14:31] mbrevoort has joined the channel [14:31] mikeycgto has joined the channel [14:31] jimt has joined the channel [14:32] deedubs: Aikar: Yeah you should see the jasmine-gem for ruby. It's a nightmare. We tried to hack phantomjs support onto it last night. Gave up as its really poorly architected [14:33] jorenl_: JasonJS: (i'll repost) "shouldn't process.on('uncaughtException', function(err) {console.log(err); }); actually show some error message? I always just get {} in my console." [14:34] mehtryx has left the channel [14:36] Aikar: deedubs: they have a function in the node ver that says getGlobal= function() { function getGlobal() { return this; } return getGlobal(); } [14:36] _th_n_ has joined the channel [14:36] Aikar: ... seriously whats wrong with jasmine.global = typeof window === 'undefined' ? global : window; [14:36] _kud has joined the channel [14:37] Aikar: i understand its more accurate across any vm.... but what else is there that people actually care to use besides node and browser? lol [14:38] catb0t has joined the channel [14:38] Aikar: BAI HAI catb0t [14:38] piscisaureus has joined the channel [14:39] raydeo has joined the channel [14:39] kawaz_home has joined the channel [14:39] eee_c has joined the channel [14:39] ryanrolds_w has joined the channel [14:40] Aikar: ohh node cluster :o ? [14:41] hij1nx has joined the channel [14:41] fatjonny has joined the channel [14:41] JasonJS: jorenl_: Is the exception that you are generating not have a message associated with it perhaps? [14:41] theprogrammer has joined the channel [14:41] `3rdEden has joined the channel [14:42] colinclark has joined the channel [14:43] gsmcwhirter has joined the channel [14:43] javaanse_jongens has joined the channel [14:45] jorenl_: JasonJS: I think it's just a typical trying to set property of undefined error [14:45] JasonJS: jorenl_: That is - is it just being generated using 'throw' vs. 'throw "MESSAGE"'? [14:45] jorenl_: JasonJS: it's being generated by node, not by me. [14:46] JakeyChan has joined the channel [14:47] arcanis has joined the channel [14:48] JasonJS: jorenl_: The following works for me as expected in 0.4.11 [14:48] JasonJS: jorenl_: process.on('uncaughtException', function (err) { console.log(err) } ); var foo = foo.bar; [14:48] RORgasm has joined the channel [14:49] aheckmann has joined the channel [14:49] jorenl_: JasonJS: Hmm :S Well, I fixed the bug that is causing it but it's quite hard without debug messages [14:49] Aikar: feedback requested (ping: ryah bnoordhuis piscisaureus ) https://groups.google.com/forum/#!topic/nodejs-dev/Y4UyWkYi2e0 [14:49] mattrobenolt has joined the channel [14:49] mattrobenolt: Anyone use Node with Amazon SQS? [14:50] Riton: ;( The npm install doesn't work on my two computers ... [14:50] jorenl_: Riton: "doesn't work" ? [14:50] jldbasa has joined the channel [14:51] Riton: the "curl http://npmjs.org/install.sh | sudo sh" gives me an error [14:51] kulor-uk has joined the channel [14:51] boaz has joined the channel [14:52] zmbmartin has joined the channel [14:52] slifty has joined the channel [14:52] neekers has joined the channel [14:53] CoverSlide: and that error is .... ? [14:53] jorenl_: Riton: shouldn't you sudo that? [14:54] Riton: this is the error https://gist.github.com/1257460 [14:54] jhbot: Riton, my almighty, artificially created brain says that that version of nodejs is ancient, use 0.4.x or newer [14:54] Riton: the same on both of my computers [14:54] dguttman has joined the channel [14:54] CoverSlide: oh wow [14:54] Riton: jorenl_: " | sudo sh" [14:54] CoverSlide: 0.2.4 [14:54] CoverSlide: yeah you need to upgrade node [14:55] Riton: when I clone https://github.com/joyent/node.git, I don't get the last version ? [14:55] context: do you have a reason for running head? [14:55] darinc: Riton: use nvm, it's great! [14:56] balaa has joined the channel [14:56] darinc: https://github.com/creationix/nvm [14:56] darinc: helps manage your installed node versions and switch between them [14:56] Riton: darinc: nice, gonna try that [14:56] context: or just install the latest version fron nodejs.org [14:57] context: i like how everyone pushes nvm for someone that hasn't even touched node yet. maybe let them get there feet wet first? [14:57] CoverSlide: well nvm is bash anyway [14:57] alphahydrae has joined the channel [14:57] stagas has joined the channel [14:57] CoverSlide: so no node knowledge is required [14:57] Riton: I did use node.js a couple of month ago [14:59] sub_pop has joined the channel [14:59] darinc: I like nvm. after installing it once, it's been self explanatory. nvm help ; nvm install v0.4.12 ; nvm ls ; nvm sync ; nvm default v0.4.12 ; # and so on and so on. [14:59] wilmoore has joined the channel [15:00] verdoc has joined the channel [15:00] alphahydrae: Is it possible to run a command with node and capture lines from stdout/stderr in the order they are printed? With the examples in the node documentation, it captures stdout and stderr separately and they seem buffered so I don't get the output of the command as I would get it in a terminal. [15:00] murilobr has joined the channel [15:00] darinc: if you clone someone's node project that "needs" a specific version, nvm makes it easy [15:00] Riton: it looks nice indeed [15:01] trose: trying to write a socket.io client... is it possible to do this without http? I want to have a tcp server using node's net class. all the examples say to use io.connect(url) on the client but I'm not sure what io is in this case? I'm using io = require('socket.io'), socket = io.connect('localhost'); and getting errors [15:01] Brandon_R has joined the channel [15:01] Brandon_R: hey guys [15:01] trose: hi [15:02] brianseeders has joined the channel [15:03] context: trose: socket.io is a websocket library isnt it [15:03] context: trose: so no.... no you cant do what you are trying to do with socket.io. [15:03] trose: context, fuuuuuuuuuu [15:04] context: trose: what are you trying to do [15:04] wink_: trose: any reason to not just use socket.io across the board? [15:04] wink_: then you dont need to worry about the 18 different transports :p [15:04] fxspark has joined the channel [15:04] inpho has joined the channel [15:04] trose: context, wink_ basically I just want to have a socket that i can send a file to, process it with a script then return data to the client [15:05] c4milo has joined the channel [15:05] jorenl_: trose: why would the protocol actually matter? [15:05] mmalecki has joined the channel [15:05] context: what jorenl_ said. use just about anything or require('net') itself .... ? [15:05] CoverSlide: using socket.io to send a file from the client? [15:05] darinc1 has joined the channel [15:06] jorenl_: node+socket.io hosts its own httpserver on whatever port you choose and you can send basically anything through sockets [15:06] jorenl_: however it seems weird to send a file through a socket instead of just using a normal http post. [15:06] context: well you're assuming its a browser client [15:06] trose: jorenl_, maybe i'm overthinking it then, can i use an http server and not serve web pages? [15:06] context: ... [15:06] JasonJS: trose: Absolutely [15:06] CoverSlide: it is possible [15:06] jorenl_: ofcourse [15:07] trose: okay, sorry I'm learning networking and trying to wrap my head around the concepts [15:07] context: ... js and css arent web pages [15:07] context: nor ajax requests [15:07] CoverSlide: you can have socket.io listen on a network address instead of having to listen on a running client [15:07] CoverSlide: s/client/server/ [15:08] bartt has joined the channel [15:08] trose: okay so i make my server a http server and have socket.io listen on it. now how can i make the client without an embedded script in a web page? [15:10] CoverSlide: you'd have to read the socket.io protocol, or the source for socket.io-client [15:10] Brandon_R: what you guys up to? [15:10] Brandon_R: can't wait for .6 huh? [15:10] fxspark: Hi guys.. I'm trying to run node.js (on port 8000) alongside my existing LAMP stack (running on default port 80) to add some realtime features to the site. I want to use socket.io but how can I serve the client side socket.io code to users connecting to port 80 [15:10] trose: CoverSlide, okay [15:11] bzinger has joined the channel [15:11] wink_: fxspark: ') instead, or use some ajaxy techniques to load it into your javascript? [17:46] flagg0204 has joined the channel [17:46] kuebk^ has joined the channel [17:46] ayaz has joined the channel [17:47] CoverSlide: console.log in the browser? [17:47] flagg0204 has joined the channel [17:48] kevwil has joined the channel [17:48] fangel has joined the channel [17:49] trose: CoverSlide, oh duh :P [17:49] trose: CoverSlide, thanks for the help btw [17:49] mmalecki: when I have an object like: var a = function () {}; a.someFunc = function () {};, how do I get rid of the first function? I want it to be just an object. [17:50] CoverSlide: mmalecki: functions can have properties too. you'd probably have to a = {} to change it to a normal Object first [17:50] tmzt has joined the channel [17:51] Brandon_R has joined the channel [17:51] Brandon_R: hey guys [17:51] davididas has joined the channel [17:51] Brandon_R: what is the best language for heavy mathematical calculations that can bind easily to node [17:51] Brandon_R: or should i just do the calculations in node itself [17:52] mmalecki: CoverSlide: problem is: this is an require, require('assert'), to be precise. and even if I can change it in scope of the current file, I can't change it like, permanently [17:52] flagg0204 has joined the channel [17:53] Brandon_R: any recommendations [17:53] mmalecki: Brandon_R: C [17:53] CoverSlide: C? [17:53] jocafa has joined the channel [17:53] Brandon_R: i'll try [17:54] gplg has joined the channel [17:54] Brandon_R: i'm talking about high level stuff like derivatives and integrals etc [17:54] CoverSlide: oh, well in that case [17:54] CoverSlide: C [17:54] bnoordhuis: Brandon_R: fortran! [17:54] mmalecki: please no. [17:54] flagg0204 has joined the channel [17:55] bengrue has joined the channel [17:55] jakehow has joined the channel [17:55] elliottcable: isaacs › it looks like you have some experience with v8::Context and the weird handling of globals-objects [17:56] trose: LOL [17:56] smus has joined the channel [17:56] elliottcable: isaacs › ran across http://groups.google.com/group/v8-users/msg/915a5fb4b622fd80 [17:56] elliottcable: isaacs › got a moment to discuss my own attempts in a similar direction? Trying to patch a painful bug in `vm` [17:56] Sorella_ has joined the channel [17:56] isaacs: dude that was YEARS ago [17:56] isaacs: like, pre-node [17:56] elliottcable: isaacs › yes, I noticed :D [17:57] isaacs: i don't really remember it [17:57] isaacs: but ok [17:57] elliottcable: isaacs › YEARS ago may be the closest thing I can find to real experience with that, because nobody else seems to be familiar with it [17:57] AvianFlu has joined the channel [17:57] tbranyen: never sign a pre-nodule agreement [17:57] syrio has joined the channel [17:57] elliottcable: isaacs › https://gist.github.com/9bb782d191532261e26e (really simple example, based on the getting started example from v8’s site) [17:58] elliottcable: I get a segmentation fault when I run that, so I’m assuming I’m doing something stupid (I still haven’t quite wrapped my head around HandleScopes, Handles, Context::Scopes, etc) [17:58] elliottcable: if I comment out the four lines involving globals (21-24 on that gist), no seg-fault. ಠ_ಠ [17:58] elliottcable: am I doing something massively stupid right-off-the-bat? [17:58] baudehlo has joined the channel [17:59] bradleymeck: its fine, but its basically actionscript4.0 [17:59] bradleymeck: mt [17:59] elliottcable: bradleymeck › haha [17:59] jocafa: huh. slight style update on github [17:59] CoverSlide: actionscript 4.0?? [17:59] bradleymeck: dart. [17:59] bradleymeck: different window fail [18:00] CoverSlide: oh yeah [18:00] nicferrier: just what we need then. [18:00] mmalecki: I THINK SOMEONE SAID DART. [18:00] CoverSlide: Hey, what's everyone think of Dart? [18:00] jesusabdullah: Don't dart me bro :( [18:00] elliottcable: oh my god no [18:00] elliottcable: don’t start this again ಠ_ಠ [18:00] flag0204 has joined the channel [18:00] CoverSlide: /join #dart [18:01] elliottcable: Dart: Because Java is a *good* influence!™ [18:01] wink_ has joined the channel [18:02] jesusabdullah: /!\ ATTENTION /!\ Those interested in commenting on Dart are directed to fill out form http://colinm.org/language_checklist.html [18:02] jesusabdullah: That is all. [18:02] McMAGIC--Copy has joined the channel [18:03] Brandon_R: does dart have pointers [18:03] elliottcable: jesusabdullah › laughing [18:03] jocafa: lol "You have reinvented PHP better, but that's still no justification" [18:03] Brandon_R: lol [18:03] Brandon_R: [ ] You have reinvented Javascript but worse [18:03] elliottcable: jesusabdullah › are we supposed to be filling that out *for Dart*? [18:03] neekers: how is socket.send different from socket.emit? [18:03] nicferrier: it should just be on the end of the google language production line [18:03] nicferrier: or maybe the beginning [18:04] vidi has joined the channel [18:04] CoverSlide: socket.send gets listened on in socket.on('message'), and you can also have a response callback [18:04] neekers: ahh [18:04] elliottcable: [ ] Rejection of basic computer science without justification [18:04] CoverSlide: socket.emit gets listen on whatever the first argument is passed [18:04] elliottcable: ↑ me in a nutshell [18:05] neekers: ta [18:05] elliottcable: jocafa › I fuckin’ lol’d at that one [18:05] bradleymeck: Brandon_R no, no pointers [18:05] dgathright has joined the channel [18:06] _kud has joined the channel [18:07] dnyy has joined the channel [18:07] elliottcable: isaacs › no insights, I suppose? )= [18:07] elliottcable: isaacs › I appreciate the time, in any case. [18:08] dexter_e has joined the channel [18:08] maushu has joined the channel [18:09] ph^ has joined the channel [18:10] arcanis has joined the channel [18:10] bradleymeck: I do want dart's auto init constructors, strings, and simple function syntax... (if only i could provide names for stack traces though...) [18:11] gplg has joined the channel [18:11] CarterL has joined the channel [18:12] Brandon_R: dart vm [18:12] Brandon_R: is it async? [18:12] Brandon_R: like node [18:12] synkro has joined the channel [18:13] bradleymeck: Brandon_R unspecified, appears to be targetting browser instead of standalone w/ io [18:13] Brandon_R: oh [18:13] piscisaureus: Aikar: hey [18:15] Aikar: piscisaureus: yo [18:15] mixin has joined the channel [18:15] piscisaureus: Aikar: https://github.com/aikar/wormhole/blob/06b37c294318346da86b5c661025d019418627a5/testperf.js [18:15] piscisaureus: ^-- how do you run that .4 [18:15] Aikar: yea? [18:16] Aikar: cant for that one :/ [18:16] Aikar: that was to demo the performance of the .fork() IPC which uses very similar code [18:16] gplg has joined the channel [18:17] Aikar: but if you run the standard wormhole benchmark (master branch) that runs on .4 and .5 [18:17] Aikar: I modified that 5xperfdegrades branch as a test of .fork IPC [18:19] elliottcable: jocafa › the new style is sexy, imo [18:19] piscisaureus: Aikar: ah, ok [18:21] pizthewiz_ has joined the channel [18:21] Raul_ has joined the channel [18:21] FireCat has joined the channel [18:22] franksalim_ has joined the channel [18:22] Brandon_R: hey guys [18:22] MooGoo: yo TheJH [18:22] heavysixer has joined the channel [18:22] Brandon_R: what is udp addmembership and dropmembership [18:22] Brandon_R: what is the tcp equilivilent [18:23] wankdanker: Brandon_R: it is multicast which i don't think has a tcp equiv [18:23] Brandon_R: what is multicast [18:23] wankdanker: Brandon_R: well, unless you open lots of tcp connections to all your destinations [18:24] Aikar: piscisaureus: i just branched a 2x version of wormhole before channel support was added, I'm seeing 160k/sec on 0.5.9, and 300k/sec on 0.4.12 [18:24] Aikar: that code is more closer to what nodes fork() ipc looks like [18:24] wankdanker: Brandon_R: it's like broadcast but more directed i guess [18:24] Brandon_R: kool [18:24] Brandon_R: like a radio [18:24] shykes_ has joined the channel [18:25] wankdanker: well, broadcast is like radio [18:25] wink_: multicast is a world of headaches you probably dont want :p [18:25] TheJH: hello MooGoo [18:25] Brandon_R: holy balls [18:25] Brandon_R: https://github.com/yrashk/socket.io-erlang [18:25] bradleymeck: wink_ unless you are doing one directional communication ;) [18:25] socialhack has joined the channel [18:25] TheJH: Brandon_R, really? looks cool :D [18:25] Brandon_R: and woah, github just had an update [18:26] MooGoo: TheJH: hax catb0t [18:26] wankdanker: Brandon_R: noticed that too. like the clone graphs. [18:26] TheJH: Brandon_R, that means we can make couch talk to its couchapps via socket.io, YEEEEAH!!!! [18:26] jbpros has joined the channel [18:27] elliottcable: yrashk <3 [18:27] elsig has joined the channel [18:27] wink_: bradleymeck: fair enough, it becomes a deep rabbit hole rather quickly though :> [18:27] bradleymeck: wink_ yea... [18:27] Brandon_R: ejabberd + socket.io Hell YEAH [18:27] TheJH: MooGoo, will try [18:27] wink_: i wonder how well that erlang implementation performs [18:27] voodootikigod has joined the channel [18:28] elliottcable: “Socket.io-erlang has entered maintenance mode. The original socket.io library has been upgraded to version 0.7.x (and the oddly similar version 0.8.x), which is incompatible with major ways with the 0.6.x versions that socket.io-erlang implements. The latest versions took more and more the shape of an entire framework that breaks backwards compatibility on the client-side as well as the server side, which the current socket.io-erlang team of maintainers ... [18:28] elliottcable: ... disagree with.” [18:28] stisti has joined the channel [18:28] balaa has joined the channel [18:30] bradleymeck: if you want to maintain separate ports of non-1.0.0 stuff there will always be breaking changes... [18:30] Brandon_R: i think i'm going to make my own socket.io for erlang [18:30] Brandon_R: now where did i put emacs [18:30] AvianFlu: psssht [18:30] AvianFlu: real men use vim XD [18:30] Aikar: /tmp [18:31] bnoordhuis: defunctzombie: re -m32: yes [18:32] Brandon_R: i will be following OTP patterns instead of doing just a direct socket.io port [18:32] Brandon_R: with supervisors etc [18:32] MooGoo: TheJH: print() [18:32] jesusabdullah: Brandon_R: What's this? [18:32] jesusabdullah: Oh, a socket.io for erlang, neat! [18:32] TheJH: MooGoo, whaah, someone's watching me! *paranoia on* [18:32] jesusabdullah: Yeah, don't do a pure socket.io port that'd be lame [18:32] Brandon_R: Otp = open telecom protocol [18:32] MooGoo: catb0t is my spy [18:33] jesusabdullah: Someday I might learn me some erlangs [18:33] sub_pop has joined the channel [18:33] CoverSlide: you haven't http://learnyousomeerlang.com 'd yet? [18:34] jesusabdullah: Actually, no [18:34] jesusabdullah: I haven't looked that closely, Ive just heard good things [18:34] piscisaureus: Aikar: I don't really get it yet [18:34] elliottcable: 59 S 771 37 < Brandon_R> now where did i put emacs [18:34] elliottcable: Brandon_R › I laughed. [18:34] jesusabdullah: too busy learning other stuff [18:34] piscisaureus: So wormhole performs worse on 0.5 [18:34] drudge: Can anyone assist me with a mongo query? i have a collection of documents with store and createDate fields. I am trying to get the latest document (max createDate) for each store. Would love it if someone could point me in the right direction [18:34] Aikar: piscisaureus: i dont either, i dont see how the code could be written in anyways [18:34] elliottcable: yeah, I just keep solitary `emacs` binaries, +x, sitting around [18:34] Aikar: piscisaureus: yes [18:34] elliottcable: and I copy them to wherever I’m working [18:34] elliottcable: ./emacs [18:34] Aikar: could be written diff* [18:34] elliottcable: ’cause I’m pimp like that [18:35] mmalecki: elliottcable: lulz [18:35] elliottcable: ACTION high-fives Brandon_R [18:35] Brandon_R: do you use gnome? [18:35] thisandagain has joined the channel [18:35] Guest25624 has joined the channel [18:35] piscisaureus: Aikar: but you wrote a test that shows that fork() iss't to good either [18:35] jesusabdullah: I think I actually want to get into clojure a bit when I have time/inclination for not-so-js [18:35] elliottcable: I was kidding; I’m an OS X user, with vim-over-ssh-and-tmux-to-an-Arch-box [18:35] elliottcable: no emacs or Gnome or b.s. for me [18:35] CoverSlide: gnomes are weaker than dwarvs [18:35] aguynamedben_ has joined the channel [18:35] elliottcable: CoverSlide’s contribution: always relevant and useful. [18:35] Aikar: piscisaureus: and also basing the fact id really expect fork()'s IPC to perform faster than 0.4.x Wormhole if it was purely a wormhole problem [18:35] colinclark_ has joined the channel [18:36] CoverSlide: but they make better spellcasters [18:36] raphdg has joined the channel [18:36] elliottcable: also, I posted my issue on the mailing list, if you’re interested (bradleymeck, isaacs): [18:36] elliottcable: http://groups.google.com/group/v8-users/browse_thread/thread/2c84071059c9fc61 [18:36] piscisaureus: Aikar: well the fork() streaming parser could use some work [18:37] Aikar: piscisaureus: i just submitted a patch to it that does increase performance by 10-15% [18:37] TheJH: .. a [18:37] Aikar: its in the pull reqs [18:37] catb0t: ReferenceError: a is not defined [18:37] isaacs: .. "welcome back, Catb0t!" [18:37] catb0t: "welcome back, Catb0t!" [18:37] CIA-48: libuv: 03Igor Zinkovsky 07 * r81303a7 10/ src/win/fs.c : fix fs_readdir_file on windows - http://git.io/YzptKg [18:37] Aikar: piscisaureus: I've focused on performance with Wormhole, so i did the same technique for nodes JSON buffer parsing. [18:38] Carter has joined the channel [18:39] criswell has joined the channel [18:39] Aikar: but the fact that nodes .fork IPC doesnt outperform Wormhole 0.4.12 speeds is a good sign its not a wormhole problem. and wormholes code isnt really anything fancy. the same basic approach it does is what the fork IPC code does. [18:39] JulioBarros has joined the channel [18:39] hij1nx has joined the channel [18:39] piscisaureus: Aikar: it could very well be a v8 issue [18:39] Aikar: piscisaureus: I really dont have the experience to debug it myself :( [18:40] Circlefusion has joined the channel [18:40] defunctzombie: bnoordhuis: updated pull request with comments [18:40] defunctzombie: s/with/using/ [18:40] Aikar: but a 40-50% performance drop is nothing to brush off your shoulder... [18:41] davv3: ACTION pet catb0t  [18:41] jesusabdullah: huh [18:42] jesusabdullah: I see what people mean with hook.io being erlang-influenced [18:42] jesusabdullah: I mean, actors sound kinda like hooks, kinda [18:42] tjholowaychuk: isnt hookio [18:42] tjholowaychuk: more like zeromq [18:42] tjholowaychuk: -ish [18:42] _th_n_ has joined the channel [18:43] jesusabdullah: no? [18:43] _th_n_ has joined the channel [18:43] jesusabdullah: Definitely not like zmq [18:43] jesusabdullah: They're processes that communicate with each other using a shared event emitter [18:44] TheJH: MooGoo, looks good so far :) [18:44] jesusabdullah: well, a shared EE2, so you get namespaces and wildcards [18:44] bnoordhuis: defunctzombie: that was quick [18:44] Aikar: i'm going to be building a system that is erlang OTP like. hook.IO came after I envisioned my system, but it really doesnt flow with how i'm intending to make it. so I'll continue on with my ideas. just working on other libs first atm [18:44] AvianFlu: and to clarify, it's not just one emitter, each hook is an emitter and they hear one another [18:44] jesusabdullah: which for so many different kinds of data on one EE, is really helpful [18:44] MooGoo: woohoo [18:44] tjholowaychuk: jesusabdullah sounds like zmq [18:45] jesusabdullah: zmq, from what I know, is just a message passing interface [18:45] AvianFlu: except for the part where it's not a message queue [18:45] jesusabdullah: zmq is more like an alternative to tcp/ip or OpenMP maybe, than anything else [18:45] jimt has joined the channel [18:45] jesusabdullah: even socket.io would be a better comparison [18:45] tjholowaychuk: you could easily set up something like hookio with zmq [18:45] Aikar: I envision a system that you say 'Run this codebase', and when you call foo.bar(), the system will know which server/process in every cluster has the lowest load/activity and run the code in the most effecient place. [18:45] tjholowaychuk: not saying it IS hookio [18:46] jesusabdullah: well, sure, you'd just make dnode support some zmq transport library [18:46] jesusabdullah: and you get that for free [18:46] Brandon_R: hi [18:47] jesusabdullah: Aikar: Have you looked at dnode-ez? It inverts dnode to message pass over EEs similar to hook.io but only does that and none of the other stuff [18:47] jesusabdullah: if you like small modules that you stack up yourself you might like it better [18:47] hellp has joined the channel [18:49] Nuck|CrapOS has joined the channel [18:50] einaros: whatever hook.io is, or isn't, it seems to cover a set of problems I'd otherwise solve with zmq, rabbit or redis [18:50] jocafa: does anyone have a good protobuf solution for node? [18:50] Aikar: jesusabdullah: I see, but i'm really wanting to just roll my own so it can integrate into my other modules and development styles easier. I intend to make it have some magic behind it. I dont really care for the elitist arguments over 'magic is bad' etc, just really looking to build a platform for developing applications that solve problems in reasonable time frames that managers find acceptable :P [18:50] reid has joined the channel [18:50] einaros: and I base that assertion on having looked at their repo for an entire 10 seconds [18:50] tjholowaychuk: einaros if you want something less robust [18:50] einaros: yep [18:50] tjholowaychuk: which is fine, it's nice to play with ideas in node [18:51] grekko has joined the channel [18:51] Destos has joined the channel [18:51] jesusabdullah: Aikar: Yeah, sure. Some magic is okay as long as it's predictable magic imo [18:51] Aikar: and documented/learable magic :P [18:51] Aikar: which is what i intend [18:51] einaros: I keep saying, although I don't think anyone is listening: just because you 'can' solve a problem with purely node.js constructs, it doesn't mean that you should [18:51] jesusabdullah: indeed [18:51] boaz has joined the channel [18:52] jesusabdullah: einaros: That's not really true. Hook.io isn't a zmq, rabbit, or redis. In fact, you could just add hook.io transports for all of these. [18:52] jesusabdullah: hook.io is a *framework* [18:53] jesusabdullah: It's like saying that, given rails, I would solve the problem with a static fileserver instead. [18:53] tjholowaychuk: http://browserify.nodejitsu.com/?require=["mrcolor", {"jquery": "jquery-browserify"}] [18:53] tjholowaychuk: sweet [18:53] jesusabdullah: TJ WHAT ARE YOU DOING [18:53] jesusabdullah: haha, thanks [18:53] defunctzombie: bnoordhuis: ttl and broadcast support could be added back soon too (then that test could be reused maybe) [18:53] tjholowaychuk: mrcolor [18:53] Aikar: I'm aiming for you to make a simple index.js that does require('cosmos').startApp(__dirname + '/config/myapp.json'); that specifies 1) a codebase to load code, 2) "startup entry paths" 3) DB credentials for cosmos to store its internal tracking data, 4) some form of networking configs. then you simply distribute the exact code base to as many servers as you want and it just routes everything on its own [18:53] einaros: crap, where's that "It looks like you're building a framework" article when I need it [18:53] jesusabdullah: For the record: I don't know if browserify.nodejitsu.com is a good idea or not. [18:54] tjholowaychuk: ACTION tries it [18:54] jesusabdullah: As long as you *know* it's a framework and that you know it's what you *want* I really don't see the problem [18:54] jesusabdullah: If you don't like frameworks, that's cool too. [18:54] Aikar: yep [18:54] errordeveloper has joined the channel [18:54] tjholowaychuk: ah i broke it [18:54] Aikar: I'm not expecting everyone to adopt my system as the holy grail [18:55] trose: so I'm reading data from my socket and trying to identify the end of the file. It seems that by the time i identify the last line of my input socket has already thrown an 'end' event. is there a way to manually stop the socket from closing or to set it as writeable again? [18:55] jesusabdullah: but it doesn't make sense to say that low-level transports and a framework are the same thing [18:55] Brandon_R: hi [18:55] jesusabdullah: Anyways [18:55] jesusabdullah: I have work to do ;( [18:55] einaros: jesusabdullah: anyhoo, your readme pretty much says you're a service bus with message queue features. if it isn't you may want to update it [18:55] Aikar: but if you know your developing a system that will need to scale... I intend to help solve that problem [18:55] whse: Aikar: bnoordhuis finally got that mess with ciphers/buffers/trsings sorted out [18:55] Aikar: whse: nice, able to share your findings? [18:55] CoverSlide: yeah I got 500 error [18:56] whse: yes, don't use binary encoded string for anything. [18:56] tylerstalder has joined the channel [18:56] CoverSlide: oh there it goes [18:56] whse: hex output to string and then convert into a Buffer. [18:56] CoverSlide: ok subby should uglify this [18:56] Brandon_R: isn't binary the best way to transport data over socket? [18:56] Aikar: odd, I couldnt get it to work with buffers I dont think [18:56] jesusabdullah: Brandon_R: Depends on what you want [18:56] Aikar: yeah i used plain strings [18:56] jesusabdullah: text encodings of binary data don't work too well iirc [18:56] gplg has joined the channel [18:56] whse: If you pass a Buffer to a socket, it will transmit the raw bytes, and you don't have Bad Behavior (tm) [18:57] jesusabdullah: but if it's text you should just send it as text [18:57] tnlogy has joined the channel [18:57] whse: jesusabdullah: GNTP/1.0 protocol is utf8 with support for encrypted blocks [18:57] Aikar: whse: i guess its a lil diff in that i was urlencoding the data and then sending it over a web request [18:58] whse: The padding was working fine, it was taking the output as binary and then truning that into a Buffer that was borking me [18:58] Aikar: damn pisg left [18:58] whse: somehow it was resulting in a fluid mess of nulls in the output [18:58] Aikar: I really hope the performande degredation of .5.x can be remedied before .6 [18:59] balaa has joined the channel [18:59] eignerchris_ has joined the channel [18:59] Aikar: whse: maybe you can make a more reliable encryption module that handles various types/padding :P [19:00] whse: Aikar: I actually dont think it was the encryption module, but binary string handling [19:00] Kunda has joined the channel [19:00] hij1nx_ has joined the channel [19:00] Aikar: var sCipherText = oCipher.update(sData, 'utf8', 'binary') return urlencode(sCipherText) [19:00] Aikar: is what I had in mine [19:01] whse: utf8 data to binary string [19:01] josdehart has joined the channel [19:01] Aikar: and urlencode was this ugly mess [19:01] Aikar: return escape(str).replace(/!/g, '%21').replace(/'/g, '%27').replace(/\(/g, '%28'). replace(/\)/g, '%29').replace(/\*/g, '%2A').replace(/%20/g, '+'); [19:01] Aikar: that urlencode got it to the point PHP would accept it [19:01] whse: you'd almost be better off with oCipher.update(sData, 'utf8', 'hex') [19:02] Aikar: the PHP endpoint read the data as urlencoded binary :/ [19:02] whse: Would have saved you all the munging anyways [19:02] wilmoore has joined the channel [19:02] dob_ has joined the channel [19:02] whse: sure, hex.length = sData.length*2 [19:03] CIA-48: node: 03Bert Belder 07 * r3fd951e 10/ lib/net.js : Make Socket.write optimizable - http://git.io/y8TjYw [19:03] Aikar: and getting the teams behind the PHP endpoint to update their code wouldnt of happened [19:03] piscisaureus_ has joined the channel [19:03] whse: besides, there are multiple specific notes about binary encoded strings being removed in the future [19:03] murilobr has joined the channel [19:03] mraleph has joined the channel [19:03] whse: from what I've seen, good riddance. [19:04] whse: That was probably 32 hours of my life wasted hunting that down and refactoring over and over [19:04] Aikar: piscisaureus_: are you able to look into the problem any? (got the right tools etc?) [19:04] smtlaissezfaire has joined the channel [19:04] neekers: i'm using express and socket.io and i cant seem to get console.log to work client side. it works server side [19:05] blup has joined the channel [19:05] Aikar: neekers: firefox requires firebug being open [19:05] brainss has joined the channel [19:05] Aikar: console.log doesnt exists unless firebug is open [19:06] CoverSlide: IE needs developer console open [19:06] paul0_ has joined the channel [19:06] syrio has left the channel [19:06] CoverSlide: in chrome, it's always open! [19:06] Aikar: though i wish theyd "exists" even when closed so the js doesnt error out ~.~ [19:06] smathy has joined the channel [19:06] CoverSlide: yeah that's shitty [19:06] neekers: Aikar: i feel like such a goofus, i thought console.log on the client was writing back to the console on the server... :) [19:06] CIA-48: node: 03Bert Belder 07 * ra73384e 10/ lib/net.js : Make Socket.write optimizable - http://git.io/t9bbfA [19:06] Aikar: neekers: lol no [19:07] AvianFlu has joined the channel [19:07] Aikar: console.log is part of browsers development tools [19:07] gplg has joined the channel [19:07] neekers: its been perplexing me for quite some time [19:07] Aikar: same names were used in node [19:07] trotter has joined the channel [19:07] metellus has joined the channel [19:08] jerrysv has joined the channel [19:08] mjr_ has joined the channel [19:08] errordeveloper: ah! github got a new style :) [19:08] brainss has left the channel [19:08] piscisaureus_: Aikar: well I have the tools [19:08] piscisaureus_: Aikar: but no benchmark I can run on v0.4 [19:09] fennec has joined the channel [19:10] _kud has joined the channel [19:10] CoverSlide: any way to build node using mingw on linux? [19:10] whse: All the same, thanks for your help yesterday Aikar & bnoordhuis [19:10] sechrist: what's up javascript people [19:10] CoverSlide: what's up dawg [19:11] sechrist: nm, sippin on some coffeescript [19:11] AvianFlu: javaSCRIPT! [19:11] sechrist: about to get sexyscript [19:11] AvianFlu: awwww yeeeaaaaa [19:11] AvianFlu: bringin' sexy back to javascript! [19:11] ryanolds_w has joined the channel [19:12] Raul__ has joined the channel [19:12] CoverSlide: javascript mothafuckaaah [19:12] sechrist: 1 hit wonder [19:12] sechrist: :P [19:12] Aikar: piscisaureus_: run the plain wormhole benchmark [19:12] mmalecki: how the hell do I access contributors tab on GH now? [19:12] whse_ has joined the channel [19:12] sechrist: mmalecki: stats and graphs [19:12] trose: how do you guys feel about coffeescipt? personally i feel like it is superfluous. What's the point in just cleaning up syntax? I mean, we ARE programmers. you should be able to deal with syntax [19:12] CoverSlide: according to your mom, one hit is all it takes [19:12] mmalecki: sechrist: ah, thanks [19:12] vidi has joined the channel [19:12] cl0udy has joined the channel [19:13] sechrist: trose: it removes the occurance count of "function(){}" by like 90000 [19:13] bartt has joined the channel [19:13] Aikar: trose: i dont like it because its a completely diff language and whitespace oriented. [19:13] CoverSlide: fucking gumby [19:13] Tobsn has joined the channel [19:13] sechrist: This is where my search-dollars go?! [19:13] wink_: i wish stock js had the existential operator for properties [19:13] wink_: thats the one thing thats made me consider cs [19:13] Aikar: trose: but I support improving JS syntax, if the base sytax is (mostly) JS :P [19:13] Aikar: ie: streamline = <3 [19:14] CoverSlide: jesus, and they're using css for the animation [19:14] CoverSlide: way too much time on their hands [19:14] xy_ has joined the channel [19:14] context: existential operator ? [19:14] Raul__: @coverslide: whats the better alternative? [19:14] dob_: good evening folks. I have some strange issue. sessionStore.load(this.user.cookie['connect.sid'], function(err, sess) <- only works sometimes. If I output sessionStore I see the session in the sessions array. Why does the load function only work sometimes? [19:15] vampi-the-frog: because other times it doesn't work [19:15] context: haha. [19:15] Raul__: .. [19:15] wink_: context: object.prop1?.prop2?.prop3 [19:15] CoverSlide: well, nothing if you want it to work cross-browser [19:15] Morkel has joined the channel [19:15] dantalizing has joined the channel [19:15] wink_: where the ? will auto check for the standard traps [19:15] context: wink_: oh. kind of like .try() in rails ? [19:15] maletor has joined the channel [19:16] wink_: context: i guess? i dont know the ruby/rails at all :p [19:16] wink_: but having a single operator checking that stuff instead of wrapping accesses like that up would be -awesome- [19:17] franciscallo has joined the channel [19:17] gplg has joined the channel [19:17] AaronMT has joined the channel [19:17] Aikar: I'm working on a system to let you use Traceur syntax, so you can get to use some of the new strawman proposals like arrow function syntax, spread/rest arguments, default argument values, block level scoping (though that implementation sucks...), classes [19:17] Aikar: and compile to normal js before publishing [19:18] criswell has joined the channel [19:18] wink_: i just want ? ;> [19:18] Aikar: nice thing about traceur is its still pretty much javascript [19:18] Aikar: spread/rest and default argument values are nice... [19:20] Renegade001 has joined the channel [19:20] Aikar: main thing i like about traceur is that it is proposed additions that can be added to js and then get rid of the preprocessor. JS++ is another new preprocessor that has even cooler things, but it worries me as its just a single guy working on it :/ [19:21] trose: ahhhh i'm so frustrated with this. What is the standard way to receive information, do something with it, and return information using net? [19:21] CoverSlide: cuz it's java to the script!what about proxies, generators, etc [19:21] harthur has joined the channel [19:21] CoverSlide: oops [19:21] trose: it can't be this hard. I think i'm missing some key aspect of the process [19:21] Aikar: CoverSlide: it has generators, but proxies are too deep of a detail to do in plain JS [19:22] Aikar: http://code.google.com/p/traceur-compiler/wiki/LanguageFeatures [19:22] franksalim__ has joined the channel [19:22] Aikar: also, destructured assignment [19:22] Aikar: forgot about that [19:22] gplg has joined the channel [19:22] CoverSlide: that is nice [19:22] Aikar: var [foo, bar] = [1, 2]; [19:23] AaronMT_ has joined the channel [19:23] dob_: any idea why sessionstore.load does only work sometimes with express? [19:24] CoverSlide: proxies would be nice, dunno how hard it would be to implement [19:24] Aikar: its in V8 currently [19:24] Aikar: node --harmony_proxies or so [19:24] Aikar: its just not on by default :| [19:24] Aikar: they arnt complete yet [19:24] Aikar: so looks like itll be at least .7 before they could likely be default on [19:25] MooGoo: there's a module that adds them [19:25] tnlogy: seem a bit messier than for example method_missing in ruby, but it's nice proxys are coming.. [19:25] Aikar: MooGoo: yeah but it has a bug with function proxies [19:25] Aikar: typeof functionproxy == 'object' [19:25] MooGoo: no idea, just messed with it once [19:25] AaronMT has joined the channel [19:25] Aikar: it worked fine other than that [19:26] MooGoo: proxys are cool shit [19:26] Aikar: I had used it for an autoloader concept, but trying to do bar instanceof Foo.Bar threw errors [19:26] Aikar: because although Foo.Bar could be used just like a function, typeof reported object [19:26] kersny has joined the channel [19:27] CIA-48: libuv: 03Ryan Dahl 07 * rc903bc3 10/ src/unix/stream.c : unix: fix a few compiler warnings - http://git.io/qfB3JQ [19:27] N0va has joined the channel [19:27] Aikar: so heres hoping they work correctly in official implementation [19:27] neekers: can someone please tell me why this isnt displaying text in the other browser. i can see on the server that broadcast is working but i never see socket.on('message' get called on the client. https://gist.github.com/1282251 [19:27] tnlogy: you can get some of the same functionality done with __defineGetter__ and __defineSetter__ though, when you know what properties that are used. [19:27] smathy has joined the channel [19:27] Aikar: tnlogy: thats what i did in my current state autoloader [19:28] Aikar: but required me scanning entire directory tree to know what getters to set [19:28] CIA-48: node: 03Ryan Dahl 07 * rb896687 10/ (6 files in 4 dirs): Upgrade libuv to c903bc3 - http://git.io/m43ySw [19:28] Aikar: https://github.com/aikar/autoloader [19:28] tnlogy: ah, I just played around a bit with it today, doing something similar to load some json-data [19:28] tnlogy: nice! [19:29] catb0t has joined the channel [19:29] zackattack has joined the channel [19:29] balaa has joined the channel [19:29] mbrevoort has joined the channel [19:29] CIA-48: node: 03Ryan Dahl 07 * r16e1d5b 10/ benchmark/http_simple.js : Remove uname and git-rev detection from http_simple.js - http://git.io/nx4OiA [19:29] Aikar: tnlogy: implementation: https://github.com/aikar/nope [19:30] Aikar: I use the "Custom Loader" aspect there [19:30] Aikar: https://github.com/aikar/nope/blob/master/lib/nope.js#L58 [19:31] jellosea has joined the channel [19:31] neekers: Aikar: do you have a moment to look at the code i posted on gist [19:31] Aikar: that trickery let anything you define with Class/Singleton functions would auto be the module.exports [19:31] tylerstalder has joined the channel [19:31] tnlogy: ah, that's nice. just used __defineGetter__ a bit today to create a "database" and then be able to store the data with db.x.y = 3 [19:32] Aikar: neekers: that looks like an old socket.io? [19:32] jellosea: is it possible to run / have my own npm respository? [19:32] Aikar: jellosea: yes [19:32] neekers: Aikar: what do you mean? [19:32] jellosea: Aikar: how do i do it? [19:33] jellosea: Aikar: if you could point me to some docs on how to that, that would be great [19:33] Aikar: jellosea: no clue [19:33] Aikar: i just know its possible :P [19:33] jellosea: Aikar: how do you know [19:33] Aikar: neekers: nvm i think i got confused by something else, whats the problem [19:33] Aikar: jellosea: cause people talk about it all the time lol [19:33] raphdg has joined the channel [19:34] neekers: Aikar: i see on the server that a broadcast is taking place, but on the client, i never see socket.on('message' being called [19:35] Aikar: neekers: not sure, i use custom events myself [19:35] dob_: any idea why sessionStore.load does not work every time? [19:35] dob_: i have really trouble with express. [19:35] tjholowaychuk: dob_ because the sid is wrong? [19:35] Aikar: neekers: emit is used as emit('eventname', 'foo'); [19:35] diogogmt has joined the channel [19:36] piscisaureus_: Aikar: here's what I get: [19:36] Aikar: ie: socket.broadcast.emit('chatmsg', {msg: 'foo', author: 'bar'}); [19:36] piscisaureus_: v0.4: 115k/s [19:36] dob_: tjholowaychuk: No, the sid is correct. Sometimes it works, sometimes not. [19:36] Aikar: then socket.on('chatmsg', function(msg) { }); on client [19:36] piscisaureus_: sorry [19:36] Brandon_R has joined the channel [19:36] Aikar: piscisaureus_: slow machine? lol [19:36] Brandon_R: Hey guys [19:36] tjholowaychuk: dob_ i cant see your code so i dont know [19:36] Brandon_R: i have a question [19:36] neekers: ok, let me try that [19:36] Brandon_R: anyone know how to use libuv by itself? [19:36] RushPL has joined the channel [19:37] piscisaureus_: Aikar: [19:37] piscisaureus_: 0.4: 161k/s [19:37] piscisaureus_: 0.5: 115k/s [19:37] piscisaureus_: fork(): 170k/s [19:37] Aikar: using master of wormhole right?, whats specs on your system? I do have 3.4ghz quad core [19:37] Aikar: and its using 3 processes [19:37] CoverSlide: Brandon_R: you probably compile and link it ... [19:38] piscisaureus_: Aikar: I don't know how many processes it uses. I have a core i7 macbook pro [19:38] Aikar: if your on a dual core may need to turn off 1 of the senders (comment out the spawn line) [19:38] Aikar: i7 should be quad right? [19:38] Brandon_R: ik but how do i write a hello world app in it [19:38] piscisaureus_: yeah [19:38] jellosea: does anyone know how to setup a private npm repo? [19:38] Aikar: ok so you shouldnt be bottlenecked, must be low cpu speed on the macbook (i thought those were beefy?) [19:38] Brandon_R: what size screen pisci [19:38] Aikar: but your obviously seeing a degrade in perf too though [19:39] piscisaureus_: Aikar: yes, but fork() seems to perform very well [19:39] CoverSlide: there's like no docs, just look at the include file [19:39] neekers: Aikar: thanks, its working [19:39] piscisaureus_: Aikar: but we also just discovered that we forgot to merge a branch with optimizations, so maybe you should retry after we fix it [19:39] Aikar: piscisaureus_: i was hitting 300k/sec with 2.0 style, fork should be up there too [19:40] piscisaureus_: 2.0 style? [19:40] Aikar: of wormhole [19:40] Aikar: before channel support was added [19:40] Aikar: the code for it was very similiar to the json reading of fork [19:40] Aikar: but the benchmark goes over a TCP socket [19:40] dob_: tjholowaychuk: http://pastebin.com/7tKTiEtM - You were right. The sid is sometimes different: this.user.cookie['connect.sid'] = Mr7qfHMSA5RYX0jMlmcejzt2.FzGrANRtyxij7raJG%2FjPOFCjM6NNmhTa9gHc3vQL3jc and sessionStore: { sessions: { 'Mr7qfHMSA5RYX0jMlmcejzt2.FzGrANRtyxij7raJG/jPOFCjM6NNmhTa9gHc3vQL3jc': ..... [19:40] Aikar: stdin of fork() may be more light weight [19:41] bnoordhuis: Brandon_R: have a look at the libuv tests [19:41] Brandon_R: k [19:41] Ang3 has joined the channel [19:41] Aikar: piscisaureus_: im guessing the % number increases as the speed scales up with faster CPU's [19:42] piscisaureus_: Aikar: that's purely speculation :-) [19:42] Aikar: piscisaureus_: what does this optimization branch contain? [19:42] flagg0204 has joined the channel [19:42] slifty has joined the channel [19:42] piscisaureus_: Aikar: some stuff that makes more of node's js crankshaft-optimizable [19:43] piscisaureus_: Aikar: but you need to be a little more clear [19:43] tmzt_ has joined the channel [19:43] Aikar: piscisaureus_: you cant deny their is a huge drop from .4 to .5, just i meant your .4x numbers arnt as high as mine i guess due to my cpu being faster [19:43] piscisaureus_: Aikar: you have (2) problems, which is performance drop from 0.4 .. 0.5 — that's a serious issue [19:44] piscisaureus_: Aikar: and you have the issue that you think fork() should be faster — well, it probably will [19:44] piscisaureus_: Aikar: but they're really unrelated issues, try to not mix those up too much [19:44] piscisaureus_: because its very confusing [19:44] colinclark has joined the channel [19:45] piscisaureus_: Aikar: I'll try to deal with the performance drop [19:45] Aikar: alright, i just meant the fact that .fork() is simpler/uses less resources than my wormhole benchmark, in that it really should be beating my 0.4.x numbers if there wasnt an issue [19:45] piscisaureus_: fist [19:45] Aikar: piscisaureus_: i was just using the fork() numbers to prove it wasnt purely a problem with my code [19:45] piscisaureus_: heh - you just showed that fork() has issues too [19:46] piscisaureus_: that doesn't mean your code has no issues :-) [19:46] Aikar: yes, showing fork is affected by same problem [19:46] Aikar: I dont deny that, but I sure as hell dont see any other way to write the logic :P [19:46] dob_: tjholowaychuk: Do you have any idea why / is replaced with % in the sid? [19:46] Aikar: i'm not using 'arguments' or anything that crankshaft could blow up on [19:47] piscisaureus_: Aikar: well you're using try..catch :-) [19:47] Aikar: piscisaureus_: able to get the optmizations merged today? [19:47] piscisaureus_: Aikar: maybe, ryah is doing it [19:47] Aikar: true, that could be why im not getting as high as numbers as the fork() one [19:48] piscisaureus_: Aikar: to find crankshaft issues, just run ./node —trace-bailout —trace-deopt yourfile.js [19:48] piscisaureus_: although it's a little more complicated to analyze child processes that way [19:49] Aikar: removing the try / catch on my 2.x branch test didnt seem to increase performance. the try/catch is wrapped OUTSIDE the while() [19:49] N0va` has joined the channel [19:49] slifty has joined the channel [19:49] Metal3d has joined the channel [19:49] Aikar: still getting 300k/sec [19:50] wink_: Aikar: have you profiled it at all? [19:51] Aikar: no, i dont know the tools to do profiling in node. [19:51] Aikar: just found the issue last night [19:51] dob_: tjholowaychuk: I think this should work. I will try this: sessionStore.load(decodeURIComponent(this.user.cookie['connect.sid']), function(err, sess) { [19:51] Carter has joined the channel [19:51] wink_: what platform are you on? [19:51] Aikar: piscisaureus_: with the --trace-bailout and --trace-deopt it ramped up to 293k/sec still, what should i have seen? [19:51] Aikar: wink_: ubuntu 11.04 x64 [19:51] Aikar: (all my systems) [19:52] Aikar: well and a debian stable at work [19:52] flagg0204 has joined the channel [19:52] josdehart has joined the channel [19:52] JaKWaC has joined the channel [19:52] piscisaureus_: Aikar: you shouldn't see any differences, it just tells you when crankshaft is unable to optimize a function [19:52] Aikar: so no output is good? [19:52] enmand has joined the channel [19:52] wink_: running node with --prof --prof_auto should generate a profile you can analyze [19:52] CIA-48: node: 03Ryan Dahl 07 * r25ff181 10/ lib/net.js : [19:52] CIA-48: node: Revert some changes made in 12486a6 [19:52] CIA-48: node: Some of the perf improvements from many-writes-fix branch were accidentally [19:52] CIA-48: node: undone in that commit. This puts them back in. - http://git.io/BdU5Og [19:52] wink_: or if you'll run it, i'll gladly take a peek at the profile for you [19:53] piscisaureus_: Aikar: try with node 0.5 [19:53] Aikar: oh [19:53] Aikar: i ran that with .4 lol [19:53] ryah: that commit puts back in a bunch of perf fixes [19:53] adriftatsea has joined the channel [19:53] flagg0204 has joined the channel [19:53] Aikar: cool [19:53] tmzt has joined the channel [19:53] Aikar: ill do an update in a bit [19:53] Aikar: damn i really need to get some work done at work tho lol >< [19:54] maletor has joined the channel [19:54] MUILTFN has joined the channel [19:54] aguynamedben has joined the channel [19:55] JaKWaC has joined the channel [19:55] Aikar: how come i cant pipe those crankshaft reports to a file [19:55] Aikar: when i do > crankshaft.log, file is empty [19:55] Aikar: but w/o the >, it prints em [19:55] wink_: its probably not printing to stdout [19:55] ph^ has joined the channel [19:55] wink_: > will only redirect stdout, not stderr [19:55] Aikar: i tried 2> [19:56] Aikar: and then it printed still [19:56] Aikar: https://gist.github.com/1282327 [19:56] russfrank: did you try 2>&1 > outfile [19:56] wink_: Aikar: try 2>&1 [19:57] russfrank: :] [19:57] flagg0204 has joined the channel [19:57] ank has joined the channel [19:57] Aikar: still nothing [19:57] Aikar: i just copied from term [19:57] Aikar: I don't have an onread func, thats in node itself isnt it? [19:58] ilikeit has joined the channel [19:58] gallby has joined the channel [19:58] piscisaureus_: yes that's node itself [19:58] c4milo has joined the channel [19:59] gallby has left the channel [19:59] flagg0204 has joined the channel [19:59] josdehart has joined the channel [19:59] TheJH: MooGoo, ping [19:59] blueadept has joined the channel [19:59] blueadept has joined the channel [19:59] pid_ has joined the channel [19:59] balaa has joined the channel [20:00] TheJH: MooGoo, you got rid of all the node stuff and just put catb0t in a nearly-vanilla v8 engine? [20:00] TRUPPP has joined the channel [20:00] tekky has joined the channel [20:02] flagg0204 has joined the channel [20:02] iammerrick has joined the channel [20:03] Aikar: Waf: Leaving directory `/home/aikar/projects/node/out' [20:03] Aikar: Build failed: -> task failed (err #2): {task: uv uv.h -> uv.a} [20:03] Aikar: make: *** [program] Error 1 [20:03] TheJH: MooGoo, looks cool :) [20:03] Aikar: ryah: it blew up :( [20:03] Aikar: i did git clean -xfd before compiling too... so i know im in prestine checkout [20:04] flagg0204 has joined the channel [20:05] Aikar: standard ./configure && make -j 4 && make install [20:05] MooGoo: TheJH: yar [20:05] MooGoo: I cheated [20:05] MooGoo: customized shell.cc [20:06] Aikar: weird [20:06] Aikar: just typing make worked [20:06] flagg0204 has joined the channel [20:06] MooGoo: well for the eval process at least [20:06] MooGoo: rest of catbot is still node n stuff.. [20:07] ryah: Aikar: make distclean [20:07] Aikar: ryah: shouldnt git clean -xfd do that essentially? that deletes every file thats not part of the index [20:08] socketio\test\40 has joined the channel [20:08] dubenstein has joined the channel [20:08] ryah: Aikar: i suppsoe [20:08] Aikar: ryah: also, we did regain alot of performance with that commit, im now showing 207k/sec on my wormhole master benchmark. better than the 145k... but still far from the original 270k [20:09] ryah: Aikar: okay - well let's dig in [20:09] fbartho has joined the channel [20:09] ryah: Aikar: can you point me to that bench again? [20:09] stagas has joined the channel [20:09] TheJH: MooGoo, one eval process per channel? [20:09] Aikar: git clone github.com:aikar/wormhole, then node examples/benchmark_recv.js [20:09] MooGoo: chan/nick [20:10] tmzt_ has joined the channel [20:10] MooGoo: I suppose if you really wanted to troll me you could start like 300 eval processes [20:10] piscisaureus_: It would be interesting to merge the benchmark and make it one process [20:10] piscisaureus_: see if it still happens [20:10] Aikar: piscisaureus_: then the receiving is botlenecked by the json serialization [20:10] piscisaureus_: Aikar: don't jump to conclusions :-) [20:10] TheJH: MooGoo, I'd have to get a few dozen different IPs for that, I think :D [20:11] Aikar: piscisaureus_: this is from my findings before when i was making the benchmarks for wormhole :P [20:11] TheJH: or, no, actually not [20:11] Aikar: the sender process pegged out 100% way before the receiver did [20:11] MooGoo: just change your nick a lot [20:11] Aikar: adding a 2nd process doubled the messages/sec rate [20:11] Aikar: and finally let the recv process cap out [20:11] TheJH: MooGoo, just realized that, too [20:12] AphelionZ has joined the channel [20:12] Aikar: testperf.js at https://github.com/aikar/wormhole/blob/06b37c294318346da86b5c661025d019418627a5/testperf.js [20:12] YamahaAlex: can anyone recommend a good book, there is a 30% B&N coupon on slickdeals [20:12] Aikar: is running at 195k/sec with latest node [20:12] Aikar: so it gained a little [20:13] Aikar: ryah: does the node source being bundled into the process get it more advanced optimizations? [20:13] piscisaureus_: Aikar: no [20:13] MooGoo: hmm object inspector is not quite accurate is it [20:14] TheJH: MooGoo, funny, I can define global variables with __defineGetter__ :D [20:14] MooGoo: .. __defineGetter__ [20:14] catb0t: { } [20:14] baoist has joined the channel [20:14] TooTallNate has joined the channel [20:14] TheJH: MooGoo, exactly :D [20:14] MooGoo: why do you need defineGetter to define global vars [20:15] TheJH: .. __defineGetter__("GLOBAL", function(){return this}); Object.keys(GLOBAL) [20:15] catb0t: [ "print", "GLOBAL" ] [20:15] TheJH: MooGoo, to check whether there's something else than print :D [20:15] MooGoo: .. Object.getOwnPropertyNames(this) [20:15] catb0t: [ "TypeError", "decodeURI", "print", "parseFloat", "Number", "URIError", "encodeURIComponent", "RangeError", "ReferenceError", "RegExp", "Array", "isNaN", "Date", "Infinity", "Boolean", "Error", "NaN"... [20:15] TheJH: oh, I'm stupid :D [20:16] TheJH: .. __defineGetter__("GLOBAL", function(){return this}); GLOBAL===this [20:16] catb0t: true [20:16] mmalecki: TheJH: hacking on people's bots again :D ? [20:16] TheJH: .. Object.getOwnPropertyNames(this).join(" ") [20:16] catb0t: "TypeError decodeURI print parseFloat Number URIError encodeURIComponent RangeError ReferenceError RegExp Array isNaN Date Infinity Boolean Error NaN String Function Math undefined encodeURI escape un... [20:16] TheJH: mmalecki, he told me to do it :D [20:16] MooGoo: catb0t's being stingy [20:16] zastaph has joined the channel [20:16] TheJH: mmalecki, TheJH: hax catb0t [20:17] TheJH: mmalecki, but he got it super-secure :D [20:17] MooGoo: all cuz of ur hax [20:17] TheJH: .. Object.getOwnPropertyNames(this).slice(20).join(" ") [20:17] catb0t: "undefined encodeURI escape unescape decodeURIComponent EvalError GLOBAL SyntaxError Object eval parseInt JSON isFinite" [20:17] Aikar: ok so wormhole is now running equally against fork IPC(), now to get them all to get up to 250+k range (judging on my system specs at least) :P [20:18] ph^ has joined the channel [20:18] TheJH: MooGoo, oh no, my hax made stuff secure :P [20:18] MooGoo: should have kept it to yourself [20:19] Aikar: so if i did.... .. Object.getOwnPropertyNames = function() { console.log("NOU"); } [20:19] TheJH: then catb0t could have overtaken the whole world for me :( [20:19] Aikar: what protects your bot from being dismantled? lol [20:19] MooGoo: lazars [20:19] jhbot: don't worry, TheJH, you still have me :) [20:19] TheJH: jhbot, let us overtake the world :) [20:20] jhbot: :) [20:20] TheJH: Aikar, one process per channel :D [20:21] TheJH: Aikar, it's not that easy :P [20:21] MooGoo: .talk jhbot [20:21] catb0t: jhbot is a GLOBAL variable if runInNewContext gives you access to the server to not use the same key more than you would do for my old firefox version talk [20:21] ph^_ has joined the channel [20:21] MooGoo: catb0t isnt taking over anything yet.. [20:21] jhbot: catb0t, but you don't use runInNewContext :( [20:21] dob_ has joined the channel [20:22] mbrevoort has joined the channel [20:23] MooGoo: catb0t runInNewContext [20:23] catb0t: runInNewContext will give you an idea [20:23] JaKWaC has joined the channel [20:23] jhbot: catb0t, stop being so mean :( [20:23] catb0t: being printed out on the workload, luajit is fast , however the mailing lists if you haven't finished reading it [20:23] trose: playing around with socket.io anyone know why I would get 'io is not defined' using the first example on their website? socket.io is in ./node_modules/ relative to the example... [20:25] CIA-48: libuv: 03Igor Zinkovsky 07 * r72b5976 10/ (5 files in 2 dirs): [20:25] CIA-48: libuv: windows: support utf8 in uv_fs functions [20:25] CIA-48: libuv: fixes #201 - http://git.io/CJvVRg [20:28] socialhack has joined the channel [20:29] swick has left the channel [20:29] JaKWaC has joined the channel [20:29] tek has joined the channel [20:29] tmzt has joined the channel [20:30] zackattack has joined the channel [20:31] dreamdust has joined the channel [20:31] openpercept has joined the channel [20:32] EvRide has joined the channel [20:33] mandric has joined the channel [20:33] piscisaureus_: Aikar: this benchmark doesn't handle backpressure, or does it? [20:33] piscisaureus_: Aikar: so if the writing process can write faster than the reading process, it'll just eat memory [20:33] jhbot has joined the channel [20:33] wbw72 has joined the channel [20:34] jetienne_ has joined the channel [20:35] jhbot has joined the channel [20:35] TheJH: bottest: https://gist.github.com/792521 [20:35] jhbot: TheJH, my almighty, artificially created brain says that that version of npm (0.x) is ancient. update npm with `curl http://npmjs.org/install.sh | sudo sh`. [20:35] jhbot: TheJH, my almighty, artificially created brain says that you're using a very unstable version of node (git master/HEAD). If you don't want to run into problems like this one, use a stable version (in x.y.z, y is an even number and there's no -pre at the end of the version). Of course, you should report problems anyway - after all, what's unstable now is supposed to become stable soon. [20:35] tdegrunt has joined the channel [20:35] TheJH: @channel: does that look good? [20:35] mmalecki: ancient && HEAD? [20:36] TheJH: mmalecki, found it via gist search :D [20:36] TheJH: "npm info using node@v0.3.6-pre" [20:36] mmalecki: ah, 0.3.6-pre [20:36] piscisaureus_: Aikar: the fun thing is, on node 0.4 the receiving process is accumulating stuff [20:36] mmalecki: TheJH++ [20:36] catb0t: TheJH now has 1 beer [20:36] versicolor has joined the channel [20:36] TheJH: :) [20:36] piscisaureus_: On node 0.5 it's the writers [20:37] tmzt_ has joined the channel [20:37] AvianFlu has joined the channel [20:37] TheJH: mmalecki, any other popular node related problems that you can think of? [20:38] mmalecki: TheJH: not enough tanks to rule the world yet? [20:38] versicolor has joined the channel [20:38] TheJH: mmalecki, :D [20:38] versicolor has joined the channel [20:38] wbw72 has left the channel [20:40] topaxi has joined the channel [20:40] isaacs has joined the channel [20:42] Venom_X has joined the channel [20:42] tlrobinson has joined the channel [20:42] `3rdEden: trose: you are probably listening in correctly, the .listen method of socket.io returns a socket.io instance [20:42] slifty has joined the channel [20:43] parshap has joined the channel [20:43] markwubben has joined the channel [20:44] Astro has joined the channel [20:45] boaz has joined the channel [20:46] boltR has joined the channel [20:47] mendel_ has joined the channel [20:47] dubenstein has joined the channel [20:47] maletor has joined the channel [20:47] piscisaureus_: aaah [20:48] piscisaureus_: it's probably just the missing string concat optimization that hurts wormhole [20:49] tjgillies has joined the channel [20:49] ph^ has joined the channel [20:49] tjgillies: how would i do this in real code? foo.(function(){this.cat = "meow"})() [20:50] mmalecki has joined the channel [20:50] zemanel has joined the channel [20:50] jerrysv_ has joined the channel [20:50] ph^_ has joined the channel [20:53] Aikar: piscisaureus_: theres more opts left out? [20:53] theCole has joined the channel [20:53] eee_c has joined the channel [20:53] eignerchris has joined the channel [20:55] slifty has joined the channel [20:55] Aikar: and what do you mean by readers/writers differing ? [20:55] bnoordhuis: Aikar: can you try this patch? https://raw.github.com/gist/1282512/d69acbe88befee79aa027d10e01196da54702361/patsje-rebase.patch [20:55] akiva has joined the channel [20:57] Aikar: err [20:57] Aikar: holy shit [20:57] Aikar: lemme double check some things [20:58] Aikar: cause im seeing 500k/sec O.o [20:58] Aikar: bnoordhuis: what the hell was in that bnoordhuis lol [20:58] bnoordhuis: not too shabby eh? :) [20:58] whse_: lol indeed [20:58] piscisaureus_: Aikar: it was an optimization that was in 0.4 but not yet in 0,6 [20:58] Aikar: my bad, that was in the 2x benchmark [20:59] piscisaureus_: we knew that it was missing, just took some time to figure out that was what your code needs [20:59] jarek has joined the channel [20:59] jarek has joined the channel [21:01] Aikar: ok, so im seeing 320k/sec but the output is very jumpy... [21:01] trotter has joined the channel [21:01] Aikar: VERY laggy [21:01] micheil has joined the channel [21:01] piscisaureus_: laggy? [21:01] BillyBreen has joined the channel [21:01] Aikar: like i can see the cursor jump to the beggining of the line every so often O.o [21:01] Aikar: by me using \r [21:01] Aikar: the output of the benchmark [21:01] micheil: piscisaureus_: have you ever seen issues with making node and gyp? [21:01] balaa has joined the channel [21:01] piscisaureus_: Aikar: that benchmark is kind of broken [21:02] Aikar: why? [21:02] piscisaureus_: Aikar: you write faster than you can read so your writer processes are accumulating the output buffer in memory [21:02] piscisaureus_: without any bounds [21:02] tmzt has joined the channel [21:02] micheil: I'm getting an error buliding node with gyp and libuv on mac os x 10.6: https://gist.github.com/1282536 [21:02] bnoordhuis: micheil: gyp support is not complete [21:02] bnoordhuis: (yet) [21:02] piscisaureus_: Aikar: look at the memory usage of the writing processes [21:02] Aikar: ok ill turn off a sender [21:02] micheil: I should be able to make node with it though, right? [21:02] piscisaureus_: Aikar: that's not the point [21:03] bnoordhuis: micheil: on a good day yes :) [21:03] micheil: :/ [21:03] bnoordhuis: micheil: i think you're running into the new kqueue stuff [21:03] micheil: ACTION reverts to using waf. [21:03] piscisaureus_: Aikar: you should have some mechanism to handle backpressure (e.g. socket.write returning 0) [21:03] piscisaureus_: Aikar: or have a fixed number of pending send operations, and only queue more after you get a write callback [21:03] bnoordhuis: micheil: what version of node is that? it's fixed (or should be fixed) in master [21:03] micheil: 0.5.9 [21:04] micheil: freshly checkout of github [21:04] elsig has joined the channel [21:04] piscisaureus_: Aikar: I think the latter is better for this benchmark [21:04] bnoordhuis: right, checkout master and it'll go away [21:04] Aikar: piscisaureus_: i understand, but removing a sender still lets you COMPARE, it just doesnt give you accurate ACTUAL throughput [21:04] Aikar: >>> node examples/benchmark_recv.js [21:04] Aikar: The "sys" module is now called "util". It should have a similar interface. [21:04] Aikar: Received 4318k messages - Rate: 215.0k messages/sec^C[ Tyrial ] ---- [ 05:03 PM ] ---- [ aikar ] ---- [ master ] - (U:0:M:1) ---- [ ~/projects/wormhole ] [21:04] Aikar: >>> n 0.4.12 [21:04] piscisaureus_: Aikar: so don't remove a sender, but handle backpressure properly :-) [21:04] Aikar: [ Tyrial ] ---- [ 05:03 PM ] ---- [ aikar ] ---- [ master ] - (U:0:M:1) ---- [ ~/projects/wormhole ] [21:04] vineyard has joined the channel [21:04] Aikar: >>> node examples/benchmark_recv.js [21:04] Aikar: Received 490k messages - Rate: 132.7k messages/sec^C [21:04] Aikar: with 1 sender, were now faster than 0.4.12 [21:05] Aikar: and the output isnt laggy [21:05] piscisaureus_: nice [21:05] Aikar: so that patch def needs to be applied [21:05] colinclark_ has joined the channel [21:05] jhurliman has joined the channel [21:05] Aikar: but yeah great work... now even faster for wormhole! /happy [21:05] Aikar: ill try to improve the benchmark tonight [21:05] tjholowaychuk: Aikar try caching the length too [21:05] tjholowaychuk: ACTION curious [21:06] tjholowaychuk: in the little for loop [21:06] Aikar: k [21:06] Aikar: wait, which length [21:07] wereHamster: how do I mark tests as pending on vowsjs? [21:07] micheil: bnoordhuis: now it's making but hitting: ar: src/uv-common.o: No such file or directory [21:07] micheil: which is kinda strange [21:07] micheil: (that's with standard make [21:07] darinc has left the channel [21:07] Aikar: tjholowaychuk: the obj._.length isnt something cachable, thats message body [21:07] bnoordhuis: micheil: you probably need to do a `make distclean` [21:07] tjholowaychuk: Aikar where's the patch again [21:07] tjholowaychuk: lost it [21:07] ryah: micheil: make distclean [21:07] Aikar: oh you mean the node patch? not wormholes code? [21:07] micheil: I have [21:08] tjholowaychuk: Aikar ah yeah sorry :) [21:08] tjholowaychuk: near the bottom i think [21:08] ryah: micheil: do it again :) [21:08] Aikar: ah k [21:08] tjholowaychuk: just curious if it will make a difference or not [21:08] micheil: ryah: see: https://gist.github.com/1282568 [21:08] micheil: :) [21:08] micheil: I have definitely done a make distclean [21:09] Aikar: tjholowaychuk: https://raw.github.com/gist/1282512/d69acbe88befee79aa027d10e01196da54702361/patsje-rebase.patch [21:09] bnoordhuis: micheil: sanity check: rm -rf out/ build/ && ./configure && make [21:09] Aikar: the data.length calls? [21:09] ryah: micheil: don't do make -j2 [21:09] micheil: ah [21:09] micheil: looks like that may have been it. [21:09] Aikar: ryah: why is -j breaking it? [21:09] _th_n_ has joined the channel [21:09] ryah: *shrug* [21:09] micheil: something recommends -j2 [21:09] AvianFlu has joined the channel [21:09] Aikar: JOBS=4 seems to still work [21:09] tjholowaychuk: Aikar for (var i = 0; callbacks[i]; ++i) [21:09] tjholowaychuk: that part [21:09] tjholowaychuk: at the bottom [21:09] micheil: Aikar: as an env? [21:10] Aikar: micheil: yea [21:10] micheil: okay [21:10] Aikar: but export it [21:10] Aikar: ive always used JOBS=4 env for node [21:10] micheil: because making on only a single core is slow on my older computer [21:10] Aikar: I thought that was how all make commands worked till i learned it was special to node :/ [21:10] Aikar: and that -j was the standard [21:11] nforgerit has joined the channel [21:11] Aikar: micheil: it doesnt seem to propogate down to all sub builds (maybe thats why it works, others dont support multiple jobs?) but node stuff seems to run on multi core with JOBS [21:11] gf3 has joined the channel [21:11] stisti has joined the channel [21:11] Aikar: tjholowaychuk: i dont see what you man to cache there? [21:12] Aikar: mean* [21:12] Aikar: it doesnt use a length property [21:12] micheil: Aikar: do you have four cores? [21:12] joshonth_ has joined the channel [21:12] Aikar: yeah [21:12] CIA-48: node: 03Ryan Dahl 07 * r08cb8fc 10/ src/node.cc : [21:12] CIA-48: node: Remove process.ARGV [21:12] CIA-48: node: Use process.argv instead. - http://git.io/wy60tA [21:12] Aikar: ryah: gonna kill GLOBAL and root too?! lol [21:12] tauren has joined the channel [21:13] jhbot has joined the channel [21:13] Tobsn has joined the channel [21:13] Aikar: piscisaureus_: would sending data on('drain', fn) be a better idea for feeding the receiver? [21:14] Aikar: im lil curious why it lags the output though [21:14] piscisaureus_: Aikar: probably just because your system is busy [21:14] Aikar: ah good point, but should of only been 3 of my 4 cores [21:14] julioj has joined the channel [21:14] cognominal has joined the channel [21:14] Aikar: https://github.com/aikar/node/tree/patsje [21:15] Aikar: there is the branch with that patch applied + my fork performance increase patch [21:15] piscisaureus_: Aikar: I think generally for IPC handling backpressure is not really much of an issue [21:15] Aikar: piscisaureus_: yeah but i really want to judge accurate total throughput, so i want to make the receiving process consume as much as possible [21:16] Aikar: and if senders are sending too much, that strains it [21:16] piscisaureus_: Aikar: well… maybe not [21:16] piscisaureus_: Aikar: the way the writers work are kind of bad but they actually make the receiver sweat [21:16] piscisaureus_: which is what you want [21:17] piscisaureus_: so in that sense the benchmark is okay [21:17] micheil: ryah: oh, yeah, just ftr, there is actually a need for node-websocket-server and node-websocket-protocol, just socket.io isn't enough. [21:18] micheil: there's two types of innovation that is possible with websockets in node, one is at protocol level, the other is at end-user API level. [21:18] towski has joined the channel [21:18] ryah: micheil: okay [21:18] piscisaureus_: Aikar: I was merely pointing out that for a real application where there is more communication that your cpu can handle, this is kind of bad style :-) [21:18] ryah: did i suggest otherwise? :/ [21:18] Aikar: piscisaureus_: true [21:19] Aikar: im looking to be averaging 312k with the laggy prompt [21:19] Aikar: could it be due to stdout being blocking now in .5? [21:19] Aikar: as compared to it not lagging in .4 [21:19] CoverSlide: stdout blocks? wtf??? [21:19] jellosea: does anybody know how to setup a private npm repository? [21:19] CIA-48: node: 03Ryan Dahl 07 * rde7fb33 10/ (doc/api/_toc.markdown doc/api/cluster.markdown): Add some docs for node cluster - http://git.io/HdTgUw [21:19] jhbot has joined the channel [21:19] piscisaureus_: Aikar: I am not really sure yet what you mean by lagging [21:19] slickplaid has joined the channel [21:19] isaacs: jellosea: npm help registry [21:20] piscisaureus_: You can see the cursor? That's an OS issue no shit. [21:20] sub_pop has joined the channel [21:20] jellosea: isaacs: will this let me do it? https://github.com/isaacs/npmjs.org [21:20] Aikar: you ran the benchmark right? notice how the text just updates really fast [21:20] piscisaureus_: yeah [21:20] Aikar: im seeing the text update like every 1-2s [21:20] piscisaureus_: aah [21:21] Aikar: and the block cursor i can actually see jump to the beginning of the line when it does a \r [21:21] Aikar: then back to end [21:21] nforgerit has joined the channel [21:21] jhbot has joined the channel [21:21] Aikar: even with all 3 cores maxed out in .4.x it didnt do that [21:21] Aikar: but i did read stdout blocks now right? [21:21] micheil: ryah: yes. about 6 months back you told me that I should give up working on both and just use socket.io instead. [21:21] wilmoore has joined the channel [21:21] ryah: micheil: oh. you sure that was me? [21:22] EvRide has left the channel [21:22] micheil: yes. and about half the other core contributors. [21:22] ryah: micheil: i take it back then :) [21:22] tjholowaychuk: micheil not a bad abstraction to make [21:22] micheil: or, "core contributors" as in the top ten on github contributions [21:22] ryah: having a separate websocket library is good [21:22] piscisaureus_: 6 months ago there were no other core contributors [21:22] gkmngrgn has joined the channel [21:22] tjholowaychuk: if you can even call that an abstraction i guess [21:23] micheil: the aim for node-websocket-protocol is to be the http_parser of websockets. [21:23] micheil: (so, very low level, extremely optimised, and written to the spec.) [21:23] piscisaureus_: Aikar: hmm. Maybe the issue is that stdout is not yet blocking, and the event loop is just too busy doing other stuff [21:24] jhbot has joined the channel [21:24] Aikar: piscisaureus_: EL being busy sounds like it would affect .4 too? [21:24] micheil: the one thing that I'm stuck with in node-websocket-protocol at the moment is just how low level it should be [21:24] dgathright has joined the channel [21:25] sechrist: "SSL3_GET_CLIENT_HELLO:no shared cipher" would I see this if my key is invalid or something? [21:25] sechrist: or is this another problem [21:25] mbrevoort has joined the channel [21:26] lmorchard has joined the channel [21:26] piscisaureus_: Aikar: yeah [21:26] piscisaureus_: Aikar: hmm... [21:26] piscisaureus_: or… heh [21:26] piscisaureus_: if that string concat patch affects stdout writes [21:27] jhbot has joined the channel [21:29] jhbot has joined the channel [21:30] fmeyer has joined the channel [21:30] matyr has joined the channel [21:30] tmzt has joined the channel [21:30] Aikar: sechrist: if thats on 0.4.x that was fixed in .13-pre [21:30] Aikar: the openssl errors spamming console [21:31] Deputaats has joined the channel [21:31] micheil: isaacs: does npm work on node v5.10.0-pre? [21:31] sechrist: Aikar: but ssl wasn't broken, right/ [21:31] Aikar: nope [21:31] sechrist: yeah it's not working for me, handshaking problem [21:31] eboyjr has joined the channel [21:31] Aikar: like trying to connect to https with an http url would throw those lil warnings into the console [21:31] sechrist: trying to figure out if I messed up concatencating my chain cert or what [21:31] TheJH: !docs search setInterval [21:31] jhbot: section "Global Objects": http://nodejs.org/docs/latest/api/all.html#global_Objects [21:31] jhbot: section "Timers": http://nodejs.org/docs/latest/api/all.html#timers [21:31] Deputaats: hi, is it possible to get server domain like in php it would be $_SERVER['HTTP_HOST'] ? [21:31] TheJH: mmalecki, docs search :) ^ [21:31] socialhack_ has joined the channel [21:32] mmalecki: TheJH: good! [21:32] sechrist: Deputaats: req.headers.host [21:32] micheil: oh. right. just saw the mailing list thing about npm and 5.10, cc isaacs [21:32] TheJH: Deputaats, get the "Host" header from the http request [21:32] balaa has joined the channel [21:32] mmalecki: I wanted to write it, but, well, TODO list. [21:32] Swizec has joined the channel [21:32] mmalecki: TheJH++ [21:32] catb0t: TheJH now has 1 beer [21:32] Deputaats: thanka [21:32] Deputaats: *thanks [21:32] mmalecki: have another beer [21:33] TheJH: mmalecki, it's based on my complex-search module (which actually is pretty basic), so you can search with ()|& [21:33] ambroff has joined the channel [21:33] mmalecki: TheJH: nice [21:33] nforgerit has joined the channel [21:33] CrabDude has joined the channel [21:33] mmalecki: TheJH: link? [21:33] AphelionZ: Can one use a socket.io heartbeat as an event? like is there an on("heartbeat")? [21:34] TheJH: !docs search repeated (execution|running) [21:34] jhbot: section "Timers": http://nodejs.org/docs/latest/api/all.html#timers [21:34] TheJH: mmalecki, to complex-search? [21:34] EvRide has joined the channel [21:34] `3rdEden: AphelionZ nope there isn't [21:34] mmalecki: yeah [21:34] TheJH: !npm search complex-search [21:34] jhbot: package complex-search: Search for stuff with &, | and parens [21:34] `3rdEden: but feel free to make feature request for it AphelionZ ;D [21:34] AphelionZ: `3rdEden: word, I might :) [21:34] TheJH: mmalecki, should be at https://github.com/thejh/node-complex-search [21:34] mmalecki: ah, ok, thanks [21:35] joshgillies has joined the channel [21:35] jarek__ has joined the channel [21:35] CrabDude: tjholowaychuk: am I smoking something or should this be installing a more recent version? [21:35] CrabDude: $ npm install expressexpress@1.0.7 ./node_modules/express├── qs@0.3.1└── connect@1.0.1 [21:35] tmzt has joined the channel [21:36] isaacs: CrabDude: are you in a folder with a package.json file? what version of node are you using? [21:36] baoist has joined the channel [21:36] davidbanham has joined the channel [21:37] CrabDude: no package.json, v0.5.8 [21:37] piscisaureus_: Aikar: just ignore the lagging for the moment. I think it might be a node bug [21:39] Aikar: piscisaureus_: ok, lemme know if you find something. i have that .patch file applied to https://github.com/aikar/node/tree/patsje if you wanna test off that [21:40] `3rdEden: tjholowaychuk vbench breaks in 0.5.9 :p [21:40] tjholowaychuk: oh probably [21:40] tjholowaychuk: i'll have to spend like 3 weeks fixing all my modules [21:40] tjholowaychuk: yayyy [21:40] tmzt has joined the channel [21:40] `3rdEden: \o/ [21:40] TheJH: tjholowaychuk, :D [21:40] TheJH: tjholowaychuk, have fun :D [21:40] Aikar: err, now its pushed, forgot to commit it [21:40] context: haha [21:41] context: how do you push whats not commited [21:41] lightcap has joined the channel [21:41] willwh: you don't [21:42] Aikar: i branched, then pushed the branch to the remote :P [21:42] Aikar: so it was essentially a clone of the parent branch, with a new name! [21:42] TheJH: tjholowaychuk, lessons learned: publishing cool modules is fine, but don't create ones people will actually care about or they'll bug you until you fix them when stuff breaks [21:42] gplg1 has joined the channel [21:42] fly-away has joined the channel [21:43] gplg1 has left the channel [21:43] tjholowaychuk: TheJH sucks too because if i publish a connect 2.0 alpha again it will break all that old crap [21:43] tjholowaychuk: haha [21:43] tjholowaychuk: good times [21:43] ph^ has joined the channel [21:45] TheJH: tjholowaychuk, I think you could set "latest" to the latest stable version (although that'd be completely hackish) [21:45] TheJH: isaacs, would that work? [21:45] tjholowaychuk: maybe [21:45] tjholowaychuk: but if people have specific releases pinned [21:45] tjholowaychuk: they will have a nice surprise [21:45] isaacs: tjholowaychuk: if you use 1.7.x or 1.x instead of <2.0.0 then it'll work. [21:46] nforgerit has joined the channel [21:46] tjholowaychuk: i'd have to re-publish [21:46] tjholowaychuk: all the old releases [21:46] baoist has joined the channel [21:46] isaacs: oh, because they all use <2.0.0? [21:46] isaacs: tjholowaychuk: then call it 2.0.1alpha ;) [21:46] tjholowaychuk: a lot of them yeah [21:46] jocafa has joined the channel [21:47] tjholowaychuk: haha yeah might be worth doing that [21:47] isaacs: tjholowaychuk: or skip over 2 and go straight to 3 [21:47] isaacs: who cares? [21:47] isaacs: it's just a number, man. [21:47] Aikar: 2.0.1? [21:47] CoverSlide: go to 7 [21:47] tjholowaychuk: ahaha [21:47] tjholowaychuk: 7 it is [21:47] Aikar: thatll brainfuck people [21:47] aguynamedben has joined the channel [21:47] Aikar: "HOLY CRAP 7?! ALL MY CODE IS GONNA BE BROKE!!!" [21:47] Renegade001 has joined the channel [21:48] Renegade001 has joined the channel [21:48] Aikar: tjholowaychuk: maybe should just bundle deps with express ;) [21:48] TheJH: tjholowaychuk, I think you can edit all versions of something at once at http://isaacs.couchone.com/_utils/document.html?registry/express [21:48] TheJH: hmm, actually [21:48] TheJH: ... [21:49] TheJH: no, that wouldn't completely work, I guess [21:49] TheJH: but at least, you can set "latest" there :) [21:50] Aikar: lol is that really open for anyone to edit? [21:51] socialhack has joined the channel [21:51] Xano has joined the channel [21:51] stagas has joined the channel [21:51] tdegrunt has joined the channel [21:51] CrabDude: isaacs: Any suggestions how to debug - "npm install express" => "express@1.0.7"? no package.json files, npm v1.0.94 [21:52] isaacs: CrabDude: what version of node. [21:52] isaacs: CrabDude: node -v [21:52] CIA-48: node: 03Ryan Dahl 07 * r73b4b86 10/ node.gyp : Add cluster.js to node.gyp - http://git.io/dDdaEA [21:52] CrabDude: v0.5.8 [21:52] CrabDude: isaacs: v0.5.8 [21:52] Aikar: I thought cluster wasnt going to be ready for .6, is it ryah ? (since its in master) [21:53] CrabDude: isaacs: npm view express shows all versions available (2+, etc..) [21:53] entropax has joined the channel [21:53] tmzt has joined the channel [21:54] mattrobenolt has left the channel [21:54] ryah: Aikar: it's going to be in v0.6 [21:55] saikat has joined the channel [21:55] gut4 has joined the channel [21:55] nforgerit has joined the channel [21:55] Aikar: cool [21:56] NetRoY has joined the channel [21:57] piscisaureus_ has joined the channel [21:57] sfoster has joined the channel [21:57] aguynamedben_ has joined the channel [21:58] Renegade001 has left the channel [21:58] CrabDude: baaaaaah! [21:58] wankdanker: what's cluster.js? are there docs started? [21:58] isaacs: CrabDude: install with -dd and gist the output, i dunno [21:59] reid has joined the channel [21:59] whse_: Aikar: talking about this?> http://learnboost.github.com/cluster/ [21:59] CrabDude: isaacs: it's cuz I'm running node v0.5+ and express 1.0.7 is the latest that doesn't explicitly specify node <0.5 [21:59] Aikar: when you have a pull req, how do you remove the 'merge from upstream/master' commit off the pullreq? [21:59] Aikar: https://github.com/joyent/node/pull/1864 [21:59] isaacs: well, there ya go :) [21:59] isaacs: CrabDude: that's why i asked node version [22:00] CrabDude: yes, thx for the tip [22:00] CrabDude: that's what led me to look [22:00] Aikar: whse_: no, an official support for that functionality [22:00] Aikar: well some of it [22:00] mmalecki: Aikar: git reset --hard HEAD^ should do it, I think... [22:00] Aikar: check lib/cluster.js on node/master [22:00] piscisaureus has joined the channel [22:00] Aikar: mmalecki: ive already commited/pushed to my origin [22:00] mmalecki: Aikar: yes [22:00] heavysixer has joined the channel [22:01] tjholowaychuk: how far is this core cluster thing going to go? [22:01] mmalecki: Aikar: you'll have to push --force later [22:01] mmalecki: Aikar: also, I'm not sure how gh acts then [22:01] piscisaureus has joined the channel [22:02] Aikar: mmalecki: https://github.com/joyent/node/pull/1864 [22:02] Aikar: thanks that worked [22:02] mmalecki: :) [22:02] balaa has joined the channel [22:02] Aikar: i guess i should have rebased and force pushed [22:02] Aikar: instead of a git pull [22:02] chance- has joined the channel [22:03] whse_: im off for the night [22:03] mmalecki: Aikar: yeah [22:03] CoverSlide: core cluster will have logging, repl, and a web interface [22:03] tjholowaychuk: haha [22:03] mmalecki: lulz [22:03] Aikar: web interface O.o? [22:03] CoverSlide: replacing cluster completely [22:03] tjholowaychuk: booyah [22:03] tjholowaychuk: we cant have two things named cluster [22:03] tjholowaychuk: that's just weird [22:03] tjholowaychuk: and require() will break [22:03] tjholowaychuk: haha [22:03] gkmngrgn has joined the channel [22:04] Aikar: ryah: https://github.com/joyent/node/pull/1864 this simple change removes unnecessary string modification and resulted in a 10-15% performance increase for me [22:04] tmzt_ has joined the channel [22:05] akiva: Why do you think it is so many Node.js programmers user prototypal patterns for their objects rather than closures? [22:05] akiva: I always found that a little baffling [22:05] Aikar: that statement seems weird [22:05] tjholowaychuk: yes it does [22:05] Aikar: why do people use apples instead of hammers O.o [22:06] joshgillies: .... [22:06] cl0udy has joined the channel [22:06] joshgillies: Aikar: the punch-line? [22:06] Aikar: akiva: do you mean seperate callback funcs instead of anonymous functions? namely to prevent indentation hell [22:06] akiva: If I am making an object to export, why would I not use a closure to expose methods rather than just prototyping? Why does that seem odd? [22:06] rudolfrck has left the channel [22:06] shipit has joined the channel [22:06] hl7Guy has joined the channel [22:06] ryah: Aikar: thanks - landing [22:07] AvianFlu has joined the channel [22:07] slifty has joined the channel [22:07] Aikar: akiva: i think your mixing words up a lil incorrectly, can you give a code example of what you mean? [22:07] akiva: Assuming it's not soething you will rneed a lot of instances of? [22:07] Aikar: what you think people do vs what you think should be done [22:07] CIA-48: node: 03Daniel Ennis 07 * r59be975 10/ lib/child_process.js : [22:07] CIA-48: node: Improve IPC performance. [22:07] CIA-48: node: Reading of JSON data off the buffer, 10-15% performance increase. [22:07] CIA-48: node: Fixes #1864. - http://git.io/TpWYmA [22:07] akiva: Ah, interesting ... Just found someone discussing it http://howtonode.org/why-use-closure [22:07] guillermo has joined the channel [22:08] jimt_ has joined the channel [22:08] nforgerit has joined the channel [22:08] akiva: Oh, I only asked because I see in a lot of code online for node.js people always resorting to a more classic way of programming an object with methods via prototype and not the more typical closure method that a lot of JS programmers would use [22:09] bradleymeck: akiva because as much as I like functional programming I do not like the multiple function iteration style where you pass many callbacks that hold state [22:09] Renegade001 has joined the channel [22:09] wilmoore has joined the channel [22:09] akiva: I always wondered if it was due to experience in a more classical style language [22:09] airhorns has joined the channel [22:09] bradleymeck: akiva, no, its just a pain to maintain state in a function rather than an object I find [22:09] bradleymeck: I wrote up a whole system a year or so ago to manage state for me and it was just too complex [22:09] akiva: But you still use objects [22:10] akiva: :? [22:10] skm has joined the channel [22:10] bradleymeck: yes. objects are easier to maintain / inspect than closures [22:10] Xano has joined the channel [22:10] chance- has joined the channel [22:10] akiva: That link is exactly how I do alot of things and explains what I mean. Sorry if my terminology seemed off? [22:10] Aikar: abuse closures too much and your going to start wasting memory. if you find yourself 10 levels deep of closures, well, thats 10 possible scopes left opened [22:11] CIA-48: node: 03Karl Skomski 07 * r9557020 10/ src/platform_win32.cc : [22:11] CIA-48: node: New win32 platform function: GetCPUInfo [22:11] CIA-48: node: Fixes #1644 - http://git.io/3gA1gA [22:11] bradleymeck: using objects rather than variables through closures by name allows easy schema validation and feature detection. [22:11] akiva: I don't understand what you mean Aikar. Imagine creating a post object from a closure (ie. an factory object) [22:11] akiva: Why should that have anything to do with many levels of depth? [22:12] bradleymeck: prototypes are just nice things that prevent massive function allocation and easy inheritance [22:12] bradleymeck: and allow* [22:12] Aikar: if you have a closure that generates a closure, and that closure also returns a closure. it gets silly [22:12] CoverSlide: I'd prefer Object.create() over new [22:12] miccolis has joined the channel [22:13] CoverSlide: then it's using prototypal not classical [22:13] chjj: yo dawg i heard you like closures... [22:13] Aikar: akiva: im still confused by your question. If you need to build an object that has multiple methods, how do you expect to replace that with closures? [22:13] bradleymeck: factory objects are painful to extend I find, I run y=Object.create(x), extend y w/ w/e and then run Object.create(y), instead of just assigning a function prototype [22:13] tjholowaychuk: CoverSlide { __proto__: foo } is pretty nice [22:13] tjholowaychuk: minus the __ [22:14] CoverSlide: it's nice, but I don't like the non-standardness [22:14] chjj: nonsense [22:14] chjj: its good non-standardness [22:14] Aikar: do you mean function foo() { var x = {}; x.foo = function() { } }; foo().foo() ? [22:15] Aikar: tjholowaychuk: hmm so foo.prototype = {__proto__: bar}; ? interesting quick way [22:15] akiva: No, no. I understand what prototypal patterns are, but I mean, why is this not used more: http://pastebin.com/k2A65FCu [22:15] chjj: akiva: its not as optimized in v8 [22:15] akiva: Why did explicitly using prototype become "the node way"? [22:15] CoverSlide: because that's slower than object.create, possibly even slower than new [22:15] Aikar: akiva: yes, the compiler doesnt know what functions will be on that object until its created [22:15] chjj: returning a closure is much more expensive than instantiating an object [22:16] tmzt has joined the channel [22:16] Aikar: it also breaks inheritance [22:16] chjj: akiva: prototypes are crazy optimized in v8 [22:16] akiva: It does allow a more secured object though. No lame __ to indicate privacy [22:16] Aikar: yes, thats its main benefit [22:16] tjholowaychuk: privacy [22:16] tjholowaychuk: is stupid [22:16] akiva: lol [22:16] chjj: yeah =/ [22:16] akiva: Do explain [22:16] CoverSlide: yes, that's nearly what's called the 'module' pattern [22:17] tjholowaychuk: i dont use a scripting language [22:17] Aikar: but seriously... this is javascript [22:17] tjholowaychuk: to have private methods [22:17] chjj: ill take performance over privacy any day [22:17] Aikar: js is like the most 'hackable' language [22:17] Aikar: privacy can not be expected [22:17] CoverSlide: which was created to emulate private functions, etc to be closer to classical oo [22:17] mmalecki: Aikar++ [22:17] catb0t: Aikar now has 1 beer [22:17] akiva: JavaScript is really not just a scripting language any longer... [22:17] tjholowaychuk: use dart [22:17] tjholowaychuk: if you want private stuff [22:17] chance-: heh, dart [22:18] mmalecki: I'M PRETTY SURE SOMEONE SAID DART. [22:18] CoverSlide: Did someone say dart?? [22:18] chjj: akiva: its a high level language any way you slice it [22:18] mmalecki: CoverSlide: YES. [22:18] chjj: node.dart whos WIT ME?! [22:18] chance-: *pukes* [22:18] steffan has joined the channel [22:19] AvianFlu: whoa, did I hear someone say Dart!? [22:19] akiva: Hm, well I guess that's that. I was expecting a bit more of a discussion than just slapping me in the face because I mentioned private methods. lol [22:19] chjj: sure did [22:19] tjholowaychuk: akiva foo() => object is still a prototype, it's just not .prototype [22:19] tjholowaychuk: i agree in general that .prototype / constructors [22:19] tjholowaychuk: are lame [22:19] AvianFlu: akiva you can create methods that are out-of-scope for all places except where they're needed [22:19] tjholowaychuk: but [22:19] tjholowaychuk: like everyone said [22:19] tjholowaychuk: v8 does magic [22:19] AvianFlu: that's fairly private, in the old school sense [22:19] chance-: anyone happen to know if its possible to have an embedded doc of a predefined schema other than a collection (in mongoose) [22:19] kuebk^: hi [22:20] kuebk^: what libuv really is [22:20] kuebk^: is a backend only for node [22:20] akiva: Yeah, well v8 have an optimized prototypal pattern is obviously a great reason, just not one I had heard before [22:20] kuebk^: or is it written to be a backend for anything? [22:20] mmalecki: kuebk^: it's a platform abstraction layer you can use for pretty much anything [22:21] Aikar: someones binding it to Lua [22:21] Aikar: another is binding it to PHP [22:21] Aikar: if the PHP Interpreter wasnt so damn slow id be really happy about that :| [22:21] Aikar: slow compared to V8 :P [22:22] chance-: the affiliation between php devs and node boggles my mind [22:22] Aikar: i am a PHP dev :P [22:22] chance-: i figured as much :P [22:22] chance-: i would have assumed it would have been more popular with the rails/sinatra crowd [22:22] Aikar: i believe theres a large ruby crowd too [22:23] Aikar: piscisaureus: any findings on the laggy console thing? [22:23] chjj: yeah, i think thats part of the reason node is great, everyone ends up here when they get sick of their original platform [22:23] russfrank: its possible to do inheritance with the style akiva suggested.. http://pastebin.com/P6bZfPe0 [22:23] Aikar: well i still like PHP, it's my day job, but node is much faster, and im an effeciency nut [22:24] piscisaureus: Aikar: probably it's a bug on our side, we forgot something making stdout blocking [22:24] piscisaureus: Aikar: don't worry about it [22:24] chance-: so im guessing it's not possible to do the embedded pre-defined schema in mongoose? gah, i'm going to have to create setter/getters of the first element on a collection? [22:24] Aikar: why do you people insist on using pastebin.com ; ; [22:24] chance-: that seems wrong [22:24] russfrank: the only good reason that i can see to not use this pattern is it might be less optimized by v8, but then again, what's optimized by v8 isn't necessarily the proper way of writing programs [22:24] piscisaureus: Aikar: basically you are writing too much shit to the console [22:24] Aikar: http://gist.github.com ! [22:24] russfrank: Aikar: it was what he used ;P [22:24] Raul_ has joined the channel [22:24] piscisaureus: Aikar: try to a little write less :-) [22:24] chance-: Aikar : because it has been around forever and gist is new? [22:24] russfrank: also whats the difference [22:24] CoverSlide: It's the proper way to write JavaScript programs [22:25] russfrank: yeah, you're probably right [22:25] Aikar: chance-: doesnt change the fact pastebin sucks and is distracting :P [22:25] russfrank: distracting? [22:25] chance-: Aikar : it has worked for years bro [22:25] Aikar: the ads (yes, i see ads, I wor kfor a marketing company), distract from content [22:25] Aikar: github=nice and clean [22:25] chance-: i mean it revolutionized help with code [22:26] russfrank: i don't see ads [22:26] chance-: Aikar : ads fuel the web [22:26] CoverSlide: it needs to die [22:26] Aikar: i dont bash its usefulness, im saying theirs a better site to do it now so use it :P [22:26] CoverSlide: there's like 50 better sites [22:26] Aikar: and you can fork gists! [22:26] chjj: chance-: flash worked for years before we had real embedded video in browsers, doesnt change the fact that flash sucks [22:27] chance-: heh, i'm not endorsing pastebin, i'm simply saying that the reason why people use it is because they have been for years. [22:27] russfrank: strawman alert! [22:27] chance-: it's familiar [22:27] Aikar: if your in the node community you should be familiar with github by now :P [22:27] chance-: gist is obviously way better and was a brilliant evolution of pastebining [22:27] russfrank: yeah man, github is where all the cool kids are at [22:27] chance-: github is not exclusive to node [22:28] russfrank: if you're not using github you're just not cool, man. [22:28] chance-: eh [22:28] chance-: heh* [22:28] chance-: what about bitbucket? :P [22:28] chance-: its basically a github clone these days [22:28] chance-: for the .py guys [22:29] jarek__ has joined the channel [22:29] slickplaid has joined the channel [22:30] chance-: you guys see douchebag's follow up to node's a cancer post? http://teddziuba.com/2011/10/straight-talk-on-event-loops.html [22:31] chjj: straight talk? [22:31] shanebo: anyone know if connect vhost will accept an array of domains on a single server? [22:32] tjholowaychuk: shanebo you can use wildcards but no arrays [22:32] tjholowaychuk: or you can loop through with .use() [22:32] tlynn_ has joined the channel [22:32] chjj: oh, he posted an image from family guy, that silly bastard [22:32] chjj: hes such a goofy regular guy, i love him! [22:32] shanebo: tjholowaychuk, wildcards? [22:32] Raul_: @all: is node really a cancer?? [22:32] chance-: Raul_ yes, yes it is [22:33] balaa has joined the channel [22:33] chance-: prostate cancer, to be exact [22:34] shanebo: tjholowaychuk, yeah I thought of use but it seems more dry and simple to extend connect vhost to accept an array of possible domains for one server [22:34] metellus has joined the channel [22:35] MUILTFN has joined the channel [22:35] AvianFlu has joined the channel [22:35] tlynn_: if nothing receives a data event on an incoming net socket, is the data lost or does it stay buffered? [22:36] chjj: tlynn_: node doesnt buffer data events, so it will be lost [22:36] chjj: which is a good thing ^ [22:37] tlynn_: that's what I thought. so every node user has to write a socket abstraction over the top? if so, where's the off-the-shelf library for that? [22:37] chjj: tlynn_: what do you mean? [22:37] smathy has joined the channel [22:37] ajpiano has joined the channel [22:38] chjj: tlynn_: what are you doing that you would need a lib for? [22:38] tlynn_: since incoming messages may not align to application frame boundaries, you need to add a buffering layer [22:39] chjj: tlynn_: well the idea in node, generally, is to stream things, so if you want to parse incoming data from a socket, you write a streaming parser [22:39] chjj: depends on the data youre faced with [22:39] skm has joined the channel [22:39] TRUPPP: hi, little question: do i have to install express seperately on windows or is it already integrated in node.exe? thanks [22:39] schwab has joined the channel [22:40] chjj: or you can go the easy route, and buffer everything, then parse it, but theres downsides to that [22:40] mbrevoort has joined the channel [22:40] chjj: TRUPPP: you have to install it separately, its not part of node [22:41] TRUPPP: okay thx =) [22:41] micheil: chance-: someone needs to write a totally non-biased response to that, I think. reading it through, there's a bit of an obvious bias that he doesn't like javascript [22:41] micheil: and also a pretty big bias towards the threads and against evented [22:43] chjj: i have a bias against githubs design changes [22:43] chance-: micheil : yea, and against javascript [22:43] chjj: and then i get used to them [22:44] chance-: ugh, underline in red? [22:44] chance-: bah [22:44] chjj: yeah, seems out of place doesnt it? [22:44] micheil: it makes me wonder about people writing these types of articles, from both sides of the fence. [22:45] micheil: each sees the problem different with a bias towards their particular side. [22:45] Raul_: Leaving the bias apart, do you guys think that the post deserves attention? [22:45] chjj: micheil: thats almost meaningless to say [22:46] chjj: micheil: everyone is always going to see things from their point of view [22:46] chance-: micheil : well, i havent used node long enough to be biased toward it. my problem is his approach to the question and his presumption to know the answer [22:46] chjj: micheil: and everyone has biases, whatever they are [22:46] micheil: chjj: not really. It's wrong to try and say something is totally wrong if you've only done something one way. [22:47] chjj: micheil: im referring to you saying "each sees the problem with a bias..." [22:47] micheil: yes [22:48] chjj: ok, making sure [22:48] micheil: however, the article should be an exposition / discussion, and have one person doing it in the threaded manner, and one doing it in the evented manner [22:48] micheil: like a proper debate [22:48] MooGoo: lol whatever [22:48] chjj: proper/formal debates are horrible [22:48] chjj: terrible terrible things [22:48] MooGoo: that post did exactly what its author intended it to [22:48] micheil: chjj: not really. [22:48] MooGoo: get a lot of attention [22:49] micheil: yeah. [22:49] Raul_: @MooGoo: He has a knack of doing that [22:49] chjj: micheil: yes really, i watch far too many of them, the only thing worth while is if the audience gets to ask the debaters questions [22:49] MooGoo: and if he was all cordial about it, no one would have noticed [22:49] micheil: but honestly, if someone is going to write something like that, then please get a person from each respective side of the fence to look at it first [22:50] chjj: micheil: everything else is just at least one of the debaters trying to sabotage the other, because he can, because its a formal debate and its structured horribly [22:50] mike5w3c_ has joined the channel [22:50] MooGoo: people cant have their opinions anymore [22:50] micheil: chjj: read: exposition then [22:50] MooGoo: without qualifying them as fair and balanced [22:51] wilmoore has joined the channel [22:51] harthur has joined the channel [22:51] slifty has joined the channel [22:51] SubStack: http://substack.net/images/github_request.png [22:51] TRUPPP: if i downloaded express.zip, do i just have to extract it to the modules folder of node? (speaking of node.exe and windows) thanks! [22:51] russfrank: um [22:52] mikeal has joined the channel [22:52] chance-: TRUPP : I haven't tried windows node dev, but I would imagine so [22:53] chjj: TRUPPP: youll need the dependencies too, put everything in a node_modules directory higher up in the directory structure [22:53] russfrank: this guy ted dziuba.. seems to think that his point is revolutionary and nobody has thought of it or something [22:53] chjj: i think it should work the same on windows ? [22:53] chance-: chjj : ahha, good point [22:53] chance-: chjj, that'd be my guess as well.. from there he *should* be able to execute the express cmd.. or at least I would hope [22:53] devuo has joined the channel [22:53] chance-: not sure if they work on windows [22:54] TRUPPP: i read it should work [22:54] chjj: yeah, i have yet to try node on windows [22:54] TRUPPP: i try it =) [22:54] TRUPPP: thank you [22:54] chjj: sure [22:54] CoverSlide: SubStack: #github [22:55] tlynn_: does node promise that multiple listeners for an event will be notified in registration order? [22:56] CoverSlide: well anyone can modify the event array [22:56] KaL has joined the channel [22:56] chance- has left the channel [22:57] tlynn_: does that mean "read the source of events.js"? [22:58] SubStack: CoverSlide: aha excellent [22:58] wankdanker: tlynn_: https://github.com/joyent/node/blob/master/lib/events.js [22:58] tlynn_: thanks [22:59] [[zz]] has joined the channel [23:01] thisandagain has joined the channel [23:01] shanebo: hey guys I need to tweak something in a connect middleware, do I need to branch the whole framework for that? [23:01] wankdanker: tlynn_: looks like so. if there is more than one listener, they are pushed on to an array... [23:01] tjholowaychuk: shanebo what do you need? [23:01] wankdanker: shanebo: from my experience with that, i would just copy the middleware and make it part of your own project, unless you care about getting future updates... [23:02] shanebo: tjholowaychuk I'd like to tweak the vhost middleware to accept an array [23:02] tjholowaychuk: ah [23:02] shanebo: as hostname [23:02] shanebo: that way I only have one server for many hostnames [23:03] shanebo: rather than a server for every hostname [23:03] balaa has joined the channel [23:03] tjholowaychuk: why not just loop through those hostnames [23:03] tjholowaychuk: and do [23:03] shanebo: (which often times in my case could mean 4-5 extra hostnames) [23:03] miccolis has joined the channel [23:03] tjholowaychuk: .use(vhost(hostname, app)) or whatever [23:03] tjholowaychuk: i did that for about 28 [23:03] tjholowaychuk: works just fine [23:04] shanebo: yeah I know it would work, but it's not as elegant as one server for many hostnames [23:05] nibblebo_ has joined the channel [23:05] tjholowaychuk: same thing [23:05] shanebo: tjholowaychuk if I make the change would you consider pulling it? [23:05] tjholowaychuk: look at the source it's maybe 10 lines [23:05] tjholowaychuk: you wont save much perf-wise [23:05] shanebo: yeah i did [23:06] shanebo: tjholowaychuk , so is that a no? :D [23:06] fbartho has joined the channel [23:08] davidbanham: Quick non-node Javascript question, I need to basically do a search and replace on the entire DOM in order to change a particular argument/flag on and anchor tags. Is there a good way to do this? [23:08] dynacker: QUICK HAMMER TIME [23:08] shanebo: tjholowaychuk all I planned on doing is checking if hostname is a string, if so push it to an empty array var and loop, if not leave alone... [23:09] wankdanker: davidbanham: #jquery [23:10] CrabDude has joined the channel [23:12] CIA-48: node: 03Ryan Dahl 07 * r651b8a0 10/ (lib/child_process.js test/pummel/test-exec.js): Fix test/pummel/test-exec.js - http://git.io/__2cIw [23:16] cjm has joined the channel [23:18] AvianFlu has joined the channel [23:18] gr-eg has joined the channel [23:20] CIA-48: node: 03Ryan Dahl 07 * r7b4370e 10/ (lib/fs.js test/pummel/test-watch-file.js): Fix test/pummel/test-watch-file.js - http://git.io/U4gWRg [23:21] wereHamster: what's the best way to test whether a function has been called or not. I can stub the function and put asserts in it, but if the function is never called the asserts have never chance to check what they are supposed to check [23:21] stevej has joined the channel [23:22] stevej has left the channel [23:22] syrio has joined the channel [23:24] lukstr: anyone here live/work in cupertino? [23:28] marcello3d has joined the channel [23:28] aho has joined the channel [23:30] stagas has joined the channel [23:33] balaa_ has joined the channel [23:36] k1ttty has joined the channel [23:36] fread2281 has joined the channel [23:39] guidocalvano has joined the channel [23:39] shesek has joined the channel [23:40] shesek: Anyone uses node-inspector and has console.log() working? [23:42] OneOfOne has joined the channel [23:42] micheil_mbp has joined the channel [23:43] micheil_mbp_ has joined the channel [23:44] enki: hey [23:44] OneOfOne: hey [23:44] enki: i am doing a for (var i = 6500000; i > 0; i--) { console.log(i) } loop [23:44] AphelionZ has joined the channel [23:44] enki: and it just stops halfway in [23:44] enki: well less than halfway [23:44] dynacker has joined the channel [23:45] enki: specifically: for (var i = 6008514751; i > 0; i--) { console.log(i); } [23:45] enki: no other code involved - can anyone reproduce? [23:48] CrabDude: wereHamster: what about setting a value in the function and asserting at the end of your test that value? [23:48] CrabDude: lukstr: mountain view…? [23:48] CrabDude: shesek: yes, node inspector works with console, what's up? [23:48] dilvie: enki: yes. [23:48] wereHamster: CrabDude: that's gets ugly in the long run. I was hoping for something more elegant [23:48] enki: dilvie: what's up with that? [23:49] shesek: CrabDude, I dunno, its weird, console.log() seems to go nowhere [23:49] smus has joined the channel [23:49] enki: is this a known issue or is node really just dying if you use console.log in a loop? :/ [23:49] dilvie: enki: I have no idea. I don't know how the node console works under the hood, but perhaps it's a buffer overflow? [23:49] shesek: Both from code and from the console itself, it just doesn't show up [23:49] tim_smart: Man I wish V8 had something like this (that isn't a node module - they have too much overhead) http://luajit.org/ext_ffi_api.html [23:50] enki: dilvie: ugh [23:50] AvianFlu: enki: your process is exiting before the output buffer is drained [23:50] enki: AvianFlu: nope, process still runs [23:50] Metal3d has joined the channel [23:50] enki: just hangs in there [23:51] enki: it's not even remotely close to being done - it dies 2 seconds in [23:51] Wa has joined the channel [23:51] CrabDude: tim_smart: you could always try creationix's new luv-it (node in lua) [23:51] CrabDude: ;P [23:51] tim_smart: CrabDude: Yeah it is great [23:51] AvianFlu: I'm gonna play with this enki, I'm sure it's something simple [23:52] tim_smart: CrabDude: Well not node in lua, but uv in lua [23:52] JSManiacs has joined the channel [23:52] tim_smart: But Tim Caswell likes the node api, so has followed it quite closest [23:53] tim_smart: *closely [23:53] CrabDude: shesek: It's probably going out to the terminal, not chrome [23:53] shesek: Nope, it doesn't go there either [23:53] rchavik has joined the channel [23:53] AvianFlu: enki: interesting! I see what you mean now, I didn't realize at first that you were counting *down* [23:53] CrabDude: shesek: odd. are you "broken"? [23:53] ben_alman has joined the channel [23:54] CrabDude: err… "braked"... [23:54] shesek: "broken"? [23:54] CrabDude: breakpoint [23:54] AvianFlu: enki: did you pinpoint a specific integer where it starts to do that? [23:54] shesek: hmm, yes [23:54] CrabDude: console.log in chrome console or in code [23:54] enki: AvianFlu: nope, i honestly just started writing 2 lines of code [23:55] enki: when i ran into this [23:55] shesek: I tried both, currently from the console while "braked"/"broken", but also from the code itself [23:55] CrabDude: if you hit play, do they show up? [23:55] shesek: nope, it doesn't [23:55] enki: must be some IO buffering problem [23:55] AvianFlu: enki: I'm suspicious of it being a large-int-in-js problem, I'm gonna mess around with it [23:56] AvianFlu: could be that too, though, for sure [23:56] AvianFlu: cause 6 billion isn't that big [23:56] Brandon_R has joined the channel [23:56] Brandon_R: Hey guys [23:57] enki: AvianFlu: it gets stuck even at a few hundred thousand, but it catches up after a while [23:57] shesek: CrabDude, require('util').log doesn't show up anywhere either. currently I have an `log = (d) -> process.stderr.write d+"\n"` function to debug stuff, but its hardly as useful as console.log :-( [23:57] enki: and then it counts fluidly [23:57] Brandon_R_ has joined the channel [23:57] AvianFlu: wait, it hangs and then gets back to it? [23:57] enki: AvianFlu: yeah, for low numbers [23:57] enki: for large numbers e.g. the buffer keeps getting filled for a long time [23:57] enki: it stays stuck [23:57] enki: i think it just doesn't properly keep track of when to flush [23:57] Brandon_R_ has joined the channel [23:57] Brandon_R_: Hey [23:58] enki: (that's my guess from the behavior, haven't looked at any node source) [23:58] Brandon_R: what you guys up to [23:58] CrabDude: shesek: odd. no idea. try coming up with the simplest example to reproduce it. [23:58] Brandon_R: Did you guys know what require is blocking? [23:58] Brandon_R: i thought node.js was fully non blocking [23:58] enki: also it gets stuck right in the middle of numbers, e.g. not at line boundaries [23:59] dynacker has joined the channel [23:59] AvianFlu: enki: it might not be "staying stuck", it might just be stuck for longer than we've bothered waiting :) [23:59] shesek: CrabDude, are you related to node-inspector's development? [23:59] CIA-48: node: 03Ryan Dahl 07 * re911171 10/ (4 files in 2 dirs): Move some slow tests to pummel - http://git.io/GIN2qA [23:59] CrabDude: shesek: nope. just a fan. [23:59] Brandon_R: Who is cia 48? [23:59] OneOfOne: Brandon_R: an agent of the american government