[00:00] jasonkuhrt: has anyone successfully done this? [00:00] RobWC has joined the channel [00:00] RobWC has joined the channel [00:02] ryanrolds_w: josephmoniz: Um, phantomjs is headless? It's complaining about not having having X going on this server. Lame. [00:03] perezd: github/open source users, can you take a moment to answer a 4 question survey for me?: http://bit.ly/xEi6mB thanks! [00:06] langworthy has joined the channel [00:06] brngardner has joined the channel [00:06] gut4 has joined the channel [00:09] colinclark has joined the channel [00:10] satyr has joined the channel [00:11] pacosoul has joined the channel [00:11] pacosoul has left the channel [00:11] [[zz]] has joined the channel [00:12] akihito_s has joined the channel [00:13] brngardner has joined the channel [00:13] richardr_ has joined the channel [00:15] cody-- has joined the channel [00:15] silky has joined the channel [00:15] baudehlo has joined the channel [00:17] htoothrot has joined the channel [00:17] alvaro_o has joined the channel [00:18] norviller has joined the channel [00:19] kevinohara80 has joined the channel [00:19] carlyle has joined the channel [00:20] Shaunzie has joined the channel [00:21] EyePulp has joined the channel [00:21] takumination has joined the channel [00:21] mikl has joined the channel [00:23] kevinswiber has joined the channel [00:24] silky has joined the channel [00:24] markq: is there a mongoose channel by any chance? [00:24] Shaunzie: donna but try it #mongoose [00:24] markq: I tried that. Didn't work :/ [00:25] DarkGrey has joined the channel [00:25] Shaunzie: did you google? [00:26] markq: strange though. only 3 people there [00:26] zpao has joined the channel [00:28] Provito has joined the channel [00:30] Dreamer3 has joined the channel [00:31] slloyd_air has joined the channel [00:31] RobWC1 has joined the channel [00:31] tim_smart: markq: I'm sure mongoose questions in this channel won't get complaints [00:32] deedubs has joined the channel [00:33] jacobolus has joined the channel [00:33] jacobolu_ has joined the channel [00:34] blup has joined the channel [00:35] jbpros has joined the channel [00:36] mikeal has joined the channel [00:36] mikl has joined the channel [00:37] markq: okay so I have a blog that has user accounts and on the user's "home" page I want there to be a feed of incoming blog post titles. how can I do this with mongoose/express? [00:37] k1ttty has joined the channel [00:37] markq: kind of like a facebook updates the user's wall [00:37] markq: but on a smaller scale of course [00:37] Shaunzie: blog.find? O.o [00:38] markq: but how do I update it automatically [00:38] markq: like comet but without having a constantly open connect [00:38] Shaunzie: socket.io? [00:39] jacobolus has joined the channel [00:39] markq: so whenever mongodb updates I want it to ajax the blog title to the user's feed [00:39] alvaro_o has joined the channel [00:39] jacobolu_ has joined the channel [00:39] markq: how can I connect socket.io with mongodb or mongoose though? [00:39] Shaunzie: enqueue node.js? [00:40] Shaunzie: take a look at the documentation for socket.io [00:40] Shaunzie: http://http://socket.io/ [00:40] skm has joined the channel [00:40] Shaunzie: fail… http://socket.io/ [00:41] nerdfiles1 has joined the channel [00:41] nerdfiles1 has left the channel [00:41] kickingvegas has joined the channel [00:41] Shaunzie: better…. so yah on the front page of the website it provides an example of how to use socket.io. You would need to create your own events to be emitted when new data returned from mongoose [00:42] markq: that makes sense [00:42] markq: socket.io is pretty powerful it seems [00:42] Shaunzie: it's sexy shite [00:43] neoesque has joined the channel [00:43] markq: holy crap it's cross-browser :O [00:43] Shaunzie: :p [00:43] Shaunzie: as I said sexy shite :D [00:43] jacobolus has joined the channel [00:43] markq: totally :D [00:43] unomi has joined the channel [00:45] mnutt has joined the channel [00:47] EriksLV has joined the channel [00:47] mandric has joined the channel [00:47] perezd: dscape: yo [00:48] perezd: I don't understand the patch [00:48] jocafa has joined the channel [00:49] kickingvegas has joined the channel [00:51] Treffynnon has joined the channel [00:51] MarkMenard has joined the channel [00:53] HardPhuck has joined the channel [00:53] mikl has joined the channel [00:53] nrajlich has joined the channel [00:54] te-brian has joined the channel [00:54] cognominal has joined the channel [00:54] sindresorhu has joined the channel [00:54] dgathright_ has joined the channel [00:56] maxogden_ has joined the channel [00:56] tellnes_ has joined the channel [00:56] zpao_ has joined the channel [00:56] unmatrix has joined the channel [00:56] ollie_ has joined the channel [00:57] shykest has joined the channel [00:57] tilgovi has joined the channel [00:57] Jalava_ has joined the channel [00:57] pig_ has joined the channel [00:57] davv3_ has joined the channel [00:57] flojistik has joined the channel [00:58] Connorhd_ has joined the channel [00:58] jmmills_ has joined the channel [00:58] cjno_ has joined the channel [00:58] jesusabd1llah has joined the channel [00:58] Lorentz_ has joined the channel [00:58] Sembianc1 has joined the channel [00:58] juske____ has joined the channel [00:58] pekim_ has joined the channel [00:58] ranza has joined the channel [00:58] chilts_ has joined the channel [00:58] kyle___ has joined the channel [00:58] yenz has joined the channel [00:58] ryah_ has joined the channel [00:58] inarru_ has joined the channel [00:58] rektide_ has joined the channel [00:58] spleeze has joined the channel [00:58] Andeye_ has joined the channel [00:59] tobmastr has joined the channel [00:59] jacobolus has joined the channel [00:59] Cromulent has joined the channel [00:59] panterax has joined the channel [01:01] zigidias_ has joined the channel [01:01] Gregor` has joined the channel [01:01] halfhalo_ has joined the channel [01:01] jxie has joined the channel [01:02] al3xnull has joined the channel [01:02] franciscallo has joined the channel [01:03] mateodelnorte has joined the channel [01:03] zigidias has joined the channel [01:04] callumacrae_ has joined the channel [01:04] k1ttty has joined the channel [01:04] dtrejo: isaacs: lol thanks for the +authors add, that one bracket was pretty crucial lol [01:05] Poetro has joined the channel [01:05] isaacs: dude, super critical [01:05] jklabo: can you use isArray in node? [01:05] llrcombs has joined the channel [01:05] dtrejo: jklabo: ype [01:05] jklabo: how do I access it? [01:06] isaacs: jklabo: if (Array.isArray(thisisanarraymaybe)) { doSomething() } [01:06] jklabo: ah yeah, sweet. thanks [01:06] utunga has joined the channel [01:06] langworthy has joined the channel [01:08] Venom_X has joined the channel [01:09] agnat_ has joined the channel [01:09] unomi has joined the channel [01:10] utunga: hey all.. hope you dont mind me asking a qusestion about node.js bot writing? [01:10] Guest18468 has joined the channel [01:10] utunga: ... y'see someone has challenged me to write a bot using daniel rapps awesome node.js thing for detecting "that's what she said".. https://github.com/DanielRapp [01:10] `10 has joined the channel [01:10] utunga: .. specifically a yammer bot.. [01:10] catb0t: Exception: SyntaxError: Unexpected identifier [01:10] cmr: Heh [01:10] Wa has joined the channel [01:10] utunga: so anyway.. i figure grab the node-yammer bindings from here https://github.com/mikeal/node-yammer/ combine with code for a node irc 'bot' maybe this one https://github.com/nodejitsu/kohai or this one https://github.com/gf3/protobot and stir vigorously any suggestions / recommendations before i get started? [01:10] cmr: .. print("Die, catb0t") [01:10] catb0t: "Die, catb0t" [01:11] utunga: .. any suggestions or recommendations (i admit im a node.js total beginner though i guess im a programmer of sorts) [01:11] catb0t: Exception: SyntaxError: Unexpected identifier [01:11] utunga: can someone just kick catb0t ? [01:11] catb0t: someone at door 8000 from outside, and tells them to check into room just [01:12] teadict: [express] how the heck can I send the req.session object to layout.jade? ^.- [01:12] utunga: OK tl;dr : node.js, yammer, bot - any recommendations? [01:12] tdubellz has joined the channel [01:16] isaacs: utunga: don't start messages with .. and catbot will leave you alone [01:16] isaacs: utunga: it's very handy in this room to be able to give js examples, since the subject comes up a lot. [01:17] isaacs: utunga: i use the irc-js for ircretary [01:17] isaacs: ircretary: hello [01:17] ircretary: isaacs: Hello :) [01:17] warz has joined the channel [01:17] warz has joined the channel [01:17] isaacs: ircretary: inst utunga [01:17] ircretary: utunga: `curl http://npmjs.org/install.sh | sh` (or, if there are permission issues, you can try: `curl http://npmjs.org/install.sh | sudo sh`) [01:17] dodo: .. process.exit() [01:17] catb0t: Exception: ReferenceError: process is not defined [01:17] jakehow has joined the channel [01:17] isaacs: .. Object.getOwnPropertyNames(global) [01:17] catb0t: Exception: ReferenceError: global is not defined [01:18] isaacs: .. Object.getOwnPropertyNames((function () { return this })()) [01:18] catb0t: [ "TypeError", "decodeURI", "print", "parseFloat", "Number", "URIError", "emit", "encodeURIComponent", "RangeError", "ReferenceError", "RegExp", "Array", "isNaN", "Date", "Infinity", "emitter", "Boole... [01:18] isaacs: .. emit.toString() [01:18] catb0t: "function () { [native code] }" [01:18] isaacs: .. emit("hello") [01:18] catb0t: "hello"{ emit:[Function] } [01:18] isaacs: thats... weird [01:18] nrajlich: lol, the global is an eventemitter? [01:18] Druide_ has joined the channel [01:18] isaacs: .. emitter() [01:18] catb0t: Exception: TypeError: Property 'emitter' of object [object Object] is not a function [01:18] isaacs: .. emitter [01:18] catb0t: { emit:[Function] } [01:18] isaacs: nrajlich: i dunno [01:19] isaacs: i mean, not normally [01:19] utunga: @isaacs thanks - helpful [01:19] TooTallNate: isaacs: i know that :p [01:20] dtrejo: why are github notifications so annoying? because they send me an email AND make me click around in their UI to mark all as read [01:20] dtrejo: #firstworldreallyannoyingproblems [01:20] enmand has joined the channel [01:20] TooTallNate: dtrejo: i ignore the notifications on GH [01:21] TooTallNate: mine's up at like 2000 somewhere lol [01:21] TooTallNate: i want to get some CSS to hide it completely [01:21] dtrejo: also, the "we just built your page for you" greattttt [01:21] dtrejo: good idea [01:21] TooTallNate: ya i hate that [01:21] TooTallNate: you could send those into a filter though [01:21] TooTallNate: ACTION assumes everyone uses gmail :p [01:21] franciscallo has joined the channel [01:21] kickingvegas has joined the channel [01:22] utunga: @isaacs i like your README for ircecretary ;-) [01:22] briandh has joined the channel [01:23] shedinja has joined the channel [01:23] descipher has joined the channel [01:23] dthompso99 has joined the channel [01:23] halfhalo_ has joined the channel [01:23] dthompso99 has joined the channel [01:24] dthompso99 has left the channel [01:24] Cromulent has joined the channel [01:24] jarek has joined the channel [01:25] azeroth_ has joined the channel [01:26] dtrejo: oh, it doesn't email me for that, it just adds a gh notification on their site [01:26] nerdfiles has joined the channel [01:28] isaacs: utunga: thanks [01:28] heavysixer has joined the channel [01:28] ircretary has joined the channel [01:29] marcello4d has joined the channel [01:30] CarlosC has joined the channel [01:30] sarlalian has left the channel [01:31] sorensen__ has joined the channel [01:35] subbyyy has joined the channel [01:36] ht has joined the channel [01:36] ht: Hi folks, Im looking for something with the similar functionality to WWW-Mechanize for perl? Is there anything out there besides Zombie.js? ty in advance [01:37] abraxas has joined the channel [01:37] briancray has joined the channel [01:38] vicapow has joined the channel [01:39] brngardner has joined the channel [01:41] icewhite has joined the channel [01:41] Shaunzie: what are you trying to do? [01:41] Shaunzie: no idea what www-Mechanize does >.> [01:42] Emmanuel` has joined the channel [01:42] markschaake has joined the channel [01:42] markschaake has left the channel [01:44] loucal_ has joined the channel [01:44] nerdfiles has left the channel [01:44] bitwalker has joined the channel [01:45] sdwrage has joined the channel [01:45] TN has joined the channel [01:46] sylvinus has joined the channel [01:47] Provito has joined the channel [01:48] Emmanuel has joined the channel [01:50] samstefan has joined the channel [01:50] ger^kallisti_ has joined the channel [01:52] carlyle has joined the channel [01:53] skm has joined the channel [01:53] JackNorris has joined the channel [01:54] thalll has joined the channel [01:54] couchquid has joined the channel [01:56] tilgovi has joined the channel [01:56] nerdfiles has joined the channel [01:57] yozgrahame has joined the channel [01:59] amasad has joined the channel [02:03] BillyBreen1 has joined the channel [02:03] bradleymeck has joined the channel [02:04] tkro has joined the channel [02:04] avi_flax has joined the channel [02:04] r04r has joined the channel [02:04] r04r has joined the channel [02:05] stagas has joined the channel [02:05] case_ has joined the channel [02:06] astropirate has joined the channel [02:07] neurodrone has joined the channel [02:08] zitchdog has joined the channel [02:08] r04r has joined the channel [02:08] r04r has joined the channel [02:09] tomlion has joined the channel [02:09] jarek_ has joined the channel [02:10] CrypticSwarm has joined the channel [02:12] jasonkuhrt has joined the channel [02:12] shinuza has joined the channel [02:13] ryanfitz has joined the channel [02:13] pt_tr has joined the channel [02:13] r04r has joined the channel [02:14] ZohoGorganzola has joined the channel [02:14] Shaunzie: ZOMG!!!!! WTF WAS I !!!! O.o…. I didn't know scripting was being added to redis D: [02:14] Shaunzie: F*** ME HARD AND OFTEN! BADDA$$!!!! [02:15] dwhittle has joined the channel [02:16] shinuza has joined the channel [02:16] cmr: Shaunzie: in what form? [02:16] overthemike has joined the channel [02:16] Shaunzie: lua [02:16] Shaunzie: http://antirez.com/post/scripting-branch-released.html [02:16] overthemike has left the channel [02:17] SirFunk: does node have a way to merge to arrays of hashes? [02:17] SirFunk: such as options arrays [02:17] Shaunzie: SirFunk: nothing native. but you can do it with as simple loop [02:18] SirFunk: Shaunzie: okie dokie [02:18] jakehow has joined the channel [02:18] r04r has joined the channel [02:18] r04r has joined the channel [02:19] tkaemming has joined the channel [02:22] innoying: Is there a way to do fs.watchfile on a file that doesn't exist yet? [02:22] a_suenami has joined the channel [02:22] nerdfiles1 has joined the channel [02:23] cmr: innoying: no [02:23] sechrist: hmm I wonder if having an LUA webserver running inside of redis is useful [02:23] cmr: innoying: You want to know when it is created? [02:23] mikeal has joined the channel [02:23] innoying: cmr: Yes. Then also when it's changed after that [02:23] r04r has joined the channel [02:23] cjm has joined the channel [02:24] Cromulent has joined the channel [02:24] sechrist: So how do people usually create javascript OO type classes that need an underlying dataset that (in node) has to be loaded async? [02:25] zivester has joined the channel [02:25] ZohoGorganzola: has anyone else had a lot of trouble installing anything with npm on ubuntu? [02:25] sechrist: put a callback in the constructor? or a function inside called load etc [02:25] rwaldron has joined the channel [02:26] ZohoGorganzola: i keep getting errors that it can't find certain files, but i can see those files, and then it throws even more errors when i try to resolve it's dependencies [02:26] JasonSmith: isaacs: tap question? "The plan cannot appear in the middle of the output, nor can it appear more than once." http://testanything.org/wiki/index.php/TAP_specification#The_plan [02:26] nerdfiles1 has left the channel [02:26] JasonSmith: I've been planning willy-nilly without too many problems. What gives? [02:26] isaacs: JasonSmith: node-tap i think does the right thing [02:27] isaacs: JasonSmith: it doesn't output a plan line in the middle of tests. [02:27] JasonSmith: I got the impression that you may only plan() once per *file* [02:27] meso has joined the channel [02:27] isaacs: JasonSmith: node-tap lets you call .plan() on any test anywhere. nested tests can also have plans. [02:27] isaacs: this is fine: [02:28] isaacs: tap.plan(1); tap.test("parent", function (t) { t.plan(2); t.pass("ok"); t.test("child", function (t) { t.plan(1); t.pass("kid's alright.") }) }) [02:28] JasonSmith: right, that's what I do. But that's my point. Isn't that nonstandard because you are outputing multiple 1..N lines per test file? [02:28] isaacs: a t.test() is treated as one "thing" for the purpose of the plan [02:28] isaacs: no, i still only output a single 1..N at the top level. [02:29] r04r has joined the channel [02:29] isaacs: i just juggle it all internally [02:29] tilgovi has joined the channel [02:29] isaacs: and adjust the numbers as needed. [02:29] JasonSmith: isaacs: Awesome, love it. I am acutally using node-tap's runner to run the couch tests these days [02:29] isaacs: so, in that result, the actual tap output will be 1..2 [02:29] JasonSmith: right [02:29] isaacs: oh, nice [02:30] isaacs: JasonSmith: if you throw a text stream at TapConsumer, and it does 1..N more than once, then it'll bark at you. [02:30] JasonSmith: I am also literally using node-tap's runner [02:30] isaacs: (well, it'll emit a failing test for that) [02:30] JasonSmith: right [02:30] isaacs: or if you do a plan in the middle of tests [02:31] isaacs: but other than that, and a few other little things, it's remarkably forgiving. [02:31] cmr: isaacs: Do you have any comments about my most recent commits in the pull request for checking executability of a script before running it? [02:31] isaacs: you can emit no tests or tap output, and just exit 0, and it'll call that a success [02:31] isaacs: cmr: didn't get to that yet. [02:31] JasonSmith: isaacs: yeah that's what it does on my harness files :) [02:31] cmr: a'ight [02:31] mrflick has left the channel [02:31] postwait has joined the channel [02:32] isaacs: cmr: had to get npm 1.1.0 ready, and some node-core things [02:32] JasonSmith: If only there was a way where it would check executability of a "script" before running it [02:32] isaacs: 0.6.8 lands as soon as we get the numeric key hash thingie in v8 3.6 [02:32] isaacs: JasonSmith: i detect a facetious air. [02:32] cmr: JasonSmith: master on https://github.com/cmr/node-tap is stable [02:32] isaacs: cmr did something like that for the tap runner [02:32] RobWC has joined the channel [02:33] JasonSmith: cmr: I typically never run code from GitHub (except my own). If I can't `npm install` it, I'm not interested [02:33] isaacs: cmr: ok, just read the code. [02:33] brngardner has joined the channel [02:33] cmr: I also considered adding a test for existence of shebangs. [02:33] isaacs: cmr: that's not correct. [02:33] isaacs: cmr: it has to be one big conditional. [02:33] isaacs: cmr: because, 0650 is a valid mode. [02:34] isaacs: ie, not user executable, but it is group-executable. [02:34] jacobolus has joined the channel [02:34] isaacs: if you're the owner, you can't execute it, but if you are in the group, well, then you CAN execute it. [02:34] isaacs: your code will abort there. [02:34] JasonSmith: I just want .tapignore [02:34] cmr: Or just not using else-if [02:34] JasonSmith: or tap --ignore [02:35] isaacs: cmr: also, if it masks against 0100, and you don't have process.getuid, then assume that it is executable. [02:35] isaacs: (ie, windows) [02:36] cmr: isaacs: Alright, I'll refactor that. [02:36] cmr: Thanks for the feedback, much appreciated. [02:36] [[zz]] has joined the channel [02:36] cmr: isaacs: how do you propose I add tests for that? [02:36] isaacs: if (( (mode & 0100) && process.getuid && uid === process.getuid()) || ((mode & 0010) && process.getgid && process.getgid() === gid) || ... [02:37] isaacs: cmr: meh. [02:37] isaacs: i dunno. [02:37] isaacs: i guess just put a non-executable file in the tests/ folder? [02:37] isaacs: that doesn't end in .js [02:37] cmr: Well I've already done that, but that doesn't test the permissions very well. [02:37] langworthy has joined the channel [02:38] isaacs: echo "if this tries to run, its a failure" > test/do-not-run; chmod 0644 test/do-not-run [02:38] isaacs: yeah, it's just a negative test. [02:38] Sir_Rai: Hi guys, im a bit confuse about the managing modules with npm,it is supossed to be installed all of them globally or locally for each project? [02:38] isaacs: but i mean, that's the bad behavior you're preventing. [02:38] isaacs: that's the bug you're fixing. [02:38] cmr: Yeah, true enough [02:38] isaacs: Sir_Rai: locally for require() stuff. [02:38] jetheredge has joined the channel [02:38] isaacs: Sir_Rai: globally only for command line apps. [02:38] Sir_Rai: alright [02:38] isaacs: Sir_Rai: (if you're not sure, do it locally in your program) [02:39] zitchdog has joined the channel [02:41] tdubellz has joined the channel [02:42] dscape: isaacs: https://github.com/joyent/node/commit/307f39ce9ed8f4d3de06f63cd1855157be2db82f#commitcomment-863310 [02:42] dscape: what do you think? [02:43] djbell has joined the channel [02:43] dscape: Actually had this problem with our production db today [02:43] dscape: hint we use a `?` in the password [02:43] dscape: lol [02:43] isaacs: dscape: i gotta run to dinner. you should be able to urlencode it [02:43] dscape: yes, but should I? or is it a bug? [02:43] isaacs: dscape: pull req with some failing tests added to test/simple/test-url.js [02:44] isaacs: dscape: dunno :) [02:44] dscape: that's the thing [02:44] dscape: too many RFCs [02:44] isaacs: ahaha [02:44] SirFunk: does npm only support git:// addresses for deps hosted on git? [02:44] dscape: there should be only one right? [02:44] dscape: if i knew what was the right behavior i would have sent a pull request with tests [02:45] davemo has joined the channel [02:45] gut4 has joined the channel [02:45] couchquid has joined the channel [02:45] JackNorris has joined the channel [02:45] isaacs: Sir_Rai: npm faq, search for "what is a package". tl;dr - Yes. [02:46] c4milo has joined the channel [02:48] ZohoGorganzola: after about an hour pulling my hair out and frantically googling, i just realize that you have to run npm install in the root of your home directory (~/) in order for it to work, everywhere else it throws errors about not being able to find package.json and then it can't resolve any dependencies when you actually run node [02:48] khrome has joined the channel [02:48] cmr: ZohoGorganzola: Huh? For what? [02:48] ZohoGorganzola: for anything to work [02:48] cmr: You should run npm install in the root of a project. [02:49] ZohoGorganzola: i tried that [02:49] cmr: Not your home directory. [02:49] ZohoGorganzola: and i kept getting errors [02:49] cmr: Then your node is broken. [02:49] cmr: ZohoGorganzola: paste up the errors you get as well as the ls of the directory you try. [02:50] Guest25532 has joined the channel [02:50] ZohoGorganzola: oh what the hell [02:50] ZohoGorganzola: i just tried running the command in my project folder so i could copy the error [02:50] ZohoGorganzola: and it worked fine [02:52] ZohoGorganzola: cmr: thanks for the offer to help, apparently that was enough to fix my problem [02:52] cmr: ZohoGorganzola: Hehe, funny how that works out, eh? [02:53] dephex has joined the channel [02:53] dwhittle has joined the channel [02:53] ZohoGorganzola: cmr: Yeah, it happens way too frequently! [02:54] RobWC has joined the channel [02:54] devongovett has joined the channel [03:00] stagas has joined the channel [03:04] sebastia_ has joined the channel [03:05] vicapow has joined the channel [03:05] stagas has joined the channel [03:07] subhaze has joined the channel [03:08] bradleymeck has joined the channel [03:09] te-brian has joined the channel [03:09] drudge has joined the channel [03:11] isufy has joined the channel [03:12] tomlion_ has joined the channel [03:12] pizthewiz has joined the channel [03:12] sgentle has joined the channel [03:13] dgathright has joined the channel [03:13] fbartho has joined the channel [03:16] yck has joined the channel [03:16] yck: node.js apps never crash meme http://www.quickmeme.com/meme/35pcga/ [03:17] cmr: yck: I LOL'd [03:18] teadict: why could I get a 302? [03:18] yck: cmr: :D [03:18] teadict: on a POST [03:18] dubenstein has joined the channel [03:21] tommyvyo has joined the channel [03:21] brngardner has joined the channel [03:22] blueadept has joined the channel [03:22] blueadept has joined the channel [03:23] dubenstein has joined the channel [03:23] dubenste1n has joined the channel [03:24] yck: anyone here uses hook.io ? [03:24] ryanrolds has joined the channel [03:27] EyePulp has joined the channel [03:27] subhaze has joined the channel [03:29] mattgifford has joined the channel [03:30] dubenstein has joined the channel [03:30] jesusabdullah: I have, why? [03:30] koo3 has joined the channel [03:30] stagas has joined the channel [03:34] yck: jesusabdullah: just wondering, does each hook generate a process? i.e. if I fires off each hook as separate service, does that mean I will end up with many processes? [03:34] sgentle has left the channel [03:35] stagas has joined the channel [03:35] nicholasf has joined the channel [03:36] dilvie has joined the channel [03:36] jesusabdullah: that's the idea [03:36] jesusabdullah: each "hook" you write is a process that connects to other processes [03:38] yck: jesusabdullah: won't that result in lots of CPU context switches? [03:39] yck: jesusabdullah: i guess it's possible to have the number of hook processes <= the number of cores [03:39] torm3nt has joined the channel [03:39] yck: jesusabdullah: do you tend to have multiple hooks on the same host? or do you separate them cross separate hosts? [03:39] mattgifford has joined the channel [03:40] lz has joined the channel [03:42] mattgifford has joined the channel [03:42] MrNko has joined the channel [03:45] jesusabdullah: multiple hooks on the same host [03:45] jesusabdullah: If they're all doing small jobs it's not too bad [03:45] jesusabdullah: if you write a hook.io-based "worker", ie you farm out an intensive process to it, then sure [03:46] jesusabdullah: but if you just want to do some things when some events happen? Why not fire them up on the same box [03:46] jesusabdullah: plus, autodiscover works on the same box, and mdns has been a recent addition [03:46] satyr has joined the channel [03:46] jarek has joined the channel [03:48] doitian has joined the channel [03:48] materialdesigner has joined the channel [03:49] yozgrahame1 has joined the channel [03:49] mattgifford has joined the channel [03:50] monteslu_ has joined the channel [03:52] nibblebot has joined the channel [03:55] sechrist_ has joined the channel [03:56] jacobolus has joined the channel [03:57] satyr has joined the channel [03:57] sarlalian has joined the channel [03:57] kenperkins has joined the channel [03:58] Vennril has joined the channel [03:59] githogori has joined the channel [04:00] joshfinnie has joined the channel [04:02] zivester has joined the channel [04:03] innoying: What's the best way to send messages between two node instances. I have a server that is always running, then I want it to run/notify a different app [04:03] unomi has joined the channel [04:03] jesusabdullah: There is no "best way" but look at dnode and hook.io [04:03] jesusabdullah: also, restful apis [04:04] dr0id has joined the channel [04:04] innoying: I know about dnode. But if they are both runnig on the same device as the same user? Still the best option? [04:04] jesusabdullah: sure, why not? [04:05] flipen has joined the channel [04:05] r04r has joined the channel [04:05] jesusabdullah: but like I said, there's no "best option" [04:05] stagas has joined the channel [04:07] jtsnow has joined the channel [04:07] socketio\test\19 has joined the channel [04:08] koo3 has joined the channel [04:08] sh1mmer has joined the channel [04:09] socketio\test\48 has joined the channel [04:10] r04r has joined the channel [04:13] mnutt has joined the channel [04:17] tkro has joined the channel [04:18] r04r has joined the channel [04:19] jarek has joined the channel [04:21] marcello4d has joined the channel [04:22] ovaillancourt has joined the channel [04:23] r04r has joined the channel [04:23] r04r has joined the channel [04:23] rwaldron has joined the channel [04:25] richardr_ has joined the channel [04:25] kriszyp has joined the channel [04:27] cainus: hey all... anyone know how to get the "hash" value off a url in express? eg. http://asdf.com?foo=1#this_value_here [04:27] r04r has joined the channel [04:27] mattgifford has joined the channel [04:27] cainus: short of string ops I mean [04:28] _unary has joined the channel [04:31] bradleymeck: cainus most brosers do not sent hash part of url [04:31] bradleymeck: browsers* [04:31] cainus: ahh okay that makes [04:31] cainus: sense [04:32] mattgifford has joined the channel [04:32] r04r has joined the channel [04:32] r04r has joined the channel [04:33] blueadept has joined the channel [04:33] bergie has joined the channel [04:34] jarek_ has joined the channel [04:35] sdwrage has joined the channel [04:35] chadskid_ has joined the channel [04:36] franciscallo has joined the channel [04:36] markq: hash tags are just anchors [04:37] r04r has joined the channel [04:39] nickdc has joined the channel [04:39] mmyjona has joined the channel [04:40] tshpaper has joined the channel [04:40] secoif has joined the channel [04:40] bradleymeck: anyone used node-tar to create a tarball? [04:41] cmr: Why would I do that instead of shelling out [04:41] bradleymeck: windows support [04:41] cmr: Sorry you need that :( [04:41] bradleymeck: starting to move towards ... :( [04:42] r04r has joined the channel [04:42] bradleymeck: its going to be hilarious when we hit the ssh part of the stack [04:42] cmr: Yech [04:42] cmr: Good luck [04:44] ryanfitz has joined the channel [04:45] brianc1 has joined the channel [04:48] CarterL has joined the channel [04:48] dtrejo has joined the channel [04:48] hij1nx has joined the channel [04:49] nickdc: So if I'm continuously sending data points (every second) to a node server using web sockets should I declare the connection once and reuse the var or create one each time [04:49] nickdc: I feel I'd only want to connect once [04:49] cmr: Reuse the socket, of course. [04:49] cainus: anyone happen to know a nice way to get the request body in express? I wrote a middleware to do it, but that seems more complicated than it should be... [04:49] nickdc: hence the reason for a socket right? :) [04:50] cainus: nickdc: might as well use http if you don't need to keep it open :) [04:50] Cromulent has joined the channel [04:50] markq: cainus: req.body [04:50] markq: and bodyParser [04:50] nickdc: one example confused me it was a socket wrapped in a http server [04:50] markq: what?!^ [04:51] markq: that's weird [04:51] nickdc: yea, it just seems pointless [04:51] markq: completely destroys the point of the socket [04:52] gavin_huang has joined the channel [04:53] dudeinthemirror has joined the channel [04:54] cainus: it's probably one app supporting 2 protocols [04:54] cainus: markq: thanks... that worked [04:54] richard__ has joined the channel [04:54] nickdc: I could have misunderstood how it was actually working yea [04:55] cainus: you can keep an http connection open for a long time too... ie long-polling [04:55] QiBala has joined the channel [04:55] satyr has joined the channel [04:56] QiBala has joined the channel [04:57] markq: I don't quite understand why services like no.de, nodester, nodejitsu are free of cost [04:58] markq: what do they gain by providing node deployment cloud servers? [04:58] markq: for free [04:58] cmr: Testers :) [04:58] chjj has joined the channel [04:58] markq: what do you mean? [04:58] cainus: marketing [04:59] cainus: ie freemium model [04:59] markq: they have a paid version too? [04:59] koo3 has joined the channel [04:59] markq: oh like an upgrade server type of thing [04:59] cainus: yeah... heroku does already... not sure about the others [04:59] BillyBreen has joined the channel [05:00] freakspire has joined the channel [05:00] markq: also, just to be sure, these services don't have like full and unrestricted access like a vps does right? [05:00] markq: ie rackspace [05:00] markq: it's restricted to node apps only via an api right [05:00] cmr: nodester doesn't [05:00] markq: what about no.de [05:01] cmr: I don't know about the others. [05:01] LeMike has joined the channel [05:01] sebastianedwards has joined the channel [05:02] cainus: pretty sure no.de is locked down [05:02] cainus: heroku is too [05:02] freakspire: whats up! [05:02] freakspire: any of u have tried ejs? [05:03] markq: jade ^ [05:03] blah has joined the channel [05:04] munichlinux has joined the channel [05:04] freakspire: but, well i read on internet that ejs compiles and executes faster than jade [05:04] BillyBreen has joined the channel [05:04] freakspire: i dont know which is more recomended, what do u suggest? [05:05] cmr: freakspire: use whichever you like best. [05:05] cmr: freakspire: And then if performance becomes an issue, look into it. [05:05] markq: agreed ^ [05:06] freakspire: thanks man [05:06] disappearedng has joined the channel [05:06] freakspire: so, this channel is for node support or anything else? [05:06] cmr: node and node-related. [05:06] cjm has joined the channel [05:09] secoif: freakspire if you're using jade on the server, #jade performance isn't an issue [05:09] devongovett has joined the channel [05:10] cmr: I haven't found a template system that I like. Jinja2 comes close. [05:11] disappearedng has joined the channel [05:11] r04r has joined the channel [05:11] jesusabdullah: plates is close for me [05:11] jesusabdullah: either something that's entirely html like that, or something that just doesn't give a fuck like ejs [05:12] yumike has joined the channel [05:12] cmr: I saw one once that I REALLY liked, but I've forgotten what it was. [05:12] cmr: It rendered json but it wasn't ejs and it wasn't PURE [05:12] warz has joined the channel [05:12] warz has joined the channel [05:13] bitwalker has joined the channel [05:14] secoif: cmr check out https://github.com/flatiron/plates [05:14] secoif: ? [05:15] secoif: oh [05:15] secoif: jesusabdullah beat me to it [05:15] cmr: secoif: Yeah, I'm already looking at it ;) [05:16] markq: very direct api [05:16] markq: could be useful [05:17] cmr: If this isn't it, it's very similar. [05:17] cmr: I like it. [05:17] jesusabdullah: Oh, dude, don't worry about perf at *all* [05:18] secoif: …on server side. [05:18] freakspire has joined the channel [05:18] jesusabdullah: usually [05:18] jesusabdullah: and to an extent on the client too [05:18] jesusabdullah: because basically there are three categories for perf that I've noticed [05:18] jesusabdullah: on the browser, mind you [05:18] Kunda has joined the channel [05:18] jesusabdullah: There's the group that's closely related to resig-style microtemplates [05:19] jesusabdullah: and those are the way fast ones [05:19] jesusabdullah: and, I mean, you might expect that [05:20] jesusabdullah: and then there's the "slow" ones that for whatever reason do something that javascript doesn't like. Maybe it has a lot of features, or maybe it uses the dom. [05:20] jesusabdullah: And then there's everything else and they're all chillin' together [05:20] mattgifford has joined the channel [05:20] jesusabdullah: They have a logarithmic distribution [05:20] jesusabdullah: if you put their hz in order [05:20] zivester has joined the channel [05:20] cmr: I think jade is one of the ugliest things since BASIC (CBMv2!) [05:21] jesusabdullah: fwiw, dom based methods are way slow on the client---slower than string manips [05:21] jesusabdullah: and on the server, well, you need to have a dom too and jsdom is not that fast [05:21] cmr: Why is the DOM so fast. Is it because it just is, or is it because the implementations suck? [05:21] cmr: s/fast/slow/ [05:22] jesusabdullah: It's because it just is [05:22] vicapow has joined the channel [05:22] jesusabdullah: but it's not even really "slow" [05:22] jesusabdullah: I mean people use jquery for that kinda stuff all the time [05:22] jesusabdullah: it's just more complex than s/{{thing}}/thing/ [05:22] jesusabdullah: plates, as it turns out, is middle-of-the-pack but still feels like it's dom-based like weld [05:28] cmr: map.where('class').is('link').use('name'); /* That's damn clever */ [05:29] jhooks_ has joined the channel [05:29] cmr: This isn't the template engine I was thinking of, but it's close enough. [05:31] khrome has joined the channel [05:34] zivester has joined the channel [05:34] gaspar09 has joined the channel [05:36] HT has joined the channel [05:36] zivester_ has joined the channel [05:39] nickdc: hah this is the coolest technology ever. since I can grab realtime datapoints from my app I have a new problem [05:40] bradleymeck: cmr the reason runs pretty deep on why it is slow, but the fact that is live node lists and attributes being nodes destroys speed [05:40] briandh has joined the channel [05:41] nickdc: Do I store all this data? I'm recieving like 30 graph points per second. Is it reasonable to store all that in a mongodb? [05:41] QiBala has joined the channel [05:41] overthemike has joined the channel [05:41] springmeyer_ has joined the channel [05:42] jesusabdullah: If you'd like [05:42] nickdc: I just don't know if it's scalable lol [05:42] jesusabdullah: it's brongodb bro [05:42] cmr: it's web scale! [05:42] zivester__ has joined the channel [05:43] jesusabdullah: loggly uses it and they store asstons of logs [05:43] cmr: No but seriously, profile it. [05:43] torvalamo: if you're worried about space you can store to /dev/null [05:43] nickdc: imagine only 1000 people sending lets say they send 2 datapoints per second. I've just stored 2000 records in one sec :) [05:43] captain_morgan has joined the channel [05:44] MUILTR has joined the channel [05:44] nickdc: I know it's possible I just have to engineer it right. I'm sorta stuck in the key / value db mindset [05:44] deoxxa: oh hey, just to backtrack for a minute re: template engines - https://github.com/deoxxa/node-ginger [05:44] deoxxa: that's my pet project at the moment, i only started it about a week ago, but it's already coming along pretty nicely [05:44] cmr: deoxxa: No readme? Really? [05:45] deoxxa: ah sorry, it's in the dev branch [05:45] cmr: Ah [05:45] deoxxa: https://github.com/deoxxa/node-ginger/tree/develop [05:46] c_t_montgomery has left the channel [05:46] deoxxa: it's a bit of an experiment right now, but i'd really appreciate input on what's good/bad about it [05:46] stationwu has joined the channel [05:47] geef_ has joined the channel [05:47] munro has joined the channel [05:47] stationwu: test [05:47] cmr: stationwu: hello [05:47] langworthy has joined the channel [05:47] RLa has joined the channel [05:48] zivester has joined the channel [05:48] yolin has joined the channel [05:49] niloy__ has joined the channel [05:50] niloy has joined the channel [05:50] caffine has joined the channel [05:52] nickdc: is it common to listen on port 80 if you have node on it's own server? If I were to do that maybe I could write docs for the api to the node server on http requests and still do the socket listening... [05:52] deoxxa: nickdc: i usually put nginx in front of node to handle things like SSL and static asset caching [05:52] hdms_ has joined the channel [05:53] nickdc: hmm ok [05:53] ryan_stevens has joined the channel [05:56] cognominal_ has joined the channel [05:56] JackNorris has joined the channel [05:56] couchquid has joined the channel [05:56] keviv has joined the channel [05:57] laczek has joined the channel [05:58] isaacs has joined the channel [05:59] isaacs: dscape: i think if you can figure out what kind of behavior you'd expect in your specific use case, then that's a place to start. [06:00] Guest74786 has joined the channel [06:01] Tiger_ has joined the channel [06:02] isaacs: chapel: that no-reply guy? seriously. [06:02] isaacs: chapel: i get email from him ALL THE TIME [06:02] chapel: wow [06:02] chapel: talk about late reply [06:02] chapel: 10+ hours [06:02] torvalamo: lol [06:02] isaacs: chapel: when people mention my name, i get notified the next time i sign on [06:02] chapel: oh [06:03] chapel: lol [06:03] isaacs: or mention "npm" [06:03] torvalamo: does the notification have a timestamp? [06:03] Tiger_: hello every one! [06:03] isaacs: yeah [06:03] isaacs: but it's async [06:03] isaacs: :) [06:03] torvalamo: :P [06:04] pquerna: npm npm npm [06:05] torvalamo: no problem mate [06:05] isaacs: pquerna: yes? [06:05] Yooman has joined the channel [06:05] meso has joined the channel [06:05] pquerna: so its just like saying bloddy mary [06:06] polotek has joined the channel [06:06] Tiger_: so cool! [06:06] isaacs: pquerna: yeah, except with slightly less blood. [06:06] isaacs: and way less mary. [06:06] torvalamo: what a buzz kill [06:07] polotek: isaacs: what's the correct way to specify engines in package.json [06:07] polotek: to include 0.4 and 0.6 [06:07] Tiger_: can i download the source code? [06:07] pquerna: TIL, full sail beer is good: -> http://www.fullsailbrewing.com/ [06:07] cmr: Tiger_: of what? [06:08] tekky has joined the channel [06:08] jesusabdullah: Yeah, full sail ain't bad [06:08] Tiger_: this site [06:08] cmr: What site. [06:08] cmr: This is IRC [06:08] jesusabdullah: It's one of those sort of no-longer-indie kinda things [06:08] pquerna: perhaps. [06:08] jesusabdullah: is why I think people rag on it [06:08] torvalamo: is it no longer hip to be indie? [06:08] jesusabdullah: like, if you're in PNW there are soo many undaground microbrews [06:09] pquerna: :-/ [06:09] jesusabdullah: Yeah, I don't care, I think it's a fine beer [06:09] jesusabdullah: but you know how beer people are [06:09] martin_sunset has joined the channel [06:09] torvalamo: drunk? [06:09] jesusabdullah: yes [06:09] pquerna: this is like my tweet this weekend, javascript is too popular, switching to lua, but aplied to beer [06:09] pquerna: some people thought i was serious [06:09] jesusabdullah: js is mainstream now [06:10] torvalamo: it's dash next? [06:10] torvalamo: whatever it is [06:10] jesusabdullah: naw dude, lua [06:10] pquerna: but the trick was, i actually was serious, https://github.com/luvit/luvit [06:10] pquerna: its a double mind trick :| [06:10] jesusabdullah: sure, sure [06:11] zivester has joined the channel [06:11] torvalamo: so you tricked both them AND yourself? [06:11] satyr has joined the channel [06:11] pquerna: lemme get another beer and i'll consider your proposal. [06:11] tkro has joined the channel [06:12] polotek: pquerna: lua needs classes [06:12] mattgifford has joined the channel [06:12] Tiger_: Sorry, Where Can I download the source code of this site? and i want to study Node.js [06:12] jesusabdullah: what site? [06:12] polotek: I'm actually surprised luvit hasn't gained a little following [06:12] isaacs: polotek: "engines": { "node": "0.4 || 0.6" } [06:13] isaacs: polotek: npm help semver <-- helpful stuff in there [06:13] pquerna: polotek: it has a tiny following, and on classes, luvit is kinda establishing a set of prototype-like classes / util.inherits [06:13] Tiger_: This website [06:13] jesusabdullah: http://love2d.org/ That plus luvit = ? [06:13] jesusabdullah: what website? [06:13] torvalamo: Tiger_, github.com/joyent/node [06:13] Tiger_: oh,my [06:13] cmr: Tiger_: there is no website here, this is IRC [06:13] jesusabdullah: irc is not a web site [06:13] torvalamo: maybe he's using a webchat of sorts [06:13] jesusabdullah: probably [06:13] polotek: pquerna: yeah the class thing was sarcasm [06:14] polotek: isaacs: I've read it. still managed to screw it up [06:14] isaacs: heh [06:14] isaacs: npm help json is also good [06:14] mattgifford has joined the channel [06:14] phire has joined the channel [06:14] Xenadi has joined the channel [06:15] airandfingers has joined the channel [06:15] airandfingers: hello hello [06:15] brianloveswords has joined the channel [06:15] Xenadi: hi there [06:15] Tiger_: oh,i see, after google [06:15] real_mjr has joined the channel [06:16] Xenadi: anyone able to help with issues on here? [06:16] airandfingers: what are the most commonly-used methods of linking a node application to a database? [06:16] airandfingers: i see couchdb a lot [06:16] deoxxa: Xenadi: not if you don't tell us what they are :) [06:16] abraxas: airandfingers: mongo seems pretty popular [06:16] deoxxa: airandfingers: i find myself using mongodb pretty often [06:16] airandfingers: hm, 2 for mongo [06:16] Xenadi: i cant run the example http server on my windows 7 box, but my old as all hell windows xp laptop works fine [06:16] airandfingers: i saw that on nodetuts, haven't seen the video though [06:16] cmr: I've been sniffing around redis. [06:16] cmr: Seems, alright [06:16] airandfingers: http://nodetuts.com/tutorials/21-nodejs-mongodb-and-mongoose-11.html#video [06:16] abraxas: airandfingers: i use membase a lot [06:16] catshirt has joined the channel [06:17] cmr: Xenadi: What code are you using, what version of node? [06:17] airandfingers: hmm, what are their relative advantages? (or how can i find that out myself) [06:17] abraxas: cmr: I love the redis api.. but very concerned (don't know enough about this yet) about the data persistence [06:17] Xenadi: 0.6.7 and the example from the main page http://nodejs.org [06:18] abraxas: airandfingers: membase is a key/value store based on the memcached api, so scaling is insanely easy, but query abilities are limited [06:18] cmr: Xenadi: from the msi installer? [06:18] Xenadi: i can log to the console without any issues, but my browser doesnt connect [06:18] Xenadi: yes [06:18] Xenadi: same installer worked fine on my laptop and on my mates win 7 box [06:18] deoxxa: airandfingers: mongoose adds a lot of functionality on top of mongodb, functionality that you may or may not need - personally i just use the regular old mongodb api [06:19] airandfingers: @deoxxa how is mongodb in terms of query expressibility and ease-of-use? [06:19] Tiger_: I am come in through the website(http://webchat.freenode.net),what about you ? [06:20] Xenadi: i should also mention im running win 7 x64 [06:20] airandfingers: @abraxas hm, sounds pretty simple.. maybe membase would be a good place to start, how does it compare to couchdb? [06:20] deoxxa: airandfingers: pretty good, the queries are just regular JSON so they map directly to javascript objects [06:20] airandfingers: hm sorry, i'm using the wrong syntax for replying ^^ [06:20] cmr: Tiger_: I'm using weechat. freenode's webchat uses qwebirc, the source is at http://hg.qwebirc.org/qwebirc/src [06:20] abraxas: airandfingers: membase is no more than simple key/value, so you can't do any scans [06:21] abraxas: airandfingers: if you don't need scans, just key/value, membase is wonderful [06:21] abraxas: airandfingers: although admittedly, redis has a much more powerful api [06:21] airandfingers: abraxas: so why use membase over redis, then? [06:22] abraxas: airandfingers: redis has not yet convined me of safe and realtime persistent storage [06:22] Tiger_: ook!thanks! i get it! sorry ,my english is poor~ :) [06:22] abraxas: airandfingers: but i'm not informed enough about redis, i need to learn more about it [06:22] nickdc has left the channel [06:23] airandfingers: abraxas: i see.. i recognize redis from the [06:23] airandfingers: abraxas: "most depended on" list of npm packages [06:23] mattgifford has joined the channel [06:24] abraxas: airandfingers: it's very popular [06:24] airandfingers: deoxxa: sounds good.. what does mongo interface with? do you have to install a database or ubuntu package like couchdb? [06:24] cmr: airandfingers: mongodb IS a database [06:24] deoxxa: yep, it's a database server [06:25] airandfingers: so the npm package actually installs the database server, or the package is just an interface to it, and you have to install it with aptitude (or something)? [06:25] deoxxa: the latter [06:25] cmr: airandfingers: yes, you need mongodb installed and running [06:25] airandfingers: got it.. so similar to couchdb [06:25] maletor has joined the channel [06:25] jesusabdullah: sort of [06:25] deoxxa: mongodb is a database server, just like couchdb, mysql, etc etc [06:25] cmr: Similar to most databases. [06:25] airandfingers: couchdb gave me all kinds of trouble though @@ aptitude kept installing version 0.11 [06:26] jesusabdullah: couchdb has an http interface [06:26] airandfingers: but not similar to redis and/or membase? [06:26] cmr: Similar to redis, yes. [06:26] cmr: I don't know about membase. [06:26] deoxxa: they fall under the "etc" [06:26] jesusabdullah: well, there are families of these kind of [06:27] airandfingers: hm, how about mongodb vs redis? sounds like mongo is more fully-featured, redis is simpler? [06:27] jesusabdullah: Here's my impression of nosql databases: [06:27] hdms_o has joined the channel [06:27] deoxxa: they both have different uses [06:27] jesusabdullah: First, there are the group of them that were like, "man sql kinda sucks let's do something better" [06:27] jesusabdullah: I think couchdb falls in that bucket, for example [06:27] Yooman has left the channel [06:27] airandfingers: deoxxa: can you describe those different uses, if you wouldn't mind? O:) [06:28] jesusabdullah: it's a document datastore with an http/json api, pretty wild [06:28] hdms_o has left the channel [06:28] airandfingers: yeah that was something different, and quite a ride [06:28] jesusabdullah: Then, there are the guys that were like, "I love sql brah but it jist doesn't scale" [06:28] Xenadi: anyone with windows + node experience? - having issues with the http example [06:28] jesusabdullah: just* [06:28] total_ has joined the channel [06:28] jesusabdullah: and mongodb and other databases are kinda like this [06:28] jesusabdullah: hbase? [06:29] jesusabdullah: the point is that they have these sort of sql-influenced dsl's (in mongo's case an edsl with javascript) for doing queries [06:29] jesusabdullah: but use mapreduce techniques, etc. underneath for mad scaling yo [06:29] jesusabdullah: couch's concept of scaling is great but I don't think it was really written with this in mind [06:30] jesusabdullah: not in the same way as some of these others [06:30] Yooman has joined the channel [06:30] airandfingers: mkay, so i'll check out mongo and redis, maybe others, but what are your impressions of those two, as compared to the others? [06:30] jjd has joined the channel [06:30] airandfingers: (already tried and gave up on couchdb) [06:30] cmr: airandfingers: Is your data relational? [06:30] jesusabdullah: there are others too that were basically just like, "let's implement this bigtable stuff and make it fast and awesome" [06:30] airandfingers: yes [06:30] cmr: Then use a relational database. [06:30] jesusabdullah: and like, redis and riak and stuff like that is like that [06:31] jesusabdullah: airandfingers: I like couch a lot actually [06:31] cmr: Don't bother with mongo, redis, etc. Go with postgres or sqlite. [06:31] jesusabdullah: mongo's also popular amongst noders [06:31] Druide_ has joined the channel [06:31] jesusabdullah: I think if you think mongo sounds more pleasant to work with than sql then you should do that, personally [06:31] jesusabdullah: same with couch [06:32] jesusabdullah: but if sql fits you might as well [06:32] airandfingers: hm, well maybe i should ask what you mean by "relational".. i interpreted that as "composed of different objects that are related to each other" (typical sql database style) [06:32] jesusabdullah: yeah, that's what that means [06:32] jesusabdullah: with mapreduce you don't have to have a schema in the same way [06:32] airandfingers: well i have sql experience, and i'm frustrated with all the new things i'm having to learn to use node (express, jade, node itself, etc) [06:32] jesusabdullah: usually you just have keys and values [06:33] jesusabdullah: well, it's a new stack yo, of course it'll take some time and effort [06:33] airandfingers: i mean you could structure data any way you like.. but maybe my mind is inclined to think in relational terms [06:33] jesusabdullah: You don't have to learn jade if you don't want to fwiw [06:33] JackNorris has joined the channel [06:33] jesusabdullah: and you certainly don't *have* to jump into the nosql pool [06:33] airandfingers: yeah that's true, i thought i did because of the nodetuts i watched [06:33] airandfingers: ^^ [06:33] cmr: ACTION dislikes jade [06:33] jesusabdullah: look around for some sql libraries and call it a day ;) [06:33] airandfingers: ^^ [06:34] airandfingers: i'll save the nosql jump for later on, i guess [06:34] jesusabdullah: Honestly, *my* problem is that I can never figure out how to get an sql server running and configured [06:34] jesusabdullah: Yeah dude [06:34] yogig has joined the channel [06:34] jesusabdullah: mapreduce is a way cool thing [06:34] airandfingers: i see [06:34] jesusabdullah: as is being able to treat your database as a webserver (couch does this) [06:35] polotek: airandfingers: the pg module for postgres is nice [06:35] jesusabdullah: Oh, is it? Good to hear :) [06:35] Hanspolo has joined the channel [06:36] Tiger_: Excuse me,Is there any way can make the Node.js support sleep() ? To unload the cpu? [06:36] Margle has joined the channel [06:36] RLa: Tiger_, use setTimeout and callbacks [06:36] polotek: Tiger_: no [06:36] polotek: :) [06:36] githogori has joined the channel [06:37] polotek: You don't want to sleep, you want to use a callback [06:37] cmr: Tiger_: Node doesn't busy loop so don't sorry about it. [06:37] airandfingers: i mean, if you _really_ wanted to, you _could_ make it busy loop [06:37] airandfingers: but it's better to learn to think in terms of callbacks [06:37] torvalamo: if you're a sadist [06:38] Tiger_: but i can't unload the cpu [06:38] airandfingers: yep, sleeps are a bad idea [06:38] cmr: Tiger_: Don't worry about it, the OS will do it for you [06:38] Tiger_: i mean use the "busy loop" [06:38] jesusabdullah: Tiger_: it happens implicitly [06:38] jesusabdullah: What you probably want to do is something like, [06:38] torvalamo: it won't just loop when nothing happens [06:38] torvalamo: well, it will, but it doesn't cost anything [06:39] zivester has joined the channel [06:39] airandfingers: bleh.. so, recommendations for sql npm packages? ^^ [06:39] airandfingers: i heard your pg, polotek [06:39] cmr: Postgres is very nice. [06:39] jesusabdullah: (function doThingEveryFewSeconds() { setTimeout(function () { doThing(); doThingEveryFewSeconds(); }, 2000); })() [06:39] jesusabdullah: Like that [06:39] polotek: node-mysql is pretty standard [06:39] airandfingers: sounds about right [06:39] airandfingers: how about sqlite? [06:40] torvalamo: node-sqlite3 [06:40] torvalamo: or something [06:40] cmr: I like sqlite because I don't need to setup a server. [06:40] jesusabdullah: I don't think they ever made it non-blocking though [06:40] polotek: yes, use sqlite3 [06:40] cmr: jesusabdullah: they did [06:40] jesusabdullah: oh? [06:40] polotek: there are some other ones, but they're not so good in my experience [06:40] jesusabdullah: Awesome! [06:40] cmr: I don't know about node-sqlite3 in specific but there is a non-blocking version available. [06:40] Tiger_: just want to do Ajax long-pulling [06:40] cmr: Yeah, it's async. [06:41] airandfingers: i don't see node-mysql, but i see references to it in other packages..mysql-helperSimple wrapper for felixge's node-mysql [06:41] polotek: Tiger_: actually you wanna use socket.io :) [06:41] satyr has joined the channel [06:41] torvalamo: sqlite is like any sql, except it doesn't give a shit about types [06:41] torvalamo: :P [06:41] torvalamo: is the short story [06:41] jesusabdullah: also, file system [06:41] torvalamo: and it stores in a local file [06:41] torvalamo: yeah [06:42] deoxxa: ha, gistdb is pretty cool [06:42] mikeal has joined the channel [06:42] airandfingers: should i be searching for packages at http://search.npmjs.org/ ? [06:42] Emmanuel has left the channel [06:43] cmr: airandfingers: Or you can use "npm search" [06:43] airandfingers: right, pretty much the same thing? [06:43] polotek: airandfingers: http://toolbox.no.de/ [06:43] cmr: Also see http://toolbox.no.de/ [06:43] airandfingers: thanks! [06:43] Tiger_: polotek: socket.io? but Browser support socket? i just know the html5 suport browser can do [06:44] cmr: Tiger_: socket.io falls back to other transports besides websockets. [06:44] deoxxa: if only there was a website for socket.io that explained this [06:44] deoxxa: something like maybe http://socket.io/ [06:44] polotek: socket.io even works in your mom's web browser [06:44] polotek: ^ tagline [06:45] yawNO has joined the channel [06:45] [[zz]] has joined the channel [06:45] torvalamo: that's... unacceptable [06:46] torvalamo: the things i'm making i hope my mom never sees [06:47] jesusabdullah: porn? [06:47] keviv: Hi, I am new to node.. I am finding it difficult to install connect (via npm) through bash on my MACbook... Could someone give me pointers towards any document\website [06:47] torvalamo: some may see it as that, but no not really [06:48] torvalamo: keviv, what kind of errors do you get? [06:49] Tiger_: ok,thinks everyone !Thank you for your warm , i'm so busy to watching the replys, it flash fast!thanks again! [06:50] keviv: Hi Torvalamo, when i key in npm install connect in bash, I get this error - npm ERR! error installing connect@1.8.5 npm ERR! Error: failed to fetch from registry: formidable npm ERR! at /usr/local/lib/node_modules/npm/lib/utils/npm-registry-client/get.js:139:12 [06:52] criswell has joined the channel [06:52] airandfingers: i'd try npm install connect formidable [06:52] cmr: I'm an ASI ninja! \o/ [06:52] cmr: http://asi.qfox.nl/ [06:52] airandfingers: but i'm an amateur [06:54] keviv: Hi airandfingers, I am getting the same error even with $npm install connect formidable [06:54] Morkel has joined the channel [06:54] torvalamo: it can't find formidable (a connect dependency) in the registry [06:54] reid has joined the channel [06:54] torvalamo: try npm search formidable [06:55] airandfingers: client.query( 'CREATE TEMPORARY TABLE '+TEST_TABLE+ '(id INT(11) AUTO_INCREMENT, '+ 'title VARCHAR(255), '+ 'text TEXT, '+ 'created DATETIME, '+ 'PRIMARY KEY (id))' ); [06:55] airandfingers: ugh, how ugly [06:55] Druide_ has joined the channel [06:56] keviv: npm WARN Building the local index for the first time, please be patient npm http GET https://registry.npmjs.org/-/all npm ERR! Error: connect ECONNREFUSED npm ERR! at errnoException (net.js:640:11) npm ERR! at Object.afterConnect [as oncomplete] (net.js:631:18) [06:56] torvalamo: isaacs wake up [06:57] airandfingers: guess i can't avoid writing some SQL if i'm gonna use an SQL database though [06:57] maletor has joined the channel [06:57] airandfingers: i'm gonna go with sqlite3 [06:57] keviv: torvalamo - do you think something is wrong with my node install package [06:57] airandfingers: thanks to all of you for your help :) [06:57] torvalamo: keviv is it updated? [06:57] torvalamo: latest version etc [06:57] torvalamo: npm also [06:58] torvalamo: i just installed formidable without errors [06:58] torvalamo: 'npm install formidable' [06:58] keviv: it throws the above exception for me [06:58] torvalamo: update node and npm [06:58] torvalamo: to be safe [06:59] torvalamo: try node -v and npm -v [07:00] keviv: node - 0.6.7; and npm - 1.1.0 -beta-10 [07:00] torvalamo: i have 0.6.6 and 1.0.106 [07:00] torvalamo: maybe some new bug [07:00] cognominal has joined the channel [07:01] keviv: k, let me downgrade and try [07:01] deoxxa: i'm using the latest and it's working fine [07:01] deoxxa: keviv: try `curl -v https://registry.npmjs.org/-/all' [07:01] deoxxa: see what it says [07:02] airandfingers: die, couchdb, dieeee [07:02] deoxxa: seems the SSL certificate is odd [07:03] deoxxa: that shouldn't break it completely though [07:03] ph^ has joined the channel [07:04] fangel has joined the channel [07:04] keviv: deoxxa - I get this error - About to connect() to registry.npmjs.org port 443 (#0) * Trying 107.20.159.167... Connection refused * couldn't connect to host * Closing connection #0 curl: (7) couldn't connect to host [07:04] deoxxa: yeah, it's a network problem [07:04] deoxxa: can you ping the hostname? i.e. `ping registry.npmjs.org' [07:05] ryankirkman has joined the channel [07:05] torvalamo: that ip is what i get [07:05] deoxxa: make sure you don't have a firewall or something blocking it [07:05] deoxxa: it's not down, since it's working from here and i get the same ip [07:05] ryankirkman: Hi guys, I have Ubuntu and tried using the "bash < <(http://h3manth.com/node)" and I get "-bash: http://h3manth.com/node: No such file or directory" on Ubuntu 10.04 LTS [07:05] keviv: I am able to ping it, all 4 pkts successfully [07:06] deoxxa: do you perhaps have something like little snitch installed? [07:06] captain_morgan has joined the channel [07:06] deoxxa: or some other kind of software firewall? [07:06] cmr: ryankirkman: that isn't valid [07:06] keviv: deoxxa need to check [07:06] cmr: ryankirkman: curl http://h3manth.com/node | bash [07:06] mattgifford has joined the channel [07:07] deoxxa: keviv: it sounds a lot like you've got something inbetween you and the npm registry blocking it - that might be on your machine, your router, your network, somewhere in between, etc [07:07] ryankirkman: cmr: Does the wiki need to be updated, or did I just not understand the instructions? [07:08] cmr: ryankirkman: Wiki where? [07:08] madhums has joined the channel [07:08] mytrile has joined the channel [07:09] ryankirkman: https://github.com/joyent/node/wiki/Installation under heading "GNU/Linux [ nodejs + npm ]" [07:09] ryankirkman: also, apparently I can't curl the "http://h3manth.com/node" url [07:09] cmr: Whoever wrote that must have been high [07:09] Locke23rus has joined the channel [07:09] RLa: hm, doesn't npmjs use snake-oil cert? [07:10] chiyam has joined the channel [07:11] cmr: ryankirkman: curl http://paste.pocoo.org/raw/534100/ | bash [07:11] dgathright has joined the channel [07:11] tilgovi has joined the channel [07:11] RLa: haha, put rm -rf in that and let run through bash [07:12] ryankirkman: cmr: I copied the instructions into a .sh file, chmoded it and ran it and it's working now [07:12] ryankirkman: cmr: I'm just concerned that newbies will be turned off by stuff not working [07:12] RLa: why you all care about newbies so much? [07:12] cmr: ryankirkman: Never even seen that page in the wiki before [07:13] ryankirkman: cmr: As far as I'm aware it's the de-facto place to find installation instructions [07:13] ryankirkman: cmr: or at least it was back in the 0.5.x days [07:14] Hanspolo has joined the channel [07:14] cmr: ryankirkman: git checkout https://github.com/joyent/node.git; cd node; git checkout v0.6.7; ./configure; make; make install; # Done [07:14] satyr has joined the channel [07:15] ryankirkman: cmr: git clone? [07:15] cmr: Yes, clone sorry [07:15] yolin has joined the channel [07:16] robi42 has joined the channel [07:18] nick_f has joined the channel [07:18] tdegrunt has joined the channel [07:19] ryankirkman: cmr: I updated the wiki here (https://github.com/joyent/node/wiki/Installation). Do my changes seem reasonable? [07:20] ryankirkman: cmr: I think I should add in a section about the -jX flag but I forget the syntax [07:20] cmr: ryankirkman: Meh, don't bother. [07:20] ryankirkman: cmr: ?? [07:20] cmr: Compiling node only take 11 minutes on a 1-core mobile celeron [07:21] ryankirkman: cmr: KISS, fair enough [07:21] jimt has joined the channel [07:21] cmr: And it's -j(Number of cores + 1) [07:21] cmr: To make [07:23] ryankirkman: cmr: Why the +1? [07:25] cmr: ryankirkman: it's how I've always seen it done, I honestly can't give you a rigorous answer. [07:26] satyr has joined the channel [07:27] SamuraiJack has joined the channel [07:27] aesptux has joined the channel [07:28] k1ttty has joined the channel [07:32] RobWC has joined the channel [07:32] Heisenmink has joined the channel [07:33] yolin has joined the channel [07:33] langworthy_ has joined the channel [07:34] secoif: ryankirkman you could try using nvm or n [07:34] secoif: npm install -g n [07:34] jetienne has joined the channel [07:34] secoif: ryankirkman then simply: n latest [07:34] secoif: will download and set node to the latest node [07:35] icewhite has joined the channel [07:36] pradeepto has joined the channel [07:37] Neil has joined the channel [07:38] dingomanatee has joined the channel [07:38] p1d has joined the channel [07:39] groom has joined the channel [07:45] briandh has joined the channel [07:46] langworthy has joined the channel [07:46] neshaug has joined the channel [07:51] slaskis has joined the channel [07:51] pgherveou has joined the channel [07:53] EyePulp has joined the channel [07:53] munichlinux has joined the channel [07:55] NothingMan65 has joined the channel [07:56] josh-k has joined the channel [07:56] ryankirkman: secoif: what is nvm? [07:56] ryankirkman: cmr: Compiling node on my vps is insanely slow [07:56] rendar has joined the channel [07:57] cmr: ryankirkman: Then compile it elsewhere and bring in the binaries. [07:57] cmr: And such [08:01] boltR has joined the channel [08:01] hipsters_ has joined the channel [08:01] `3rdEden has joined the channel [08:01] einaros has joined the channel [08:02] joshfinnie has joined the channel [08:03] catshirt has joined the channel [08:03] fangel has joined the channel [08:03] dreapuf has joined the channel [08:04] herbySk has joined the channel [08:06] jbpros has joined the channel [08:06] harthur has joined the channel [08:07] hcchien has joined the channel [08:08] shinuza has joined the channel [08:10] tdegrunt has joined the channel [08:10] pig has joined the channel [08:12] jomoho has joined the channel [08:12] raphdg has joined the channel [08:15] pig has joined the channel [08:16] ccare has joined the channel [08:19] torm3nt has joined the channel [08:20] pig has joined the channel [08:20] npa has joined the channel [08:22] tvw has joined the channel [08:23] ambroff has joined the channel [08:26] chiyam has joined the channel [08:26] lperrin has joined the channel [08:26] shanebo has joined the channel [08:26] janeUbuntu has joined the channel [08:26] ph^ has joined the channel [08:28] arcanis has joined the channel [08:30] HardBit has joined the channel [08:30] HardBit: Hi people! [08:30] pt_tr has joined the channel [08:31] [AD]Turbo has joined the channel [08:32] [AD]Turbo: hi there [08:32] ccare has joined the channel [08:33] pt_tr has joined the channel [08:33] djcoin has joined the channel [08:34] matejv has joined the channel [08:34] dubenstein has joined the channel [08:35] yawNO has joined the channel [08:37] munichlinux has joined the channel [08:39] a_suenami has joined the channel [08:39] pt_tr has joined the channel [08:41] johnnychimpo has joined the channel [08:43] rendar has joined the channel [08:44] rio{ has joined the channel [08:46] dob has joined the channel [08:46] dubenstein has joined the channel [08:50] bobslaede has joined the channel [08:51] dreapuf has left the channel [08:51] sproates has joined the channel [08:52] pors has joined the channel [08:53] Druide_ has joined the channel [08:53] yawNO has joined the channel [08:54] _olouv_ has joined the channel [08:54] levi501d: Aloha, how do you send the esc key through stdin.write()? i know return in \n but dunno esc [08:54] Nss has joined the channel [08:54] tytsim has joined the channel [08:55] bobslaede: Hi everybody. Im trying to debug why my node.js http server wont listen on any port below 1024. Im not really getting any usable errors [08:55] RLa: levi501d, asciitable.com [08:55] polotek: bobslaede: anything below 1024 is protected, you need to have root privileges [08:55] levi501d: thanks RLa [08:55] bobslaede: polotek: awesome! thank you, didnt even think about that [08:56] levi501d: so its not '^] [08:56] whitman has joined the channel [08:56] levi501d: ^] [08:56] robi42 has joined the channel [08:56] unomi: I am trying to get a 'quick and dirty' proxy up and running for a remote https API - any hints? [08:57] salva has joined the channel [08:57] cmr: levi501d: the representation would be ^[, but to write the character it'd be \27 [08:57] unomi: I don't seem to be able to grok how I can put http-proxy to that task [08:57] levi501d: ahh so stdin.write("\27 wq"); to esc and write quit vi then [08:58] venkat has joined the channel [08:58] salva has left the channel [08:58] ccare has joined the channel [08:59] stonebranch has joined the channel [09:01] snearch has joined the channel [09:01] paera has joined the channel [09:01] aliem has joined the channel [09:02] cosmincx has joined the channel [09:04] robhawkes has joined the channel [09:04] aaronmcadam has joined the channel [09:05] Margle_ has joined the channel [09:06] gut4 has joined the channel [09:07] dwhittle has joined the channel [09:08] hipsters_ has joined the channel [09:12] __tosh has joined the channel [09:13] hall_ has joined the channel [09:13] burningdog has joined the channel [09:13] jjt has joined the channel [09:14] jjt has left the channel [09:15] sx2020 has joined the channel [09:15] sx2020: yo yo yo [09:15] icebox has joined the channel [09:15] stagas has joined the channel [09:15] jjt has joined the channel [09:15] sx2020: anyone here use jade templating? i can't find any documentation about operators [09:16] sx2020: - if (x != 1) [09:16] sx2020: doesn't work [09:16] sx2020: but - if (x == 1) [09:16] sx2020: does [09:16] sx2020: sup w that [09:16] icebox: !== maybe [09:16] sx2020: lemme try brb [09:16] icebox: as in js [09:16] broofa has joined the channel [09:17] sx2020: nope [09:17] abraxas: sx2020: i've never used jade, but alternatively you may wanna try if (x <> 1) ? [09:18] sx2020: ok trying that next :) [09:18] sx2020: @abraxas nope it didn't like that one [09:19] abraxas: if (x does not equal 1) ? :) i give up [09:19] RLa has joined the channel [09:19] sx2020: hah [09:20] icebox: sx2020: ne [09:20] k1ttty has joined the channel [09:21] deoxxa: sx2020: might i take this opportunity to whore my current pet project out? https://github.com/deoxxa/node-ginger [09:21] icebox: sx2020: if ne 1 [09:21] TomY_ has joined the channel [09:22] sx2020: hang on now == isn't even working [09:22] icebox: sx2020: if eq 1 [09:24] swestcott has joined the channel [09:24] sx2020: @deoxxa looks like django [09:24] sx2020: which i like [09:24] agnat_ has joined the channel [09:24] deoxxa: it's inspired by the syntax of django (specifically twig, which was inspired by jinja2, which in turn was inspired by django) [09:24] deoxxa: heh [09:25] beevits has joined the channel [09:25] a_suenami has joined the channel [09:25] deoxxa: gonna convince my boss to let me use it at work [09:25] deoxxa: then he'll sponsor development of it, since it'll speed up our work by quite a lot [09:26] vvo has joined the channel [09:26] niloy has joined the channel [09:26] sx2020: @icebox, are you saying to try: - if (x eq 1) [09:27] sx2020: @deoxxa i do love ginger so maybe i should try it out [09:27] deoxxa: hooray! [09:28] sx2020: but [09:28] sx2020: that would be on a future project [09:28] deoxxa: it's a little rough around the edges at the moment, i'm writing a tool to compile a collection of templates into a single .js file at the moment [09:28] deoxxa: yeah, of course [09:28] deoxxa: it's not quite ready for production - i only started work on it a few days ago :P [09:28] sx2020: jade is good but not perfect for me [09:29] AD7six has joined the channel [09:29] sx2020: i'm getting used to it [09:29] sx2020: the docs suck though, how can they not post basic operators [09:29] lzskiss has joined the channel [09:29] deoxxa: that's one of the things i need to work on for this... docs [09:30] deoxxa: i'm not even that horrible at writing them, it just takes forever for me to get in the mood to do it [09:31] davetayls has joined the channel [09:33] sx2020 has joined the channel [09:34] yolin has joined the channel [09:35] sx2020: ok i'm an idiot, the '==' and '!=' do work [09:35] sx2020: in jade [09:35] cesconix has joined the channel [09:37] iRoj has joined the channel [09:38] tytsim has joined the channel [09:39] yawNO has joined the channel [09:45] stagas has joined the channel [09:45] markwubben has joined the channel [09:46] sx2020 has joined the channel [09:47] sx2020 has left the channel [09:48] abraxas: can anyone tell me what i can use to analyze v8.log? [09:48] npa has joined the channel [09:51] vguerra has joined the channel [09:51] fangel has joined the channel [09:52] sgimeno has joined the channel [09:53] fangel has joined the channel [09:54] hz has joined the channel [09:54] _olouv_1 has joined the channel [09:55] robde has joined the channel [09:55] LeMike has joined the channel [09:56] c4milo has joined the channel [09:56] spolu has joined the channel [09:58] eldios has joined the channel [09:59] fly-away has joined the channel [10:00] ppcano has joined the channel [10:01] hugdubois has joined the channel [10:02] _JSilva has joined the channel [10:03] tytsim has joined the channel [10:04] plutoniix has joined the channel [10:05] yolin has joined the channel [10:06] deoxxa: so uglify-js is fun [10:07] deoxxa: the code generator and ast thing is actually pretty neat to use [10:07] deoxxa: my experience with ast manipulation in other languages has been far from enjoyable, so it's a nice change [10:07] satyr has joined the channel [10:10] spolu: Hi all, I have a proxy server which I use to connect to an nginx http server and retrieve html. Every minute or so I get a socket Hang Up error on my agent request (going to the nginx server). Looks like a timeout happening on my proxy or on nginx side. Anybody would have any clue on how to avoid that? [10:10] phire has joined the channel [10:10] spolu: I could remove the socket from the globalAgent but that would become highly inefficient I guess [10:11] deoxxa: spolu: got code? i can't quite imagine what you're doing... [10:11] spolu: deoxxa: [10:11] spolu: sure [10:12] deoxxa: hooray! [10:12] jimt has joined the channel [10:12] spolu: deoxxa: https://gist.github.com/1605400 [10:12] spolu: deoxxa: you can ignore the infra.access call [10:12] deoxxa: ok [10:13] MrTopf has joined the channel [10:14] yolin has joined the channel [10:15] spolu: deoxxa: every minute or so (always the same time) line 53 -> socket hang up [10:15] spolu: deoxxa: within a minute I performe ~ 50 different request [10:16] claudio has joined the channel [10:16] deoxxa: i see [10:16] kickingvegas has joined the channel [10:17] yawNO has joined the channel [10:17] deoxxa: so preq times out, somehow? [10:17] spolu: deoxxa: that's my guess [10:17] spolu: deoxxa: or the underlying pooled connection [10:18] deoxxa: sounds like the req#data event might not be firing [10:18] deoxxa: or req#end [10:18] deoxxa: that'd be what i'd look at first, anyway [10:18] shinuza has joined the channel [10:19] mara has joined the channel [10:19] spolu: deoxxa: req.data is never fired (I do only GET in that use case) [10:19] davetayls has joined the channel [10:19] deoxxa: but req#end is? [10:19] niloy has joined the channel [10:19] cmr: I see that syntax everywhere. What does req#end mean, exactly? [10:19] cmr: Well, "everywhere" as in docs mostly. [10:20] mara has joined the channel [10:20] deoxxa: object#event [10:20] cmr: Ahhhhh. [10:20] cmr: That's really convenient. [10:20] spolu: deoxxa: well that might not be the case but that would mean that all request would hang up, only here it happens only once very minute for 50 different incoming request [10:20] TimTim has joined the channel [10:20] deoxxa: var req = http.request(config); req.on("data", cb); << req#data [10:21] deoxxa: spolu: does it happen for all requests? or only some? and if it's only some, is it always the same ones? [10:21] disappea_ has joined the channel [10:21] spolu: deoxxa: I do a req.end() on the proxy client side [10:21] deoxxa: and if it's always the same ones, is it also the same ones if you change the order of the requests? [10:21] spolu: deoxxa: one every 50-60 request [10:22] yolin has joined the channel [10:22] spolu: deoxxa: each request is unique [10:22] deoxxa: ah [10:22] spolu: deoxxa: one request every second [10:22] spolu: deoxxa: always happen on the Xth [10:22] deoxxa: oh that's interesting [10:23] spolu: deoxxa: the underlying connection is probably kept alive right? [10:23] spolu: deoxxa: if nginx timeout that keep alive connection every minute or so [10:23] deoxxa: hmm iirc the default node http client doesn't support pipelining, so there'd be no reason to have it stay open [10:23] spolu: deoxxa: ok [10:24] deoxxa: that was a while ago i heard that though, it may have changed [10:24] deoxxa: ah, no, it does do keep-alive now [10:24] spolu: deoxxa: right [10:24] tytsim has joined the channel [10:25] spolu: deoxxa: so I guess the nginx server just decide to close it after some time (as it's kind of unusual to have such a long keep-alived connection) [10:25] deoxxa: yeah [10:25] spolu: deoxxa: so I'd like to force my agent to recycle connection every 30s [10:26] spolu: deoxxa: maybe I can set the req.connection.timeout [10:26] spolu: or the request.timeout [10:27] spolu: or maybe try a setKeepAlive(true) [10:27] disappearedng has joined the channel [10:27] spolu: since the timeout is enforced only when the connection is inactive... [10:28] deoxxa: might work [10:28] larsschenk has joined the channel [10:28] larsschenk1 has joined the channel [10:29] pickels_ has joined the channel [10:29] gut4 has joined the channel [10:30] larsschenk1 has left the channel [10:31] kulor-uk has joined the channel [10:32] yolin has joined the channel [10:34] ger^kallisti has joined the channel [10:34] EvRide1 has joined the channel [10:35] mc_greeny has joined the channel [10:36] Cromulent has joined the channel [10:36] niloy has joined the channel [10:41] EvRide has joined the channel [10:46] pksunkara: does anybody have an old macbook for sale? [10:47] deoxxa: i will have one for sale in about 3 weeks, if that helps [10:47] deoxxa: ACTION upgrading [10:47] booo has joined the channel [10:47] booyaa: crikey pksunkara will your customs/execise try to tax you for it? [10:47] torvalamo: how old? [10:48] torvalamo: i have a g4 [10:48] pksunkara: torvalamo: dunno, I just need it to run for 1yr more [10:49] torvalamo: dunno if it will :p [10:49] torvalamo: think im gonna turn it linux [10:49] phire has joined the channel [10:49] torvalamo: those os x updates just get heavier and heavier [10:50] panterax has joined the channel [10:50] torvalamo: quite a sneaky way to get people to buy new computers [10:50] booyaa: not nearly as bad as windows [10:51] booyaa: my macbook pro has seen action since tiger [10:51] torvalamo: windows doesn't have tailor made hardware [10:51] torvalamo: which makes the mac os update creep even less sensible [10:51] booyaa: only avoided lion because of fusion performance issues [10:51] dr0id has joined the channel [10:52] case_: (my macbook pro runs ubuntu perfectly fine ) [10:52] torvalamo: i have a power pc mac [10:52] booyaa: has linux desktop sorted out its continual need to updated everything yet? [10:52] torvalamo: but i dont doubt linux will outperform os x majorly [10:53] torvalamo: booyaa, that depends on the distro [10:53] shripadk has joined the channel [10:53] pksunkara: I use linux only, but mac is pretty :D [10:53] fermion has joined the channel [10:53] booyaa: heh [10:54] pksunkara: and my HP laptop sucks majorly [10:54] deoxxa: i find that mac hardware is pretty solid [10:54] torvalamo: it's pretty like gnome is pretty... looks good but not very helpful [10:54] pksunkara: lol [10:54] __doc__ has joined the channel [10:54] deoxxa: my last couple of pc laptops have only lasted about 6 months each [10:54] deoxxa: (not counting my toughbooks - those things are indestructible) [10:55] zivester has joined the channel [10:55] deoxxa: i'm probably pretty rough on my gear though [10:55] cmr: Yeah... I've never had a laptop die on my from handling issues. [10:55] torvalamo: the laptop i'm typing on now is an lg p1 from 2007/8 [10:55] torvalamo: works like a charm [10:55] deoxxa: i went through 3 in high school :( [10:55] cmr: jeez! [10:56] cmr: Maybe I'm just unusually kind to my hardware [10:56] deoxxa: heh [10:56] raincole_ has joined the channel [10:56] torvalamo: it has a white keyboard and one thing i always found a bit odd.. the keys go yellow, but only totally random.. and it's not related to use [10:56] vesln has joined the channel [10:56] deoxxa: haha [10:56] torvalamo: like, f9 and f11 are yellow, but f8, f10 and f12 are fine [10:57] torvalamo: and scroll lock is yellow, i definately never use that [10:57] deoxxa: oh yeah, that happened with my HP thing a while back [10:57] deoxxa: i found that the keys i didn't use got dirtier [10:57] deoxxa: i think using them wipes dirt off them [10:57] pksunkara: lol [10:57] satyr has joined the channel [10:57] torvalamo: nah also keys i use are yellow [10:57] torvalamo: like A [10:57] deoxxa: oh [10:58] deoxxa: ha [10:58] torvalamo: and G and U and L [10:58] booyaa: torvalamo: do you smoke? [10:58] torvalamo: it's just totally random [10:58] torvalamo: nope [10:58] deoxxa: nor do i [10:58] booyaa: ah okay can't blame nicotine :) [10:58] torvalamo: and they're not like part yellow either.. the entire key, single color [10:58] Alpha|home has joined the channel [10:58] shripadk: anyone here use ST2 on OSX? [10:59] torvalamo: what's st2? [10:59] torvalamo: (i guess that answers it) [10:59] booyaa: yeah doesn't ring any bells here [10:59] booyaa: i do use tf2 on osx [11:00] RLa: anyone run osx without gui? [11:00] RLa: besides me [11:00] torvalamo: i run the terminal window from time to time [11:00] torvalamo: but that's because os x is for noobs [11:00] torvalamo: and it cant handle me [11:00] torvalamo: :P [11:00] Alpha|home: I'm setting up node to run on a production server, looking at cluster as a way of managing it, does anyone have any better suggestions ? [11:00] booyaa: RLa: most of my coding is in iterm2 with screen/iterm2 [11:00] booyaa: tmux even [11:00] shripadk: sublime text 2 :P [11:00] booyaa: shripadk: no, used to use coda [11:01] booyaa: i know there's a lot of textmate fans [11:01] Edy has joined the channel [11:01] Edy has joined the channel [11:01] booyaa: ACTION switched back to vim [11:01] RLa: i'm using gui-less osx as build server [11:01] torvalamo: Alpha|home, cluster is fine [11:01] RLa: it works very well without it [11:01] shripadk: :) [11:01] RLa: and takes way less than 250M ram without gui [11:02] deoxxa: Alpha|home: i use a home-grown process management thing that just pipes stdout/stderr to log files and restarts processes when they die [11:02] booyaa: i'm still on the look out for any refactoring vim scripts [11:02] booyaa: i need something that allows me to extract as method, rename variables and functions. [11:02] torvalamo: i spent three days trying to get gentoo compiled with the right options before i surrendered and went fedora.. im still recovering from the trauma [11:02] booyaa: and doesn't involving some regex voodoo [11:02] davetayls has joined the channel [11:03] deoxxa: booyaa: might want to look at burrito - it may or may not do what you want? [11:03] booyaa: gentoo <-- does some up linux users obsession with the need for speed [11:03] booyaa: if i just take a dump, strip off all my clothes i'll be 5ms faster [11:03] Alpha|home: self flagellation [11:03] deoxxa: booyaa: http://substack.net/posts/eed898 [11:04] Alpha|home: cheers torvalamo deoxxa [11:04] booyaa: s/does some/does sum [11:04] booyaa: deoxxa: nah that's a lib man, i'm not writing this damn vim script :P [11:04] deoxxa: ha [11:05] deoxxa: i thought it was maybe a one-off thing :P [11:05] booyaa: <-- lazy osx coder [11:05] booyaa: i'll wait till someone writes for me [11:05] torvalamo: i thought slackware was the one for speed freaks [11:05] deoxxa: wat r ur CFLAGS bro???? [11:05] booyaa: i used to carry the 10 or so 3.5" discs for slackware [11:06] booyaa: i think linux hadn't hit 1.0 yet [11:06] torvalamo: i just had flashbacks to the gentoo install [11:06] booyaa: kernel [11:06] torvalamo: mention cflags again and i will kill your mother [11:06] deoxxa: hahaha [11:06] cmr: deoxxa: You know, the developers of the applications usually use sane cflags in their makefiles. No need to go shoving your own down their throat. [11:06] deoxxa: torvalamo: http://funroll-loops.info/ [11:07] cmr: ACTION used gentoo for quite some time, and performance is never a good reason to use gentoo (Spoiler: You'll be disappointed) [11:08] booyaa: okay periscope down. dive dive dive! [11:08] torvalamo: nice deoxxa [11:09] jimt_ has joined the channel [11:10] cognominal_ has joined the channel [11:11] insin has joined the channel [11:13] paq has joined the channel [11:13] torvalamo: cmr, i never chose it for performance reasons. some cartoon here said "gentoo for you, ubuntu for your grandma", and so i went gentoo.. oh the horror [11:14] cmr: torvalamo: You used gentoo as a newb? [11:14] cmr: I'm so sorry. [11:14] RLa: why not debian, less compiling [11:14] torvalamo: me too [11:14] margle has joined the channel [11:14] torvalamo: i don't mind compiling [11:14] cmr: Neither do I. [11:14] RLa: or slackware, gives base distro without compiling but everything else has to be compiled [11:14] torvalamo: i mind having to look at a list of 4000 compile options and trying to figure out which of the 300 intel ones are my computer [11:15] RLa: it should be ./configure && make && make install [11:15] torvalamo: lol [11:15] cmr: ./configure --prefix=/usr --disable-* --enable-* && make && make install [11:15] cmr: --with-lots-of-stuff [11:15] cmr: RLa: Don't let that silly "./configure" fool you [11:16] torvalamo: i did at one point consider just selecting everything on the kernel options and go for it [11:16] cmr: And then there's cmake, autoconf, rake, and other things. [11:16] Alpha|home: never used to mind compiling up freebsd, tried gentoo once, didn't smell good [11:16] eeemsi: hi there [11:17] cmr: My main distros these days are exherbo (split from gentoo for technical and political reasons, uses a different (dare I say superior) package manager) and debian. [11:17] torvalamo: how hard is it to autodetect your cpu these days? [11:17] eeemsi: i fixed some of the questions i was putting in here and wanted to give some feedback [11:17] torvalamo: or any hardware [11:17] eeemsi: 1. doing stuff with sqlite3 [11:17] cmr: torvalamo: If you aren't using a second-generation intel core-i[357], -march=native works flawlessy. [11:18] torvalamo: well i did manage to figure out that i needed some prescott thing [11:18] torvalamo: for march [11:18] thalll has joined the channel [11:18] torvalamo: and then i killed myself [11:18] eeemsi: s += (rows[rowIndex].id) is workiong perfectly [11:18] deoxxa: i just use debian for all my pc hardware [11:19] eeemsi: 2. my fuckup with the codesnippet [11:19] eeemsi: dont use http://something for defining the host [11:20] piscisaureus has joined the channel [11:20] cmr: eeemsi: host should never include protocol [11:20] sindresorhus has joined the channel [11:21] eeemsi: just wanted to give this knowledge back to the community and say thank you again to the people who helped me [11:21] staar2 has joined the channel [11:21] staar2: hello [11:21] EuroNerd has joined the channel [11:21] piscisaureus_ has joined the channel [11:22] cmr: Do ops work at joyent? [11:22] eeemsi: cmr: why do you think i am calling this "my fuckup" ;) [11:22] cmr: eeemsi: fair enough :P [11:23] eeemsi: but i just found out that the codesnippet does not understand atom.xml clearly -> http://ricochen.wordpress.com/2011/11/15/a-simple-node-js-rss-parser-using-sax-js/ [11:24] eeemsi: tested it using http://code.stapelberg.de/git/i3/atom/?h=next [11:26] sindresorhu has joined the channel [11:28] staar2: i found good article http://howtonode.org/express-mongodb [11:29] staar2: only problem is that its a bit old [11:29] niloy_ has joined the channel [11:29] staar2: any good articles about using express and mongodb? [11:30] eeemsi: staar2: cant you do theses things without using a specific npm for nosql connections? [11:31] paq has joined the channel [11:31] hackband has joined the channel [11:33] Druide_ has joined the channel [11:33] tkro has joined the channel [11:33] aslakhellesoy has joined the channel [11:34] aslakhellesoy: Does anyone know if dgram support will be fixed in the 0.6 series? [11:34] stefpb has joined the channel [11:35] deoxxa: is it broken? [11:36] marcello3d has joined the channel [11:36] slaskis has joined the channel [11:37] methodT has joined the channel [11:37] LeftWing has joined the channel [11:38] mape has joined the channel [11:38] Druide_ has joined the channel [11:38] fcoury has joined the channel [11:38] wycats has joined the channel [11:38] k1ttty has joined the channel [11:39] jn has joined the channel [11:39] dscape has joined the channel [11:39] dnyy has joined the channel [11:39] Raynos has joined the channel [11:39] jslatts has joined the channel [11:39] Juan77 has joined the channel [11:39] eventualbuddha has joined the channel [11:39] Draggor has joined the channel [11:42] martin_sunset has joined the channel [11:45] hugdubois has joined the channel [11:46] akter has joined the channel [11:47] eeemsi: interesting graph: http://www.internettrafficreport.com/30day.htm?jan13 [11:47] tomh has joined the channel [11:48] cmr: I wonder what that jump was [11:48] d0k has joined the channel [11:48] relix has joined the channel [11:49] jimmysparkle has joined the channel [11:49] RLa: packet loss is 30%, so high? [11:49] tkro has joined the channel [11:50] cmr: That says 20% [11:54] dharmesh has joined the channel [11:54] jarek has joined the channel [11:55] satyr has joined the channel [11:57] amasad has joined the channel [11:57] dep has joined the channel [11:57] patrickgamer has joined the channel [11:59] krnlyng has joined the channel [12:00] aliem has joined the channel [12:00] unomi has joined the channel [12:00] Carmivore has joined the channel [12:00] Carmivore has joined the channel [12:01] blup has joined the channel [12:01] patrickgamer has left the channel [12:01] appr: what is the best way to write into syslog with two different facilities within one node instance? i've tried node-sylog, but since require(...) returns same object every time being called, i can not call syslog.init(name, options, facility) on different syslog instances [12:02] liar__ has joined the channel [12:02] iRoj has joined the channel [12:03] tvw has joined the channel [12:03] Nss_ has joined the channel [12:05] jasonkuhrt has joined the channel [12:05] bicranial has joined the channel [12:06] neshaug has joined the channel [12:13] burningdog has joined the channel [12:16] satyr has joined the channel [12:17] FIQ has joined the channel [12:17] cjm has joined the channel [12:18] cjm has joined the channel [12:19] torvalamo: so make a proxy [12:19] torvalamo: appr [12:19] cmr: ACTION is digging html5's data-* [12:22] Kunda has joined the channel [12:22] jomoho has joined the channel [12:23] deeprogram has joined the channel [12:27] gut4 has joined the channel [12:27] shinuza has joined the channel [12:28] amasad has joined the channel [12:29] qsobad has joined the channel [12:29] jetienne: is it possible to stack getter/setter ? like one getter is called, then the next etc.... [12:30] deoxxa: jetienne: depends what you're talking about - do you mind clarifying? [12:30] stagas has joined the channel [12:30] staar2: i need to makes some data scraper and run it like batch job, i thought to use setTimeout(function() { runjob(); }, 10 * 60 * 1000); ? [12:31] philipd has joined the channel [12:31] deoxxa: staar2: if only there was a standard unix utility for that [12:31] staar2: you mean cron ? [12:31] deoxxa: hooray! [12:31] jetienne: deoxxa: i want to have multiple getter for a property, and i want them excecuted in order. exactly like the usual dom element.addEventListener. they are stacked and run in order when needed [12:31] staar2: :D [12:31] cjroebuck has joined the channel [12:31] arcanis has joined the channel [12:33] bnoordhuis has joined the channel [12:33] kriszyp has joined the channel [12:33] aslakhellesoy: deoxxa: yes, dgram last worked in 0.4.12 [12:33] deoxxa: jetienne: you mean an actual getter? like defined with `get myProperty()'? [12:34] jetienne: deoxxa: yes. there are various syntax. i dont have any prefs on the syntax [12:35] deoxxa: ah, i don't think you can "stack" them as such - you could however maintain a stack on your own that does that [12:35] ovaillancourt has joined the channel [12:36] real_mjr has joined the channel [12:36] jetienne: deoxxa: hmm too bad. doing my own stack isnt possible in my case. as it would force every getter to not be standard... [12:37] RLa: why you need such functionality at all [12:37] Sami_ZzZ has joined the channel [12:38] RLa: tere staar2 :) [12:38] staar2: tere [12:38] agnat has joined the channel [12:39] sgimeno has joined the channel [12:39] RLa: btw, there is https://github.com/ncb000gt/node-cron [12:39] RLa: it uses setInterval/setTimeout functions under the hood [12:40] staar2: good ! [12:41] staar2: if error occurs inside the cronJob, job dies ? [12:43] TripC4 has joined the channel [12:43] robde has joined the channel [12:44] aliem_ has joined the channel [12:44] skm has joined the channel [12:45] Industrial: Say I have this bit of code: a=new Item(); a.save(function(e){if(e){return cb(e);cb()}); [12:45] Industrial: How do I execute that 10 times [12:45] cmr: Industrial: In a for loop [12:45] jetienne has joined the channel [12:45] Industrial: and then call the cb at the end of the 10'th time [12:45] satyr has joined the channel [12:45] cmr: for ( var i = 0; i < 10; i++ ) { ... } cb() [12:46] Industrial: cmr: You are misunderstanding, this is an async callback [12:46] Industrial: the save [12:46] booo has joined the channel [12:46] Industrial: can't just loop it [12:46] deoxxa: Industrial: check out async.js [12:47] Industrial: Without an async library :) [12:47] deoxxa: https://github.com/caolan/async [12:47] deoxxa: why without an async library? [12:47] Industrial: there has to be a code pattern for the easiest solution for this [12:47] robde has joined the channel [12:47] Industrial: because I'm working on a big project and can't just introduce another lib [12:47] deoxxa: well [12:47] deoxxa: you keep track of the number of callbacks [12:47] deoxxa: you decrement that number at the end of each operation [12:48] deoxxa: once it reaches zero, you call the final callback [12:48] deoxxa: there's a great implementation of that in that library [12:48] jetienne: Industrial: https://github.com/jeromeetienne/gowiththeflow.js/blob/master/gowiththeflow.js this one is 20line only. no dependancy. you can cut/past it in your functions [12:48] HardFu has joined the channel [12:48] HardFu has joined the channel [12:49] deoxxa: https://github.com/caolan/async/blob/master/lib/async.js#L91 << this can be pretty easily extracted too [12:49] wawan has joined the channel [12:49] deoxxa: jetienne: that's some horribly ugly code [12:50] jetienne: deoxxa: wont work tho, this function got dependancy [12:50] deoxxa: what, no it doesn't [12:50] deoxxa: replace _forEach with arr.forEach [12:50] jetienne: deoxxa: reread it [12:50] deoxxa: there's no dependency there [12:50] Industrial: like https://gist.github.com/01fd7dc86367f699454e ? [12:50] deoxxa: Industrial: that'd do it [12:51] deoxxa: well [12:51] deoxxa: actually no [12:51] deoxxa: you want to increment a counter inside that callback to .save [12:51] shripadk has joined the channel [12:51] jetienne: becarefull with closure too [12:54] frnkkpp has joined the channel [12:54] jetienne: deoxxa: hmm maybe i should expand it :) [12:55] jetienne: at the begining it was like 30lines [12:55] jetienne: and i made it short for the post story [12:55] jetienne: and now it is really unreadable :) [12:55] adambeynon has joined the channel [12:55] deoxxa: it's just way more complex than it needs to be [12:55] jetienne: i dont think you can od simpler [12:56] jetienne: it handle seq and par [12:56] deoxxa: ACTION points to async.js#L91 [12:56] jetienne: only seq can be simpler [12:56] simenbrekken has joined the channel [12:56] jetienne: deoxxa: what about it [12:56] deoxxa: it does exactly what Industrial was asking about [12:56] kwmiebach has joined the channel [12:57] jetienne: this is a good idea [12:57] jetienne: would it be better to split seq an par ? [12:57] jetienne: hmm nope it isnt possible or you dont have the chained api [12:57] texinwien has joined the channel [12:58] jetienne: and par is important for performance in many case [12:58] texinwien: complete idiot question here - I ran the windows.msi and installed node for local dev purposes. No where is it? [12:58] texinwien: No findy [12:59] Hakuhonoo has joined the channel [13:00] texinwien: am setting up this new backbone boilerplate and would like to try out the builder, which relies on node: https://github.com/tbranyen/backbone-boilerplate [13:00] yawNO has joined the channel [13:01] MooGoo: I'm tempted to try to install node on windows just for the experience [13:01] insin: *double click* Next Next OK [13:02] texinwien: insin: yeah, did that. Now what? :) [13:02] insin: [13:02] MooGoo: how many times does it need to restart windows to work [13:02] MooGoo: 3 or 4 at least [13:02] insin: texinwien: open a command prompt and type node -v [13:02] texinwien: MooGoo: well, it hasn't asked me to restart at all, yet, and the installation process has completed. [13:02] MooGoo: hmm 183 bits/s ... this is a good sign [13:02] insin: if it shows a version number, Node is correctly on your PATH [13:03] piscisaureus__ has joined the channel [13:03] texinwien: 'node' is not recognized as an internal or external command, operable program or batch file [13:03] texinwien: so it appears node is not in my path [13:04] deoxxa: well, where did you tell it to install? [13:04] texinwien: I hate windows command line [13:04] MooGoo: well that was dissapointingly easy [13:04] deoxxa: haha [13:04] texinwien: deoxxa: It didn't even ask me, and I've done a search in C:\ for 'node' and 'joyent' [13:04] texinwien: no luck. [13:04] Hakuhonoo: Hello, can someone help me with nodeJS debug problems? It stops not on breakpoints, when starts... It somehow connected with require() [13:04] insin: Program Files\nodesomething [13:04] MooGoo: texinwien: where does anything go in windows [13:04] texinwien: MooGoo: Where did it put node fo ryou? [13:05] MooGoo: Program Files (x86( [13:05] MooGoo: ) [13:05] MooGoo: like most things [13:05] MooGoo: it's actully a fair bit more predictable than nix installs [13:05] texinwien: aha, must've overlooked it - that's the first place I looked [13:06] MooGoo: tho it would be cool if the windows install updated the PATH [13:06] MooGoo: you know [13:06] texinwien: looking good - will add to path. [13:06] texinwien: yeah, would be nice [13:06] MooGoo: and even dropped a folder in the start menu [13:06] xerox: : ( https://gist.github.com/1606000 [13:06] xerox: out of nowhere [13:07] texinwien: was just sorta weird - installer ran, didn't ask where I wanted to install (or tell me where it installed) [13:07] MooGoo: yea...didnt even give me an ADVANCED option [13:07] texinwien: MooGoo: No folder in program files here (unless I'm blind, which is a distinct possibility) [13:07] MooGoo: I like clicking on the expert install option, it makes me feel like an expert [13:07] texinwien: MooGoo: They thought it was idiot-proof. Then I came a long and proved them wrong. [13:07] texinwien: Thanks for the assistance. [13:07] MooGoo: are you running 32 bit windows? [13:07] texinwien: 64 [13:08] icebox: xerox: it is down something or the file is locked, maybe [13:08] MooGoo: and you checked program files (x86) [13:08] MooGoo: sort folders by date modified [13:08] texinwien: MooGoo - I found the nodejs folder in (x86) [13:08] xerox: icebox: what does that mean? I just did node-irc's client.connect() [13:08] MooGoo: oh ok [13:08] texinwien: wasn't clear about that up at 14:04 [13:08] icebox: xerox: Error: write EPIPE [13:09] scott_gonzalez has joined the channel [13:09] texinwien: will add to path and start noding [13:09] enmand has joined the channel [13:09] MooGoo: I think the real fun comes when you try to start using modules in windows [13:09] cmr: Hope you have a toolchain. [13:10] qsobad has joined the channel [13:10] icebox: xerox: maybe the client is attempting to write on a dead connection [13:10] xerox: it could very well be, my connection died, then came back up, and on 'connect' it died [13:10] icebox: MooGoo: why? [13:10] xerox: icebox: it did do client.disconnect() first tho [13:11] insin: just tried it, it does add it to your PATH, but you have to log out and in on certain versions of Windows for that to take [13:11] MooGoo: dunno really...just a casual observation of many frusterated windows users on this chan [13:11] insin: certain modules need to compile things... boom [13:11] Hakuhonoo: Hello, can someone help me with nodeJS debug problems? It stops not on breakpoints, when starts... It somehow connected with require(). Any suggestions? [13:11] insin: generally it's fine though - npm works ok [13:11] icebox: xerox: because the other peer (the servr) has closed the connection [13:11] cognominal has joined the channel [13:12] xerox: icebox: the obvious question is, argh, how to have the process not die? : ) [13:12] davetayls has joined the channel [13:12] MooGoo: hmm yea it does add to the path [13:12] robde has joined the channel [13:14] texinwien: MooGoo: Just noticed that. didn't work for me, for some reason. [13:14] deeprogram_ has joined the channel [13:14] MooGoo: I'm sure a restart would make it work or logoff/on [13:16] icebox: texinwien: you need to close the console and to reopen it [13:17] Xenadi has joined the channel [13:17] texinwien: icebox: I'll be damned - I had already started and restarted the console a couple of times. [13:17] texinwien: but this time it worked [13:17] texinwien: I also 'refreshed' my path variable, in the meantime [13:17] texinwien: dunno what the magic was [13:18] texinwien: probably a pebkac :) [13:18] icebox: texinwien: did you change the system path or the user path? [13:18] Xenadi: anyone else had issues with the example http server code on windows 7, my browser cant connect [13:18] texinwien: system [13:18] icebox: Xenadi: no [13:19] icebox: texinwien: well.. usually chaging the path, closing and reopening the console does the job [13:20] texinwien: right. I didn't really change the path. I just changed the variable name from 'Path' to 'PATH' and saved [13:20] texinwien: which is what I mean by refreshing [13:20] texinwien: didn't change anything 'real' in it. anyway, it's running now. I'm so excited I may node all over myself. [13:21] icebox: texinwien: :) [13:21] icebox: Xenadi: did you resolve your issue? [13:21] Xenadi: nope [13:22] Xenadi: tried, reinstalling, different examples, but all http examples wont let any browser connect [13:22] icebox: Xenadi: error? [13:22] Xenadi: i can verify that the socket is being created because i can see it [13:22] Xenadi: no errors at all [13:22] Xenadi: it times out after a few minutes [13:22] icebox: Xenadi: check the firewall [13:22] christophsturm has joined the channel [13:22] Xenadi: windows firewall is off, bigfoot killer set to allow [13:23] icebox: Xenadi: well... what the browser says? timeout? [13:23] Xenadi: yeah [13:23] kyonsalt has joined the channel [13:23] Xenadi: Firefox can't establish a connection to the server at 127.0.0.1:1337. [13:23] icebox: Xenadi: are you pointing to the correct port? [13:23] Xenadi: yes [13:23] christophsturm: are there up to date ubuntu packages for node? [13:24] icebox: Xenadi: do you see Server running at http://127.0.0.1:1337/ message? [13:24] swestcott has joined the channel [13:25] Xenadi: so u want me to try something like http://127.0.0.1:1337/blah?blah=true [13:25] Xenadi: that doesnt work either, just says connecting [13:26] icebox: Xenadi: no... I was wondering if the server is started correctly [13:26] texinwien: Xenadi: When you started the server, did you see the 'server running' message? [13:26] Xenadi: yes [13:26] Xenadi: server running at http://127.0.0.1:1337/ [13:26] texinwien: huh. worked flawlessly for me. wish I could help. [13:26] Xenadi: its a copy paste of the example scrpt on the main page [13:26] Xenadi: yeah, cant find anyone who can :( [13:27] Cromulent has joined the channel [13:27] icebox: Xenadi: indeed I don't think it is a node issue... [13:27] Xenadi: works fine on my old xp laptop [13:27] texinwien: i copy/pasted the same thing - just installed node on win7. works perfectly. [13:27] Xenadi: xampp works fine on the same box [13:27] icebox: Xenadi: here w7 [13:27] Xenadi: even the same port [13:27] icebox: Xenadi: w7 64 bit [13:27] Xenadi: yes 64bit [13:28] icebox: Xenadi: Chaneg the port, as a try [13:28] texinwien: am thinking some kind of security - where you had to 'allow' xampp when you installed it, and will have to allow node, as well. [13:28] Xenadi: done, same thing [13:28] Xenadi: well windows firewall is disabled, UAC disabled, no other firewalls on the system [13:29] Xenadi: i do have windows security essentials installed, but my laptop has that too, and no issues [13:30] subhaze has joined the channel [13:30] willwhit_ has joined the channel [13:30] Xenadi: my only thought is that node doesnt like Bigfoot Networks Killer Ethernet Controller my nic [13:30] beawesomeinstead has joined the channel [13:30] shinuza has joined the channel [13:30] patrickgamer1 has joined the channel [13:30] icebox: Xenadi: I have not idea what is that "Bigfoot..." [13:31] EvRide: its an expensive ass network card [13:31] jetienne has joined the channel [13:31] Xenadi: its a gaming network card with some nice QOS [13:31] Xenadi: mine is onboard [13:31] icebox: Xenadi: nice [13:31] Xenadi: i got the new gigabyte socket 2011 board [13:32] Xenadi: other people have had the same problem [13:32] Xenadi: http://stackoverflow.com/questions/8553937/basic-node-js-examples-not-working-on-windows-7 [13:32] willwhite has joined the channel [13:32] amigojapan has joined the channel [13:32] cognominal has joined the channel [13:32] icebox: Xenadi: telnetting to 127.0.0.1 and 1337? [13:32] garrensmith has joined the channel [13:33] zilch_ has joined the channel [13:33] jetienne has joined the channel [13:33] Xenadi: ill download putty, dont think win 7 has telnet [13:33] EvRide: sure it does [13:34] Xenadi: ok putty looks like its connected, but no data [13:34] icebox: Xenadi: ah... [13:35] cmr: Xenadi: I congratulate you on your persistence in this issue; I hope it is resolved. [13:35] cesconix has joined the channel [13:35] fairwinds has joined the channel [13:35] Xenadi: thx cmr, i thrive on issues that are difficult to solve, probably why i get paid doing it :P [13:35] icebox: Xenadi: you need to type GET / [13:35] cmr: icebox: shouldn't it be HTTP/1.1 GET / [13:36] Xenadi: putty doesnt look like its going to let me type anything [13:36] cmr: Neat, GET / works [13:36] erichynds has joined the channel [13:36] texinwien: more of a 'working with JSON' question, but I guess it fits in here... [13:37] sylvinus has joined the channel [13:37] Xenadi: meh putty doesnt like it ill install telnet [13:37] cmr: Xenadi: Windows has telnet builtin [13:37] Xenadi: win7 doesnt [13:37] EvRide: yes it does [13:37] cmr: Yes it does. [13:37] Xenadi: gotta go through extra features [13:37] texinwien: how do you query for a specific object that's nested deep in a JSON string and has "name":"name I'm looking for"? [13:37] cmr: It's an optino somewhere in the control panel iirc [13:38] thurmda has joined the channel [13:38] EvRide: +R, type in cmd and press ok. type in telnet /? for help [13:38] texinwien: I'm coming from a pretty heavy XML / XPath background, so I know how I'd do it in XPath. [13:38] icebox: texinwien: you need to know the path... as myobj.myobj2.mynesteddobj.name [13:39] thurmda: Does anyone know how I would start multiple node processes via `npm start` [13:39] Xenadi: hmm the telnet session is behaving very strangely [13:39] gbatcisco has joined the channel [13:39] texinwien: ok, so if mynestedobj is in an array, I'd just need to loop through the array and find the one with obj.name="name I'm looking for"? [13:40] kuhrt has joined the channel [13:40] thurmda: What would my package.json scripts.start value be? [13:40] Xenadi: so i connect and get a blinking cursor, but when i type in GET / i dont see the characters and nothing happens even after i press enter [13:40] icebox: texinwien: for instance myobj.myobj2.mynesteddobj[2].name [13:40] cmr: thurmda: you want to start them serially? [13:41] cmr: thurmda: or all at once? [13:41] texinwien: yes, but that assumes I know which index in the array has the object I want [13:41] cmr: texinwien: If you don't know, yes you need to loop [13:41] texinwien: I'm going the other way - I have an array of objects, and I want to find the one that has a specific name value. [13:41] slaskis: texinwien: http://stackoverflow.com/questions/777455/is-there-a-query-language-for-json [13:41] Xenadi: ok GET / is returning nothing [13:41] icebox: texinwien: it was a syntax example [13:41] kuhrt: Hi I have a very simple problem but I am new to working with Node so it's confusing me. I am trying to get all the data froma response but the "data" event is streamed, which event can I use to get the data when it has all returned? [13:41] burningdog has joined the channel [13:42] icebox: texinwien: mtest for yobj.hasOwnProperty("name") [13:42] icebox: texinwien: test for myobj.hasOwnProperty("name") [13:42] texinwien: icebox: Thanks, am pretty familiar with javascript, JSON and the syntax. [13:42] thurmda: all at once [13:42] thurmda: well [13:42] thurmda: one first then any others [13:42] texinwien: slaskis: Thanks, I had come across that article. Any thoughts on any of the JSON query options presented? [13:43] thurmda: I have a main service and then additional workers [13:43] robi42 has joined the channel [13:43] slaskis: texinwien: no, i haven't needed any like those yet. i'm looking for another one that was popular sometime in the last 6 months but couldn't find it [13:43] thurmda: I tried "start": "node bin/uploadService.js; node bin/workers/*", [13:43] IrishGringo has joined the channel [13:43] icebox: Xenadi: it should return "Hello world" [13:43] cmr: kuhrt: you want a pattern like: http://paste.pocoo.org/raw/534221/ [13:44] texinwien: icebox: OK, thanks. That confirms my 'suspicion'. The 'standard' way is to loop through. [13:44] thurmda: but not what I thought [13:44] texinwien: am using underscore.js for dealing with collections, mostly. [13:44] texinwien: will probably continue to just rely on that. [13:44] kuhrt: cmr: ah ok of course, thanks! [13:44] cmr: thurmda: "node bin/uploadService.js &; ..." [13:44] Xenadi: also very strange, if i start the script with node debug example.js it looks fine, but my browser gets a message to say remote debugging session already exists [13:45] icebox: texinwien: or a library (as you said) or a custom traverse function [13:45] shanebo has joined the channel [13:45] Poetro has joined the channel [13:45] icebox: gotta go... bye [13:45] texinwien: icebox: ciao - thanks for the tips [13:46] heavysixer has joined the channel [13:47] dodo_ has joined the channel [13:47] lazyshot has joined the channel [13:48] thurmda: Linux is complaining about the ; now bash-3.2$ node bin/uploadService.js &; node bin/youtubeWatcher.js bash: syntax error near unexpected token `;' [13:48] Margle has joined the channel [13:48] cmr: 3.2, really? [13:48] thurmda: yea [13:49] cmr: That's almost 4 years old. [13:49] thurmda: I know I've seen this done but I can't find it on Google now [13:50] cmr: Anyway guess that's not valid syntax, sorry about that :S [13:50] case_: thurmda, it's ; or &, not both [13:50] Xenadi: well im completely out of ideas. [13:50] cmr: Indeed, drop the ; [13:50] thinkfast has joined the channel [13:50] k1ttty has joined the channel [13:51] thurmda: ha [13:51] thurmda: that is it! [13:51] thurmda: oh [13:51] yawNO has joined the channel [13:51] thurmda: I thought that didn't work before but it does [13:52] thurmda: I'm confused a bit after integrating hook.io [13:52] thurmda: any hook.io users in here? [13:52] Xenadi_ has joined the channel [13:52] thurmda: I had some nice loggin to console before I intergrated hook.io into my project [13:53] thurmda: Hook.io is great but it's bombing my logging [13:53] thurmda: anyone know how to make it run silent? [13:53] fumanchu182 has joined the channel [13:53] thurmda: Or pipe it's output elsewhere? [13:54] amigojapan has joined the channel [13:54] fermion has joined the channel [13:55] vkareh has joined the channel [13:56] neurodrone has joined the channel [13:57] andorraclaim has joined the channel [13:57] cosmincx has joined the channel [14:00] adrianmg has joined the channel [14:00] e6nian has joined the channel [14:00] k1ttty has joined the channel [14:01] adrianmg has left the channel [14:01] yawNO has joined the channel [14:02] andorraclaim_ has joined the channel [14:05] lduros has joined the channel [14:07] mmalecki: thurmda: {debug:false} [14:08] yawNO has joined the channel [14:08] thurmda: omg, really? [14:08] tdegrunt_ has joined the channel [14:08] thurmda: where in the constructor call? [14:10] k1ttty has joined the channel [14:11] AaronMT has joined the channel [14:11] thurmda: var hook = new Hook({name: "uploader", debug: false}); [14:12] liar__ has joined the channel [14:12] thurmda: not doing it [14:12] fermion has joined the channel [14:12] thurmda: do I set debug false some other way? [14:12] tomlion has joined the channel [14:13] k1ttty has joined the channel [14:14] orangevinz has joined the channel [14:15] louissmit has joined the channel [14:16] pauls1 has joined the channel [14:16] thurmda: just found that has changed to {silent: true} [14:17] bshumate has joined the channel [14:17] bshumate has joined the channel [14:19] anacrolix has joined the channel [14:19] cesconix has joined the channel [14:20] mmalecki: thurmda: oh, derp [14:20] mmalecki: yeah, it changed, forgot about it [14:20] mmalecki: sorry [14:22] davidsklar has joined the channel [14:22] Venom_X has joined the channel [14:24] urlisse has joined the channel [14:24] postwait has joined the channel [14:25] deeprogram has joined the channel [14:25] thomblake has joined the channel [14:25] thomblake has left the channel [14:26] shinuza_ has joined the channel [14:26] jstash has joined the channel [14:29] zmbmartin has joined the channel [14:30] zmbmartin: Anyone use browserling? Are the paid plans much better performance? The free look was extremely slow. [14:32] zitchdog has joined the channel [14:32] chjj: bnoordhuis needs a gravatar, at some point i'll begin thinking he's really an octocat [14:33] socketio\test\88 has joined the channel [14:34] AD7six_ has joined the channel [14:34] piscisaureus_ has joined the channel [14:34] carlyle has joined the channel [14:34] devdazed has joined the channel [14:35] cmr: chjj: I am a cuddly alien baby! https://secure.gravatar.com/avatar/46042ea486a5817d8faf09d187fee487?s=140&d=https://a248.e.akamai.net/assets.github.com%2Fimages%2Fgravatars%2Fgravatar-140.png [14:37] adrianmg has joined the channel [14:37] cmr: (His name is Ted) [14:37] adrianmg has left the channel [14:37] c4milo has joined the channel [14:37] AAA_awright has joined the channel [14:41] patrickgamer1 has left the channel [14:42] willwhite has joined the channel [14:45] indutny has joined the channel [14:45] raincole_ has joined the channel [14:46] sam_b has joined the channel [14:46] socketio\test\83 has joined the channel [14:46] AndreasMadsen has joined the channel [14:47] robde has joined the channel [14:47] sam_b has joined the channel [14:47] myndzi has joined the channel [14:48] sam_b has joined the channel [14:48] myndzi: recommended template engines anybody? [14:48] snearch has joined the channel [14:48] socketio\test\29 has joined the channel [14:48] cmr: myndzi: plates has caught my attention [14:49] myndzi: ACTION looks [14:49] jgornick has joined the channel [14:50] myndzi: this one? https://github.com/flatiron/plates [14:50] cmr: yeh [14:50] sam_b has joined the channel [14:50] bkaney has joined the channel [14:50] insin: jade [14:50] SamuraiJack has joined the channel [14:50] cmr: ACTION despises jade [14:51] sam_b has joined the channel [14:51] rwaldron has joined the channel [14:51] myndzi: yeah, i'd kind of like my html to look like html [14:52] blueadept has joined the channel [14:52] myndzi: i ran into something called doT too, (though it seemed like self promotion) and it left me wondering why in the world you would use double curly braces as delimiters in a language that uses curly braces [14:52] myndzi: a three line sample had my eyeballs going wat [14:52] myndzi: i'm not really sure i even need any templating, i'm just curious and looking around [14:53] Cromulent has joined the channel [14:53] insin: I like double curly braces, probably just my years of using Django though [14:54] deeprogram has joined the channel [14:54] cmr: I don't mind them. I like them better than <% [14:54] chrisvwebdev has joined the channel [14:55] unomi has joined the channel [14:56] myndzi: {{if () {}} just looks horrible to me [14:56] cmr: missin' a brace ;) [14:56] myndzi: naw, multi-line if [14:56] myndzi: that's why it's confusing! picking out braces amidst a sea of braces, lol [14:56] insin: raw javascript in templates? I'd rather not [14:57] cmr: plates is the only template engine I would consider right now. [14:57] myndzi: i'm trying to figure out what it looks like and having trouble haha [14:58] myndzi: ah wait, i get it [14:58] insin: are there any examples of plates being used in the large? [14:58] cmr: Pretty much you give it a chunk of example html, and then tell it how your data object maps to it. [14:58] Hanspolo has joined the channel [14:58] andorraclaim has joined the channel [14:59] myndzi: yeah, i was like "where's the html?" (expecting more html than was used in the examples) [14:59] myndzi: isn't it rather unwieldy to assign all your html into a single variable? [14:59] myndzi: how do you deal with that cleanly? put it in another file? [14:59] cmr: That's what I'd do [14:59] myndzi: i could deal with that [14:59] bkaney has joined the channel [15:00] myndzi: seems it's hardly templating anymore at that point [15:00] myndzi: but it doesn't really matter [15:00] cmr: It really isn't. [15:00] myndzi: 'getting the job done' is more what i care about ;) [15:00] cmr: You could drop in the non-mapped HTML and have an accurate mockup [15:00] myndzi: yeah, i see [15:00] myndzi: it's pretty interesting [15:01] myndzi: the page was talking about DOM stuff being slow, but parsing HTML in javascript can't be terribly fast either..? [15:01] yawNO has joined the channel [15:01] myndzi: or perhaps it uses simpler / lazier processing? [15:01] cmr: regexps [15:01] zemanel has joined the channel [15:02] cmr: And a small parser [15:02] cmr: https://github.com/flatiron/plates/blob/master/lib/plates.js [15:02] myndzi: yeah, i was told very firmly never to use regexes to parse html ;) [15:02] cmr: All of plates. [15:02] myndzi: (but if you're writing the html i doubt it matters) [15:02] cmr: It's not just regexps [15:02] deedubs has joined the channel [15:03] myndzi: nice and small, i like [15:03] myndzi: dunno if i'd wind up using it for our web app, but the project i want to start could give it a run and see how it goes [15:03] cmr: I'll be using it on silenceofeden.net [15:04] cmr: If it doesn't go well, it's easy to refactor out [15:04] myndzi: ACTION runs down his mental checklist [15:04] myndzi: there was something else i was going to look up before i got started, but now i'm having a hard time remembering it, heh :P [15:04] colinclark has joined the channel [15:04] napperjabber has joined the channel [15:04] cmr: Somewhere out there is a template engine similar to plates but better. I saw it once and I've never been able to find it since :( [15:05] aheckmann has joined the channel [15:06] myndzi: better in what way? [15:07] cmr: It had a more explicit syntax, iirc, and the javascript looked less odd. [15:07] cmr: As soon as I find it I'll let you know [15:07] Alpha|home has joined the channel [15:07] myndzi: https://github.com/hij1nx/weld ? [15:07] insin: http://beebole.com/pure/ ? [15:08] cmr: Weld [15:08] cmr: That's it [15:08] myndzi: :) [15:08] myndzi: you searched for templating [15:08] myndzi: i searched for anti-templating :D [15:08] cmr: heh [15:08] cmr: I guess that's what this is. [15:08] myndzi: well, that's what plates calls itself [15:08] cmr: weld is "template antimatter" [15:08] cmr: Which is close enough [15:08] bkaney has joined the channel [15:09] chjj has joined the channel [15:10] cmr: Let's see how accurate my memory is [15:10] myndzi: plates basically happens before sending the html, weld happens after [15:10] myndzi: it seems [15:10] chjj_ has joined the channel [15:10] myndzi: (server side vs client side) [15:11] insin: ACTION has a horrible-looking template engine which does both, all in code :D [15:11] cmr: plates also runs on the clientside. [15:11] insin: Hmm, so caustic is a bit more like Weld then: https://github.com/visionmedia/caustic [15:12] amasad has joined the channel [15:14] skm has joined the channel [15:14] cmr: myndzi: thanks for finding that :D [15:15] cmr: However on a memory refresh, I think flatiron is better in that it takes a string and not a DOM element, which more closely matches my usecase. [15:15] jaha has joined the channel [15:16] deoxxa: oh hello, are we talking about template engines? :) [15:16] AAA_awright: myndzi: Jade [15:17] deoxxa: allow me to put in my 2c: https://github.com/deoxxa/node-ginger [15:18] carlyle has joined the channel [15:18] insin: *everyone scans for their must-haves, must-have-nots* [15:18] insin: ☑ template inheritance [15:18] cmr: If "ctx.add_template("simple", new Function("ctx", compiler.compile(Ginger.Parser.parse(fs.readFileSync("res/simple.twig").toString()))));" weren't so ugly [15:19] AAA_awright: That's... like a standard template... Jade is cool because it defines a structure at the DOM level, so I have my own DOM render implemented [15:19] deoxxa: cmr: that's the output - you don't need to look at it, ever [15:19] deoxxa: unless you want to, of course [15:19] cmr: deoxxa: ohhhhh [15:19] deoxxa: the example usage is out of date, too [15:19] npa has joined the channel [15:19] cmr: Well that's unuseful [15:19] deoxxa: sorry :( [15:19] myndzi: suddenly, unicode! [15:20] AAA_awright: I dearly want to move away from HTML representations of the DOM and move to EXI [15:20] deoxxa: i should fix that example usage, actually [15:20] myndzi: AAA_awright: if i'm making a web page, i'd rather write my html in html ;) [15:20] myndzi: i like the idea of compiling the templates like that, too [15:21] myndzi: the curly braces are slightly less annoying when padded out with another symbol :P [15:21] AAA_awright: Who uses HTML for structural design? I use Jade, and for page content we can just parse HTML, or any other markup language (Docbook, Mediawiki, Markdown) [15:21] thomblake has joined the channel [15:21] thomblake has left the channel [15:21] insin: ooh, ginger is very Django-ey [15:21] AAA_awright: NOT A GOOD THING [15:22] deoxxa: AAA_awright: how would you improve it? (looking for honest criticism here) [15:22] deoxxa: if there's actual problems, i want to know about it [15:22] deoxxa: s/it/them/ [15:22] deoxxa: s/it/them/ [15:23] insin: there needs to be a huge list of these with checkboxes you can use the ones you don't event want to see for personal taste reasons :) [15:23] cmr: insin: Sounds like a great idea for a site. [15:23] pauls1: strange question: anyone know if the behavior of something like for ( x in array) { … } changed near or in node 0.6.6? it broke a few things for me [15:23] LuckySMack has joined the channel [15:23] cmr: pauls1: you should never use for-in on an array. [15:23] myndzi: insin: haha, i like the idea [15:24] myndzi: ....but what templating engine would you use for it!?!? [15:24] insin: cmr: the list of categories could be endless, though, and would likely be judged on surface rather than experience :) [15:24] insin: my own, of course! [15:24] insin: :p [15:24] cmr: pauls1: that iterates over the keys, not the indices [15:25] insin: you could have each one render its own section :) [15:25] cronopio has joined the channel [15:25] myndzi: i think i have a good jumping-off point now, thank you guys for your input [15:25] myndzi: just looking at the list of templating systems on the nodejs site was like D: [15:25] cmr: .. for (x in [1, 2, 3]) { print(x); } [15:25] catb0t: "0"; "1"; "2" [15:25] gsmcwhirter has joined the channel [15:25] deoxxa: i really need a live demo thing for ginger [15:26] myndzi: i gots me sql, nodejs will let me avoid rewriting a bunch of code for validation, if i wind up needing some sort of templating i have a good range to pick from depending on the case [15:26] myndzi: now i just have to uhh.. write some code, haha [15:26] cmr: Am I confused about for-in on arrays? [15:26] myndzi: i was all gung ho about an hour ago, then i woke up i guess [15:26] joshfinnie has joined the channel [15:26] AAA_awright: deoxxa: It's the nature of mixing template code and other code that makes it ugly, and slightly-more-difficult to preparse into a DOM structure [15:27] pauls1: cmr: i had some doubts about for ( i in .. ) when I used it on a few lines some months back but found it worked unexpectedly there. lucky to have stuck to my gut feeling and used an int counter in most other places. thanks for clarifying [15:27] cmr: pauls1: I'm not certain that I'm right [15:27] lperrin: pauls1: you can also use forEach [15:27] pauls1: lperrin: ah yes i use forEach a lot, and async (<3) [15:28] sriley: well with the index you can then access the value of the array [15:28] AAA_awright: pauls1: And in any event, you NEED to use for(var i in ...) in regular Javascript. Note "var". [15:28] pauls1: cmr: well it seems to be working! I actually found this bug appear in two different places over the last few days in unexpected places, so it was kinda boggling at first [15:28] pauls1: AAA_awright: yep that's what i tend to do in my clientside code [15:28] ritch has joined the channel [15:28] sriley: the var doesnt have to appear there, just as long as its scoped correctly (not in global scope) [15:28] ritch has left the channel [15:28] Cromulent has joined the channel [15:29] AAA_awright: Normally that doesn't happen, but yeah [15:29] AAA_awright: pauls1: You especially don't want to be defining a global in server side [15:30] cmr: Am I wrong about for-in iterating over keys in arrays? [15:30] deoxxa: AAA_awright: i agree, it breaks html pretty badly. i'm not just using it for html though, it's also going to be used for email templates and some config file templates for stuff at work. it's not an html specific solution, pretty much, so there's probably better options for html-only composition. [15:30] Neil: Can I specify the name of an npm when publishing? [15:30] AAA_awright: That would be a better use [15:30] myndzi: a little side-question that has more to do with js programming in general: would it be obnoxious to "unroll" a number of objects on load (<10) so that the methods all perform very specific, short pieces of code (rather than looping/varying the parameters each time a method is called)? [15:30] deoxxa: cmr: it does iterate over keys [15:31] garrensmith has joined the channel [15:32] insin: things are fiddly in different ways for element-level templates, though [15:33] pauls1: myndzi: if it's something you do a lot it sounds like it might be a good step towards better code factoring [15:33] pauls1: myndzi: but i don't know anything about what you're actually doing, from what you said [15:33] jtsnow has joined the channel [15:34] insin: tag browsing on npmjs.org seems to be busted [15:34] AAA_awright: The entire website is very broken... [15:34] triptec has joined the channel [15:34] AAA_awright: #Node.js, please, PLEASE, publish git clone URLs for us non-npm users [15:35] deoxxa: why do you not use npm? [15:36] deoxxa: actually curious here [15:36] trotter has joined the channel [15:36] meso has joined the channel [15:36] stagas: insin: this is a nice npm site http://blago.dachev.com/modules [15:36] insin: nice, thanks [15:36] deoxxa: ooh that is pretty [15:36] meso has joined the channel [15:36] myndzi: pauls1: true enough, i didn't want to get too offtopic [15:37] insin: "template" - found 286 out of 415 [15:37] captain_morgan has joined the channel [15:37] AAA_awright: deoxxa: Because it's bloated and horribly designed, because it blindly copies all the other awful decisions of other package managers [15:37] insin: 4151 [15:37] myndzi: it's just tetris, but we tetris folks care quite a bit about responsiveness [15:37] brianc1 has joined the channel [15:37] triptec has joined the channel [15:37] myndzi: i had some thoughts for optimizing things, such as having the piece have a method for each rotation that explicitly places itself on the field, for example [15:37] AAA_awright: I should write a paper on the topic it might end up being easier... [15:38] myndzi: these could be dynamically generated so that it's easy to modify too i guess [15:38] fangel has joined the channel [15:38] cmr: AAA_awright: what is your ideal package manager? [15:38] myndzi: i'm considering storing the main data in a single integer and using bitwise operations too ;) [15:38] fatjonny has joined the channel [15:38] MooGoo: tetris isn't exactly the spaziest game out there [15:39] MooGoo: people have been making tetris clones in JS for like 10 years, they run fine even in IE6 [15:39] myndzi: sure, but it's hard to explain to people who aren't really into tetris what matters and why [15:39] myndzi: yeah, people have been making TERRIBLE tetris clones in js for years :P [15:39] MooGoo: all tetris clones are terrible [15:39] myndzi: 99% of tetris clones fail hard on at least one point, frequently more than that [15:39] cmr: ACTION still plays the original [15:39] AAA_awright: deoxxa: Here's a better way to do packages for Node.js and FAR simpler: [15:39] AAA_awright: $ cat .gitmodules [15:39] AAA_awright: [submodule "node_modules/jade"]/path = node_modules/jade/url = git://github.com/visionmedia/jade.git/npmname = jade/version = master [15:40] MooGoo: why no one will make a tetris attack clone is beyond me [15:40] AAA_awright: Use git submodules, define compatible versions there. [15:40] myndzi: ha, nintendo already made like four [15:40] c4milo has joined the channel [15:40] myndzi: they keep rebranding it [15:40] MooGoo: yea [15:40] myndzi: puyo puyo too [15:40] MooGoo: but I want a JS one [15:40] myndzi: hehe [15:40] joshkehn has joined the channel [15:40] myndzi: anyway. i did a little experiment [15:40] joshkehn has left the channel [15:40] MooGoo: considering I've basiclly lost my DS long ago [15:40] deoxxa: AAA_awright: we use git submodules at work for our in-house code - it's painful [15:40] myndzi: i took a js/canvas tetris game and fixed it so it didn't sock on most counts, then experimented with the input for extra finesse [15:41] triptec has joined the channel [15:41] AAA_awright: cmr: Portage is the best package manager I've used, I use Gentoo on my desktop and four servers [15:41] napperjabber has joined the channel [15:41] deoxxa: ACTION understands now [15:41] myndzi: when i saw how fairly simple the code wound up, i'm more interested now in making canvas/js interface for king of stackers (which is a turn-based tetris game i've done work on) [15:41] cmr: AAA_awright: I knew that was coming [15:41] cmr: AAA_awright: Used paludis? [15:41] myndzi: one of the annoying things about KoS is that it's php in back and js in front, so you have to write most of the code twice or trust the client [15:41] myndzi: thus, node.js :D [15:41] AAA_awright: deoxxa: I can't imagine you're using them right... submodules works FAR better than npm, there's absolutely zero configuration [15:42] myndzi: extra bonus that not only is the code the same, it can be literally inherited from the same file [15:42] AAA_awright: cmr: Haven't heard of it [15:42] myndzi: anyway. i know browsers aren't the ideal gaming platform, but i want to do everything within my power... [15:42] fangel has joined the channel [15:42] deoxxa: submodules require you to go into each dependent project and update the commit they're pinned to every time you update a depended-on library or module [15:42] MooGoo: I spent a lot of time optimizing some functions for this canvas demo I was working on, including using new Function to pre compile appropriate functions, as to get rid of needless conditional checks every step of the animation [15:42] deoxxa: that gets really old, really quick [15:42] MooGoo: and used bitwise trickiness to speed some things up in some cases [15:43] deoxxa: so they're definitely not zero configuration [15:43] myndzi: the most important concern to tetris players is timing accuracy [15:43] MooGoo: but these days js implamentations do a pretty damn good job on their own [15:43] myndzi: if you hold down the button for the same amount of time, it needs to be reflected in the game with minimum variance [15:43] shanebo has joined the channel [15:43] MooGoo: you should be able to get 60 fps easily, which would be very responsive [15:43] myndzi: so all the drawing code isn't as important, but the less it runs, the more time there is for the cpu to get other stuff out of the way and respond to a keypress [15:43] cmr: AAA_awright: it's inspired by portage (is even compatible with ebuilds) but is faster and tons more extensible. Instead of having overlays, repositories are something you can install. Same with system users, instead of having the exheres (equivalent of ebuild) make them itself, it installs it via the normal package manager methods. [15:44] AAA_awright: deoxxa: That wouldn't be configuration, but even considering it so, I don't EVER have to go into child modules and handle their dependencies [15:44] myndzi: yeah, i may have said it a bit wrong; consistency is king [15:44] myndzi: players can deal with 3 frames' lag [15:44] trotter has joined the channel [15:44] cmr: AAA_awright: exherbo uses it exclusively [15:44] cmr: (also available on gentoo) [15:44] myndzi: but if the DAS varies between 4 and 8 frames, it'll piss em right off [15:44] myndzi: erm. auto-shift; the "repeat delay" like when you hold a key on your keyboard [15:44] AAA_awright: deoxxa: It's trivial to work out dependencies automatically without having to do it by hand, thats what Node.js SHOULD be doing [15:45] myndzi: it's important to fast play :) [15:45] mlin has joined the channel [15:45] deoxxa: AAA_awright: say you're using express (or anything else). they update the library, what happens when you next do a build of your dependant project? [15:45] MooGoo: 3 frame lag at 60fps ~= 48ms ... I'd notice [15:45] AAA_awright: And then you don't run into the awful global namespace issues [15:45] MooGoo: but that's just the snes gamer in me.. [15:45] myndzi: 3 was quite an exaggeration, but not that far off from like, tetrisfriends [15:45] ryanfitz has joined the channel [15:45] myndzi: nobody's ever measured TF though [15:45] myndzi: i can feel the frame difference between swing and slick in nullpomino [15:45] myndzi: i can play with 2 frames less DAS at about equivalent skill [15:46] strevat_ has joined the channel [15:46] josh-k has joined the channel [15:46] jakehow has joined the channel [15:47] jetienne_ has joined the channel [15:47] AAA_awright: deoxxa: What does it matter if they push new commits? You continue using the code, by default... How would one tell if the new commit is compatible with your code? [15:47] rauchg has joined the channel [15:48] AAA_awright: jade doesn't use semantic versioning yet, but that's what this line is: version = master [15:48] Destos has joined the channel [15:48] ank has joined the channel [15:48] deoxxa: well, the version number is meant to reflect whether or not changes will break compatibility [15:48] AAA_awright: You could just as easily use version = 4 and use any tag of v4.*.* [15:49] deoxxa: can you do that with submodules? really? [15:49] AAA_awright: Yeah, it's an extra line in .gitmodules [15:49] AAA_awright: Now, you have to have the script to resolve those version stuff [15:49] deoxxa: to check out any tag that matches a certain pattern? [15:50] nibblebot has joined the channel [15:50] AAA_awright: Git doesn't do that automatically, but it's a simple script [15:50] monteslu_ has joined the channel [15:50] nibblebot has joined the channel [15:50] deoxxa: ok, so it's no longer "just submodules" [15:51] Neil has joined the channel [15:51] deoxxa: i get the feeling you like doing things differently just to be different :( [15:51] russfrank: how can I test a function which takes a callback with jasmine? I'm for some reason not really understanding the docs [15:51] AAA_awright: Well, it pretty much is, it just adds some metadata to them to define upgrade paths and help with conflict resolution [15:51] xetorthio has joined the channel [15:51] bodisiw has joined the channel [15:52] AAA_awright: deoxxa: No, I just don't like using brain-dead software [15:52] AAA_awright: Especially when git submodules solved 80% of the problem, there's some major NIH syndrome going on [15:52] cmr: AAA_awright: and when not using git? [15:53] triptec has joined the channel [15:53] captain_morgan has joined the channel [15:53] AAA_awright: Well then you're probably downloading an application and not a library, and you'll have all the Node.js modules with correct versions provided for you [15:54] cmr: No, when writing an application/library. [15:54] AAA_awright: If you don't want to do revision control just clone with --shallow=1 [15:54] isaacs has joined the channel [15:54] cmr: What if I'm using hg or fossil. [15:54] cmr: I can't use git submodules then. [15:54] cmr: And now I suddenly have no way to pull in dependencies but manually. [15:54] SirFunk: Question: I have a project using nodejs, socket.io and amberjs (client). There are some things that i need to handle asyncroniously from server->client (updating items on bills) and some things that need to be done syncroniously (making sure a payment goes through before moving on to the next 'page'). How would you handle this. A.) use ajax calls from the client to express or something on the server for the syncronious calls? Or B.) pipe [15:54] SirFunk: everything through socket.io and have the server send a message back to the client when payment processes successfully and then the client will listen for that and continue? [15:54] AAA_awright: That's no argument, what if I'm not using npm? I can't use npm tarballs then [15:55] AAA_awright: You can't argue "Well what if I don't want to adopt the proposed solution" as a reason against the solution :p [15:55] c4milo: isaacs: yt? I'm having a weird behavior with npm and wanted to double check it with you [15:55] cmr: AAA_awright: using git submodules isn't portable across any of the other SCM's somebody might want to use. npm is. [15:56] AAA_awright: cmr: npm isn't portable against any of the other package managers people might want to use, your argument is invalud [15:56] cmr: AAA_awright: How so? [15:56] cmr: All it needs is a package.json [15:56] AAA_awright: If you don't want to use git as revision control, again, --shallow=1 [15:56] richardr has joined the channel [15:56] AAA_awright: You can certainly use some other revision control too [15:56] cmr: Ah, package managers. [15:57] cmr: But package.json is portable. [15:57] cmr: (In theory) [15:57] Edy has joined the channel [15:57] geekbri has joined the channel [15:57] c4milo: isaacs: I have a project that has superagent as dependency as well as libraryxyz. libraryxyz has also superagent as dependency but it's a patched version and it's a url dependency. When installing my project npm is telling me that libraryzxy is going to use the superagent dependency of my project which is undesirable. Any ideas? [15:58] AAA_awright: cmr: gitmodules is an ini-format file, dead simple to read [15:58] cmr: AAA_awright: Can't clone a git repo if you ain't got git. [15:58] deoxxa: package.json is a json-format file, dead simple to read [15:58] tomlion has joined the channel [15:58] cmr: Anyone can wget a tarball. Or even netcat a tarball. [15:58] AAA_awright: cmr: You're complaining you can't download a package if you don't have the package manager? Why? [15:58] deoxxa: how exactly is package.json not portable anyway? you could pretty simply publish an npm module to another service... [15:58] cmr: AAA_awright: Git isn't a package manager, that's the thing. [15:59] cmr: AAA_awright: It's a SCM [15:59] AAA_awright: It's 80% of one [15:59] tomlion has joined the channel [15:59] cmr: Dependency resolution is more than 20% of a package manager. [16:00] AAA_awright: When compared to git's native utilities, that's what remains [16:00] xtianw has joined the channel [16:00] AAA_awright: It's simple is x.version > y.version and if so clone [16:00] draginx has joined the channel [16:00] AAA_awright: *It's simply: [16:01] draginx: Why am I getting TypeError: Cannot set property 'email' of undefined for expressjs if I'm just doing req.session.email = "test@test.com"; ? [16:01] AAA_awright: ... That's simplified down but that's the flowchart [16:02] deedubs has joined the channel [16:03] Destos has joined the channel [16:03] nathanpalmer has joined the channel [16:03] blueadept has joined the channel [16:03] blueadept has joined the channel [16:04] cmr: So that takes care of npm install. What about the rest? [16:05] isaacs: cmr: ++ [16:05] cmr: isaacs: stay out of this :P [16:05] isaacs: cmr: package management and content management are not identical. they overlap a lot, but not 100% [16:05] isaacs: haha [16:05] isaacs: ok :) [16:05] cognominal has joined the channel [16:06] captain_morgan has joined the channel [16:06] isaacs: AAA_awright: if you're going to say that it's "just" something or "simply" something, then that (to me) should mean <100 loc. [16:06] nathanpalmer: hey guys.. maybe someone can point me in the right direction.. i'm trying to use node-request to pull down an image.. and then write it back out using express.. I've done a request({url:url, encoding:'binary'}, function(err,res,body){ res.send(body,{'Content-Type': 'image/png', 200); }); but it doesn't seem to be returning the right content (doesn't render) [16:06] isaacs: >100loc is not "just" or "simply" [16:07] LeMike has joined the channel [16:07] isaacs: AAA_awright: you can use ryp with npm's tarballs. [16:07] isaacs: c4milo: hey [16:07] fastest963 has joined the channel [16:08] c4milo: isaacs: what do you think about my question? [16:08] _rockbot_ has joined the channel [16:08] nathanpalmer: nevermind.. just changed it to this request({url:url, encoding:'binary'}, function(err,res,body){ res.send(new Buffer(body, 'binary'),{'Content-Type': 'image/png', 200); }); and it works.. [16:08] isaacs: hm. is there something i can install to reproduce it? [16:08] charles_ has joined the channel [16:09] charles_: d [16:09] c4milo: isaacs: hm. not really :/ it's a private repo. But if you tell me that it's an unexpected behavior I can reproduce it in a small project. [16:09] isaacs: c4milo: well, it sounds weird, and oyu seem confused by it. [16:09] c4milo: isaacs: and fill out an issue. [16:09] isaacs: c4milo: best case, there's something not being reported as usefully as possible. [16:09] joshthecoder has joined the channel [16:09] avih has joined the channel [16:09] AAA_awright: isaacs: 71 lines [16:10] isaacs: AAA_awright: orly? where? [16:10] thurmda has left the channel [16:10] icebox has joined the channel [16:10] c4milo: isaacs: I'll back to you once I have a project to reproduce. BTW I'm using npm 1.0.106 [16:10] AAA_awright: My implementation, now that's missing some more complex conflict resolution, it pretty much only handles recursive dependencies [16:10] isaacs: c4milo: hm, ok [16:11] isaacs: AAA_awright: where's the code? [16:11] barberdt has joined the channel [16:11] CarterL has joined the channel [16:11] sorensen__ has joined the channel [16:12] okee has joined the channel [16:12] cmr: AAA_awright: npm isn't that much different than portage. Actions are implemented by hooks to other things, just like ebuilds. [16:12] isaacs: AAA_awright: is it open source? on github somewhere? [16:13] AAA_awright: isaacs: It's a script of mine [16:15] AAA_awright: That's the one I end up using but I have a number of rewrites with various amounts of semver and npm compatibility disorganized across my systems... If we really want semver support for git submodules I'd imagine it needs ~300 lines plus support libraries for semver, running git commands, and parsing config files [16:16] AAA_awright: That script is also piped through xargs so it's a bit of a hack [16:16] isaacs: AAA_awright: semver is already supported by node-semver [16:16] isaacs: AAA_awright: and it has a cli interface [16:16] warz has joined the channel [16:16] warz has joined the channel [16:16] isaacs: and there's a json-tool node program for doing json parsing, also has a cli interface for pulling out fields and such [16:16] davehamptonusa has joined the channel [16:17] isaacs: and you could curl/gzcat/tar the tarballs in the registry. the url format is pretty easy to grok. [16:17] isaacs: (or tar -z if you wanna do it that way) [16:17] diogogmt has joined the channel [16:18] isaacs: i don't really get the fascination with git submodules, though. [16:18] draginx: Why would req.session be undefined in ExpressJS when Im doing app.use(express.session({ secret: 'whatever', store: store })); in app.configure() ? [16:18] isaacs: i use them in npm itself, and they're pretty bad, actualy [16:18] isaacs: the only nice thing is that i can do `npm explore request -- git pull origin master` to update it [16:18] warz: draginx, it uses the middleware in the order that theyre specified [16:18] warz: so make sure its prior to the router. [16:18] isaacs: but even there, i could just do `npm update request; git add node_modules/request` [16:19] isaacs: i'll probably ditch the submodules soon in favor of checked-in deps. [16:19] mnutt has joined the channel [16:19] ryan_stevens has joined the channel [16:19] metaverse has joined the channel [16:19] draginx: warz: ty sir :) [16:20] c4milo: isaacs: https://gist.github.com/1607296 [16:21] mandric has joined the channel [16:21] isaacs: c4milo: sweet, thanks. checking it out [16:21] brngardner has joined the channel [16:21] isaacs: arg, node 0.4, really? [16:21] isaacs: c4milo: can you upgrade to 0.6? [16:21] isaacs: i mean, 0.7 is going to come out in a few weeks. [16:22] cmr: Ohhh [16:22] AAA_awright: Oh how much did you miss... isaacs: Submodules gives you all your first-level dependencies right there, the only thing needed for Node.js is consolidating submodules to the root path and specify compatible future versions, which I do in .gitmodules, module.package.version=4 or whatnot [16:22] c4milo: isaacs: we have that in our task list but it isn't something that we can do overnight sadly :/ [16:22] cmr: isaacs: Any major new things (or should I see git log) [16:22] isaacs: the reason i whine is that, if it IS a bug in npm, it'd be a lot to fix in 1.0. [16:23] jocafa has joined the channel [16:23] isaacs: c4milo: npm 1.1 has a lot of fixes and good stuff. mostly driven by windows support, but also this is now free of system tar utilities and their oddnesses. [16:24] c4milo: isaacs: I see [16:24] isaacs: it uses node-tar, so i control the oddness directly :) [16:24] isaacs: but this requires having a zlib binding. so, no 0.4 support. [16:24] isaacs: AAA_awright: that's a nice approach, if you control the world. if you're trying to push a community to do your work for you, it's often suboptimal, and adds frictional agreement. [16:25] tjholowaychuk has joined the channel [16:25] isaacs: AAA_awright: but i still dont' grok why submodules are preferred to just checking your stuff into git. [16:25] isaacs: AAA_awright: having managed projects for several months that do both, i can say with confidence, submodules are bullshit. [16:25] isaacs: they ruin pretty much everything that makes git awesome. [16:25] c4milo: isaacs: yeah I understand node 0.6.x has a lot of improvements but you know, it's hard to move a big code base of a working system overnight, it's a cost that can't happen fast, it has to be something gradual. [16:25] c4milo: isaacs: I think I have a workaround [16:25] isaacs: c4milo: totally understnad. [16:25] AAA_awright: isaacs: How does this involve "controlling the world"... Then you run into cmr's problem, how do you keep up-to-date? submodules define a place to look for updates [16:25] c4milo: in the mean time [16:26] pquerna: yes, we are just about to do the 0.6 jump now, hurrah :) [16:26] isaacs: AAA_awright: easy. use npm. nest your deps as necessary to handle cycles and conflicts. check your node_modules folder into git. [16:27] AAA_awright: That eliminates everything that's good and right with Git [16:27] isaacs: AAA_awright: then you have a clear place to look for updates, you have a simpler deploy process, you can float patches if necessary, etc. [16:27] isaacs: AAA_awright: you get bisect, diffs, etc. you can see exactly what changed and when. [16:27] isaacs: there's a reason node bundles v8 and statically links to it. because it's a downloadable application. [16:27] isaacs: same with npm's releases. [16:27] isaacs: ACTION goes off to strip out npm's submodules and put his code where his mouth is... [16:28] AAA_awright: It's practically forking v8, I can deal with that (barely... the build system I can't) [16:28] AAA_awright: But also because Google is stupid and doesn't use Git for whatever reason [16:28] sorensen_ has joined the channel [16:28] markq has joined the channel [16:29] neurodrone has joined the channel [16:29] jscheel has joined the channel [16:29] NetRoY has joined the channel [16:29] EyePulp has joined the channel [16:29] mikl has joined the channel [16:30] arturadib has joined the channel [16:31] Neil_ has joined the channel [16:31] grampajoe has joined the channel [16:31] idoru has joined the channel [16:32] c4milo: my node_modules folder is 193M [16:32] sorensen__ has joined the channel [16:32] c4milo: I find kind of crazy to upload it to github [16:33] k1ttty_ has joined the channel [16:33] k1ttty has joined the channel [16:33] context: 193M wtf ? [16:34] context: did you throw every module possible into your project? [16:34] idoru has joined the channel [16:34] isaacs: context: yeah, that's kind of crazy big. [16:34] isaacs: context: also, you should only check in node_modules if it's something you'er deploying anyway. libraries and such should not. [16:35] context: ACTION waits for it [16:35] isaacs: er, c4milo [16:35] isaacs: haha [16:35] c4milo: context: if am I throwing? dude I just have a package.json that's it haha [16:35] isaacs: c4milo: also, that's not how git works. you only send diffs. [16:35] c4milo: isaacs: after the first upload yes [16:35] blueadept has joined the channel [16:35] c4milo: isaacs: my complain is the space [16:35] isaacs: but seriously, 193M is crazy gigantic. [16:36] context: i wanna know how its 193M honestly [16:36] isaacs: what are you doing? [16:36] c4milo: isaacs: yeah, one pending task that I have is kick TJ's ass for including jscoverage in expresso [16:36] c4milo: that's a fucking virus [16:36] isaacs: ohhhh, ok [16:36] isaacs: no shit. [16:36] isaacs: you know node-tap has coverage now? [16:36] c4milo: I'm not using code coverage! [16:36] isaacs: it's kind of wonky and experimental, but mostly works. [16:36] isaacs: oh, then gah!! [16:36] isaacs: wth? [16:36] c4milo: and all my tests are now in mocha [16:37] boltR has joined the channel [16:37] isaacs: c4milo: you can also exclude it with a .gitignore [16:37] c4milo: but there tons of other dependencies that still use expresso [16:37] isaacs: and your deps should not get their devdeps installed anyway [16:37] isaacs: (by default) [16:39] brianc1 has joined the channel [16:39] c4milo: isaacs: ehh, we have a deployment process where we never replace the production app if all the tests don't pass [16:39] saesh has joined the channel [16:39] c4milo: isaacs: so, dev deps are getting installed always [16:41] c4milo: isaacs: we are small and this project can afford a staging env yet [16:41] c4milo: :( [16:41] c4milo: anyways, I figured something out. isaacs thanks for your help man [16:42] isaacs: c4milo: kewl, np. i'm happy to tell you to give me examples and then not get to them in time for you to solve your own problems any time :) [16:42] mikl has joined the channel [16:42] mikl has joined the channel [16:42] jomoho2 has joined the channel [16:42] nmtmason has joined the channel [16:43] c4milo: hehe [16:43] isaacs: c4milo: yeah, that explains the 193M size issue, though. crazy. [16:43] raenger has joined the channel [16:43] isaacs: c4milo: compile on install is kind of awful. [16:43] c4milo: indeed [16:44] isaacs: opens the door for a lot of bad decisions like including spidermonkey in a node test harness. [16:44] isaacs: if you had to do the compilation up front, you'd never choose to do that. [16:44] c4milo: isaacs: well, the 193M is mostly normal dependencies, as devdependecies we have only like 5 or 6 modules [16:44] deoxxa: wait what [16:44] deoxxa: spidermonkey? [16:44] isaacs: c4milo: right, but if a bunch of them use expresso, then you'll have multiple copies. [16:44] isaacs: deoxxa: YEAH! [16:44] isaacs: deoxxa: how stupid si that?? [16:44] deoxxa: i'm... [16:44] deoxxa: what? [16:45] isaacs: deoxxa: jscoverage uses spidermonkey [16:45] isaacs: expresso uses jscoverage. [16:45] isaacs: most expresso users don't use coverage anyway [16:45] deoxxa: i can't rightly imagine what sequence of decisions led to this outcome [16:45] deoxxa: like, i see the beginning and i see the end [16:45] c4milo: isaacs: exactly [16:45] deoxxa: but the middle is murky [16:45] isaacs: deoxxa: yep. [16:45] isaacs: it was a murky time, i'm sure. [16:45] bodisiw has joined the channel [16:45] c4milo: it's a fucking virus [16:45] c4milo: ACTION has said that twice today  [16:46] __tosh has joined the channel [16:46] deoxxa: generally you can look at something and go "oh, i see. they were here, then they went there, then this happened and now we're at this point" [16:46] deoxxa: but... yeah [16:46] dthompso99 has joined the channel [16:46] zmbmartin: SubStack: Can I expect much better performance on a browserling paid plan. The free ver was very slow. [16:46] dthompso99 has left the channel [16:46] Kiryaka: having a weird issue with node 0.6.7 // socket.io 0.8.7... on some machines of my colleagues (mint linux and mac os), the connection is established but then nothing happens. It seems like the client does not receive anything and can't emit... [16:47] Kiryaka: On our prod, preprod server and on my dev machine, it works like a charm [16:47] Kiryaka: there's no error at all [16:47] booyaa: firewall? [16:47] Kiryaka: and I don't know how to reproduce [16:47] Kiryaka: booyaa: i don't think so [16:47] Kiryaka: heartbeats works [16:47] devongovett has joined the channel [16:47] AvianFlu: hey isaacs, would you like a pull request for https://github.com/isaacs/npm/issues/1329 ? [16:47] Kiryaka: the connection is alive.. [16:47] deoxxa: Kiryaka: using socket.io-client on node? [16:48] isaacs: AvianFlu: OMG I AM SO CLOSE TO FINISHING THIS AMAZINGLY. [16:48] AvianFlu: well sweet! [16:48] Kiryaka: deoxxa: using socket.io, not socket.io-client [16:48] isaacs: AvianFlu: so, if you want to do this, ok, but we should have a conversation about the approach. [16:48] deoxxa: Kiryaka: so you're accessing it via a browser? [16:48] AvianFlu: isaacs, people put their main start scripts in their .gitignore sometimes, I'd love to stop them for good! [16:48] Kiryaka: deoxxa: yup [16:48] isaacs: AvianFlu: ie, i'd be happy to delegate, but a patch coming out of nowhere has a low likelihood of being acceptable. [16:49] einaros has joined the channel [16:49] isaacs: AvianFlu: yeah, the latest npm 1.1 should prevent that. [16:49] Kiryaka: using socket.io js that's served by socket.io [16:49] AvianFlu: isaacs, well if you're actually in the middle of it, then carry on [16:49] isaacs: AvianFlu: since their .gitignore will turn into a .npmignore, and their package will stop working if they don't fix that. [16:49] JarrodBell has joined the channel [16:49] AvianFlu: but if you hadn't gotten to it yet I'm happy to help [16:49] isaacs: :) [16:49] AvianFlu: nice [16:49] deoxxa: ah, can't offer any help then :( Kiryaka - i had a similar problem but it was socket.io-client being incompatible with > 0.4.x node [16:49] isaacs: AvianFlu: it's been a long ride. [16:49] Kiryaka: deoxxa: it is compatible [16:49] Kiryaka: it works with the same install procedure [16:49] deoxxa: it wasn't before [16:49] Kiryaka: but on different machines [16:49] isaacs: AvianFlu: but the pure-js glob impl is just about done now (just need to add a sync version, really) and then the ignorefile module will use that. [16:49] Kiryaka: can't get what makes it work [16:50] AvianFlu: isaacs, yeah, I saw you bump 1.1.0 yesterday, congrats [16:50] CarlosC has joined the channel [16:50] AvianFlu: isaacs, cool [16:50] JarrodBell has left the channel [16:50] isaacs: AvianFlu: then i'm going to update fstream's dir walker to be ignorefile aware, so you can say "respect the globs in files named 'blah' and skip them" [16:50] deoxxa: Kiryaka: https://github.com/LearnBoost/socket.io-client/issues/290 << see [16:50] isaacs: AvianFlu: the exact api is still somewhat fuzzy. [16:50] tdegrunt has joined the channel [16:51] isaacs: AvianFlu: but the target is, "if you have a thing that does things with files, you can use this to ignore certain ones very easily" [16:51] AvianFlu: isaacs, that's a pretty cool idea [16:51] isaacs: AvianFlu: i also want to have a .tapignore support for node-tap, so you can exclude tests easily. [16:51] isaacs: AvianFlu: ti's kind of annoying for me in a few places to have to do this manually. [16:51] Kiryaka: deoxxa: thank you, but version does not correspond at all :/ [16:51] deoxxa: exactly [16:51] deoxxa: this is what i was saying ._. [16:51] AvianFlu: isaacs, yeah, that could be very useful [16:52] cmr: isaacs: I'll patch that in if you wish [16:52] davetayls has joined the channel [16:52] isaacs: cmr: well, once ignorefile is done, adding it into tap should be trivial. [16:52] isaacs: but we'll see. [16:52] cmr: a'ight [16:52] TheJH has joined the channel [16:52] isaacs: it's vaporware at this point, so i don't want to say too much about it. [16:53] cmr: My offer will stand for as long as the feature needs implementing [16:53] isaacs: miniglob/node-glob is very close to the finish line, though [16:54] robde has joined the channel [16:54] ljackson has joined the channel [16:55] isaacs: no more submodules in npm: https://github.com/isaacs/npm/commit/c1238f7b02ca079e270f66ff161050b825120f70 [16:55] isaacs: moving to the "check in deps" model. [16:55] deoxxa: urk, express template calls are weird [16:56] stefpb has joined the channel [16:57] broofa has joined the channel [16:57] jbpros has joined the channel [16:57] isaacs: AvianFlu: you see that optionaldeps landed, too? [16:57] AvianFlu: NICE [16:57] overthemike has joined the channel [16:57] Kiryaka: One precision, it does not depend on the protocol... [16:58] Kiryaka: whatever I use, send, emit, and on methods does not work [16:58] AvianFlu: it's gonna take some time before jitsu can take advantage of any of this, but it's all awesome [16:59] sam_b has joined the channel [17:00] cangeceiro has joined the channel [17:02] ryanfitz has joined the channel [17:02] idoru has joined the channel [17:02] hotchkiss has joined the channel [17:02] alvaro_o has joined the channel [17:02] GrizzLyCRO has joined the channel [17:03] yogig has joined the channel [17:03] djbell has joined the channel [17:03] warz has joined the channel [17:03] warz has joined the channel [17:04] gut4 has joined the channel [17:05] deoxxa: any express.js wizards around? i'm looking at doing an express wrapper for my template thing, but i'm not sure how best to go about it... [17:05] _dc has joined the channel [17:05] warz: a wrapper for your template thing? [17:05] deoxxa: sorry, i've written a templating engine [17:05] bergie has joined the channel [17:06] deoxxa: it doesn't work the way express expects it to work, though [17:06] jerrysv has joined the channel [17:06] warz: here is a good example for you, then. this creates the compile function that express expects, for hogan.js. [17:06] warz: https://github.com/Dundee/express-hogan.js/blob/master/lib/express-hogan.js [17:06] warz: you'll need to make something similar [17:07] soapyillusions has joined the channel [17:07] langworthy has joined the channel [17:07] RobWC has joined the channel [17:07] deoxxa: hm, yeha [17:07] deoxxa: that looks a lot like what i've got going on already [17:08] thurmda has joined the channel [17:09] booo has joined the channel [17:09] thurmda: Anyone know of an example of tracking progress of a read stream .pipe 'd to a write stream ? [17:10] thurmda: I am currently reading a file and .pipe() it to an httpRequest [17:10] thurmda: but I want to keep track of how much I've sent [17:10] thurmda: I thought I could track it via the httpRequest.on('data') event [17:11] thurmda: but that doesn't fire :( [17:11] thurmda: any ideas? [17:12] thurmda: I was hoping to keep .pipe() cause I think it does some nice things with pausing the streams as necessary [17:12] tmcw has joined the channel [17:12] astropirate has joined the channel [17:14] thurmda: quite room for all the peps logged on [17:16] topriddy has joined the channel [17:16] deoxxa: thurmda: it actually just uses pipe() underneath, as in posix pipe [17:17] Kiryaka: deoxxa: ... seems like a port issue after all [17:17] Kiryaka: https://github.com/LearnBoost/socket.io/issues/708 [17:17] rio{ has joined the channel [17:17] Kiryaka: here, he describe exactly the same problem [17:17] dudeinthemirror has joined the channel [17:17] deoxxa: weird [17:17] thurmda: but does node http.request, that is being piped to, know when it writes data and raise an event? [17:17] ritch has joined the channel [17:17] kenperkins has joined the channel [17:17] thurmda: that'd be ideal for me [17:17] deoxxa: i don't think so [17:18] thurmda: and I could keep all the magic in pipe [17:18] thurmda: and know how much I've written to the request [17:18] amasad has joined the channel [17:18] dgathright has joined the channel [17:18] deoxxa: ACTION suggests `man 2 pipe' [17:19] deoxxa: basically as soon as you pipe two fds together it goes into kernel space [17:19] ritch has left the channel [17:19] eignerchris has joined the channel [17:20] trotter has joined the channel [17:21] thurmda: wouldn't the http.request object know when it's being written to? [17:21] heavysixer has joined the channel [17:21] thurmda: pause/continue could all happen via pipe [17:21] madhums has joined the channel [17:22] thurmda: but http.request could fire 'data' events when it has data written to it [17:22] dgathright has joined the channel [17:22] deoxxa: actually maybe i'm mistaken, i was under the impression it actually used posix pipe() but it doesn't mention it [17:23] RobWC has joined the channel [17:23] laczek has joined the channel [17:24] gregpascale has joined the channel [17:24] christkv has joined the channel [17:24] Destos has joined the channel [17:25] isaacs: deoxxa: Stream.pipe() is not pipe(2) [17:25] deoxxa: evidently [17:25] isaacs: deoxxa: it's conceptually similar [17:25] isaacs: but it's just a JS artifact. [17:26] _rockbot_: Hi folks! Can anyone help me understand why query string is being dumb here? http://pastebin.com/EnxEcDif [17:26] icrazyhack has joined the channel [17:27] peregrine81 has joined the channel [17:27] thurmda: deoxxa, I just changed my ` video.pipe(put, { end: false }); ` to ` video.on('data', function(data){ console.log('bytesSent : ' + (bytesSent += data.length)); put.write(data); }); ` [17:27] thurmda: deoxxa, I get the progress I need but I fear I'm not getting the pipe magic via that change [17:28] deoxxa: yeah, you'll end up buffering a lot of data if you saturate put [17:28] thurmda: any suggestions? [17:28] ryanrolds_w: _rockbot_: Extra symbols? Like slashes? [17:28] thurmda: know of an appropriate event I can listen too on the put request I'm piping to? [17:29] _rockbot_: Like "note=Something+awesome%21" [17:29] franciscallo has joined the channel [17:29] ph^ has joined the channel [17:29] deoxxa: thurmda: if you call write() on it and it returns false, you should stop writing to it. then when it emits "drain", you can start writing again... [17:30] deoxxa: that's a much simpler version of what pipe() does it seems [17:30] thurmda: ah [17:30] markschaake has joined the channel [17:30] captain_morgan has joined the channel [17:30] markschaake has left the channel [17:31] _rockbot_: ryanrolds_w: so, basically, postNote has the correct information, but I can't seem to solely extract the text from the query string (which I though was just querystring.parse(stringToParse).text) [17:31] TheJH: _rockbot_, what does console.log(Object.keys(querystring.parse(postNote))) say? [17:31] ryanrolds_w: _rockbot_: That code looks OK. If you run the string that console.log is printing through the REPL does it work? [17:31] thurmda: deoxxa, do I have to worry about readding the file from disk? I don't want reads to happen there if I can't write to the put request [17:31] thurmda: deoxxa, do I call pause on it? [17:31] _rockbot_: TheJH, ryanrolds_w: lemme check.. [17:31] deoxxa: yeah, you'd want to pause it [17:31] deoxxa: then unpause it when it's ready to write again [17:32] thurmda: deoxxa, ;) [17:32] pyrotechnick has joined the channel [17:32] thurmda: deoxxa, Thanks, sounds like what I want and less trouble than I thought [17:32] willwhite has joined the channel [17:32] deoxxa: hooray! [17:33] Kiryaka: deoxxa: do you have a clue of what can act as a firewall under mac os x ? [17:33] Kiryaka: (i don't really know this os) [17:33] Kiryaka: (and default firewall is disabled) [17:34] Kiryaka: (and everything is local...) [17:34] ryanrolds_w: The whole OS acts like a firewall to usefulness. [17:34] Prasoon has joined the channel [17:34] Prasoon: JECRC iWeekend presents iSoftware. Means Innovation in software. Show us your innovation and Get money worth 1000$. Goto http://jecrciweekend,com [17:34] vkandy has joined the channel [17:34] flip_digits has joined the channel [17:35] cmr: Always-semicolons is a hard habit to break. [17:35] cmr: I don't even think about it anymore :( [17:35] _rockbot_: TheJH: output says [ 'note' ] [17:36] ryanrolds_w: Yeah, so text isn't there. [17:36] ryanrolds_w: qs.parse(...).text isn't avilable, but qs.parse(...).note will be. [17:36] TheJH: _rockbot_, well, then your querystring only contains a "note" key [17:36] TheJH: _rockbot_, qs.parse gives you an object, and its keys are the keys fromt he querystring [17:37] draginx has joined the channel [17:37] _rockbot_: ok, so what do I need to do? [17:37] ryanrolds_w: 5: var fullNote = querystring.parse(postNote).note; [17:37] _rockbot_: ah! [17:38] mikl has joined the channel [17:39] _rockbot_: Thanks, TheJH & ryanrolds_w ! [17:41] chadskidmore has joined the channel [17:42] storrgie has joined the channel [17:42] stonebra_ has joined the channel [17:45] sdwrage has joined the channel [17:47] maletor has joined the channel [17:49] aslant has joined the channel [17:50] EhevuTov has joined the channel [17:50] k1ttty has joined the channel [17:50] buttface has joined the channel [17:51] dilvie has joined the channel [17:51] mattgifford has joined the channel [17:52] andorraclaim_ has joined the channel [17:53] skm has joined the channel [17:53] N0va` has joined the channel [17:54] mark_azevedo has joined the channel [17:57] captain_morgan has joined the channel [17:57] satyr has joined the channel [17:58] mikeal has joined the channel [17:59] fantastikibne has joined the channel [17:59] fantastikibne: hi var z; function l(){ z='a'; } why this doesnt work? [18:00] fantastikibne: how can i export a data to out of the function [18:00] slaskis has joined the channel [18:01] gsmcwhirter: fantastikibne: what does it do instead? (looks like it should work to me) [18:02] gsmcwhirter: fantastikibne: modulo the fact that you never call l() [18:02] cmr: .. var z; function l() { z = 'a' }; l(); print(z); [18:02] catb0t: "a" [18:02] r1ngzer0 has joined the channel [18:03] ryan_stevens has joined the channel [18:04] fantastikibne: http://pastebin.com/Cdv9mhH3 [18:04] fantastikibne: C:\Users\pc\Desktop\nodejs>req.js undefined [18:05] satyr has joined the channel [18:06] NetRoY has joined the channel [18:06] jgaui_ has joined the channel [18:06] t0mmyvyo has joined the channel [18:07] fantastikibne: var tokenlar; client.query( 'SELECT user_id,access_token FROM '+dbtable+' limit '+sqlbaslangic+','+sqlson, function selectCb(err, results) { if (err) { throw err; } tokenlar=results; client.end(); } ); console.log(tokenlar); [18:07] fantastikibne: returns undefined [18:08] dshaw_1 has joined the channel [18:08] gr-eg has joined the channel [18:09] joaquin_win has joined the channel [18:10] ryanrolds_w: When that callback executes it's no longer in that scope, it's in the global scope. So tokenlar you're looking at isn't being set. [18:10] ryanrolds_w: Use a closure to fix it. [18:10] phidah has joined the channel [18:10] draginx: Any reason why res.render() wont pass {locals} ? [18:11] ryanrolds_w: oh wait. [18:11] ryanrolds_w: I'm wrong. [18:11] langworthy has joined the channel [18:11] ryanrolds_w: Node.js is non-blocking. [18:11] ryanrolds_w: So that console.log is called before the callback has had a chance to fire. [18:11] draginx: http://pastie.org/private/kyfk5rmq2jrzvfi0izflhq [18:11] robde_ has joined the channel [18:11] reid has joined the channel [18:12] robi42 has joined the channel [18:12] phidah: I have this code that spawns a child ssh process and connects to a server. However, my stdout listener doesn't pick up the password prompt. How can I do this? I need my node.js application to log on by itself - http://paste.viaweb.biz/p/491 [18:13] heavysixer has joined the channel [18:13] RobWC has joined the channel [18:13] TooTallNate has joined the channel [18:13] ryanrolds_w: fantastikibne: That console.log is called before that callback has been run. [18:13] bodisiw has joined the channel [18:13] Kunda has joined the channel [18:13] fantastikibne: hm [18:14] fantastikibne: so when i can use tokenlar? [18:14] stephank has joined the channel [18:14] Topcat has joined the channel [18:14] joshfinnie has joined the channel [18:15] willwhite has joined the channel [18:17] idefine: fantastikibne: you can use it in your callback [18:18] franciscallo has joined the channel [18:18] jtrudeau has joined the channel [18:20] fbartho has joined the channel [18:21] nadirvardar has joined the channel [18:21] mnutt: phidah: I think the ssh password prompt is on stderr [18:21] Phoenixz has joined the channel [18:21] dannyamey has joined the channel [18:22] lz has joined the channel [18:22] draginx: is there a qucik way of saying if variable is undefined then default to this value? [18:22] adrianF has joined the channel [18:22] draginx: like a var ||= "hello"; ? [18:22] StanlySoManly has joined the channel [18:23] fantastikibne: varz=var?var:"hello" [18:23] Phoenixz: New to node here.. Question, I am toying with the examples of http://socket.io/#how-to-use, one thing I dont understand is, the browser loads