[00:01] strcK has joined the channel [00:05] tjholowaychuk has joined the channel [00:06] Xeon06_ has joined the channel [00:07] bksf has joined the channel [00:07] jellosea has joined the channel [00:08] bksf: is node-static the best way to serve static assets? [00:08] sonnym has joined the channel [00:08] AvianFlu: bksf: you could also try http-server, as in 'npm install http-server -g' [00:08] AvianFlu: it's a CLI tool for node-static, put briefly [00:08] bksf: for serving static files in additon to a dynamic backend? [00:08] jellosea: how do i export/import a module so that i can just straight away go new ClassA() instead of var something = require(foo); new something.ClassA() [00:09] bksf: not looking for a cli tool [00:09] thedjinn has joined the channel [00:09] tjholowaychuk: bksf there are about 6 or 7, all are pretty much the same [00:09] fdenbow has joined the channel [00:09] tjholowaychuk: pick one with an api you like :D [00:09] AvianFlu: bksf: do some git searching [00:10] mikeal has joined the channel [00:11] bksf: ok [00:11] isaacs: jellosea: exports.ClassA = function ClassA ... [00:12] jerrysv has joined the channel [00:12] level09: is there any sample website examples on github on how to use express ? [00:12] level09: how do I load my website's assets ? js and css /img files ? [00:13] tjholowaychuk: level09 the express repo ./examples dir has about 12 examples [00:13] level09: ah great [00:13] level09: thanks [00:13] CrisO has left the channel [00:13] Swizec has joined the channel [00:13] jellosea: isaacs: no.. then when i import don't i have to scope it to a variable? [00:14] guidocalvano has joined the channel [00:14] booo has joined the channel [00:15] isaacs: oh, *instead of* [00:15] KingJamool has joined the channel [00:15] avalanche123 has joined the channel [00:15] level09: are most of these nodes ideas inspired by ruby ? [00:15] isaacs: in a.js: module.exports = ClassA; in b.js: var ClassA = require("./a"); new ClassA [00:15] level09: like express and jade etc .. [00:16] akshatj has joined the channel [00:16] isaacs: level09: i don't think that tj's packages count as "most of node's ideas" [00:16] isaacs: level09: ;) [00:16] tjholowaychuk: level09 yeah i wrote ruby stuff for a few years [00:16] level09: ah , you actually are a ruby dev [00:16] hippich has joined the channel [00:16] level09: that makes sense :) [00:16] Naked has joined the channel [00:17] tjholowaychuk: nothing much in node-land is new really [00:17] tjholowaychuk: just different [00:17] brianm has joined the channel [00:17] brianm has joined the channel [00:17] markmarkoh has joined the channel [00:17] level09: tjholowaychuk: does node have a lot of advantages over ruby ? [00:18] bradleymeck: less magic [00:18] tjholowaychuk: well node isn't a language [00:18] jellosea: isaacs: oh okay [00:18] tjholowaychuk: but yeah i find it better to work with [00:18] tjholowaychuk: more natural [00:18] ctide: tjholowaychuk: are all tests passing for you with node v0.4.9 for express? [00:18] level09: you mean as in syntax [00:18] ctide: i pulled it down earlier, and was getting a few failures [00:18] tjholowaychuk: ctide one is failing right now [00:18] Yuffster_work: Ruby and JavaScript are quite similar, but Ruby is slightly more open to modifications. [00:19] tjholowaychuk: ruby is a clusterfuck more or less [00:19] tjholowaychuk: so is js, but less so [00:19] Yuffster_work: You can't make a method in JS called `. [00:19] level09: :) [00:19] ctide: https://gist.github.com/16bb8f1e4f4b39fc82b1 was what i was seeing [00:19] level09: I like how easy to learn node is [00:20] tjholowaychuk: ctide ah yup i have those right now as well, just haven't had time to fix them [00:20] ctide: ok cool [00:20] ctide: just making sure [00:20] level09: but it is still kind of tricky learning the async thing [00:20] ctide: i also just opened a pull request [00:20] Yuffster_work: Asynchrnous is fun, though. [00:20] Yuffster_work: It's like time travel. :D [00:20] tjholowaychuk: sounds good. im pretty sick today so i might have to take a look at it tomorrow [00:20] ank has joined the channel [00:20] level09: especially when having more complex stuff [00:20] ctide: no worries [00:20] level09: the code becomes really horrible [00:20] Yuffster_work: You just have to stop thinking of code as a linear story. [00:21] pquerna: http://www.dougfirlounge.com/ [00:21] level09: Yuffster_work: it is still linear , but every new step must be moved to the callback instead on the next line [00:22] SubStack: node is like the tardis [00:22] mikey_p: http://www.jupiterhotel.com/ [00:22] Yuffster_work: level09: Thinking of it wrong. ;) [00:22] Yuffster_work: SubStack: has it right, you need to watch all of Doctor Who (even the original episodes that have been lost), and then you will understand JavaScript. [00:22] level09: it is way easier when you know that the next line won't execute unless the first line is executed :D [00:22] SubStack: especially blink [00:23] level09: for simple loops I have to write recursive functions now :) [00:23] Yuffster_work: But not the other episode with the weeping angels because they were crap in that episode. [00:23] Yuffster_work: "omg amy it's living in ur eye!!!" [00:23] sholden: Im crawling a lot of urls, and after about 3000, or just under 1min, i start getting a lot of 'EAFNOSUPPORT, Address family not supported by protocol family [00:23] SubStack: level09: there are flow control libraries for that [00:23] bayousoft has joined the channel [00:23] sholden: coming from syscall: 'connect' [00:24] level09: SubStack: you mean modules ? [00:24] level09: SubStack: is there any recommended design patterns for node ? [00:24] sholden: level09: check out https://github.com/medikoo/deferred and https://github.com/caolan/async [00:24] level09: I'm ending up in a very complicated situation :) [00:24] level09: thanks [00:24] level09: ACTION looking ... [00:24] rpflo has joined the channel [00:25] SubStack: I wouldn't call them "design patterns" [00:25] kuya_ has joined the channel [00:25] SubStack: too much GOF bullshit baggage [00:25] Yuffster_work: They're riffs. [00:25] SubStack: idioms is a better term [00:25] level09: SubStack: these are great [00:26] level09: async.series is kind of synchronizing the workflow [00:26] level09: *like [00:26] fattytuna has joined the channel [00:26] SubStack: level09: writing your own flow control lib is fun, give it a spin [00:27] SubStack: level09: here's another neat one: https://github.com/creationix/step [00:27] SubStack: here's mine: https://github.com/substack/node-seq [00:28] Nuck has joined the channel [00:29] EyePulp has joined the channel [00:29] level09: nice [00:29] fakewaffle has joined the channel [00:29] level09: do these libraries handle memory efficiently ? [00:29] sholden: so... are lots of people using coffee script on node these days? or mostly js? [00:29] sholden: (obviously cs IS js, but what are people writing in?) [00:30] fakewaffle: Nexxy++ [00:30] catb0t: Nexxy now has 1 beer [00:30] v8bot_: fakewaffle has given a beer to Nexxy. Nexxy now has 1 beers. [00:30] Wa has joined the channel [00:30] SubStack: `v beers SubStack [00:30] v8bot_: SubStack: SubStack has 0 beers. [00:31] SubStack: drat, my beers! [00:31] bradleymeck: level09 handeling memory efficiently in JS depends on knowing what you are keeping references to. Its more up to your closures than the libs. [00:32] willwhite has joined the channel [00:32] level09: yeah , right [00:33] bksf has joined the channel [00:33] Nuck: lol [00:33] Nuck: Having fun? [00:33] Nexxy: lolwat [00:33] Nuck: SubStack++ [00:33] catb0t: SubStack now has 3 beers [00:33] v8bot_: Nuck has given a beer to SubStack. SubStack now has 1 beers. [00:34] Nuck: :P [00:34] Aria has joined the channel [00:34] Nuck: SubStack: You deserve it. [00:34] te-brian2 has joined the channel [00:35] NuckingFuts: Nuck++ [00:35] catb0t: Nuck now has 3 beers [00:35] v8bot_: NuckingFuts has given a beer to Nuck. Nuck now has 1 beers. [00:35] NuckingFuts: ACTION whistles innocently. [00:36] Nuck: Fuck, I need to change that plural issue, I'm a grammar nazi D: [00:38] bksf: any idea why i dont see static files from public here? http://pastebin.com/4s0TkRUe [00:38] SubStack: Nuck sure does have a lot of beers for a 17 year old! [00:39] Nuck: SubStack: 17-year-olds usually drink more than 21-year-olds [00:39] Nuck: You know it's true. [00:39] SubStack: it's true [00:39] balupton has joined the channel [00:39] Elems: haha [00:39] tbranyen: i didn't drink till i was 18 :-/ [00:39] Swizec_ has joined the channel [00:39] Nuck: (though I don't drink them, I just hoard_ [00:39] Nuck: I hoard beers :P [00:39] SubStack: when I turned 21 I didn't have anything to drink for a month [00:39] balupton has left the channel [00:39] SubStack: since I had all this shit to do [00:39] Nuck: My siblings have both vowed to get me shitfaced two days in a row. [00:40] Nuck: When I turn 21 [00:40] arlolra has joined the channel [00:40] Elems: If I live to be 21, I'll start drinking legally. [00:40] SubStack: getting shitfaced is not very pleasant actually [00:40] Nuck: I'm gonna have one hell of a 21st birthday. [00:40] Nuck: SubStack: I know :P [00:40] SubStack: I would advise against it. Shoot for pleasantly numb. [00:40] Nuck: They're siblings, their purpose in life is to antagonize their younger siblings. [00:41] Nuck: I am the youngest [00:41] fattytuna has joined the channel [00:41] Nuck: (also the best, stastically speaking) [00:41] Nuck: (and spasticly speaking) [00:41] Xeon06_ has joined the channel [00:42] bksf: bump [00:43] Nuck: I hope I'm in SF area before I turn 21 [00:43] Nuck: Because then I'm gonna have one hell of a birthday :P [00:44] konobi: drinking legally since 16... europe++ [00:44] Nuck: fuck europe and your young boozers D: [00:45] Nuck: I get the suspense! [00:45] Nuck: And two sibilings who will probably travel many, many hours just to get me shitfaced. [00:45] Nuck: My sister drove from Portland to Modesto in one night for my brother's 21st birthday [00:46] Nuck: With a 2-year-old [00:46] jacobolus has joined the channel [00:47] rchavik has joined the channel [00:47] Nuck: I hope I'm as awesome as my brother when he's drunk. [00:48] Nexxy: and welcome to today's episode of "things you probably shouldn't be bragging about", with your host... Nuck ! [00:48] Nuck: When he's drunk, he's a fucking pimp. My sister even had to stop him from walking home with a pack of girls. [00:48] Damm has left the channel [00:49] Nuck: Nexxy: I think that is something to brag about :P [00:49] albertosheinfeld has joined the channel [00:49] rpflo has joined the channel [00:49] Nuck: Being a pimp-drunk is an awesome ability. [00:49] mikey_p: Nexxy: this is the week of oscon and all those wild open source parties...go figure [00:50] sub_pop has joined the channel [00:50] Nuck: lol [00:50] jerrysv has joined the channel [00:50] albertosheinfeld: Anyone here hs used socket.io? [00:50] Nuck: mikey_p: Someday I wanna go to one of those parties. [00:50] Nuck: albertosheinfeld: No, but I'm looking at using it. [00:51] ap3mantus has joined the channel [00:51] albertosheinfeld: i am unable to run it on 0.4.10 :S [00:51] mikey_p: Nuck: i don't think any checks our ID when you go to the ones that are at offices [00:51] Nuck: for my chat server [00:51] mikey_p: Nuck: like puppet labs, etc [00:51] albertosheinfeld: and i dunno how to downgrade to 0.4.9 [00:52] Nuck: mikey_p: I know, but I'm not in bay area or anywhere [00:52] Nuck: I'm in Modesto, CA [00:52] thepatr1ck: albertosheinfeld: I'm using it, but on 0.4.9 & 0.5.1 (really need to upgrade to 0.5.2, but download/conf/make install is too much effort for this time of morning) [00:52] skm has joined the channel [00:52] Nuck: I wanna move to SF or Oakland within a year or two. [00:53] mikey_p: Nuck: OSCON is in portland, come crash at your sisters place [00:53] mikey_p: Portland is cooler [00:53] mikey_p: ACTION waits for vim vs. emacs debate [00:53] Nuck: mikey_p: lol I agree, but I wanna be in SF for my startup :P [00:53] albertosheinfeld: LOL, so 0.4.10 is not the latest stable version for node? [00:53] mikey_p: albertosheinfeld: i believe that 0.4.11 is out? [00:53] Nuck: mikey_p: I don't like modal editors, I use nano. [00:53] Nuck: It's as close to a good UI as I can expect from a CLI. [00:54] Nuck: In fact, it's not half bad. [00:54] mikey_p: Nuck: me too! I love watching peoples face when they see you editing code with syntax highlighting in nano [00:54] SubStack: Nuck: I've got an empty room at stackhaus I need to fill [00:54] albertosheinfeld: ok, thanks [00:54] mikey_p: most folks don't even know that nano can do syntax highlighting [00:54] Nuck: mikey_p: lol [00:54] Nuck: SubStack: You still haven't filled that? [00:54] Nuck: Damn [00:54] Nuck: You msut smell REALLY bad. [00:54] k1ttty has joined the channel [00:54] SubStack: well haven't been trying to fill it very hard [00:55] SubStack: there are a lot of rooms [00:55] execution has joined the channel [00:55] Nuck: For now, until I get VC or enough savings to move, I'm gonna be sticking to Modesto [00:55] SubStack: because oakland is awesome like that [00:55] mikey_p: what's stackhaus? [00:55] thepatr1ck: mikey_p: I certainly didn't, until it just started happening (but then nano has been my choice of editor for 10 years or so anyway) [00:55] Nuck: SubStack: Do you own the placE? [00:55] execution: are there any very well-known (ie. not some new, small startup) alternatives to heroku and joyent for managed node.js hosting? [00:55] SubStack: Nuck: just renting but it's got 4 rooms [00:55] Nuck: SubStack: Ah lol [00:55] mikey_p: execution: dotcloud? [00:56] jerrysv has joined the channel [00:56] Nuck: I am applying to the next round on Y Combinator, if I get in, I'm gonna need to move to SF area :P [00:56] jewgonewild has joined the channel [00:56] Nuck: I doubt I will get in [00:56] jesusabdullah: What's your idea? [00:56] SubStack: YC is all the way down in mountainview too [00:56] CrabDude: execution: nodejitsu? [00:56] mikey_p: isnt' SF actually pretty far from Standford? [00:56] jewgonewild: Hey.. quick question about a node.js chat room I'd like to run on multiple node instances [00:56] jesusabdullah: Yeah, that it is [00:56] mikey_p: or Palo alto or wherever [00:56] kawaz_home has joined the channel [00:56] SubStack: mountainview is hella out of the way [00:56] jesusabdullah: MV is like an hour drive from Oakland [00:56] jesusabdullah: :( [00:57] mikeal has joined the channel [00:57] jesusabdullah: Nuck: Never fear wrt YC, they seem to have little rhyme or reason when it comes to chosing people to incubate [00:57] Nuck: jesusabdullah: lol yeah [00:57] Nuck: We've got a damn good team [00:57] jesusabdullah: Word [00:57] Nuck: The idea is a tad weak, but our team is solid [00:57] jesusabdullah: I'm gonna be a damn good team someday [00:57] mikey_p: and the name Nuck...that's gotta be worth some points right there [00:57] jesusabdullah: you just wait [00:57] jesusabdullah: THAT'S RIGHT THE ENTIRE TEAM [00:58] Nuck: Our CTO could give a LOT of company's CTOs a run for your money. [00:58] Cleer has left the channel [00:58] Nuck: He's definitely smarter than the CTO of deviantART. [00:58] Nexxy: what an accomplishment! [00:58] Nuck: mikey_p: My name ain't nuck ;) [00:58] Nuck: It's Peter. [00:58] Nuck: I have handles. [00:58] Nuck: Well, handle. [00:58] Nexxy: mayb if you'd exercise moar [00:58] Nexxy: ;o [00:59] SubStack: ACTION handles Nuck  [00:59] jesusabdullah: Oh yeah, you're all like deviantarted [00:59] jesusabdullah: and stuff [00:59] jesusabdullah: OH MY [00:59] Nexxy: devianTART [00:59] SubStack: HELLO MY NAME IS IAN TART AND I AM A DEVELOPER [01:00] Aria has joined the channel [01:00] Nuck: Nexxy: Fatness runs on my father's side of the family. My maternal grandpa, who I take after VERY much, could eat asstons of food and never gain wait. [01:00] Nuck: *weight [01:00] Nuck: ACTION derps [01:00] Nuck: SubStack++ [01:00] catb0t: SubStack now has 4 beers [01:00] v8bot_: Nuck has given a beer to SubStack. SubStack now has 2 beers. [01:00] execution: thanks, mikey_p and CrabDude [01:00] Nuck: Genius. [01:00] Nexxy: just how much is an asston? [01:00] jakehow has joined the channel [01:00] jesusabdullah: I'm a fatass [01:00] jesusabdullah: but I don't care! [01:00] jesusabdullah: Okay I care a little bit [01:00] SubStack: jesusabdullah: bike moar [01:00] jesusabdullah: but not enough to change my ways! [01:00] jesusabdullah: My food-nomming ways [01:01] Nuck: Nexxy: Well, in eating dutch pancakes (pannekoeken), he could down like 12 in an hour. [01:01] jesusabdullah: I *am* biking more :) Not enough but, y'know, more [01:01] Nuck: And that's thin pancakes rolled up with sugar [01:01] SubStack: jesusabdullah: you don't even eat much more than I do [01:01] jesusabdullah: I biked all the way to the post office today! [01:01] jesusabdullah: I got my diplomas and grandpa's old playstation 2 [01:01] jesusabdullah: (makes it sound like a family heirloom doesn't it?) [01:01] softdrink has joined the channel [01:02] SubStack: as if he was using it in 'nam [01:02] jesusabdullah: Exactly [01:02] jesusabdullah: This here is grandpappy's ole' PS2 [01:02] jesusabdullah: He fought off the japs with this thing [01:02] jesusabdullah: ...in BF2 [01:03] Nuck: We got my sister's old PS2 [01:03] SubStack: jesusabdullah: do a comic [01:03] Nuck: Her ex shoved it in the dishwasher to be an ass. [01:03] jesusabdullah: whose ex? [01:03] AvianFlu: Nuck: you shoved what in your what now!? [01:04] jesusabdullah: I guarantee you this PS2 is in operating condition! [01:04] jesusabdullah: They don't make 'em like they used to! [01:04] Nuck: jesusabdullah: lol [01:04] Nuck: We have an original model PS2 [01:04] jesusabdullah: Oh, this is one of the compact ones [01:04] Nuck: And an original model NES [01:04] jesusabdullah: it's actually pretty new [01:04] Nuck: ah, thinlines suck. [01:04] jesusabdullah: They still make it I think [01:04] jesusabdullah: Yeah, at least it's tiny [01:05] jesusabdullah: I used to have an early-model PS2 [01:05] Nuck: Doubt it, they want to drive people to the PS3 [01:05] jesusabdullah: My friends' [01:05] Nuck: We have 2 Gamecubes too [01:05] jesusabdullah: er [01:05] jesusabdullah: My friend used to have a PS2 and then it stopped working so he gave it to me [01:05] Nuck: And we got a Wii almost a year ago [01:05] jesusabdullah: It turned out to be clogged with the most disgusting dust in the world [01:05] Nuck: We've got rather few game systems here [01:05] jesusabdullah: It smelled like smoked salmon [01:05] jesusabdullah: oh God [01:05] Nuck: jesusabdullah: eww [01:05] jesusabdullah: but I totally got it working again [01:05] jesusabdullah: Yeah, it was so gross [01:06] jesusabdullah: and I was an idiot and sprayed it out in my bedroom [01:06] Nuck: Yeah, I think we tried the one that got dishwashed didn't work [01:06] jesusabdullah: Holy shit, I was in high school when this all went down! [01:06] Nuck: We tried it, but it didn't work well [01:06] jesusabdullah: hah [01:06] jesusabdullah: Oh, it also came with tons of games [01:06] Nuck: As in, it just sat there and did nothing [01:06] jesusabdullah: no really GOOD games, but games nonetheless [01:06] jesusabdullah: Now I just need a TV [01:06] tmzt: with water? [01:06] tmzt: wow [01:06] jesusabdullah: or a computer with a tuner card [01:07] Nuck: We have a nice TV [01:07] Nuck: We bought the cheapest 40" LCD TV. [01:07] Nuck: But it works [01:07] Nuck: And it's 40 fucking inches. [01:07] lot49 has joined the channel [01:07] Nuck: We had a shitty SD-DVR from comcast before [01:08] tmzt: price? [01:08] Nuck: Then it stopped working, went wonky, the clock stayed at 12:00 midnight [01:08] Nuck: And they replaced it [01:08] Nuck: With an HD-DVR [01:08] halfhalo: bah, crapcast [01:08] Nuck: Dunno if they realized that. [01:08] Nuck: So we basically got a free upgrade :P [01:08] konobi: Nuck: cto of deviantart? what about him? [01:08] jesusabdullah: Zach Weiner just proposed selling a fridge magnet set that comes with 3, 8, D, ~ and \ only [01:08] jesusabdullah: s/\/= [01:09] jesusabdullah: s/\/=/ RATHER [01:09] Nexxy: jesusabdullah, that's obscene! [01:09] jesusabdullah: D: [01:09] Nuck: konobi: Well, my CTO was able to debate with him recently [01:09] jesusabdullah: I'm not obscene! [01:09] Nuck: And I'd honestly say mine is a bit more knowledgable, if less experienced. [01:10] jesusabdullah: Obviously it's for writing down certain equations [01:10] Nuck: dA's CTO is one of those "throw money at the problem" guys [01:10] execution: hmm, dotcloud looks clean and well-priced, but the gallery shows that no one notable is using them. nodejitsu, on the other hand, looks too new/young/startupy. heroku is crazy expensive. then there's joyent... going to check out their prices now [01:10] konobi: Nuck: *shrug* andy's pretty sharp... though quite business-ey [01:10] materialdesigner has joined the channel [01:10] Nuck: konobi: Andy? Hmmm, must not be their CTO I'm thinking of [01:10] jesusabdullah: Nexxy: I actually with it came with :, ), (, ; and < as well [01:10] Nuck: konobi: I meant their SA, sorry [01:10] Nuck: mixed up terms [01:10] Nuck: chris [01:10] jesusabdullah: as funny as i think the idea is, I think I'd get bored with it pretty quick [01:11] konobi: Nuck: chris bolt, yeah [01:11] Nuck: konobi: You know the guys at dA? [01:11] konobi: yup [01:11] tmzt: jesusabdullah: the secret is participating in 15 post long threads on HN [01:11] jesusabdullah: tmzt: Huh? [01:11] Nuck: konobi: lol they think Node doesn't scale [01:11] Nuck: They told me that [01:11] Nuck: And I giggled. [01:11] jesusabdullah: tmzt: Why would I go to hater news? [01:11] jesusabdullah: whaat [01:11] Nuck: Because they're on PHP + MySQL [01:12] Nuck: The least scalable stack I've ever seen. [01:12] Nexxy: oh cuz php scales! [01:12] albertosheinfeld has joined the channel [01:12] d0k has joined the channel [01:12] Nuck: riiiiiiight, it scales wonderfully. [01:12] jesusabdullah: I'm of the belief that anything can scale if you have enough of it [01:12] tmzt: any chance that php could ever support a long lived process properly? [01:12] Nuck: jesusabdullah: lol fair enough :P [01:12] bksf has joined the channel [01:12] konobi: Nuck: their CTO and ryan have talked at length over drink before [01:12] thepatr1ck: php can scale, I think facebook proves that. I wouldn't want to do it myself though. [01:12] jesusabdullah: Spin up ALL the instances! [01:12] bksf: anyone here using node on heroku with a db? [01:12] jesusabdullah: More bash scripts! MORE [01:12] Elems: if I have an object like this, http://pastebin.com/PC93m6KU , I get an error about child1 being undefined. What would the proper way of doing this be? [01:13] jesusabdullah: "I tried to parse a string and I think I ki9lled 20 people!" [01:13] thepatr1ck: bksf: I'm using it to talk to a couch instance at cloudant [01:13] Nuck: konobi: I know, but all of deviantTech "informed" me that Node doesn't scale well during a recent chat. [01:13] konobi: Nuck: there;s a C/C++ bias there, not a php one =0) [01:13] Nuck: konobi: They all know C, but their servers for their site are all PHP [01:13] konobi: infact, i believe they were looking at java too [01:14] jesusabdullah: yessch, java [01:14] ekryski has joined the channel [01:14] jesusabdullah: I kinda wanna learn me some clojure though [01:14] bksf: thepatr1ck: i like the structure of couch, im an advanced front and backend dev ... but coming from php then ruby to node (which i feel comfortable with the syntax of). is couch persistent? sorry not too familiar with it ... [01:14] Nuck: Java scales well, but finding a truly competent Java dev is harder than you'd think. [01:14] jesusabdullah: when I have time [01:14] konobi: actually, reminds me i need to call andy at some point to grab drinks [01:14] jesusabdullah: and stop being lazy [01:14] Nexxy: THERE IS NO TIME LIKE THE PRESENT [01:14] Nuck: tmzt: Long-lived processes? That's EASY. Just use php-cli. [01:14] Nuck: Duh. [01:15] Nexxy: Nuck-- [01:15] catb0t: Nuck now has 2 beers [01:15] v8bot_: Nexxy has taken a beer from Nuck. Nuck now has 0 beers. [01:15] zeade has joined the channel [01:15] Nuck: lol [01:15] thepatr1ck: bksf: couch is persistent, but is document based and doesn't support queries - you have to use map/reduce views, but that's not a minus for my use case [01:15] bksf: word gotcha. [01:15] Nuck: deviantART will never upgrade their tech. [01:16] tmzt: Nuck: only works if you have a routing framework [01:16] Nuck: They've invested far too much in PHP [01:16] bksf: im saving social media account info. best thoughts for heroku/node db? [01:16] Nuck: tmzt: Minor detail :P [01:16] Nuck: bksf: Dunno, would Mongo work on Heroku? [01:16] konobi: Nuck: if it ain't broke, why fix it? [01:16] AvianFlu has joined the channel [01:16] tmzt: turns out it's easy to build apis by dropping php files in folders [01:16] jesusabdullah: php-cli? What's that? [01:16] Nuck: konobi: I disagree, they still have issues with their site breaking daily. [01:16] thepatr1ck: bksf: couch also has rather nice replication, and with that a remote change notification feed that can give you a rather nice way of (combined with socket.io) pushing updates live to all clients without needing your node's to be talking to each other [01:16] jesusabdullah: I think I would honestly use forever for most of my process monitoring [01:17] jesusabdullah: It's, like, the process monitor I wish I had for my thesis [01:17] kdng-tr7 has joined the channel [01:17] Nuck: konobi: The entire community agrees dA hasn't fixed any of the glitches on-site in years. [01:17] Nuck: It's quite sad. [01:17] konobi: Nuck: heh, yeah i haven't used the site in about 10 years really =0) [01:17] jesusabdullah: Nuck: Making a better dA? [01:17] jesusabdullah: I bet you could do that [01:17] Nuck: jesusabdullah: Who's to say I won't :3 [01:17] bksf: thepatr1ck: sweet thanks man - [01:17] tmzt: Nuck: i've done pieces and parts of one [01:17] jesusabdullah: Make dA and ComicGenesis have a baby that studied with Dr. Imgur Dotcom [01:18] tmzt: in node :) [01:18] jesusabdullah: and went on to become good friends with node.js, obviously [01:18] Nuck: konobi: I've been hanging out on their chats for about a year and a half. The chats go down at least once or twice a week, have glitches that have stayed there for 6 years straight, and the JS for the client fits the traditional defition of spaghetti code [01:19] Nuck: Plus some of their static servers are incorrectly configured [01:19] Nuck: Causing all CSS, JS, and images to 404 [01:19] Nuck: tmzt: I have too ;) [01:20] Nuck: That's the startup lol [01:20] Nuck: I wanna provide an art site built from the ground up on modern architecture. [01:20] tmzt: now there's express-resource which I should have just built when I needed it [01:20] tmzt: oh that recommendation thing you've been talking about? [01:20] jesusabdullah: Some people think this hypothetical startup and node.js are dating, but they're not saying [01:21] jesusabdullah: We have, however, seen the way they look at each other! SOMETHING IS THERE DAMMIT [01:21] dreamdust: A one person team will have a tough time even coming close to building something on the level of DeviantArt... [01:22] jesusabdullah: That's why there's an entire team [01:22] Nuck: Two noders, a mobile app dev, and one of the best SAs I've ever known. [01:22] jesusabdullah: of leet hackers [01:22] jesusabdullah: Something Awful? [01:22] Nuck: Anywho time to go watch dinner an eat LOST! [01:23] dreamdust: Good luck, can't wait to sneak a peak! [01:23] Nuck: :D [01:23] kmiyashiro: I think it's called dribbble [01:26] jewgonewild: hey curious if anyone is building a chat like service running on multiple node servers .. wondering if anyone is handling state with redis and using a simple tcp node balancer .. haproxy etc in front of the nodes... [01:26] jewgonewild: ^load balancer.. not node balancer [01:26] Xeon06_ has joined the channel [01:27] bminer: ummm... i've run Node on EC2 [01:27] bminer: using Redis to handle state [01:27] bminer: i haven't used a load balancer yet, but it seems like it would be extremely straight-forward [01:27] ank has joined the channel [01:28] jewgonewild: bminer .. yeah running it on ec2 as well for now .. I only have 1 node server so I use objects to handle mapping of rooms <-> users [01:28] bminer: i dunno if Amazon uses haproxy... they have their own load balancing service [01:28] nuck-mobile has joined the channel [01:28] bminer: sure [01:29] neoesque has joined the channel [01:29] bminer: yeah you can also map users to rooms using Socket.IO 0.7 now [01:29] bminer: are you using Socket.IO? [01:29] jewgonewild: yeah bminer i use that for my web based views [01:29] lot49 has joined the channel [01:29] bminer: cool, using Express or Connect? [01:30] jewgonewild: but I have a mobile chat room that uses straight sockets, not websockets [01:30] nuck-mobile: Wow socket.io sounds epic for chat :D [01:30] captain_morgan has joined the channel [01:30] emet has joined the channel [01:30] bminer: nuck-mobile, yeah socket.io is definitely the library for anything real-time and Node related [01:31] tmzt: it's heavy and sometimes unpredictable [01:31] bminer: so hey... this is a message for everyone.... anyone used SocketStream AND Express web frameworks? [01:31] bminer: any opinions on them? [01:31] tmzt: it tries a bunch of protocols that don't really work (multipart http??) [01:31] nuck-mobile: I want to build it on joltproject.com's protocol and client (I have access to both) but use socket.io for the access layer [01:31] jewgonewild: it is pretty epic for chat .. I wrote that part in literally 15 minutes with socket.io [01:31] tmzt: socketstream expects you to do everything their way [01:31] tmzt: down to the directory structure [01:32] elliottcable: Nexxy: We lost you )= [01:32] bminer: tmzt - yes I agree [01:32] bminer: the other thing I don't like about SocketStream is the single-page application concept.... [01:32] bminer: or well... i should clarify... i love the concept, but it kills SEO [01:32] nuck-mobile: All I'll have to do is build a server. Might have my other noder work on if when they get going [01:32] Nexxy: elliottcable, I lost myself too ;< [01:32] boogyman has joined the channel [01:33] bminer: SocketStream also adds some REALLY cool functionality like API trees, shared code between client/server, RPC, etc. [01:33] sholden: does anyone know how i can set a timeout for dns requests? it's making my http requests hang waaay longer than i want them to [01:33] Nexxy: basically a bunch of things that are already available in existing packages?! [01:34] bminer: i suppose that's true [01:34] bminer: it's just nice to start with a robust framework [01:34] nuck-mobile: bminer: I plan to use pushState for my single-page setup so my seo shouldn't suffer [01:34] nuck-mobile: Plus it's not socket driven, it's all REST. [01:34] markmarkoh has joined the channel [01:34] yozgrahame has joined the channel [01:35] albertosheinfeld has joined the channel [01:35] bminer: nuck-mobile: what about Google's crawler? Check out http://code.google.com/web/ajaxcrawling/docs/getting-started.html [01:35] brolin has joined the channel [01:35] jewgonewild_ has joined the channel [01:35] bminer: i am not a true fan of REST... btw... just use GET and POST and forget about it [01:36] nuck-mobile: bminer: it's not a problem, pushState means I'm using normal urls and such [01:36] jewgonewild_: I like that socket.io abstracts away a lot .. [01:36] bminer: nuck-mobile: i'm interested... how does that work exactly? [01:36] abraxas has joined the channel [01:36] bminer: nuck-mobile: do you have a link I can read up on it? [01:37] nuck-mobile: bminer: it's simple: you use normal links, preventDefaulr, then pushState and Ajax to update the URL and page (respectively) [01:37] tmzt: pushState? [01:38] tbranyen: tmzt: he means html5 history api [01:38] tmzt: okay [01:38] tbranyen: which allows you to maintain browser state and change the url without refreshing the page [01:38] nuck-mobile: It's what Facebook and github use for stuff, and yes, that's right. [01:39] tbranyen: well i mean you can't just use pushState [01:39] tbranyen: I gave a talk on this stuff a while back that explains one method of working with HTML5 history navigation backed by a server... its still not very easy to do cleanly [01:39] nuck-mobile: I'll use a link-overriding thing similarly for hashurls too [01:39] tbranyen: I've been messing with backbone to alleviate some code duplication [01:39] bminer: nuck-mobile: alright fine, but what about incompatible browsers???? [01:39] tbranyen: bminer: f em, just load pages from the server [01:39] elliottcable: Nexxy: → ##Paws! [01:40] nuck-mobile: bminer: falls back like tbraynen said. [01:40] tbranyen: Those are people who aren't going to be looking for a fast experience anyways [01:40] tbranyen: anyone running modern firefox, chrome, opera, etc. will get it, but IE users unfortunately are still left out [01:41] saurabhverma has joined the channel [01:41] nuck-mobile: But I'll also be providing hash urls as a fallback. If the page has a hash URL on load, but the browser supports pushState, it'll fix it [01:41] tbranyen: nuck-mobile: that sucks tho, since those aren't easily bookmarkable [01:41] tbranyen: servers can't read hashs data [01:41] MarkMenard has joined the channel [01:41] tbranyen: you'll have to write even more code to handle rendering the correct page after / has already loaded [01:42] nuck-mobile: Tbraynen: I'm thinking about that, and wondering if it's a problem. [01:42] nuck-mobile: And my entire site is one page anyways [01:42] bminer: so let me get this straight.... i use pushState to trick the browser to display a new URL in the address bar. Client JS loads a page or page fragment and replaces a DOM element, for example? [01:42] emet: is mongodb typically used with node.js [01:42] tbranyen: mine is sorta the same thing. client side its one page, but you can hit any pages and they will be immediately rendered by the server [01:42] tbranyen: emet: i'm using it [01:43] tbranyen: bminer: sure [01:43] nuck-mobile: bminer: that about sums it up, I think [01:43] bminer: I also hook my JS to any anchor tags? [01:43] tbranyen: and forms probably [01:43] tbranyen: those are the only two i know of that would need it [01:43] bminer: so my and
tags point to REAL links [01:43] tbranyen: yes [01:43] CrabDude: bminer: and when you go "back" to the faux url, it pops whatever object you stored in the history stack, presumably your state to repopulate the page [01:43] nuck-mobile: Tbraynen: I don't return any HTML from the server ever [01:43] tmzt: bminer: you can do that with just jquery as well [01:43] bminer: nuck-mobile: hmmm.... interesting stuff [01:43] tbranyen: nuck-mobile: ah, thats where we differ then [01:44] nuck-mobile: All is json through a restful api [01:44] tmzt: I've used $("a[href='/whatever']") a few times [01:44] tbranyen: nuck-mobile: yeah i have that too [01:44] tmzt: the problem is navigation doesn't always work that way [01:44] tbranyen: but i want every page to load ridic fast [01:44] tmzt: because if you set the location.href it actually goes to taht that page [01:44] nuck-mobile: Same but rest is pretty wicked fast [01:45] tbranyen: nuck-mobile: not fast enough that i don't notice it :-/ [01:45] tbranyen: i can tell when stuff is loaded async on the first load [01:45] tbranyen: and i care most about that first page load [01:45] tbranyen: than the rest [01:46] nuck-mobile: It'll be rested in on later pageloads [01:46] albertosheinfeld has joined the channel [01:46] harthur has joined the channel [01:46] tbranyen: also its kind of nice knowing my site will load in any browser regardless of JS support [01:46] tbranyen: one thing thats cool is conditionally caching your templates and data nuck-mobile [01:47] tbranyen: you can get some huge speed boosts there [01:47] nuck-mobile: Well yeah I'm gonna do like fb or gh with regular fallbacks [01:47] tbranyen: have node poll for file changes and update a hash with the crc and then use that as the e-tag [01:48] nuck-mobile: Lolwat [01:48] tbranyen: thats what i've been thinking [01:48] tbranyen: instead of doing it per request [01:48] tmzt: tbranyen: bminer: actually, you can still use hashtag navigation with real urls [01:49] CrabDude has left the channel [01:49] nuck-mobile: Oh I see to check if the source is modified [01:49] tbranyen: yeea [01:49] CrabDude has joined the channel [01:49] tbranyen: tmzt: huh [01:49] tmzt: it's easye enough to support both and wildcard route on the server [01:49] fengshaun has joined the channel [01:49] tmzt: returning the same page for any url requested [01:49] tmzt: then detect the location as you would for a hash [01:49] tbranyen: tmzt: yeah and that looks like crap [01:49] tbranyen: unfortunately [01:49] tbranyen: its a poor solution [01:49] tbranyen: to something that isn't a problem [01:49] tmzt: how would it look like anything? [01:49] tmzt: HTTP is just a protocol transferring resources [01:50] dreamdust: No… tmzt is talking about having /#/events and /events resolve to the same thing. [01:50] tbranyen: because it needs to load a generic page until the client can ping back the hash url [01:50] fengshaun: I just learned about node.js today. And before I start, I wanted to know: is node its own server or does it need a web server like apache, etc.? [01:50] tmzt: and 'same page' [01:50] tmzt: actually no, you can do the same routing server side if you prefer [01:50] tbranyen: dreamdust: yes i know [01:50] tbranyen: and it looks bad [01:50] tmzt: and serve the same partials [01:50] tbranyen: tmzt: its not possible to do it as clean as history api [01:50] tmzt: by same page I mean same code handling it (easy in node, not so much in php for instance) [01:51] dreamdust: The only way to do history tied to URL's is hashes. [01:51] dreamdust: You can do an iframe history [01:51] dreamdust: but you won't have a URL in the address bar [01:51] tmzt: right, because you fix up the url to a hash address if js is enabled [01:51] nuck-mobile: Aren't there any Ajax-ifying libs yet? [01:52] apejens: fengshaun: quite new myself, but it is easy to write a stand alone server with node.js. IF that is how most people deploy things I don't know (the things I ahve deployed, is deployed like that) [01:52] tbranyen: you have more symapthy for users of crappy browsers than i do :-p [01:52] tmzt: apejens: that or with a reverse proxy in front [01:52] nuck-mobile: That'll do like socket.io and unify ahit [01:52] fengshaun: apejens: thanks! But I want to know what is the common deployment method. [01:53] dreamdust: @fengshaun many people use Connect [01:53] dreamdust: http://senchalabs.github.com/connect/ [01:53] fengshaun: dreamdust: thanks! [01:53] tmzt: dreamdust: you talking about spark? [01:53] nuck-mobile: That's deployment? [01:54] dreamdust: Oh… sorry fengshuan I misread your quesiton [01:54] dreamdust: blah [01:54] nuck-mobile: Last I checked connectwas just a middleware lib [01:55] fengshaun: dreamdust: oh! [01:55] fengshaun: that's alright. [01:55] AAA_awright: nuck-mobile: I would strongly recommend against hash-bang URLs, they don't mean anything to the web server and thus you can't return a proper 404 or other things like you should be able to with a HEAD request. It's one of those things you can never go back... I would just sugguest a traditional page load, period. [01:55] tbranyen: AAA_awright: +1 [01:55] dreamdust: Agreed. [01:56] CIA-65: libuv: 03Ben Noordhuis 07master * ra1adfe3 10/ src/uv-unix.c : uv-unix: cast argument to uv__stream_open() to uv_stream_t* - https://github.com/joyent/libuv/commit/a1adfe3e236eb7d3e18d724034e657e197dcab54 [01:56] tbranyen: AAA_awright: I didn't even think of traditional 404, thats an excellent point [01:57] upstream has joined the channel [01:58] thinkt4nk has joined the channel [01:58] cjm has joined the channel [01:58] plutoniix has joined the channel [01:58] AAA_awright: just onclick=function(e){if(window.history.pushState){ajaxLoadPage(this); return false;}} [01:59] nuck-mobile has joined the channel [01:59] _jhs has joined the channel [01:59] tbranyen: AAA_awright: you should also test for http [01:59] tbranyen: and allow those requests to pass through [01:59] tbranyen: external pages shouldn't be subject [02:00] fengshaun has left the channel [02:00] nuck-mobile: AAA_Awright: I've been thinking about those problems too [02:01] AAA_awright: tbranyen: Well, check for a relative URL while you're doing that [02:02] AAA_awright: Maybe more along the lines of: [02:02] tbranyen: AAA_awright: only time i can think of that failing is if you have ftp or something else [02:02] tbranyen: like spotify:/// [02:02] AAA_awright: onclick=function(e){if(window.history.pushState && ajaxLoadPage(this)) return false;} [02:02] S3ig3 has joined the channel [02:02] S3ig3 has left the channel [02:02] AAA_awright: So now the page loader can run its own tests and return true to catch it [02:02] tbranyen: what would ajaxLoadPage return if its a valid url? [02:02] tbranyen: er [02:03] tbranyen: would ajaxLoadPage do the valid url checking [02:03] Drakonite has joined the channel [02:03] AAA_awright: Yeah, you get to define ajaxLoadPage however you want :) [02:04] tbranyen: thats not a bad idea [02:04] plutoniix has joined the channel [02:04] tbranyen: i'd prefer to be more explicit [02:06] execution: anyone here use dotcloud for managed node.js hosting? looks like a great service to me. [02:06] jtsnow has joined the channel [02:06] ditesh|cassini has joined the channel [02:07] zeade has joined the channel [02:10] tracker1 has joined the channel [02:11] Nuck: AAA_awright: I'm gonna create a function to handle each pageload for me. [02:11] Xeon06_ has joined the channel [02:12] apejens: execution: I juse dotcloud for some other stuff, works great :) [02:12] Nuck: I just put it in onclick for all links, and it'll override the default links [02:12] Nuck: something like ajax.get('/path/or/api/call') [02:14] CIA-65: node: 03Ben Noordhuis 07master * rde26171 10/ (20 files in 5 dirs): uv: upgrade to a1adfe3 - https://github.com/joyent/node/commit/de261713bfdffece3a5675fcf325dbcca7542e87 [02:14] CIA-65: node: 03Igor Zinkovsky 07master * r187fe27 10/ (10 files in 3 dirs): stdio binding + javascript to enable process.stdin.listen() - https://github.com/joyent/node/commit/187fe27a6e7da9d1f5ec9896af51a16c69d4c6c2 [02:14] CIA-65: node: 03Ben Noordhuis 07master * r83b82f9 10/ (src/pipe_wrap.cc src/tcp_wrap.cc): wrap: upgrade pipe_wrap and tcp_wrap to new libuv API - https://github.com/joyent/node/commit/83b82f900faa0c1ecb1adb9fcfe31936ce51fa41 [02:15] _jhs has left the channel [02:15] shanebo has joined the channel [02:20] joshfng has joined the channel [02:21] seivan has joined the channel [02:21] Xeon06_ has joined the channel [02:22] ngs has joined the channel [02:23] ank has joined the channel [02:25] sw8sw8 has joined the channel [02:26] konobi: enotj? [02:29] sw8sw81 has joined the channel [02:30] luke` has joined the channel [02:30] Swimming_bird has joined the channel [02:31] slifty_ has joined the channel [02:31] Xeon06_ has joined the channel [02:32] rpflo has joined the channel [02:34] Me1000 has joined the channel [02:34] Nuck: AAA_awright: My new node guy took my multi-paragraph algorithm and turned it into a 5-line function. [02:34] Nuck: Best of all, it follows the map, reduce setup, where you map out the results, then reduce them. [02:34] Nuck: (I might add, this setup is what Google uses) [02:34] gazumps has joined the channel [02:35] AAA_awright: multi-paragraph, what's that? [02:35] Nuck: AAA_awright: It means I wrote it out in plain English [02:35] konobi: Nuck: schwartzian transform? [02:35] Nuck: He made my entire sorting mechanism in 5 lines [02:36] Nuck: (it'll probable be blown into about 10 lines) [02:36] Lorentz: Give him a raise [02:36] Nuck: It's fucking efficient, now that I look at it [02:36] Nuck: It can effectively sort using VERY little iteration. [02:36] Nuck: (well, not sorting an array, but generating a value for each) [02:36] AAA_awright: Nuck: Oh oh, I thought you meant some paragraph-splitting algorithm, no you mean yours [02:36] Xeon06_ has joined the channel [02:37] Nuck: AAA_awright: yeah, the entire sorting mechanism in 5 lines. [02:37] Nuck: And he gave me a basic example of what the results would be, it sorts VERY cleanly [02:37] irrumato1_ has joined the channel [02:37] bradleymeck: Array.sort is soo hard to fin beat though in practice [02:37] Nuck: Though my "values" will get a bit high with lots of inputs. [02:37] Nuck: bradleymeck: Not sorting an array [02:37] bradleymeck: cant always be used though [02:37] AAA_awright: Nuck: Well I still don't have your description of what it's supposed to _do_, I'm still thinking of my idea which calculates a probability of favorite/like based on past ones [02:37] Nuck: Sorting a simple array by values. [02:38] Nuck: Err derp [02:38] Nuck: It'll be algorithmically ranking it. [02:38] Nuck: AAA_awright: That's the general purpose, but I'm keeping it safe inside my company. [02:38] Nuck: It's our core feature [02:38] konobi: Nuck: http://en.wikipedia.org/wiki/Schwartzian_transform [02:38] konobi: it look like that? [02:39] irrumator_ has joined the channel [02:39] tracker1: anyone in here familiar with spidernode? [02:39] Nuck: Hmmm [02:39] cjm has joined the channel [02:40] mraleph has joined the channel [02:40] tracker1: (spidermonkey based port of node)... mainly curious if anyone has used it, if e4x is enabled, and how the performance compares... [02:40] Nuck: konobi: That's not a sorting algorithm, is it? [02:40] AAA_awright: Nuck: We can talk about it in private but, are you familiar with http://www.artspots.com/ ? They have some sugguestion for similar art, if not calculated for you individually [02:40] konobi: yup [02:40] konobi: a rather efficient one too [02:41] Nuck: konobi: Well, the concept is to look at tags on uploads and tags that the user likes, then associate the sorting value to the id of each upload [02:41] Nuck: And then just sort by the value [02:42] Nuck: The sorting value is where the secret magic happens [02:42] Nuck: it's not based on x relative to y [02:42] konobi: so it's a weighted set as the result of a union? [02:42] captain_morgan has joined the channel [02:43] Nuck: konobi: Yeah, that about sums it up. We've got some optimizations on the set-retrieval too, of course, otherwise that'd be a LOT of data to process. [02:43] AAA_awright: Nuck: Talking multiplication and tags and stuff as I understand it would be easy to implement, and is probably well suited for map-reduce, but I can't imagine it's very good or accurately predicts what users would like [02:44] Nuck: AAA_awright: Surprisingly, it worked effectively on test groups. [02:44] Nuck: I think it's the rule of KISS [02:44] Nuck: It's so simple it's actually very efficient. [02:45] lot49_ has joined the channel [02:45] konobi: sounds similar to a hotel search engine I worked on once [02:45] Nuck: Before, I was worried that the sorting algorithm would be a major bottleneck, since it'd hafta be computed a lot. However, seeing the simplicity of an implementation, it'll be more of a bottleneck in the optimizing. [02:45] konobi: though that was crazier due to use of hilberts curve [02:45] konobi: worked for the data though [02:46] Nuck: konobi: we're gonna cull the obvious outliers before set retrieval, keep a cached weightlist for tags on each user, etc. - overall, it's gonna be a highly efficient algorith, [02:47] Swizec has joined the channel [02:47] Nuck: The problem lies entirely in narrowing down the set before we run the sort over it [02:47] Nuck: But even that should be feasible with minimal quality loss on the algorithm. [02:48] dgathright has joined the channel [02:48] Nuck: And if there are still problems, that algorithm can run on a separate Node instance. [02:49] AAA_awright: Nuck: How are you testing? [02:49] Nuck: AAA_awright: Generating our own testing data sets, using shitty fanart as examples lol [02:49] AAA_awright: Doing prediction, you trained on a test set, and test on separate experimental data [02:50] aconbere has joined the channel [02:50] konobi: genetic algorithm time! [02:50] sechrist has joined the channel [02:52] Nuck: The example last night was sonic fanart, actually. [02:52] Nuck: It'll keep us laughing as it returns yiffing, I'm sure :P [02:53] AAA_awright: Again maybe this is me not understanding the purpose, but if you're testing for subjective things like that you need actual data that reflects people's complexities [02:53] lot49 has joined the channel [02:53] Nuck: AAA_awright: The thing we're testing is if it properly sorts relevant artwork for a given person's preferences. [02:53] AAA_awright: Biggest example I can think of, Netflix was trained on half the data set and tested on the other half, of every rating that people inputted [02:54] Nuck: We input weighted tags [02:54] Nuck: And a data set [02:54] Nuck: And the sorting algorithm spits out ordered data [02:54] edude03 has joined the channel [02:54] AAA_awright: You can mathematically prove you're supposed to use half the data too, if it matters, instead of, say, training on 2/3 and testing on 1/3rd [02:54] Nuck: Simple enough. [02:55] Nuck: AAA_awright: We're laid-back folks, we develop using fucked-up example data, then to test it better, we do alpha testing. [02:56] Nuck: The only way to test if it's gonna work is to let a small ecosystem develop around the site, and then see if it holds up [02:57] willwhit_ has joined the channel [02:57] amerine has joined the channel [03:00] EyePulp has joined the channel [03:01] Swizec has joined the channel [03:01] Xeon06_ has joined the channel [03:02] ghost has joined the channel [03:03] oakmac has joined the channel [03:04] oakmac: is there an IRC channel specifically for express or socket.io ? [03:04] Nexxy: #express [03:04] yhahn has joined the channel [03:04] oakmac: thank you [03:05] oakmac has left the channel [03:06] elliottcable: Nexxy: WE STILL LOVE OU [03:06] elliottcable: Nexxy: … with … a y. [03:06] Nexxy: lol thanks <3 [03:07] captain_morgan has joined the channel [03:08] clifton has joined the channel [03:08] Corren has joined the channel [03:08] bminer: question for anyone about jade template engine [03:08] bminer: would anyone suggest using it on the client-side in the browser? [03:08] bminer: and if so... what's the best way? [03:08] bminer: i know it's possible... just want to understand performance implications [03:11] Navarr has left the channel [03:11] Xeon06_ has joined the channel [03:11] jameson has joined the channel [03:13] ank has joined the channel [03:13] cha0s has joined the channel [03:13] cha0s has joined the channel [03:14] skm has joined the channel [03:16] sridatta has joined the channel [03:17] mscdex: hrm.. why does npm install modules up one level instead of the cwd? [03:18] jokil has joined the channel [03:19] bminer: mscdex: it puts them in ./node_modules, right? [03:19] mscdex: not for me [03:19] gtramont1na has joined the channel [03:19] mscdex: it put them in ../node_modules [03:19] mscdex: :S [03:20] jokil: hey guys. is there any documentation available on the "node --prof" option for profiling? [03:20] konobi: did you create a node_modules directory in .? [03:20] mscdex: no [03:20] bminer: ummm... what is the cwd? [03:20] bminer: in this particular case? [03:20] mscdex: a path in my home dir [03:20] bminer: hm... [03:20] wookiehangover has joined the channel [03:21] sub_pop has joined the channel [03:21] bminer: what version of npm? [03:21] mscdex: this is a fresh node and npm install [03:21] bminer: lol you read my mind [03:21] mscdex: node 0.4.10 and latest npm (1.0.22) [03:21] mscdex: :-) [03:21] bminer: your computer is broken [03:21] Xeon06_ has joined the channel [03:21] mscdex: it's a VM [03:21] mscdex: :p [03:22] mscdex: isaacs: ping [03:22] bminer: lol turn it off... or whatever it is you do to stop it [03:22] bminer: h/o lemme try something [03:22] mscdex: bminer: it's not becoming self-aware ;-) [03:23] bminer: ummm... [03:24] bminer: when you do npm install in your home dir... it puts it under ~/node_modules/ [03:24] bminer: so your question is why? [03:24] jacobolus has joined the channel [03:25] bminer: mscdex: check out npm help install [03:25] bminer: you have to specify ./ [03:25] bminer: otherwise it puts it in ~/node_modules by default [03:25] bminer: unless you use -g flag [03:26] mscdex: no, it didn't install in ~/node_modules [03:26] Xeon06_ has joined the channel [03:26] mscdex: it installed in ../node_modules, which is not ~/node_modules [03:26] mscdex: :S [03:26] bminer: umm yikes [03:27] bminer: so it installed it in ~/.../.../foo? And cwd was ~/.../.../foo/bar [03:27] admc has joined the channel [03:27] mscdex: good thing i didn't have any modules installed in the parent dir [03:27] mscdex: heh [03:27] mscdex: bminer: yes [03:28] bminer: what was the command you issued to npm? [03:28] mscdex: npm install foo [03:28] mscdex: in this case it was express [03:29] bminer: the parent dir and cwd aren't named 'express' right? [03:29] bminer: stupid question but have to ask... [03:29] mscdex: nope [03:29] mscdex: they're named totally different [03:30] bminer: are you root? [03:30] Swizec has joined the channel [03:31] Corren has joined the channel [03:31] mscdex: no [03:32] Me1000 has joined the channel [03:32] bminer: what does ' npm config list' give you? [03:33] irrumator_ has joined the channel [03:33] irrumator_ has joined the channel [03:34] bminer: mscdex: ping [03:34] mscdex: bminer: ping [03:34] mscdex: :p [03:34] mscdex: bminer: it just lists a bunch of normal stuff [03:34] bminer: lame [03:34] scoates: I'm looking for a library that will convert e.g. "tomorrow at noon" to a Date object… any suggestions? [03:35] mscdex: scoates: date.js? [03:35] mscdex: just a guess [03:35] bminer: date.js will do it, i think [03:35] scoates: thanks. I'll check it out. [03:36] Corren has joined the channel [03:36] bminer: i've used it and it handles most of those things [03:36] Wa has joined the channel [03:36] scoates: it won't convert that particular one [03:36] scoates: at least not according to the on-page renderer at http://www.datejs.com/ [03:37] hacfi has joined the channel [03:37] scoates: flaky, but better than nothing. thanks. [03:37] bminer: true [03:38] bminer: it might not parse it, but you can call tomorrow().addHours(12) or something, right? [03:38] scoates: right. I was hoping to allow users to give it free-form (for an IRC bot) [03:38] AvianFlu has joined the channel [03:38] bminer: gotcha [03:39] bminer: i know it parses "Thursday 12 PM" [03:39] towski has joined the channel [03:39] bminer: that's close anyway [03:39] scoates: it gets "tomorrow at 12pm" wrong, though [03:39] scoates: I'm not complaining (-: [03:40] bminer: and "tomorrow at 12 pm" [03:40] bminer: oh you're right [03:40] bminer: lol [03:41] bminer: it accepts it but it's wrong [03:41] bminer: even better! [03:41] mscdex: scoates: maybe this patch will fix it for you: https://github.com/bislr/Datejs/commit/03bf1f7de78193e7144325a102c6bc974ae62635 [03:42] scoates: cool; thanks mscdex [03:44] upstream has left the channel [03:45] escii has joined the channel [03:45] alek_br has joined the channel [03:46] escii: npm ERR! error rolling back libxmljs@0.4.2 Error: libxmljs@0.4.2 preuninstall: `make clean` [03:46] escii: any idea whats wrong with libxmljs [03:46] shanebo: any mongodb-ers/mongoosers in here? [03:46] Xeon06_ has joined the channel [03:47] Rick_ has joined the channel [03:47] execution has left the channel [03:47] k1ttty has joined the channel [03:49] halfhalo-work has joined the channel [03:49] __directory: shanebo: sorta... [03:50] zeade has joined the channel [03:50] shanebo: well my main questions pertain to schema, which isn't particular to mongoose [03:51] __directory: what's the question? [03:51] Xeon06_ has joined the channel [03:52] Spion_ has joined the channel [03:52] bartt has joined the channel [03:54] shanebo: I have a collection of products which have a brand, warranty, and category [03:54] jesusabdullah: Oh man, part numbering schemes [03:54] shanebo: so a product belongs to a brand [03:55] shanebo: a product has_one warranty [03:55] kriszyp has joined the channel [03:55] shanebo: a product belongs_to a category [03:55] jesusabdullah: Why not multiple categories? [03:55] jesusabdullah: TAGS [03:55] shanebo: so I'm just confused what the best setup is [03:55] jesusabdullah: TAGS IF YOU WILL [03:55] jesusabdullah: I've not use the mongodeebees [03:55] jesusabdullah: That almost sounds like a good problem for an sql db [03:55] jesusabdullah: like, classic [03:56] shanebo: yeah but man the joins get nasty [03:56] __directory: I think with document storage craps you try and store everything on the product document [03:56] shanebo: and re tags, I could, however these categories are high level and definitional [03:56] __directory: embedded [03:56] Xeon06_ has joined the channel [03:57] ditesh|cassini has joined the channel [03:57] shanebo: __directory, yeah my only related question with that way is what if a brand name changes abroad? Do I just run an update across the board? [03:58] Corren has joined the channel [03:58] __directory: shanebo: man I don't there..I think i've seen that question answered with yes, you mass update [03:58] shanebo: k [03:58] __directory: insert know somewhere in my sentence [03:58] jhurliman has joined the channel [03:58] __directory: mongo's fast with that sort of stuff i've read [03:59] TooTallNate has joined the channel [03:59] __directory: im doing my first mongo thing right now and keep wanting to switch to Postgres [04:00] strcK has joined the channel [04:00] thepatr1ck: document based databases do require a change in thinking [04:00] alnewkirk has joined the channel [04:00] thepatr1ck: (that's not to say they're right for every situation, of course) [04:00] __directory: so do you mass update changes like that [04:00] Wa has joined the channel [04:01] thepatr1ck: the kind of data I'm storing doesn't need me to do that [04:02] thepatr1ck: (my work is using couch as the main "db" and mongo for stats) [04:02] shanebo: thepatr1ck so are you setting up multiple collections and saving relational ids in cases where embedding isn't wise? [04:02] AAA_awright: Hey #Node.js, I'm writing an authorization function that tests a user (already authenticated) for a granted permission, since it's likely against a database it'a async, so how would I design that? I have been using authz(user, permission, acceptcb, denycb) [04:02] AAA_awright: Did I say hi #node.js? [04:02] __directory: couch eh [04:03] Me1000 has joined the channel [04:03] thepatr1ck: shanebo: mongo: there's no relationships there (well I guess stats are stored against a "site", and that kind of counts as a relationship, but the site information isn't in mongo) [04:04] shanebo: i just listened to a talk from some 10gen guy that said relationships do exist [04:04] thepatr1ck: shanebo: and couch doesn't have collections, but there's a couple of cases where things refer to other things (page documents refer to a theme & layout, and those come from a theme document) [04:05] thepatr1ck: sorry, I meant we don't do relationships in mongo [04:05] shanebo: i see [04:06] Nuck has joined the channel [04:06] __directory: Nuck: ruby on rails; [04:06] Nuck: ACTION rages at __directory [04:06] Nuck: I'm rebuilding Node on Cygwin [04:06] Nuck: Haven't had a working node locally for months. [04:07] captain_morgan has joined the channel [04:07] gf3: don't the have a windows node now? [04:07] gf3: *they [04:07] Lorentz: So nice just doing ./configure && make && make install [04:08] Lorentz: And have everything work [04:08] __directory: yah but it's 0.5 [04:08] malkomalko has joined the channel [04:09] shanebo: thepatr1ck so what schema would you recommend for my products example? [04:09] ank has joined the channel [04:09] xonev has joined the channel [04:09] jewgonewild_: hey node on ec2.. 32bit or 64 bit instances? [04:10] domo1 has joined the channel [04:10] jesusabdullah: I dunno dude :( [04:11] jesusabdullah: I like 64 bit just cause it's teh futar [04:11] domo1: hello.. who would like to recommend a solid template engine for me to use in my node.js app [04:11] domo1: I'm not using express - so anything goes [04:11] jesusabdullah: and I think node doesn't give a shit [04:11] __directory: gurl you so right [04:11] shanebo: domo1 mustache [04:11] domo1: i'm looking at ejs.. looks pretty cool [04:11] jewgonewild_: hmm .. varying opinions about it [04:11] jesusabdullah: so it probably depends on what outside of node you're interested in [04:11] thepatr1ck: shanebo: the years-of-SQL-made-my-brain-mush side of me says "seperate documents", the nosql-hasnt-mushified-my-brain-yet side says "I need a nap" [04:11] CrabDude has joined the channel [04:11] jesusabdullah: ie, if some dep is pissy with respect to 64bit, then, well [04:11] jesusabdullah: u noe [04:12] jewgonewild_: well just pure node servers.. nothing else running on em [04:12] thepatr1ck: jewgonewild_: I've only used node in 64-bit land [04:12] jesusabdullah: domo1: jade, ejs, mustache, etc [04:12] CrabDude: just curious, anyone here have any particular opinions on AMD? [04:12] jesusabdullah: I always forget what I'm rollin' with [04:12] jesusabdullah: AMD; Intel's competition. [04:12] jewgonewild_: hmm .. I hate that ubuntu images on ec2 go from micro to large... [04:12] jewgonewild_: 64bit that is .. [04:12] thepatr1ck: domo1 / jesusabdullah: and handbrake, which is mustache with... something (performance optimisations I think) [04:12] CrabDude: https://github.com/amdjs/amdjs-api/wiki/AMD [04:12] CrabDude: Asynchronous Module Definition [04:13] __directory: hmm [04:13] malkomalko: anybody messed around with trying to create a headless browser via the qtwebkit bridge? [04:13] CrabDude: it's a Javascript cross-environment module definition specification [04:13] Aria: It's been done, malkomalko. [04:13] materialdesigner has joined the channel [04:14] malkomalko: I found phantomjs, but it doesn't look like you can interact with it directly [04:14] domo1: whoa [04:14] domo1: phantomjs looks great [04:15] jewgonewild_: using phantom js for some stuff [04:15] jewgonewild_: pretty solid [04:15] domo1: wow.. this is great [04:15] malkomalko: jewgonewild_: how are you using it from node? [04:16] domo1: so jade looks a little heavy to me.. maybe something light? mustache seems lighter. anything lighter than that [04:16] shanebo: mustache is about 300 lines. can't get much lighter than that [04:16] thepatr1ck: jade and I didn't get along _at all_ [04:16] jewgonewild_: I'm not .. [04:17] domo1: ejs? [04:17] domo1: I haven't looked yet.. will now :) [04:18] thepatr1ck: domo1: https://github.com/thepatrick/change-counter is a stupid little app I built that uses handlebars with express for its views [04:19] Wa has joined the channel [04:19] domo1: thepatr1ck: very nice thanks [04:21] jellosea: if i export a class using module.export = constructor, can i export other static functions in the same file using exports.staticfunction = staticfunction? [04:21] jellosea: that doesn't seem to work for me.. [04:22] avalanche123 has joined the channel [04:23] malkomalko: yes [04:23] malkomalko: only one module.exports [04:23] malkomalko: not module.export [04:23] jellosea: yeah [04:23] jellosea: okay thanks [04:24] irrumator_ has joined the channel [04:24] jellosea: so i should make those static functinos part of the prototype of the class [04:24] jellosea: "class" [04:26] Xeon06_ has joined the channel [04:26] ceej has joined the channel [04:27] Corren has joined the channel [04:31] jerrysv has joined the channel [04:31] sholden has joined the channel [04:31] JaKWaC has joined the channel [04:31] JaKWaC: Anyone have some experiences migrate an application to a new cryption algorithm for password? [04:31] Xeon06_ has joined the channel [04:35] dexter_e has joined the channel [04:36] Xeon06_ has joined the channel [04:37] zackattack has joined the channel [04:37] CrabDude has joined the channel [04:40] felixge has joined the channel [04:40] felixge has joined the channel [04:41] domo1 has left the channel [04:41] Xeon06_ has joined the channel [04:44] ngs has joined the channel [04:45] guest_693 has joined the channel [04:46] Xeon06_ has joined the channel [04:47] losing has joined the channel [04:48] JojoBoss has joined the channel [04:48] jvdev has joined the channel [04:48] ank has joined the channel [04:49] mendel_ has joined the channel [04:49] Skipants has joined the channel [04:49] bradleymeck has joined the channel [04:50] TooTallNate has joined the channel [04:50] CrabDude has joined the channel [04:51] collinwat has joined the channel [04:52] jaket has joined the channel [04:53] collinwat has joined the channel [04:55] Nuck: Okay, now I'm having NPM troubles. [04:55] Nuck: Fun. [04:55] Nuck: https://gist.github.com/5ead47f52f9190a89c06 [04:55] Nuck: Can somebody help meh? [04:56] AvianFlu has joined the channel [04:56] Xeon06_ has joined the channel [04:58] thepatr1ck: that is one unhappy npm, although it looks like it's trying to unpack an invalid tar.gz/.tgz... (stupid question time) tried clearing out /tmp, the node_modules directory in the directory you're in, and tried it a second time? [04:58] boehm has joined the channel [04:58] Nuck: thepatr1ck: I'll try that lol but it's a pretty much fresh install [05:00] jstroem has joined the channel [05:01] Xeon06_ has joined the channel [05:02] tig has joined the channel [05:02] srid has joined the channel [05:02] srid has joined the channel [05:02] tig: hurr. express requires I use node < 0.5. Gotta re-build it [05:04] Nuck: thepatr1ck: No luck, same issue :/ [05:05] Nuck: tar is still dying for me. [05:06] Xeon06_ has joined the channel [05:07] Nuck: Aynone else got any ideas? [05:07] thepatr1ck: I'd try here, but I'm on node 0.5.x so express goes NO I DON'T WANT TO PLAY IN YOUR SANDPIT and I say "but I don't have a sandpit" and it all goes downhill from there. [05:07] Nuck: lolwat [05:07] thepatr1ck: (I think I need more caffeine) [05:08] thepatr1ck: ok, so the exact error message is npm ERR! Not compatible with your version of node/npm: express@2.4.3, but close enough ;) [05:08] seivan has joined the channel [05:09] battlecollie has joined the channel [05:10] tig: thepatr1ck, same problem as me =]. Hm, is it possible to just force npm to install it anyway? [05:10] Ian_Corne has joined the channel [05:14] Nuck: Any kown issues with NPM and Cygwin? [05:16] Xeon06_ has joined the channel [05:18] lot49 has joined the channel [05:19] tig: whoa weard [05:19] tig: weird [05:20] tig: I built and installed node 0.4.9 to get around the version problem, and now when I install with npm I get lines like this: ��� connect@1.6.0 [05:20] tig: why the funny character? [05:21] AvianFlu: tig: what npm version [05:21] tig: 1.0.20 [05:21] Xeon06_ has joined the channel [05:21] AvianFlu: does it work properly and just show weird chars, or does it not work? [05:21] tig: hm, seems like it doesn't work [05:22] tig: I mean it pretends to work but then when I go and require() something it's not there [05:22] tig: could be cuz I built it for my old version of node and now I gotta re-install it [05:22] xonev: does anyone know if there's a templating engine which works with express and has an emacs major mode? [05:22] zilch has joined the channel [05:23] xonev: i looked around for a jade major mode, but the only one i found was in very early (buggy) stages of development [05:24] Wa has joined the channel [05:24] tig: hurr [05:24] tig: this is frustrating [05:24] tig: npm wont install anything [05:24] thepatr1ck: definitely worth reinstalling npm [05:26] tig: just did [05:26] tig: no luck [05:26] tig: though [05:27] tig: I didn't install it with a package in the first place, so I dunno how to get rid of it... [05:27] tig: oh it's on the github page [05:29] mikeal has joined the channel [05:30] hassox has joined the channel [05:31] jokil has joined the channel [05:31] sridatta has joined the channel [05:31] skm has joined the channel [05:31] Xeon06_ has joined the channel [05:32] tig: argh this is frustrating [05:32] fangel has joined the channel [05:33] Ginlock has joined the channel [05:33] tig: do I have to set an environment variable so node can find the node modules? [05:33] Nuck: Still looking for help on that NPM issue [05:35] tig: yep [05:36] ibolmo has joined the channel [05:36] tig: what's the environment variable I have to set so node can find its modules? [05:36] thepatr1ck: tig: node just looks node_modules in the current directory, then in the parent directory, and so on and so on and so on (until it runs out of directories ;)), but then also looks in other places - require.paths tells you where it looks (0.5.2 changes that to a function call or something) [05:36] AvianFlu: don't use require.paths [05:36] ibolmo: anyone know if it's appropriate to ask requirejs questions here? perhaps a better channel? [05:36] AvianFlu: there's a NODE_ENV environment variable or something, I'll go look for the link [05:36] Xeon06_ has joined the channel [05:37] tig: thepatr1ck, well npm is instnalling stuff to /usr/local/lib/node_modules so I need it to look there [05:37] tig: ibolmo, idk but I might be able to answer [05:37] AvianFlu: disregard NODE_ENV, I'm confused [05:37] ibolmo: thanks tig [05:37] thepatr1ck: try NODE_PATH [05:37] AvianFlu: there's an env variable though [05:37] AvianFlu: YES [05:37] AvianFlu: that was it [05:37] Spion_ has joined the channel [05:37] luke` has joined the channel [05:37] luke`_ has joined the channel [05:37] thepatr1ck: AvianFlu: I was pointing at require.paths to get an idea of what the paths node was looking at already, not to modify [05:38] tig: yeah now it works [05:38] secoif has joined the channel [05:38] tig: heh, would be nice if npm and node could just agree on where to put things though [05:38] thepatr1ck: (although every other scripting language I use supports modifying the require path at run time grumble grumble) [05:38] tig: since the default doesn't seem to work [05:38] ibolmo: i'm doing this: require([depA, depB], onReady); except I'm expecting that onReady will only get called after depA, and depB are "ready".. meaning if depA is: require([depC, depD], onReadyA) and so on [05:38] ibolmo: right now i'm logging that onReadyA is being called prior to onReady [05:39] tig: ibolmo, well there is a require.ready(callback) [05:39] tig: but I'm surprised that would happen for you [05:39] ibolmo: oh sorry rather that onReady is called prior to onReadyA [05:39] ibolmo: require.ready is for the DOM right? [05:39] tig: yes [05:39] materialdesigner has joined the channel [05:39] tig: i don't think that is supposed to happen [05:39] ibolmo: yeah my question is more of the way that modules are loaded [05:40] tig: ACTION shrugs [05:40] ibolmo: yeah ditto ;D [05:41] thepatr1ck: ibolmo: are you just requiring ordinary node modules/npm modules or something else? [05:42] Nuck: ... [05:42] tig: oh wait [05:42] tig: I know the problem [05:42] tig: you're supposed to use define() for modules, not require() [05:42] Nuck: the fuck just happened? [05:42] tig: require() runs right away. define() waits [05:42] ibolmo: oh [05:42] ibolmo: i'll try that thanks tig [05:42] tig: you have to start with a require() but everything it requires should use define() [05:42] e6nian has joined the channel [05:43] Nuck: chapel, jesusabdullah: lolwat. [05:43] chapel: lol [05:43] chapel: !gtfo [05:43] chapel: :) [05:43] chapel: nothing [05:43] chapel: was just playing around [05:44] ryuh: bfdl !!! [05:44] chapel: okay, time for bed [05:44] jesusabdullah: gnight homie g [05:44] ibolmo: woot. good eye tig [05:44] jesusabdullah: chaple. [05:44] jesusabdullah: Obviously. [05:44] chapel: kakarot [05:44] chapel: ACTION parts [05:45] blueadept has left the channel [05:45] Nuck: https://gist.github.com/5ead47f52f9190a89c06 Here, guys, have an updated error log. [05:45] Nuck: I added npm-error.log too [05:45] Nuck: Can somebody read these things? [05:46] Skipants has left the channel [05:48] thepatr1ck: weird, failing on the npm package now, it's almost like somethings failing to retrieve them .tgz files correctly [05:48] Nuck: Maybe it's github? [05:49] yozgrahame has joined the channel [05:51] Xeon06_ has joined the channel [05:52] AvianFlu: thepatr1ck: try npm config set loglevel info [05:52] AvianFlu: see if it gives you any extra info [05:52] AvianFlu: I should say, 'see if it gives you any extra USEFUL info' [05:52] thepatr1ck: Nuck: try that (AvianFlu: npm is fine for me, to the extent that npm is ever fine) [05:53] Xano has joined the channel [05:53] AvianFlu: wrong name then, but the advice stands :-P [05:53] Nuck: AvianFlu: k lol [05:53] ibolmo: thanks again tig [05:53] ibolmo has left the channel [05:53] AvianFlu: I like npm at loglevel info, it's easier to tell whether or not my internet is down! [05:54] Nuck: suddenly, I think it worked? [05:55] Nuck: it did D: [05:55] Nuck: LOLWAT [05:55] __directory: Nuck: Rails [05:55] __directory: Nuck: Rails!!!! [05:55] Nuck: RAGE-OLS [05:56] wbw72 has joined the channel [05:57] stephank has joined the channel [05:59] tmpvar has joined the channel [06:01] Xeon06_ has joined the channel [06:02] SamuraiJack has joined the channel [06:04] xonev has joined the channel [06:06] Xeon06_ has joined the channel [06:07] tig: oh huh, express is giving a "forbidden" response to some of my files [06:07] tig: why is this... [06:08] jesusabdullah: Probably because you're FORBIDDEN [06:08] jesusabdullah: from VIEWING them [06:08] jesusabdullah: Try changing the permissions [06:08] tig: yeah but why [06:08] jesusabdullah: that's my suggestion [06:08] jesusabdullah: the files themselves may not be o+r [06:08] tig: it has r's in every category [06:08] jesusabdullah: Really? [06:08] tig: and it's owned by the same user as the server [06:08] tig: yes [06:08] jesusabdullah: Oh my [06:08] jesusabdullah: Well, there go MY ideas :( [06:08] jesusabdullah: Soz dude [06:09] tig: =[ [06:11] Xeon06_ has joined the channel [06:12] _dc has joined the channel [06:16] tmzt: tig: forbidden in the browser? (403 or so)? [06:16] tig: yes [06:16] Xeon06_ has joined the channel [06:16] tmpvar: tig: static files? [06:17] tig: yep [06:17] tig: served by express [06:17] tmpvar: weird [06:17] shanebo: hey guys are these two lines doing the same thing? [06:17] shanebo: emitter.addListener(event, listener) [06:17] shanebo: emitter.on(event, listener) [06:18] shanebo: or is one attaching a listener and the other fires it? [06:19] ctide: addListener + on are the same thing [06:19] thepatr1ck: shanebo: same, though I believe on is the preferred now [06:20] shanebo: okay, so how do you fire it though? [06:20] __directory: emit [06:20] fille has joined the channel [06:20] shanebo: app.emit(event, args) ? [06:21] __directory: pretty sure [06:21] tig: hm, tried using readFile in node on those files and it says unknown encoding [06:21] Xeon06_ has joined the channel [06:21] tig: why would that be [06:22] tig: file says it's ASCII text [06:23] tig: oh I was using readFile wrong [06:23] tig: hurr, raw bits [06:23] tig: if I tell it its ascii it works fine [06:25] newy_ has joined the channel [06:26] NetRoY has joined the channel [06:26] Xeon06_ has joined the channel [06:27] __directory: thing.on('booze', function() { console.log('booze!'); [06:27] __directory: }); [06:27] __directory: thing.emit('booze'); [06:27] __directory: thing.emit('booze'); [06:27] svenlito has joined the channel [06:27] __directory: yah that works [06:27] __directory: million dollar code. [06:29] AvianFlu has joined the channel [06:30] mikedeboer has joined the channel [06:30] Nuck: Node is one perful fucker. [06:30] __directory: perl? [06:30] Nuck: *powerful [06:30] Nuck: And *npm [06:31] Nuck: ACTION 's brain is dying DX [06:31] donald_cook has joined the channel [06:31] loob2 has joined the channel [06:31] tig: ACTION sighs [06:31] andree has joined the channel [06:31] tig: idk why it's doing this [06:31] Xeon06_ has joined the channel [06:31] tig: it works fine no my macbook [06:32] tig: guess I'll try and match the versions... [06:35] CrabDude has joined the channel [06:35] tig: ACTION tears out hair [06:36] tmzt: tig: try tracing with strace [06:36] Xeon06_ has joined the channel [06:36] tmzt: hmm [06:37] tig: how do I do that? [06:37] tmzt: no, you don't need that [06:37] tmzt: it wasn't file permission issue [06:37] tmzt: (but, for reference strace -ff -e open,stat -p is what I use) [06:38] tmzt: you can specify encoding for a Buffer and for toString() from a buffer [06:38] tig: uh? [06:38] lot49 has joined the channel [06:38] groom has joined the channel [06:38] tig: what are you telling me? [06:39] tmzt: tmpvar: ? [06:40] mscdex: is there some way to see what (watchers) libev is still waiting on? [06:40] yozgrahame has joined the channel [06:43] herbySk has joined the channel [06:43] shanebo: callback hell isn't fun [06:43] CrabDude has joined the channel [06:44] mscdex: you're doing it wrong ;-) [06:45] shanebo: obviously [06:46] zane has joined the channel [06:46] stephank has joined the channel [06:46] shanebo: but doing it right is inconspicuous [06:46] Xeon06_ has joined the channel [06:47] tig: looks like there are a couple cases where it can be forbidden https://github.com/senchalabs/connect/blob/master/lib/middleware/static.js#L117 [06:47] mscdex: shanebo: can you post the code? what's the particular problem? [06:48] tmzt: post is one of those, as I learned the hard way [06:48] tmzt: trying to handle a post from facebook a middleware that invoked static [06:48] shanebo: mscdex the code is too large to post [06:48] tmzt: all is good until it gets to the method test [06:48] mscdex: shanebo: ah [06:48] tmzt: shanebo: gist.github.com [06:49] gozala has joined the channel [06:50] tig: .... [06:50] tig: wow [06:50] tig: hahahah [06:51] tig: https://github.com/senchalabs/connect/blob/master/lib/middleware/static.js#L123 [06:51] tig: root is '.' [06:51] tig: path is "style.css" [06:51] shanebo: mscdex, tmzt, basically I've rolled my own router that routes to a controller, controller sets action specific vars, view, layout etc., does related db calls but the rest of the dispatcher doesn't wait on db calls so I'd have to roll my render related code inside each action…. unless I figure out how to fire events. or unless there's another way. [06:51] tig: there is a dot in style.css [06:51] tig: why is this line even here [06:52] amerine has joined the channel [06:52] shanebo: mscdex, tmzt, all is working except for when I do a db request [06:54] tmzt: shanebo: sounds like express/connect and middleware would be much easier [06:54] mscdex: i'm not sure you can easily auto-render like that [06:54] mscdex: when you're doing async stuff [06:55] mscdex: you'd have to manually call render [06:55] pen has joined the channel [06:56] mscdex: that's how you'd do it with express [06:56] mscdex: you render explicitly [06:56] shanebo: yeah [06:57] margle has joined the channel [06:57] shanebo: mscdex i wonder if I can pass args to the next func in the middleware stack once the previous middleware func is done? [06:58] stuk1 has joined the channel [06:59] battlecollie has joined the channel [07:00] akshatj has joined the channel [07:01] Xeon06_ has joined the channel [07:02] stuk1: Hi all, the node sqlite bindings are using EventEmitter which I see has been removed in 0.5.2. I haven't done anything with c++ node modules before, so does anyone have any suggestions on how to update the code? [07:02] stuk1: here's (one of) the offending lines https://github.com/orlandov/node-sqlite/blob/090d71eb5afc22d19a7e89e3e533ebeb71fa638e/src/database.cc#L35 [07:03] jesusabdullah: wait, wahat? EventEmitter got removed? [07:03] jesusabdullah: That doesn't make *any* sense. [07:03] jesusabdullah: You must be mistaken. That, or 0.5.2 is mistaken. [07:03] jesusabdullah: Or, I'm going to be shitting bricks pretty soon. [07:03] kkaefer: jesusabdullah: it was removed from C++, it's now implemented in JavaScript only [07:04] mscdex: yeah [07:04] mscdex: kinda sad [07:04] mscdex: :( [07:04] jesusabdullah: Oh, rm'd from c++ huh? [07:04] kkaefer: mscdex: why? [07:04] jesusabdullah: Crazylegs [07:04] jesusabdullah: why for? [07:04] mscdex: because i emit events from c++ land [07:04] jesusabdullah: THEN AGAIN EE2 is pure JS and is pretty fast [07:04] mscdex: in one of my modules [07:04] kkaefer: mscdex: you can still do that [07:04] tig: :P what is it with node and removing important things all the time? [07:04] mscdex: yeah i guess, but it seems like it'll be more of a pita now [07:05] tig: don't they have deprecation cycles? [07:05] tig: you know, so shit doesn't just break all the time? [07:05] mscdex: tig: 0.5.x is an unstable branch [07:05] tig: ah [07:05] mscdex: tig: even numbered major releases are stable (i.e. 0.2.x, 0.4.x, 0.6.x, etc) [07:05] tmzt: jesusabdullah: EE2? [07:05] tig: hm, looks like on my mac I'm using 0.5-pre [07:06] kkaefer: tig: if you're doing production stuff, you should use 0.4.10 [07:06] tig: is there a 0.4.10 tag? I just saw 0.4.9 [07:06] tig: oh wait lol alphabetization [07:06] tig: crap [07:06] tmzt: oh [07:06] mscdex: heh [07:06] tig: too lazy to rebuilt it now :P [07:06] tmzt: eventemitter [07:07] fangel has joined the channel [07:07] mscdex: how are we supposed to emit from c++ now? [07:08] ivanfi has joined the channel [07:08] jacobolus has joined the channel [07:08] topaxi has joined the channel [07:09] ts___ has joined the channel [07:10] skm has joined the channel [07:10] ablomen has joined the channel [07:10] `3rdEden has joined the channel [07:11] Xeon06_ has joined the channel [07:12] shanebo: mscdex looks like what I need is called Step [07:12] sub_pop has joined the channel [07:14] amiller has joined the channel [07:14] techwraith has joined the channel [07:14] stuk1: I didn't realise the EE news would be so shocking :P [07:15] techwraith: Got a global scope question for you guys :) [07:16] techwraith: If I define a variable using var, it doesn't seem to be in global scope, but if I omit the 'var' then it is. [07:16] Xeon06_ has joined the channel [07:17] techwraith: I'm not inside any closures, and it's not being required (it has not parent). [07:17] jesusabdullah: tmzt: EventEmitter2, a nodejitsu project! Gives namespacing to events, might make it into core \m/ [07:17] jesusabdullah: It's some sweet shit [07:18] jvduf has joined the channel [07:18] __directory: ooo gurl [07:18] stuk1: jesusabdullah: so if I were to fix the sqlite module, should I use EE2? [07:18] __directory: techwraith: yep [07:18] jesusabdullah: stuk1: Naw, use EE [07:18] tig: hurr, trying to npm install pg, but it needs the node header files [07:18] jesusabdullah: stuk1: EE2 is backwards compatible [07:18] tig: which aren't installed for some reason [07:18] techwraith: I'll post a gist [07:19] ccare has joined the channel [07:19] saurabhverma has joined the channel [07:19] mendel_ has joined the channel [07:19] techwraith: __directory: what do you mean by 'yep'? [07:19] tig: I'm not having a good day :P [07:19] stuk1: jesusabdullah: but EE has been removed in 0.5.2, that's why I need to use something different :) [07:19] tig: hey guys, how do you get node to install with the header files? [07:19] jesusabdullah: stuk1: This is also in pure js [07:19] jesusabdullah: stuk1: I don't know anything about the c++ side of EEs [07:20] dreamdust has joined the channel [07:20] stuk1: jesusabdullah: ah k, the module is pretty much all in c++ [07:20] stuk1: thanks [07:20] jesusabdullah: I SEE [07:20] techwraith: https://gist.github.com/1108845 [07:20] jesusabdullah: stuk1: It's pretty easy to implement your own EE, at least in dynamic languages [07:20] jesusabdullah: stuk1: I did it in python after all: https://github.com/jesusabdullah/pyee [07:21] jesusabdullah: Actually that module got like 40 watchers which is a LOT for me [07:21] jesusabdullah: I have no idea how that happened [07:21] jesusabdullah: well, I kinda do [07:21] jesusabdullah: I got reflog'd [07:21] jesusabdullah: but that doesn't explain all of them [07:21] emattias has joined the channel [07:22] stellaartois has joined the channel [07:22] hybsch has joined the channel [07:22] tig: help? [07:22] __directory: y0 gurl [07:22] mrtrosen has joined the channel [07:22] stellaartois: hi guys, i just made my first library, does anyone want to look at it? please be gentle. http://flatiron.github.com/jsonForm/ [07:22] __directory: thats log the test name for me just fine in 0.4.10 [07:22] skm has joined the channel [07:23] djcoin has joined the channel [07:23] tig: somebody? [07:23] demerzel3 has joined the channel [07:23] __directory: techwraith: dig? [07:24] techwraith: I'm probably missing something really simple, but I would assume that the 'this' in the function would refer to global scope. Am I wrong? [07:24] jensn has joined the channel [07:24] techwraith: __directory: hmmm, I'm not seeing that in my console... [07:24] techwraith: I'm getting this: [07:24] techwraith: foo bar undefined [07:24] techwraith: foo bar something new [07:24] techwraith: foo bar something new [07:25] __directory: techwraith: works in the repl, not outside [07:25] techwraith: My question is why :) [07:25] stellaartois: techwraith: this is the scope of your current closure [07:25] stellaartois has left the channel [07:25] zilch has joined the channel [07:25] tig: =[ [07:25] techwraith: stellaartois: Right, I thought I'd be in global scope at that point... [07:25] tig: come on, I know some of you are using C++ extensions [07:26] tig: should be able to help me with this [07:26] __directory: var means local and you close out of it i think [07:26] __directory: take var out and your global and it runs in/out of the repl [07:26] zeade1 has joined the channel [07:26] techwraith: yeah, I saw that too [07:26] tig: am I invisible? [07:26] __directory: tig: no [07:27] tig: am I asking a stupid question? [07:27] __directory: I dont know how to answer it [07:27] techwraith: I'm trying to figure out what the scope is at that point. [07:28] tig: did any of you build node from source and then try to use something like pg? [07:28] tig: that requires the header files? [07:29] __directory: techwraith: node does not have a global scope like a browser [07:29] __directory: its the scope of the 'module' [07:29] techwraith: __directory: even if it's not being run as a module? [07:29] Lorentz: tig: Don't know about pg, but never had issue with my own compiles [07:29] __directory: techwraith: http://nodejs.org/docs/v0.4.10/api/globals.html#global_Objects [07:29] Lorentz: I usually install node via clean code compile anyway [07:30] Lorentz: "./configure && make && make install" etc [07:30] stuk1: tig: if you followed https://github.com/joyent/node/wiki/Installation then the headers should be in $HOME/local/node/include [07:30] stuk1: which npm should find [07:30] techwraith: __directory: Thanks! [07:30] tig: $HOME? [07:30] tig: why $HOME? [07:30] tig: why would npm look in $HOME? [07:30] level09 has joined the channel [07:30] stuk1: ...because it's your home directory [07:30] stuk1: what os are you on? [07:30] __directory: techwraith: sorry it took so long, I had to learn all that myself as I went [07:31] tig: stuk1: ubuntu. But that doesn't mean I want standard directories in my home [07:31] tig: can't it go in /usr/local/node instead? [07:31] skm has joined the channel [07:31] stuk1: okay, so it's in /usr/local, it's in $HOME if you followed the link I gave [07:32] tig: except it isn't... [07:32] stuk1: are the headers in the eqivalent directory there? [07:32] Nuck: Now that Fakooda is growing beyond just myself, I'm debating writing unit tests. [07:32] Nuck: What's the usual Node unit test lib? [07:32] tig: maybe I messed something up. sec [07:32] zokko: hi [07:32] __directory: Nuck: rails [07:32] Nuck: __directory: Dear god I hope I don't have to use Rails to test my Node.js apps. If I do, I'll shoot you personally. [07:32] Lorentz: phpunit [07:32] Nuck: Should I just use vows? [07:33] __directory: phpunit, yes [07:34] jbpros has joined the channel [07:34] [AD]Turbo has joined the channel [07:35] bergie has joined the channel [07:35] zilch has joined the channel [07:35] __directory: Jasmin, Expresso [07:35] __directory: i've dorked with those for testing Nuck [07:36] __directory: srsly brah. [07:36] skm has joined the channel [07:36] Nuck: ... [07:36] uchuff has joined the channel [07:36] __directory: Nuck: https://github.com/mhevery/jasmine-node [07:36] Xeon06_ has joined the channel [07:37] Nuck: LOLSPECS [07:37] Nuck: I think Vows looks better [07:37] Nuck: It's designed for async [07:37] tig: oops, sorry for raising such a fuss. Looks like I accidentally stripped out the headers when I built a deb using fpm. Followed some tutorial on it that I can't find anymore. Anyway, it's built right now =] [07:38] Lorentz: Good to know [07:38] __directory: use it then, knob. [07:38] tig: I shoulda looked at the built files before fussing =[ [07:39] tig: hehe, how many of you use coffee as your commandline interface? [07:39] __directory: coffee is for staying awake and getting the colon working [07:40] tig: oh I don't drink the stuff. I just use it instead of javascript [07:40] zilch has joined the channel [07:40] radiodario has joined the channel [07:40] ogd has joined the channel [07:41] [AD]Turbo: hi there [07:41] Nuck: tig: RAAAAAAAAAAAAAAAAAAAAAAGEEEEEEEEE [07:41] Nuck: CoffeeScript!? [07:41] tig: yes [07:41] Nuck: RAAAAAAGGGGEEEEE [07:41] __directory: my favorite language is C so JS feels ok [07:41] tig: why the rage? [07:41] Nuck: JS 4 LYFE [07:41] Nuck: ACTION punts tig [07:41] tig: lol [07:41] tig: have fun binding to this all over the place instead of just using a handy fat arrow [07:41] ambroff has joined the channel [07:41] Nuck: WAT [07:41] tig: have fun with your == truth table every time you forget to === [07:41] zilch_ has joined the channel [07:42] Nuck: tig: I don't ever bind to this, I just use scope [07:42] tig: so you don't use prototypes at all? [07:42] Nuck: As for mixing up == with ===, that's a newbie mistake. [07:42] Nuck: tig: Honestly, no. [07:42] __directory: i type :make in vim [07:42] tig: == is never the right thing to use [07:42] __directory: and jslint finds the == issues [07:42] Nuck: == is SOMETIMES right [07:42] Nuck: SOMETIMES [07:42] Nuck: VERY RARELY [07:43] Nuck: But there are times you want type coercian. [07:43] Nexxy has joined the channel [07:43] tig: Nuck, I used to not use prototypes. It's nice to have total control. But it isn't so good for memory usage and performance reasons. [07:43] Nuck: But still, RAAAAAAAGGGEEEEEE [07:43] Nuck: tig: I just use objects normally [07:43] Nuck: I haven't run into a case that required a prototype yet [07:43] whitman has joined the channel [07:43] Nuck: I'll probably use them on my chat server more [07:43] Nuck: But right now, I have no reason to. [07:44] __directory: ...all that aside I dont know what this kid gets so pissy about your starbucksscript [07:44] Nuck: __directory: How dare you defile the name of my second-favorite coffeehouse? [07:44] __directory: coffee probably helps the whole js thing [07:44] Nuck: I AM OFFEND. [07:44] tig: Nuck, what if you want to model an object, any object, like a vector or a user? Would you rather it created every method of every user individually? [07:44] _bat has joined the channel [07:45] zilch has joined the channel [07:45] tig: or just stick it on the prototype so it's only allocated once? [07:45] yokoe has joined the channel [07:45] Nuck: tig: I don't bother [07:45] tig: :P yeah I didn't either until some guy from Mozilla lectured me on javascript performance [07:45] Nuck: Since V8 will reuse the variables either way, as I understand it. [07:46] tig: I'm not really sure how that feature works [07:46] tig: but it'd be nice to look into to see if it really does help with that [07:46] Nuck: IDK [07:46] seivan has joined the channel [07:46] Nuck: I can use prototypes, I just haven't had to model anything like that yet [07:46] temp01 has joined the channel [07:46] Nuck: Most of my code is single-instance. [07:46] __directory: Nuck.prototype.rage [07:47] tig: XD [07:47] Nuck: __directory: Error: Not defined. [07:47] Nuck: Try Nuck.rage() [07:47] tig: Nuck::notmad [07:47] zilch_ has joined the channel [07:48] TomY has joined the channel [07:48] Nuck: tig: Even if it DOES handle binding and whatnot for you, CS is still so ugly I can't look at it for long enough to write the admittedly shorter code. [07:48] bergie has joined the channel [07:48] tig: idk why you think it's ugly [07:48] simenbrekken has joined the channel [07:48] Nuck: Um, because it's fucking nasty? [07:48] tig: I think too much punctuation is ugly [07:48] mraleph has joined the channel [07:48] Nuck: It does not appeal to me in any way, shape, or form. [07:49] tig: and you're gonna indent things anyway so why not make it significant? [07:49] industrial: With mongoose how do I make a link to another collection? A hasmany B so in the schema bees: [ObjectId] ? I dont want to embed the B under the A document. [07:49] __directory: you're both just talking shit at this point anyway [07:49] tig: yeah [07:49] ank has joined the channel [07:50] groom has joined the channel [07:50] tig: industrial, I haven't used mongoose but I've used mongodb. Just put the ObjectId in there. It's not gonna do anything special for ya [07:50] tig: you still have to do a second query [07:50] tig: cuz there's no joins in mongodb [07:52] industrial: yeah okay, thought mongoose maybe had (lazy) joins or something [07:53] industrial: A.prototype.getBees() it is :D [07:53] tig: =] yeah you can implement your own laziness [07:53] svenlito has joined the channel [07:54] tig: no idea if mongoose has any of that stock [07:54] dgathright has joined the channel [07:54] groom has joined the channel [07:55] Nuck: Is it module.exports taht allows functions? [07:55] Nuck: Meh, I'll just test. [07:56] igl: exports = module.exports = functions(){}; [07:56] igl: -s [07:56] Nuck: exports is not module.exports [07:56] hybsch has left the channel [07:56] igl: yes [07:56] igl: but thats always my first line [07:56] jomoho has joined the channel [07:56] Xeon06_ has joined the channel [07:56] Nuck: that's an odd boilerplate you use. [07:57] igl: true =) [07:58] igl: but it works and i still use the exports keyword even when overwriting module.exports [07:58] admc has joined the channel [07:58] tig: I use requirejs [07:59] tig: on the server side [07:59] tig: code sharing ftw [07:59] mikedeboer has joined the channel [07:59] Nuck: meh, I just share variables I need to share by xporting a function which takes an argument for that variable [07:59] tig: ? [08:01] booo has joined the channel [08:02] tig: well this backtrace is real helpful http://friendpaste.com/5h9xNnPIIv8H7JzbyoQnSf [08:06] kmox83 has joined the channel [08:06] Xeon06_ has joined the channel [08:07] Nexxy has joined the channel [08:07] Nexxy has joined the channel [08:08] liquidproof has joined the channel [08:11] jomoho has joined the channel [08:11] zakuni has joined the channel [08:11] Xeon06_ has joined the channel [08:12] versicolor has joined the channel [08:12] tig: ah, switching to native mode gives me a real error message. good [08:13] unlink has joined the channel [08:13] unlink has joined the channel [08:13] unomi has joined the channel [08:16] lot49 has joined the channel [08:21] Xeon06_ has joined the channel [08:26] Xeon06_ has joined the channel [08:27] __doc__ has joined the channel [08:28] seivan_ has joined the channel [08:28] steffkes has joined the channel [08:28] Esteb has joined the channel [08:29] dgathright has joined the channel [08:30] Nuck: How would I unit-test on my database layer? [08:30] Nuck: Like, to make sure all my db calls work properly? [08:30] Nuck: Is that even possible? [08:30] pietern has joined the channel [08:31] Xeon06_ has joined the channel [08:32] mike5w3c has joined the channel [08:32] blup has joined the channel [08:34] Nexxy has joined the channel [08:34] saurabhverma has joined the channel [08:37] robhawkes has joined the channel [08:38] felixge has joined the channel [08:38] felixge has joined the channel [08:39] luke` has joined the channel [08:41] temp02 has joined the channel [08:41] azeroth__ has joined the channel [08:41] Xeon06_ has joined the channel [08:44] eldios has joined the channel [08:45] bshumate has joined the channel [08:45] bshumate has joined the channel [08:46] drupleh has joined the channel [08:46] Xeon06_ has joined the channel [08:47] tig: Nuck, create a test database, load some test data into it, and test manipulating it. Then destroy the database and re-create it next time you run the tests [08:47] zilch_ has joined the channel [08:48] tig: or if it's fast enough, recreate the database for every test [08:48] chjj: wow, jslinux is crazy [08:48] jetienne: chjj: especially the perf [08:48] jensn has joined the channel [08:48] kulor-uk has joined the channel [08:49] jetienne: chjj: i mean this is fast enougth to be used [08:49] chjj: i didnt realize this was a full x86 vm at first [08:49] jetienne: this is a software emulation in javascript [08:49] jetienne: i almost dont believe it :) [08:49] jetienne: chjj: you can edit and compile C if you want :) [08:50] chjj: lol [08:50] chjj: yeah thats awesome [08:50] chjj: very impressive [08:51] chjj: 2011, were writing vms in high level languages [08:52] pickels has joined the channel [08:52] industrial: I need a tool for restarting a node process on recursive file change. [08:52] industrial: However it needs to STOP restarting when theres an error. [08:52] guybrush: it can do internet too! http://youtu.be/MEsmgHrKQYM [08:52] __tosh has joined the channel [08:52] chjj: the guy who wrote this looks very smart, but new still new to js maybe [08:54] zakuni has joined the channel [08:54] chjj: jsmodem? [08:55] hellp has joined the channel [08:55] guybrush: https://github.com/ewiger/jsmodem [08:55] MikhX has joined the channel [08:56] ditesh|cassini has joined the channel [08:56] Xeon06_ has joined the channel [08:58] CStumph has joined the channel [08:58] tig: man, node.js libraries have you make sooo many callbacks [08:58] chjj: rofl this is crazy [08:58] tig: is there a way to write stuff so it looks synchronous but actually isn't? [08:58] muhqu has joined the channel [08:58] gozala has joined the channel [08:58] chjj: tig: if you dont like callbacks you might be in the wrong place [08:58] tuhoojabotti: tig: Do it with callbacks [08:58] tuhoojabotti: :P [08:58] guybrush: tig: like flow-control-libraries? [08:59] tig: well I mean [08:59] guybrush: tig: search for seq async async-array step [08:59] chjj: you could always try streamline, id never use it, but some people like it [08:59] chjj: you can write stuff sync and it walks the ast and compiles your code with callbacks [08:59] gozala has joined the channel [09:00] tig: for example, lets say you have a function that generates a UUID. Then later you decide you want to use postgres' builtin function for that. But that requires touching the database, which means you need a callback. Now your function can't just return the value anymore -- it has to have a callback too [09:00] jetienne: tig: gowiththeflow.js 30 lines work in node and browser https://github.com/jeromeetienne/gowiththeflow.js [09:00] tig: callbacks are infectious [09:00] chjj: or there was that other thing [09:00] chjj: JS-sex or something [09:01] jetienne: many exist, they all do the same :) [09:01] jetienne: almost [09:01] gozala has joined the channel [09:01] chjj: yeah i wouldnt recommend preprocessors [09:01] guybrush: JS-sex sounds cool :D [09:01] tig: hm [09:01] CoinOpeBoy has joined the channel [09:01] jetienne: oh the guys who preprocess js... yep i stick to standard [09:01] Xeon06_ has joined the channel [09:01] tig: I'm just sad I can't have functions that return things anymore [09:02] Nuck: Guys [09:02] bzinger has joined the channel [09:02] Nuck: We should try and make that JSLinux VM able to do GCC [09:03] Nuck: And everything else [09:03] Nuck: And compile node on it :D [09:03] jetienne: Nuck: go ahead. i'll catch up :) [09:03] rurufufuss has joined the channel [09:03] chjj: well its x86, it can execute x86 opcodes, it should be possible [09:03] Nuck: lolno [09:03] Nuck: chjj: Exactly [09:03] Nuck: That'd be so awesome if you could run node in a JS Linux VM [09:04] chjj: run jslinux IN jslinux [09:04] Nuck: OMG INCEPTION [09:04] chjj: ! [09:04] sylvinus has joined the channel [09:05] Twisol has joined the channel [09:05] jetienne: but for sure callback become rapidely an issue when doing database or file things [09:05] Metal3d has joined the channel [09:06] aliem has joined the channel [09:06] guybrush: it would be cool to run a windows-vm in jslinux :D [09:08] chjj: rofl [09:09] chjj: we need to create a hallway of mirrors [09:09] Twisol: Is there anywhere I can ask a v8-specific question? And if anyone can help, I'm trying to write a C++ bind for Node.js to a C library, and I want to take a function as a parameter to one of the C++ functions. In javascript i'd be foo(function() { }), and I need to be able to invoke that callback at a later point. [09:09] Twisol: *binding [09:10] chjj: https://github.com/isaacs/node-async-simple/blob/master/nas.cc [09:10] chjj: Twisol: thats a small example [09:11] Twisol: Ah fantastic, thanks [09:11] whitequark has left the channel [09:11] medice: if i want to add new function to array prototype from within module, how would that be done [09:11] Twisol: V8 is so difficult to extend compared to what I'm used to :/ [09:12] chjj: medice: you mean `Array.prototype.func = function() {};` ? [09:12] medice: right, but will that be accessible from outside the module? [09:12] tuhoojabotti: Yes [09:12] chjj: yes [09:12] chjj: its the same global context [09:12] medice: oh, alright then, then i have no trouble [09:13] tuhoojabotti: Messing up with globals<3 [09:13] tuhoojabotti: :P [09:13] guidocalvano has joined the channel [09:13] jetienne: medice: this is your code. but many considere it is bad to change global objects [09:13] jetienne: because it may create conflict and unexpected behavior down the road. but once again this is your code [09:14] chjj: just be very careful, make sure you dont break any internal code by doing that, and dont ever extend the Object prototype [09:14] Twisol: my personal rule is: libraries shouldn't, but you can. So if you're writing a library, avoid it. [09:14] michaelhartau has joined the channel [09:14] jetienne: my rule is: dont (there is always another way) [09:14] medice: screw the rules, i have money [09:15] chjj: yeah, as long as youre in control of the environment its ok, but you need to be careful, it generally isnt a good idea [09:15] tuhoojabotti: :) [09:15] chjj: especially becauses theres internal code executing in node, if it tests an object by testing for a certain property, and you extend to array prototype with a property that has the same name [09:15] chjj: youre in trouble [09:16] ank has joined the channel [09:16] jetienne: and got super hard time to find out where is the issue :) [09:16] chjj: yeah [09:16] Twisol: Gotta be aware of duck typing [09:18] framlin: medice: so you should realy at LEAST do: if (typoef array.func === 'undefined'){ //patch array wiith func } [09:18] chjj: Also if you're going to do it, make it non-enumerable so for..in doesnt pick it up [09:18] chjj: use Object.defineProperty(Array.prototype, ...) [09:18] liar has joined the channel [09:19] tuhoojabotti: Also, don't do it. [09:19] tuhoojabotti: :D [09:19] chjj: lol [09:19] tuhoojabotti: I have Number.tobytes and String.tobytes :P [09:20] mehlah has joined the channel [09:21] Xeon06_ has joined the channel [09:22] jetienne: https://github.com/kriskowal/es5-shim/ a good lib [09:22] chjj: for the browser yeah [09:22] jetienne: especially to get function.bind() in safari :) [09:25] __class__ has joined the channel [09:26] chjj: hmmm, a buffer.realloc would be nice [09:26] muhqu_ has joined the channel [09:26] zilch_ has joined the channel [09:27] Xeon06_ has joined the channel [09:27] ank has joined the channel [09:28] saurabhverma has joined the channel [09:28] AvianFlu has joined the channel [09:29] shanebo: hey guys is there anything to do dynamic recursive stepping? [09:31] markwubben has joined the channel [09:32] michaelhartau has joined the channel [09:32] emattias has joined the channel [09:35] Swizec has joined the channel [09:35] AvianFlu: shanebo: what, specifically, do you mean by 'stepping' [09:35] shanebo: AvianFlu https://github.com/creationix/step [09:36] AvianFlu: gotcha, I haven't used step much [09:36] paulwe_ has joined the channel [09:36] AvianFlu: you may also want to look at http://github.com/caolan/async [09:36] Xeon06_ has joined the channel [09:37] cjroebuck has joined the channel [09:37] te-brian has joined the channel [09:38] versicolor has joined the channel [09:38] rook2pawn: https://github.com/rook2pawn/node-queuelib is pretty easy to use [09:40] Twisol: Do I really have to go through the whole process with an ObjectTemplate just to get an object I can set key/value pairs on? (C++ API) [09:41] Xeon06_ has joined the channel [09:42] shanebo: AvianFlu async looks great. especially series, but I'm not sure it's recursive is it? [09:43] chjj: shanebo: what do you mean recursive? its possible to write something that is both async and recursive by hand, i dont see how any library would make it any easier [09:44] shanebo: let's see if i can pseudo code it [09:44] chjj: i mean, the async part, yes [09:44] chjj: but the recursive part, youd do that yourself [09:45] shanebo: chjj but I want to keep that logic out of the controller action if possible [09:45] shanebo: use case would be something like that [09:45] shanebo: middleware runs steps: [09:45] AvianFlu: shanebo: there's an async.forEach, I haven't used it myself but it MIGHT do what you want [09:46] aliem has joined the channel [09:46] Xeon06_ has joined the channel [09:47] jensn_ has joined the channel [09:48] shanebo: router -> load controller -> fire controller action (action *could* contain db calls, fileReads etc.) -> render view -> render layout (if not ajax) -> req.end(html) [09:49] chjj: ok [09:49] shanebo: so what's happening is that my steps work at level one, but anything in the action level doesn't stop the train so when it calls back it doesn't have what it needs to continue [09:50] AvianFlu: I mean, for one thing, you could do some kind of `if (this should not fire) { nextFn() } [09:51] Xeon06_ has joined the channel [09:52] AvianFlu: shanebo: if you don't mind, can you elaborate on 'level one' and 'action level'? I'm not familiar with the terms [09:52] boehm has joined the channel [09:53] tbassetto has joined the channel [09:54] Shrink has joined the channel [09:54] framlin: shanebo: maybe you have to pass an objects that holds what you need to continue and may be you have to pass this using a closure, if there is some kind of loop involved [09:55] shanebo: yeah i'm just call backing into oblivion LD [09:55] shanebo: :d [09:55] shanebo: :D [09:55] shanebo: seems so much simpler on the frontend :D [09:56] rook2pawn: shanebo: in my module you can set a nodelete flag and each work function on each object can control the flow and queue [09:56] Xeon06_ has joined the channel [09:56] skm has joined the channel [09:56] NetRoY has joined the channel [09:56] framlin: mostly within such situation you have to pass a callback, that is declared within another function, that gets passed the params of the current loop. This ensures, that actually the *current* state is saved and therefor passed cause of the closure [09:58] shanebo: yeah and i'm not used to heavily keeping track of args/scope [09:58] simenbrekken has joined the channel [09:58] shanebo: i use mootools where you can easily bind and pass args [10:01] weezle has joined the channel [10:01] Xeon06_ has joined the channel [10:02] fermion has joined the channel [10:03] AvianFlu_ has joined the channel [10:04] Twisol has left the channel [10:06] Xeon06_ has joined the channel [10:07] zakuni has joined the channel [10:07] BS-Harou has joined the channel [10:07] BS-Harou: hi [10:08] BS-Harou: I have some problems with installing node.js 0.5.2 on x64 Win7 ... can someone help me? :) [10:10] thalll has joined the channel [10:11] BS-Harou: The problem is the 'Build failed: -> task failed (err #2): {task: libv8.a SConstruct -> libv8.a}' error ... I have gcc+ 4.x and I set the linux shell, but it didn't help :/ [10:11] zakuni has joined the channel [10:11] Xeon06_ has joined the channel [10:14] framlin: shanebo: but that stuff makes the beuty of JavaScript! [10:14] framlin: ;) [10:16] zakuni has joined the channel [10:16] Xeon06_ has joined the channel [10:17] Arenstar has joined the channel [10:18] NetRoY has joined the channel [10:18] shanebo: framlin, alright how would you pass 'data' to the next step in this paste? http://pastie.org/2278688 [10:19] Croms has joined the channel [10:19] shanebo: without writing over the args being applied from readFile? [10:21] adrianmg has joined the channel [10:23] adrianmg has left the channel [10:24] BS-Harou: anyone? please? [10:25] tuhoojabotti: BS-Harou: Windows support is under development :P [10:26] BS-Harou: i know [10:26] BS-Harou: but I had no problem on my other computer with WinXP [10:26] Xeon06_ has joined the channel [10:26] BS-Harou: (32bit) [10:28] BS-Harou: anyway, are you telling me that I won't get over the ' task failed (err #2): {task: libv8.a SConstruct -> libv8.a}' error? :( [10:30] Wizek has joined the channel [10:30] hellp has joined the channel [10:30] BS-Harou: Wizek: hi [10:30] tcurdt has joined the channel [10:31] christophsturm has joined the channel [10:31] Wizek: hi BS-Harou [10:31] Xeon06_ has joined the channel [10:31] tar_ has joined the channel [10:33] okuryu has joined the channel [10:33] boaz- has joined the channel [10:34] Croms has joined the channel [10:36] empt has joined the channel [10:38] Vertygo has joined the channel [10:40] secoif has joined the channel [10:40] leek- has joined the channel [10:40] pastak has joined the channel [10:41] Xeon06_ has joined the channel [10:42] framlin: shanebo: you want to pass the fun itself at a callback to fs.readFile and pass data? [10:42] shanebo: can you rephrase? [10:43] shanebo: readFile callbacks two args, I need to add data to the args that get passed back [10:43] shanebo: make sense? [10:46] zilch_ has joined the channel [10:47] piscisaureus has joined the channel [10:47] __class__ has joined the channel [10:49] seivan has joined the channel [10:49] alexhq has joined the channel [10:49] Wizek has joined the channel [10:49] empt has left the channel [10:51] Xeon06_ has joined the channel [10:52] BS-Harou has joined the channel [10:52] alexhq: Is it possible to close ClientResponse manually to emit 'end' event? I have simple http proxy, when client (curl) killed, proxy still receives data. [10:54] aliem has joined the channel [10:55] fairwinds has joined the channel [10:55] pgte has joined the channel [10:56] Xeon06_ has joined the channel [11:00] H4ns` has joined the channel [11:01] dexter_e: Anyone familiar with Upstart on Ubuntu ? [11:01] dexter_e: export NODE_ENV=production should that just work? [11:01] Xeon06_ has joined the channel [11:02] threecreepio has joined the channel [11:03] diegoviola has joined the channel [11:03] Badababuba has joined the channel [11:04] framlin: shanebo: why do you want to pass 'this' as a callback? [11:05] shanebo: framlin because that's the step api: https://github.com/creationix/step [11:05] Badababuba has joined the channel [11:06] framlin: shanebo: thats the very simple case: http://pastie.org/2278839 [11:06] framlin: ah ok, I do not know that api, caus I do not use async apis [11:06] Xeon06_ has joined the channel [11:09] framlin: ah ok, I saw the example, this Step-Constructor gets callbacks passed [11:10] Badababuba has joined the channel [11:11] eldios: what is the difference between var foo = new bar() and var foo = new(bar.baz)() ? [11:11] eldios: couldn't I make var foo = new bar.baz() ? [11:11] Xeon06_ has joined the channel [11:12] stagas: eldios: you can [11:12] eldios: k thanks stagas.. just needed a confirm [11:13] pen has joined the channel [11:13] framlin: shanebo: sorry, I do not understand, what the Step Developer is intending, and do not have the time, to study this :( [11:14] shanebo: no worries [11:17] FireFly has joined the channel [11:19] saschagehlich has joined the channel [11:21] skm has joined the channel [11:21] Nuck: hey guize, gitorious or gitolite? [11:21] Xeon06_ has joined the channel [11:26] Xeon06_ has joined the channel [11:27] versicolor has joined the channel [11:28] huskyr has joined the channel [11:29] BS-Harou: still looking for help [11:30] tuhoojabotti: v8: true !!== true [11:30] v8bot_: tuhoojabotti: SyntaxError: Unexpected token ! [11:30] tuhoojabotti: so sad :/ [11:30] tuhoojabotti: v8: true ! !== true [11:30] v8bot_: tuhoojabotti: SyntaxError: Unexpected token ! [11:31] eee_c has joined the channel [11:31] Xeon06_ has joined the channel [11:34] shapeshed has joined the channel [11:34] jonaslund: v8: true !==! true [11:34] v8bot_: jonaslund: true [11:35] tuhoojabotti: jonaslund: but it's not the same :/ [11:35] jonaslund: well your statement didn't really make sense :P [11:35] tuhoojabotti: I know [11:35] tuhoojabotti: But if it had worked!! [11:36] Xeon06_ has joined the channel [11:36] leek- has joined the channel [11:37] simenbrekken: is it common to put own project modules in the node_modules folder for easy access? [11:37] tuhoojabotti: simenbrekken: require('./module') [11:37] simenbrekken: yeah but still is it frowned upon or can I use it? [11:37] tuhoojabotti: or ./my_moduels/module etc. [11:37] tuhoojabotti: duels :O [11:37] tuhoojabotti: simenbrekken: Guess not. [11:37] tuhoojabotti: :P [11:39] okuryu has joined the channel [11:41] materialdesigner has joined the channel [11:41] Xeon06_ has joined the channel [11:41] tcurdt: is there a dedicated expressjs room? somehow the bodyParser seems quite limited .. unless I missed something [11:42] SamuraiJack has joined the channel [11:42] jonaslund: tuhoojabotti: i guess you really want to be programming lisp :P [11:42] tuhoojabotti: Not really. [11:43] dexter_e: tcurdt: #express [11:43] TechCel has joined the channel [11:43] tcurdt: thx, dexter_e [11:44] unlink has joined the channel [11:44] dexter_e: v8: 1+1 [11:44] v8bot_: dexter_e: 2 [11:45] dexter_e: :) [11:45] dexter_e: Who ever made that feature needs a gold brick fedexed to their pad. [11:45] Roxy has joined the channel [11:45] tuhoojabotti: lol [11:46] heavysixer has joined the channel [11:47] pietern has joined the channel [11:47] gausby has joined the channel [11:47] dexter_e: v8: process.exit(); [11:47] v8bot_: dexter_e: ReferenceError: process is not defined [11:47] dexter_e: hehe [11:48] tuhoojabotti: dexter_e: It's sandboxed, timeouted, and boring. :/ [11:48] tuhoojabotti: ;-) [11:49] Roxy: can somebody tell me if i should be using callbacks here? http://pastebin.com/sniacqiZ [11:50] dexter_e: v8: navigator.appName; [11:50] v8bot_: dexter_e: ReferenceError: navigator is not defined [11:50] dexter_e: v8: window [11:50] v8bot_: dexter_e: ReferenceError: window is not defined [11:50] TheFuzzball has joined the channel [11:50] dexter_e: tuhoojabotti: Still pimptastic tho. [11:51] tuhoojabotti: dexter_e: also works in query. ;) [11:51] dexter_e: 2 gold bricks ! [11:51] tuhoojabotti: lol [11:51] pgte_ has joined the channel [11:51] tuhoojabotti: dexter_e: Send me gold too, thanks. [11:51] tuhoojabotti: :P [11:51] tuhoojabotti: Roxy: This is not #coffee :E [11:53] dexter_e: the v8bot makes me feel like I'm living in a BladeRunner like future I thought would never come. [11:54] CrisO has joined the channel [11:55] mendel_ has joined the channel [11:55] Roxy: whoops. here's the JS version. are callbacks needed here? http://pastebin.com/8fCY5QUF [11:57] tuhoojabotti: Roxy: You come to Node.js channel and ask are callbacks needed? :) [11:57] tuhoojabotti: :D [12:00] eldios: anyone have news about the npm adduser issue cb() never called ? [12:01] pedroteixeira has joined the channel [12:01] Xeon06_ has joined the channel [12:03] jtsnow has joined the channel [12:05] luke` has joined the channel [12:05] SamuraiJack has joined the channel [12:05] kriszyp has joined the channel [12:06] luke`_ has joined the channel [12:06] luke`_ has joined the channel [12:06] Xeon06_ has joined the channel [12:07] luke`__ has joined the channel [12:08] uchuff has joined the channel [12:08] eldios: and another question.. does anyone know how to recover the npm-user password? [12:10] jbpros has joined the channel [12:11] jshaw has joined the channel [12:12] mraleph has joined the channel [12:16] igl1 has joined the channel [12:16] Xeon06_ has joined the channel [12:18] cojack has joined the channel [12:18] cojack: hello guys [12:19] cojack: I got an error during compiling [12:19] brianseeders has joined the channel [12:20] cojack: http://pastebin.com/vCNRm92c [12:20] cojack: can any one help? [12:20] sridatta has joined the channel [12:20] jokil has joined the channel [12:22] kulor-uk has joined the channel [12:23] albertosheinfeld has joined the channel [12:24] seivan has joined the channel [12:25] booo has joined the channel [12:25] SamuraiJack has joined the channel [12:25] cha0s has joined the channel [12:26] Xeon06_ has joined the channel [12:27] mapleman has joined the channel [12:27] boaz has joined the channel [12:28] pgte_ has joined the channel [12:28] pgte_ has left the channel [12:28] eee_c has joined the channel [12:29] zilch_ has joined the channel [12:29] boaz has joined the channel [12:29] jtrudeau has joined the channel [12:30] temp01 has joined the channel [12:30] zilch has joined the channel [12:31] bradleymeck has joined the channel [12:32] fumanchu182 has joined the channel [12:36] framlin: eldios: callbacks ar not only usefull for IO. callbacks could be used in may circumstances ... [12:36] Xeon06_ has joined the channel [12:37] framlin: uups, i menat Roxy ... [12:37] CrisO has joined the channel [12:38] xtianw has joined the channel [12:38] Roxy: thanks, framlin. but specifically is there a chance "game" won't be defined when it is referenced in line 5? it seems to work fine but... [12:39] cojack: there was an error [12:39] eldios: framlin, I do not need npm calbacks, I was only trying to adduser [12:39] cojack: Idk where is generated file CPackConfig.cmake [12:39] cojack: but during instalation this file is generated [12:40] cojack: and I have no idea which developer got this idea to put everywhere // Copyright Joyent, Inc. and other Node contributors. [12:40] cojack: but in line where is SET(CPACK_PACKAGE_FILE_NAME ... [12:41] cojack: was also this line after node- [12:41] cojack: and this generat an error during compiling [12:42] SamuraiJack has joined the channel [12:43] edude03 has joined the channel [12:44] framlin: Roxy: sorry, but your pastie is not big enought to get the context. Sems you define a callback there, but its not to see, if you pass this to any other funtion or call the defined function directly .... [12:45] framlin: but if line 5 is vital, you should ensure, that your assignToGame will be called anywhere [12:46] Roxy: fram: there are no callbacks. but i'm thinking i should use one. just surprised that game is ALWAYS assigned when i run this code... [12:46] thalll has joined the channel [12:46] Xeon06_ has joined the channel [12:49] boaz has joined the channel [12:50] framlin: Roxy: then I would expect, that there is anywhere a line with a call like assignToGame(any_client); [12:50] futuredarrell has joined the channel [12:51] Xeon06_ has joined the channel [12:52] saurabhverma has left the channel [12:54] Roxy: fram: got it. thanks for the help. ;) [12:54] AaronMT has joined the channel [12:56] Xeon06_ has joined the channel [12:56] eldios: wooo ooo.. just publish my first npm package ---> http://search.npmjs.org/#/connect-cradle [13:00] kulor-uk_ has joined the channel [13:00] SamuraiJack has joined the channel [13:01] Xeon06_ has joined the channel [13:02] Xeon06_ has joined the channel [13:02] seivan has joined the channel [13:03] mert has joined the channel [13:04] jbpros_ has joined the channel [13:05] EvRide has joined the channel [13:06] swilson06 has joined the channel [13:07] aklt has joined the channel [13:08] aklt: Hi! [13:08] hwinkel has joined the channel [13:11] CrisO has joined the channel [13:11] patrickjst has joined the channel [13:11] Xeon06_ has joined the channel [13:14] kulor-uk has joined the channel [13:15] unomi has joined the channel [13:16] Xeon06_ has joined the channel [13:18] everton has joined the channel [13:18] SamuraiJack has joined the channel [13:20] willwhite has joined the channel [13:20] rfay has joined the channel [13:21] bnoordhuis has joined the channel [13:21] Xeon06_ has joined the channel [13:22] hippich has joined the channel [13:23] sooli has joined the channel [13:23] tokumine has joined the channel [13:24] c4milo1 has joined the channel [13:25] guidocalvano has joined the channel [13:25] kuya: argh.. node-mysql-native returns null values as 'null'..... [13:25] akshatj has joined the channel [13:25] kuya: thats... useless [13:25] tuhoojabotti: :D [13:27] seivan has joined the channel [13:28] ksheurs has joined the channel [13:29] kuya: no forks... [13:29] kuya: ACTION files an issue and looks for another client  [13:29] tuhoojabotti: kuya: I use node-mysql [13:29] tuhoojabotti: :u [13:29] tuhoojabotti: or well [13:29] tuhoojabotti: hmm [13:30] tuhoojabotti: npm install mysql [13:30] tuhoojabotti: :D [13:30] patrickgamer has joined the channel [13:30] ceej has joined the channel [13:30] patrickgamer has left the channel [13:30] tuhoojabotti: ye [13:30] tcurdt has joined the channel [13:31] ap3mantus has joined the channel [13:31] kuya: ill try that one first, thanks tuhoojabotti [13:31] Xeon06_ has joined the channel [13:33] thomblake has joined the channel [13:33] simenbrekken has joined the channel [13:34] dexter_e has joined the channel [13:34] BillyBreen has joined the channel [13:34] igl has joined the channel [13:34] jbrokc has joined the channel [13:35] aheckmann has joined the channel [13:35] zokko: anybody using Zombie.js? [13:35] tuhoojabotti: zokko: I herd it required coffeescript [13:36] mnaser: y u no like coffeescript [13:36] tmzt_ has joined the channel [13:36] Xeon06_ has joined the channel [13:37] zokko: tuhoojabotti: i know [13:37] zackattack has joined the channel [13:37] zokko: i've strange problem, but there're no ppl on zombiejs channel [13:37] zokko: one one instance zombie.visit works and on second instance it does not [13:37] zokko: s/one\ one/on\ one/g [13:38] tuhoojabotti: wot [13:38] mnaser: you didn't need the g flag there. [13:38] mnaser: just sayin [13:38] tuhoojabotti: ah [13:38] tuhoojabotti: Yeah [13:38] tuhoojabotti: Also that just confused me. [13:38] hunterloftis has joined the channel [13:39] hunterloftis has joined the channel [13:39] anykey has joined the channel [13:39] zokko: it's just inurement ;) [13:40] tuhoojabotti: Now you're confusing me more. [13:40] aheckmann has joined the channel [13:40] luke` has joined the channel [13:41] DarylM has joined the channel [13:41] versicolor has joined the channel [13:41] sonnym1 has joined the channel [13:42] mert has joined the channel [13:43] mikl has joined the channel [13:43] mikl has joined the channel [13:44] bassui has joined the channel [13:47] cesutherland has joined the channel [13:48] davidcoallier has joined the channel [13:49] losing has joined the channel [13:50] cjroebuck has joined the channel [13:51] Xeon06_ has joined the channel [13:51] kmiyashiro has joined the channel [13:52] kulor-uk has joined the channel [13:52] Xeon06_ has left the channel [13:52] baudehlo has joined the channel [13:53] xerox: do you know of a tutorial to expresso? [13:53] carmony has joined the channel [13:53] xerox: I am extremely interested in the code coverage part, but it looks like I have to write tests for it to work, and I don't know what it needs exactly [13:54] mikeycgto has joined the channel [13:55] rvb has joined the channel [13:55] mikl has joined the channel [13:55] mikl has joined the channel [13:58] ank has joined the channel [13:59] xerox: ah it's *tests* coverage [13:59] irrumator_ has joined the channel [13:59] irrumator_ has joined the channel [13:59] xerox: not javascript code execution coverage [13:59] tbranyen: xerox: i think thats pretty much the same thing [14:00] xerox: tbranyen: I want to know if there are parts of the library that are never called [14:00] xerox: not if I am not testing part of the library [14:00] neorab has joined the channel [14:00] TomY has joined the channel [14:00] tbranyen: xerox: again i don't think there's a difference [14:00] tbranyen: its checking if you hit code in your tests [14:00] xerox: I don't have any tests [14:00] tbranyen: but those tests could just have easily been function calls [14:01] tbranyen: yeah dude, tests are irrelevant forget them [14:01] tbranyen: think of javascript [14:01] tbranyen: not abstract ideas [14:01] xerox: ok [14:01] tbranyen: >_> [14:01] balupton_ has joined the channel [14:01] tbranyen: what magic are tests doing? [14:01] xerox: no idea? [14:02] tbranyen: none, because magic ain't real [14:02] tuhoojabotti: You sre? [14:02] tuhoojabotti: surE* [14:02] xerox: $ expresso -I lib-cov test/* [14:03] xerox: that's the command to produce coverage report [14:03] tbranyen: tuhoojabotti: p sure [14:03] _jhs has joined the channel [14:03] pen has joined the channel [14:03] xerox: it does indeed look like it needs a folder with tests in it, doesn't it [14:03] tuhoojabotti: :( [14:03] xerox: plus there's the comment "The output will look similar to below, depending on your test coverage of course :)" [14:04] xerox: http://visionmedia.github.com/expresso/ [14:04] davidwalsh has joined the channel [14:04] broofa has joined the channel [14:05] xerox: tbranyen: you with me? [14:06] agnat has joined the channel [14:06] tbranyen: oh xerox i thought you were talking about SubStacks thing [14:06] tbranyen: my b [14:07] xerox: which thing! [14:07] tbranyen: https://github.com/substack/node-bunker [14:07] tbranyen: that [14:07] xerox: uhu! [14:07] dexter_e has joined the channel [14:08] Druide_ has joined the channel [14:09] JJMalina has joined the channel [14:10] Charuru has joined the channel [14:13] adrianmg has joined the channel [14:15] newy_ has joined the channel [14:17] _jhs has left the channel [14:18] jbrokc: is it possible to give fs.watchFileSync a glob? as in, fs.watchFileSync("*.html") ? [14:18] colinclark has joined the channel [14:18] Aikar: how does one do 'watchFile' synchronously? [14:19] criswell has joined the channel [14:19] tuhoojabotti: Aikar: You don't :( [14:19] jbrokc: err, I mean watchFile* [14:19] Aikar: lol ok [14:19] Aikar: i was like uh... how is that possible [14:19] jbrokc: sorry I have writeFileSync going on in my head [14:19] jbrokc: got an error that says it only takes instances of functions =\ [14:19] tuhoojabotti: jbrokc: fs.walk or sth like that? [14:20] bnoordhuis: anyone with os x lion here who can double-check this issue? https://github.com/joyent/node/issues/1401 <- Results of stat() incorrect, don't match statSync [14:20] Aikar: i dont think it supports multi files in 1 call [14:20] jbrokc: tuhoojabotti: fs.walk ? [14:20] tuhoojabotti: readDir [14:20] tuhoojabotti: perhaps [14:21] tuhoojabotti: http://nodejs.org/docs/v0.5.1/api/fs.html#fs.readdir [14:21] Aikar: jbrokc: fs.readdir(basePath, function(file) { fs.watchFile(basePath + file, fn); }); [14:21] tuhoojabotti: Then find your html files [14:21] jbrokc: you guys is crazy [14:21] tuhoojabotti: Why? [14:21] Aikar: i think he meant it as a compliment [14:21] eee_c has joined the channel [14:22] tuhoojabotti: Ah [14:22] tuhoojabotti: Yeah [14:22] seivan has joined the channel [14:22] tuhoojabotti: jbrokc: tuhoojabotti++ ;-) [14:22] tuhoojabotti: :D [14:22] tuhoojabotti: like [14:22] tuhoojabotti: Aikar++ [14:22] catb0t: Aikar now has 1 beer [14:22] v8bot_: tuhoojabotti has given a beer to Aikar. Aikar now has 1 beers. [14:22] tuhoojabotti: hihi [14:23] Aikar: wat, did v8bot get reset? I swear i had multiple beers before lol [14:23] tuhoojabotti: eah [14:23] tuhoojabotti: YeahÄ [14:23] tuhoojabotti: ** [14:23] tuhoojabotti: I think so. [14:23] Aikar: i know he crashed, is it stored in memory only? [14:23] jbrokc: how would i tell it not to watch a directory, but only a certain filetype? do I have to do, path.extname === "html", function(file) { fs.watchFile("/Users/foo/Desktop/" + file, fn} ? [14:23] xerox: bnoordhuis: using 0.4.10 or 0.5 ? [14:23] tuhoojabotti: Guess so. [14:23] xerox: bnoordhuis: I get the same result using 0.4 [14:24] xerox: bnoordhuis: the same resultS, that is, the two outputs are the same, sync and nonsync [14:24] tuhoojabotti: jbrokc: Yes. [14:24] xcgfly2sky has joined the channel [14:24] bnoordhuis: xerox: with 1970 timestamps? [14:24] tuhoojabotti: or something like that. [14:24] jbrokc: tuhoojabotti: is there a way to refer to the current file being executed and then get the directory from it? [14:24] xerox: bnoordhuis: no, 2011 [14:24] jbrokc: as in ruby it's __FILE__ for current file [14:24] tuhoojabotti: jbrokc: Yes. :D [14:24] bnoordhuis: xerox: right, so it works for you [14:24] xerox: exactly [14:24] jbrokc: tuhoojabotti: what's the file constant then? [14:24] xcgfly2sky: hello [14:24] bnoordhuis: xerox: okay, thanks! [14:24] xerox: no problem bnoordhuis! [14:25] Aikar: jbrokc: with fs.stat, example: https://github.com/aikar/cosmos/blob/master/node_modules/autoloader/autoloader.js#L37 [14:25] tuhoojabotti: jbrokc: I'm trying to remember, read the docs! [14:25] tuhoojabotti: :P [14:25] Aikar: use the async versions if able, my use case required sync :P [14:25] zemanel has joined the channel [14:25] Know1edge has joined the channel [14:26] Know1edge has left the channel [14:26] tuhoojabotti: jbrokc: http://nodejs.org/docs/v0.5.1/api/globals.html#__dirname [14:26] tuhoojabotti: or __filename [14:26] jbrokc: tuhoojabotti: perfecto! thanks!! [14:26] tuhoojabotti: jbrokc: No beer for me? :/ [14:27] jbrokc: i'm new to this concept [14:27] tuhoojabotti: :D [14:27] jbrokc: tuhoojabotti++ [14:27] catb0t: tuhoojabotti now has 3 beers [14:27] v8bot_: jbrokc has given a beer to tuhoojabotti. tuhoojabotti now has 1 beers. [14:27] tuhoojabotti: \o [14:27] tuhoojabotti: ACTION is now drunk @work [14:27] jbrokc: it's 9 in the morning [14:27] tuhoojabotti: or 17:27 now. [14:28] brianc has joined the channel [14:28] aliem has joined the channel [14:28] tuhoojabotti: Still 31 minutes to go :E [14:28] bnoordhuis: where are you from, tuhoojabotti? [14:29] tuhoojabotti: Finland \o/ [14:29] bnoordhuis: i should've guessed [14:29] tuhoojabotti: /o\ [14:29] bnoordhuis: didn't know finland is in gmt+3 [14:29] Aikar: has anyone invented a time machine in node yet? I need to go 2.5 weeks into the future [14:29] jonaslund: +2 [14:29] tuhoojabotti: It is in summer [14:29] tuhoojabotti: +3 is summertime, +2 winter [14:29] jonaslund: gmt isn't adjusted? [14:29] bnoordhuis: right, because it's 16:29 here now [14:30] Aikar: DST is for morons [14:30] Aikar: ACTION is american [14:30] eldios: is anyone using iriscouch ? [14:30] Aikar: ACTION hates DST [14:30] bnoordhuis: we have DST >:( [14:30] tuhoojabotti: Aikar: This is not Python, not yet. [14:30] tuhoojabotti: ;-) [14:30] balupton has joined the channel [14:30] jonaslund: yeah DST is pretty stupid [14:30] tuhoojabotti: GMT<3 [14:30] jonaslund: well maybe not for farmers [14:30] jonaslund: or early industrialists [14:30] Aikar: machines plowing farms can work just as good in the dark these days /moderntechnology [14:30] jonaslund: but everyone else [14:31] tuhoojabotti: But yeah we have summer and winter time. [14:31] jonaslund: Aikar: errr [14:31] balupton has left the channel [14:31] tuhoojabotti: To compensate the light difference :D [14:32] jonaslund: Aikar: personally i wouldn't wanna be working on anything out in the field when it's dark [14:32] Aikar: jonaslund: lot of machines dont need human drivers :P [14:32] jbrokc: how do i execute a shell command in a js file with node? [14:32] jonaslund: My dad is a hay producer and i helped out driving tractors,etc during the summers when i was young [14:32] tuhoojabotti: http://www.stupidvideos.com/video/all/Winter_And_Summer_Comparisons_In_Finland/#352467 [14:32] tuhoojabotti: :P [14:32] bradleymeck has joined the channel [14:32] tuhoojabotti: jbrokc: DOCS! [14:32] tuhoojabotti: Read them, ask then. [14:32] tuhoojabotti: ;-) [14:33] jonaslund: Aikar: eh like ? [14:33] dexter_e has joined the channel [14:34] Aikar: iono specifically, pretty sure ive seen reference to farm equipment that can operate itself [14:34] webben has joined the channel [14:34] jonaslund: Aikar: you might get away with some automation and late night running on big flat farms [14:34] Xano has joined the channel [14:34] c4milo has joined the channel [14:34] tuhoojabotti: jonaslund: The round farms in mexico? [14:34] jbrokc: tuhoojabotti: couldn't find it [14:34] tuhoojabotti: process.exec? [14:34] tuhoojabotti: or sth like that. [14:34] jakehow has joined the channel [14:34] jonaslund: Aikar: but alot of farming (atleast where i lived.. you know much produce needs to be made locally) are done in less than ideal landscapes [14:34] brianV has joined the channel [14:35] jonaslund: Aikar: we lived next to a river f.ex... and you didn't wanna drive a tractor there at times without having a good peek on how wet the land is [14:35] bpierre has joined the channel [14:35] mendel_ has joined the channel [14:35] brianV: Hi all. Is there a good collection of use-case examples for node.js anywhere around? [14:35] jonaslund: i doubt a machine can yet make educated desicions about how moist the ground is based on the color of the ground [14:35] jbrokc: tuhoojabotti: i only see a process.execPath... [14:35] tuhoojabotti: :u [14:35] hybsch has joined the channel [14:35] empt has joined the channel [14:36] brianV: I understand a lot about how it works, and how to write intro apps... but does anyone know where I can see a list of what it *has* been used for? [14:36] tuhoojabotti: jbrokc: http://nodejs.org/docs/v0.5.1/api/child_processes.html#child_process.exec [14:36] tuhoojabotti: :E [14:36] tuhoojabotti: jbrokc: Read it all. [14:36] tuhoojabotti: :P [14:36] eignerchris has joined the channel [14:36] robertstuttaford has joined the channel [14:36] bnoordhuis: ffs, gmail down? [14:36] Drake_ has joined the channel [14:36] tuhoojabotti: :O [14:36] tuhoojabotti: Nope. [14:36] jonaslund: Aikar: otoh my dad constructed a robot (he kinda "re-invented" the flipflop circuit in a high voltage setting to store it's state) to automate one task [14:37] robertstuttaford: i got in [14:37] chjj has joined the channel [14:37] tuhoojabotti: bnoordhuis: Maybe your account got terminated. [14:37] jbrokc: tuhoojabotti: thanks. is a child process just a completely separate program from node? [14:37] robertstuttaford: i'm trying to decide what testing framework to use to automate tests for a dojo toolkit based node.js web app [14:37] tuhoojabotti: It's a child process. [14:37] jonaslund: That was quite funny.. me and my brothers are programmers and he had no knowledge of anything related to that (he can hardly use a computer) but he actually figures out how to do a single bit memory with a flipflop :) [14:37] tuhoojabotti: :D [14:37] jbrokc: i don't understand the child connotation of a process executed [14:37] robertstuttaford: any comments, sarcastic or otherwise? [14:37] empt: hi, anyone could please send me an invitation for Google+? [14:37] Aikar: lol [14:38] tuhoojabotti: jbrokc: I guess it dies if your node dies. [14:38] tuhoojabotti: thus a child process [14:38] jbrokc: oh, okay - but they're still on the same thread? [14:38] slaskis_: my node process keeps exiting before process.stdout has been completely written, any tricks to avoid that? [14:38] tuhoojabotti: jbrokc: thread? o.O [14:38] tuhoojabotti: slaskis_: Yes. [14:38] clifton has joined the channel [14:38] tuhoojabotti: But I don't remember any, sorry mate. [14:38] tuhoojabotti: :D [14:38] robertstuttaford: the vows bdd framework looks nice [14:38] slaskis_: tuhoojabotti: :P [14:39] jonaslund: node should not exit until all cb's have been processed [14:39] tuhoojabotti: Yeah [14:39] empt has left the channel [14:39] jbrokc: tuhoojabotti: in the doc example for child_process.exec, why does it require util if it's never used? [14:39] tuhoojabotti: Dunno [14:40] slaskis_: jonaslund: i tried adding a listener for 'end' on process.stdout but i guess listeners don't really matter [14:40] jbrokc: it's repeated quite often in the child_process docs... [14:40] tuhoojabotti: jbrokc: utils is useful ;-) [14:40] tuhoojabotti: are* [14:41] mikeycgto has joined the channel [14:41] RORgasm has joined the channel [14:41] greg has joined the channel [14:41] DarylM has joined the channel [14:41] jonaslund: end.. ? [14:42] tuhoojabotti: flush! [14:42] jonaslund: writeable streams has the events drain, close and error [14:42] tuhoojabotti: Yeah [14:42] tuhoojabotti: drain it was [14:42] tuhoojabotti: :P [14:42] slaskis_: oh right [14:42] slaskis_: that might work... [14:43] bassui has left the channel [14:44] slaskis_: nope [14:45] saschagehlich has joined the channel [14:46] seanouimet has joined the channel [14:47] gtramont1na has joined the channel [14:47] rvb has joined the channel [14:47] Poetro has joined the channel [14:47] Poetro has joined the channel [14:48] adrianmg has joined the channel [14:49] adrianmg has joined the channel [14:49] mapleman has joined the channel [14:50] swilson has joined the channel [14:51] Ans5i has joined the channel [14:52] gazumps has joined the channel [14:52] fattytuna has joined the channel [14:52] softdrink has joined the channel [14:54] Wizek has joined the channel [14:54] fumanchu182 has joined the channel [14:54] TheJH has joined the channel [14:55] sivy has joined the channel [14:56] christophsturm has joined the channel [14:57] DarylM has joined the channel [14:58] jonaslund: hmm [14:58] jonaslund: you know when it will terminate ? [14:58] mbrevoort has joined the channel [14:59] mbrevoort has joined the channel [14:59] luke`_ has joined the channel [15:00] mbrevoort has joined the channel [15:00] kevwil has joined the channel [15:00] zanes has joined the channel [15:02] AvianFlu has joined the channel [15:04] irrumator_ has left the channel [15:04] _dc has joined the channel [15:06] kriss has joined the channel [15:07] kriss: Good eve. [15:07] TheJH has joined the channel [15:07] TheJH has joined the channel [15:08] zokko: i think that i've made it [15:08] zokko: Zombie: GET http://www.google-analytics.com/ga.js [15:08] zokko: Zombie: GET http://www.google-analytics.com/ga.js => 200 [15:08] zokko: Zombie: Running script from /ga.js [15:08] slifty_ has joined the channel [15:09] zokko: any1 uses node.js + zombie.js to handle google-analytics ecommerce? [15:10] sub_pop has joined the channel [15:13] ank has joined the channel [15:13] djayc has joined the channel [15:14] djayc: Hey guys.. I'm having a hard time installing npm with the latest version of node. The npm install script hangs when running cli.js. If I pull the source and make install it myself it hangs just after installing a module. The binaries exist, but when I try to install a module using npm it just hangs. Any ideas? [15:15] robertfw has joined the channel [15:15] djayc: Is there some combo of node version and npm version that's known to work? [15:15] christophsturm has joined the channel [15:15] bnoordhuis: djayc: node 0.4.10 [15:15] djayc: bnoordhuis: Yeah, that's the version I built from [15:15] bronson has joined the channel [15:15] alnewkirk has joined the channel [15:15] c4milo: something that knows about connect? [15:15] gde33 has joined the channel [15:16] c4milo: specifically about writing middlewares [15:16] djayc: bnoordhuis: npm is version 1.0.22 [15:16] sbisbee_ has joined the channel [15:16] JumpMast3r has joined the channel [15:16] bnoordhuis: djayc: no idea, it should work [15:17] uchuff has joined the channel [15:17] bnoordhuis: isaacs is the guy you want but he's not around yet [15:17] frodenius has joined the channel [15:17] frodenius has joined the channel [15:18] davemo has joined the channel [15:19] broofa has joined the channel [15:19] smtlaissezfaire has joined the channel [15:19] thalll has joined the channel [15:19] edude03 has joined the channel [15:20] tjholowaychuk has joined the channel [15:20] kuya has joined the channel [15:22] halfhalo-work has joined the channel [15:22] mbrevoort has joined the channel [15:23] digitaltoad has joined the channel [15:23] Corren has joined the channel [15:25] harthur has joined the channel [15:26] jmalina has joined the channel [15:26] amiller has joined the channel [15:27] Swizec has joined the channel [15:28] booo has joined the channel [15:28] kmiyashiro has joined the channel [15:29] mbrevoor_ has joined the channel [15:29] aconbere has joined the channel [15:30] Shrink has joined the channel [15:30] Shrink has joined the channel [15:31] jtsnow has joined the channel [15:32] edude03 has joined the channel [15:32] jacobolus has joined the channel [15:32] Ginlock has joined the channel [15:32] albertosheinfeld: Anyone has a GREAT tutorial on how to uninstall and install node? [15:34] tomaw has joined the channel [15:34] kmiyashiro: port install nodejs [15:34] xerox: albertosheinfeld: install: git clone http://.../node.git; cd node; git checkout v0.4; ./configure --prefix=$HOME/.node; make; make install; add 'export NODE="$HOME/.node"' and 'export PATH="$NODE/bin:$PATH"' to ~/.profile, restart the terminal [15:34] xerox: albertosheinfeld: uninstall: rm -rf ~/.node; remove the two exports from ~/.profile [15:34] xerox: : ) [15:35] djayc: Is it bad practice to install node in /usr/local ? [15:35] xerox: err, git checkout origin/v0.4 [15:36] djayc: I'm wondering if that's what's giving me my issues when attempting to install npm. Although, node works fine.. it's just npm that takes a shi [15:36] djayc: Hangs at: "node cli.js rm npm -g -f --loglevel error" [15:36] xerox: which is basically what it says here https://github.com/joyent/node/wiki/Installation but I like the directory to be hidden : ) [15:36] bradleymeck: djayc no, just not everyone has permissions to all that / wants permissions [15:36] Spion has joined the channel [15:36] djayc: bradleymeck: Gotcha [15:37] tar_ has joined the channel [15:38] tar_ has joined the channel [15:38] EyePulp has joined the channel [15:39] djayc: The reason why I ask re: installing in /usr/local, the npm failures / hangs seem to only happen with global installs [15:39] djayc: for example, npm install mysql finishes fine.. but npm install -g mysql hangs [15:39] Circlefusion has joined the channel [15:39] albertosheinfeld: thanks Xerox! [15:39] xerox: albertosheinfeld: no problem! [15:39] albertosheinfeld: i manually deleted some npm files :S [15:40] eldios: is anyone using cradle? [15:40] piscisaureus has joined the channel [15:40] albertosheinfeld: i dunno if that will mess up everything [15:42] CIA-65: node: 03Aku Kotkavuo 07master * r562bef5 10/ doc/api/buffers.markdown : [15:42] CIA-65: node: Add missing parentheses in buffer docs. [15:42] CIA-65: node: Fixes #1405. - https://github.com/joyent/node/commit/562bef5ff3e04701098f180177d26634f5bcd003 [15:42] ksheurs has joined the channel [15:42] xerox: albertosheinfeld: npm ought to be install after node, and it uses process.installDir which if you used that did before will be ~/.node/... [15:43] jstroem has joined the channel [15:44] kriss: Any way to get SO_BINDTODEVICE in node? Go fish? [15:45] albertosheinfeld: yes but i deleted some files in the /bin after uninstalling node :s [15:45] thinkt4nk has joined the channel [15:45] albertosheinfeld: and now i cant even install node with those commands you gave me, i want to completely remove EVERYTHING and start fresh [15:46] piscisaureus has joined the channel [15:46] mbrevoor_: anyone else around that's managing a private npm registry? [15:47] brolin has joined the channel [15:47] Corren has joined the channel [15:48] d0k has joined the channel [15:49] perezd has joined the channel [15:49] jakehow has joined the channel [15:50] newy_ has joined the channel [15:50] bradleymeck: kriss i remember a patch that added support for binding a socket to an interface, not sure where it went [15:50] Xano has joined the channel [15:52] bradleymeck: kriss : https://github.com/joyent/node/pull/643 [15:52] level09 has joined the channel [15:52] isaacs has joined the channel [15:52] kriss: bradleymeck: Righty. It's probably not too damn tricky to hack in support for it, thankfully. Was more curious as to whether there was a sanctioned way of going about it. [15:52] stephank has joined the channel [15:53] kriss: Hmm.. [15:53] jbpros has joined the channel [15:53] level09: what are some decent solutions or modules for search [15:53] level09: specifically mongodb [15:53] jgautier has joined the channel [15:54] kriss: bradleymeck: Ah, that's for binding the local side. I was thinking along the lines of limiting incoming broadcasts. Different beast. [15:54] jgautier: SubStack, how would browserify work with a npm package that has c++ add ons? like if i wanted to browserify https://github.com/voodootikigod/node-serialport [15:54] kriss: bradleymeck: Thanks for looking that one up nonetheless :-) [15:55] bradleymeck: jgautier you wont get C++ running on your user's machine [15:55] jgautier: so obviously browserify wouldnt work [15:56] edude03 has joined the channel [15:57] albertosheinfeld has joined the channel [15:57] albertosheinfeld: Which version of node works GOOD with socket.io??? [15:57] albertosheinfeld: i had 0.4.10 but i couldn't make it work [15:57] mape: anyone poked around with twilio and node? [15:58] bradleymeck: jgautier if your goal is to run something on a users serial port, correct that would not achieve that [15:58] jgautier: well I would want to run the serial port piece in node ont he server, thats fine...but id like to do a require on the client side....so there would need to be some sort of transport [15:59] Yuffster_work has joined the channel [15:59] bradleymeck: jgautier, dnode it? [15:59] jgautier: yeah that could work for sure [16:00] jgautier: just wondering if browserify was smart enough to dnode it for me [16:00] DarylM has left the channel [16:00] guidocalvano has joined the channel [16:01] sholden has joined the channel [16:01] bradleymeck: well that would change the meaning of the function really, which would be odd [16:02] sveimac has joined the channel [16:02] blueadept has joined the channel [16:02] overra has joined the channel [16:02] sveimac has left the channel [16:03] avalanche123 has joined the channel [16:04] caike has joined the channel [16:05] caike has left the channel [16:05] _dc has joined the channel [16:06] caolanm has joined the channel [16:07] knutsen has joined the channel [16:07] donald_cook has joined the channel [16:08] zeropx has joined the channel [16:08] brolin has joined the channel [16:09] amerine has joined the channel [16:09] amiller has joined the channel [16:09] mundanity has joined the channel [16:13] yozgrahame has joined the channel [16:15] theCole has joined the channel [16:15] kevwil has joined the channel [16:16] piscisaureus has joined the channel [16:17] TomY has joined the channel [16:19] dannycoates has joined the channel [16:21] AvianFlu_ has joined the channel [16:22] othiym23 has joined the channel [16:22] Xeon06_ has joined the channel [16:22] Xeon06_: Hey all [16:22] dexter_e has joined the channel [16:22] Xeon06_: Is anyone else going to the Ottawa meetup tonight? [16:24] christophsturm has joined the channel [16:25] kriszyp has joined the channel [16:27] skybound has joined the channel [16:27] dc has joined the channel [16:28] raidfive has joined the channel [16:28] _dc has joined the channel [16:28] markdaws has joined the channel [16:29] markdaws has joined the channel [16:29] booo has joined the channel [16:29] jbrokc has joined the channel [16:29] unomi has joined the channel [16:30] fattytuna has joined the channel [16:30] skybound: Can anyone enlighten me why the behaviour of the 'this' keyword is different in the interactive repl compared to executing in a file? e.g. "for (k in this) console.log(this[k])" prints something in the repl but not otherwise? [16:31] MooGoo: this should refer to the REPL's global object [16:31] MooGoo: this in modules refers to exports [16:34] jvduf has joined the channel [16:34] Xeon06_ has joined the channel [16:35] iammerrick has joined the channel [16:36] case_ has joined the channel [16:38] RORgasm has joined the channel [16:38] skybound: i see; is there a way to allow addressing globals via "this" (in a file)? for example "this.Date" should be the same as the built-in "Date" [16:39] bradleymeck: the global variable is set to the global object or ... (function(){return this})() [16:39] guillermo has joined the channel [16:40] bradleymeck: even then you can always override the built-in objects at other points if you are trying to ensure they are "pure" you will need to maintain a separate context [16:42] japj has joined the channel [16:42] edude03 has joined the channel [16:43] jbrokc has joined the channel [16:43] JoelC has joined the channel [16:44] ekryski has joined the channel [16:45] pandeiro has joined the channel [16:47] butu5 has joined the channel [16:47] butu5: I am getting SyntaxError: Unexpected identifier in express.. while rendering a jade page using express [16:47] butu5: how to debugg this issue... [16:49] jbrokc has joined the channel [16:49] butu5: ohh luckily I figured it out very quickly... but not sure how to get the debug working for express app... [16:49] necrodearia has joined the channel [16:49] albertosheinfeld: Guys, i just installed node v0.4.9 [16:49] albertosheinfeld: and im trying to install npm but it's constantly giving me permission errors [16:50] butu5: albertosheinfeld: gr*... [16:50] albertosheinfeld: even if i sudo curl ....... [16:50] butu5: which enviroment [16:50] albertosheinfeld: mac os [16:50] butu5: u used sudo [16:50] albertosheinfeld: yes i am running: sudo curl http://npmjs.org/install.sh | sh [16:51] brianm has joined the channel [16:51] albertosheinfeld: and the error is [16:51] brianm has joined the channel [16:51] albertosheinfeld: Error: EACCES, Permission denied '../lib/node_modules/npm/bin/npm.js' [16:52] albertosheinfeld: and that folder has 777 access! :S any ideas??? [16:53] butu5: https://github.com/isaacs/npm/issues/194 [16:53] isaacs: butu5: that bug is a year old. [16:54] butu5: ohh [16:54] c_t has joined the channel [16:54] isaacs: albertosheinfeld: why are you sudo'ing the curl? [16:54] isaacs: albertosheinfeld: and not the sh? [16:54] sivy has joined the channel [16:54] albertosheinfeld: hmm let me try [16:54] Destos has joined the channel [16:55] albertosheinfeld: WORKED!!! [16:55] albertosheinfeld: thanks isaacs! you rule~! [16:55] isaacs: np :) [16:55] albertosheinfeld: stupid me :) [16:55] xerox: what is the correct way to add a SIGINT handler that cleans up and then lets the process die as it needs to [16:55] xerox: without blocking other SIGINT handlers of course, which might want to do the same [16:56] caolanm has joined the channel [16:58] MooGoo: process.once('SIGINT', function() { ...cleanup...; process.exit() }) [16:59] albertos_ has joined the channel [16:59] skybound has joined the channel [17:00] markmarkoh has joined the channel [17:01] Isaiah has joined the channel [17:03] xerox: MooGoo: does that let the other process.once('SIGINT', ...) fire? [17:03] MooGoo: only if it was added last [17:03] MooGoo: well [17:03] MooGoo: it will if you dont have process.exit() in your code [17:03] MooGoo: but the default action of aborting the script wont happen [17:04] NetRoY has joined the channel [17:04] xerox: ah I see [17:04] xerox: if I don't process.exit it's pretty nice [17:05] xerox: first ^C does the clean up, the second quits [17:05] xerox: I might do some semaphore to know if the cleanups are finished, and a callback to set the semaphore back [17:06] MooGoo: yea I did something like that to keep myself from accidently killing the bot [17:06] xerox: you got the use case 100% right : ) [17:07] MooGoo: .uptime [17:07] catb0t: I haz not crashed for 2 days 19 hours 17 minutes 22 seconds and 536 milliseconds and has been connected to this server for 1 day 17 hours 15 minutes 26 seconds and 27 milliseconds [17:07] MooGoo: woohoo [17:08] CrabDude has joined the channel [17:08] MooGoo: in that case it is a good idea to start a timer that re-attaches the sigint event if the second sigint does not come in a short period of time [17:08] gaba has joined the channel [17:08] MooGoo: or something like that [17:09] preethi_ has joined the channel [17:09] xerox: oh you're the catb0t person [17:09] xerox: MooGoo++ [17:09] v8bot_: xerox has given a beer to MooGoo. MooGoo now has 1 beers. [17:09] catb0t: MooGoo now has 2 beers [17:09] MooGoo: lol [17:09] xerox: haha [17:10] MooGoo: bots disagreeing [17:10] xerox: or, you have 3 beers, consider that [17:10] MooGoo: if only I knew what kind [17:11] catb0t: MooGoo++ [17:11] v8bot_: catb0t has given a beer to MooGoo. MooGoo now has 2 beers. [17:11] MooGoo: there [17:11] xerox: hahahaha [17:11] xerox: that's not fair! [17:11] liar has joined the channel [17:11] m2matson has joined the channel [17:12] AvianFlu has joined the channel [17:12] Cleer has joined the channel [17:12] `3rdEden has joined the channel [17:12] kmiyashiro has joined the channel [17:12] MooGoo: I use my bot responsibly [17:13] xerox: don't drink and use heavy bot-tery [17:14] altamic has joined the channel [17:14] altamic_ has joined the channel [17:16] MooGoo: hmm...what is the signal name for ctrl-d [17:18] tbranyen: SIG-KO [17:18] MooGoo: SIGSLAUGHTER [17:18] Scriptor has joined the channel [17:18] Xeon06_ has joined the channel [17:18] Stythys has joined the channel [17:19] butu5: I m using express + mongooose.. I am able to insert data. after that page is keep on reloading [17:19] sweetd has joined the channel [17:19] butu5: not able to see any error message [17:19] butu5: how to know what's going wrong.. when browser keep on trying?? [17:19] slifty_ has joined the channel [17:20] EyePulp has joined the channel [17:20] tjholowaychuk: butu5 step through with node's debugger [17:20] jokil has joined the channel [17:21] sridatta has joined the channel [17:21] saschagehlich has joined the channel [17:21] jbpros has joined the channel [17:21] tomtomaso has joined the channel [17:21] dherman has joined the channel [17:21] butu5: node-inspector? [17:22] tomtomaso has joined the channel [17:22] xerox: MooGoo: is it even a signal [17:22] MooGoo: dunno [17:22] MooGoo: it's something [17:22] jellosea has joined the channel [17:22] jellosea: `3rdEden: hey, i found another bug wtih the memcached library- - [17:22] slajax has joined the channel [17:22] jellosea: `3rdEden: i fixed the first one btw [17:22] JoelC has left the channel [17:23] jellosea: `3rdEden: but if i try and store zlib'd data, it doesn't store it properly... i'm having some difficulties figuring out how to fix this though [17:23] skohorn has joined the channel [17:23] xerox: MooGoo: it's a character [17:23] butu5: tjholowaychuk: i have to do some setup? [17:23] xerox: either 0x01 or 0x02 [17:23] avalanche123 has joined the channel [17:24] tjholowaychuk: butu5 add the debugger statement somewhere in your code [17:24] tjholowaychuk: and do [17:24] tjholowaychuk: $ node debug app [17:24] tristanseifert has joined the channel [17:24] xerox: (I think) [17:24] MooGoo: xerox: maybe it's 3, End of Text [17:25] Twisol has joined the channel [17:25] pjacobs has joined the channel [17:25] ank has joined the channel [17:25] xerox: MooGoo: agreed [17:25] tristanseifert has joined the channel [17:25] cccaldas has joined the channel [17:26] Hurreman has left the channel [17:26] tristanseifert has joined the channel [17:27] tristanseifert has joined the channel [17:27] _bat has joined the channel [17:27] topaxi has joined the channel [17:27] kjeldahl_ has joined the channel [17:27] tristanseifert has joined the channel [17:28] `3rdEden: jellosea awesome [17:28] tristanseifert has joined the channel [17:28] `3rdEden: jellosea it could be that it stores it a wrong format [17:28] jellosea: upto private.setters its okay [17:29] jellosea: i'm lookng to see if adding the linebreak kills it [17:29] tristanseifert has joined the channel [17:29] `3rdEden: jellosea you could check if the bytelength is the same as when you store it [17:29] mehlah has joined the channel [17:30] markmarkoh has joined the channel [17:30] `3rdEden: jellosea https://github.com/3rd-Eden/node-memcached/blob/v0.0.1/lib/memcached.js#L592 that might be wrong assumption i'm making [17:30] bassui has joined the channel [17:30] jellosea: `3rdEden: thats okay actually [17:30] jellosea: `3rdEden: i checked [17:30] battlecollie has joined the channel [17:31] `3rdEden: https://github.com/3rd-Eden/node-memcached/blob/v0.0.1/tests/memcached-get-set.test.js#L274-299 but it does pass my binary test [17:31] `3rdEden: it gets and sets my hot chicks image correctly: https://github.com/3rd-Eden/node-memcached/blob/v0.0.1/tests/fixtures/hotchicks.jpg [17:31] jellosea: LOL [17:31] jellosea: picture delivered [17:31] `3rdEden: <3 hot chicks [17:31] jellosea: me too [17:31] monokrome has joined the channel [17:32] jerrysv has joined the channel [17:32] zeade has joined the channel [17:32] jellosea: yeah got the problem [17:32] jellosea: adding the linebreak fucks it up [17:33] brez has joined the channel [17:33] butu5: tjholowaychuk: thanks.. now able to put sos sys.debug statement and going thru the code [17:33] `3rdEden: jellosea hmz, thats, odd but glad you caught it [17:33] butu5: now it looks like ... my code stops at Document.find().all (documents)-> [17:33] brez: anyone have an example of how to write a base64 encoded string to a file? seems obvious but i can't quite find an example / figure it out [17:33] butu5: here Document is mongoose model... not sure wht is going wrong here [17:33] chipnt has joined the channel [17:34] butu5: I am able to insert a Document model... query seems ok.. find().all [17:34] jellosea: should i just insert 0d 0a in a new buffer [17:34] devdazed has joined the channel [17:34] butu5: how to get more information.. here what is going wrong.. [17:34] jellosea: i don't know if there is a safe way to add the strings [17:34] dgathright has joined the channel [17:34] butu5: any way to catch the exception.. [17:34] EricL has joined the channel [17:34] bassui: in jade if i want something like how do I escape tr##{myarray._id} [17:34] tjholowaychuk: bassui td(id=myarray._id) [17:35] `3rdEden: jellosea if we store it as hex the problem would probably be gone [17:35] topaxi: bassui: tr(id=myarray._id) ? [17:35] jellosea: yeah i think i'll just create a new buffer and prepand 0d 0a [17:35] devdazed: hi all, does anyone know of a package that would allow me to store and iterate on objects outside of the v8 heap? i was looking into node-judy but it seems I can only store buffers and strings [17:36] bassui: thanks [17:36] butu5: tjholowaychuk: any tip how to catch the exception here? [17:36] battlecollie has left the channel [17:37] reid has joined the channel [17:37] Twisol: How can I return a new Object from a C++ extension? Right now I have an ObjectTemplate I created, and I'm calling New() on it, Set()'ing my values, and passing it along. But when the Javascript side gets it, it's a String 'f' or 'Interface' or something weird like that. [17:38] jbrokc: what are some examples of operations on a website that are much better being async than sync? ie - when is blocking bad? [17:38] Twisol: If I don't reuse the same ObjectTemplate but always create a new one (ObjectTemplate::New()->NewInstance()), it works. Is there something about ObjectTemplates I'm not understanding? [17:38] jakehow has joined the channel [17:38] jhurliman has joined the channel [17:38] dnjaramba has joined the channel [17:39] tar_ has joined the channel [17:40] dnjaramba has joined the channel [17:40] sveimac has joined the channel [17:40] sveimac has left the channel [17:40] albertosheinfeld has joined the channel [17:41] sridatta has joined the channel [17:41] jokil has joined the channel [17:42] kmiyashiro: v8bot [17:42] kmiyashiro: v8bot_: [17:42] kmiyashiro: v8bot_: return 'foo'; [17:42] kmiyashiro: :( [17:43] booo has joined the channel [17:44] synkro has joined the channel [17:44] jerrysv: v8: 1+1; [17:44] v8bot_: jerrysv: 2 [17:44] chipnt has left the channel [17:44] jerrysv: .. 1+1; [17:44] catb0t: 132 [17:46] smtlaissezfaire has joined the channel [17:47] matbee: anyone have a recommended pub/sub system for node? [17:47] matbee: im looking at faye [17:47] tbranyen: faye looks cool, gave me a few issues [17:47] matbee: yeah? [17:48] bassui: try socket.io [17:48] MooGoo: .. 1 [17:48] catb0t: 1 [17:48] matbee: .. 1 [17:48] catb0t: 1 [17:48] matbee: ? [17:48] matbee: lol [17:48] jameson has joined the channel [17:48] monokrome: Whoa. [17:48] kevwil has joined the channel [17:48] matbee: .. what u say? [17:48] catb0t: SyntaxError: Unexpected identifier [17:49] boehm has joined the channel [17:49] mikeycgto has joined the channel [17:49] matbee: bassui, doesn't faye use socket.io? :-/ [17:49] `3rdEden: nop [17:50] `3rdEden: faye doesn't have as many fallbacks as socket.io [17:50] matbee: ah [17:50] `3rdEden: + it doesn't kill all loading indicators [17:50] matbee: okay, so, any other alternatives for a socket.io pubsub? [17:50] harthur has joined the channel [17:50] patrickjst has joined the channel [17:51] harthur has joined the channel [17:52] hellp has joined the channel [17:53] bradleymeck has joined the channel [17:53] isaacs has joined the channel [17:54] cl0udy has joined the channel [17:54] cl0udy: anybody wanna join me for a project? [17:55] cl0udy: no one? [17:55] cleifer has joined the channel [17:55] sweetd_ has joined the channel [17:56] ank has joined the channel [17:56] stagas: cl0udy: what project? [17:56] cleifer has left the channel [17:56] cl0udy: u free? [17:56] cl0udy: can pm? [17:56] cl0udy: nodejs project of course :) [17:57] cl0udy: can pm? [17:57] ekryski has joined the channel [17:59] shanebo has joined the channel [17:59] shanebo: $seen fakedarren [17:59] shanebo: oops wrong room [18:00] markmarkoh has joined the channel [18:00] cl0udy: i plan to start a project dealing with notifications [18:00] Wizek has joined the channel [18:00] cl0udy: web app [18:01] JJMalina has joined the channel [18:01] cl0udy: anyone hv time to work w me? [18:02] losing has joined the channel [18:02] bassui has left the channel [18:03] Twisol has left the channel [18:03] bradleymeck: cl0udy detailing what you need help wise, or having a skeleton prototype at least will likely get you more attention than just asking [18:04] cl0udy: i hv created a list on redmine [18:05] zeade1 has joined the channel [18:06] CIA-65: libuv: 03Igor Zinkovsky 07master * rfc7bc2b 10/ (include/uv-win.h msvs/libuv.vcxproj src/win/process.c): fix mingw build; add stubs for child process API - https://github.com/joyent/libuv/commit/fc7bc2be7016d313a44b3a136ef80882a59e30aa [18:06] altamic has joined the channel [18:07] jacobolus has joined the channel [18:09] xerox: I came across a pluralization/inflection module for node [18:09] idefine has joined the channel [18:09] xerox: but I can't find it anymore, anybody knows about it? [18:10] NickABusey has joined the channel [18:10] tjholowaychuk: xerox natural [18:10] cl0udy: i guess not nvm [18:10] Xeon06_ has joined the channel [18:10] mbrevoor_: isaacs: hey, if you're around. should I expect npmjs registry design documents to replicate without error? [18:11] isaacs: mbrevoor_: i'm asking about the replication failures in #couchdb right now [18:12] aconbere has joined the channel [18:12] CIA-65: node: 03Ben Noordhuis 07master * r8430148 10/ (3 files in 3 dirs): uv: upgrade to fc7bc2b - https://github.com/joyent/node/commit/8430148ccba72e313c9f99da05987a7c9d29c9ba [18:12] jokil: is anyone familiar with using node's built-in profiler? [18:13] chapel: is anyone not able to use socket.io websocket transport with the newest chrome dev? [18:13] xerox: natural General natural language (stemming, classification, inflection, phonetics [18:13] qcom has joined the channel [18:13] xerox: oh yes that must be hit tjholowaychuk thanks [18:13] Rubikzube has joined the channel [18:14] mbrevoor_: isaacs: thanks [18:14] xerox: hang on, tjholowaychuk, are you the author of node-jscoverage? [18:14] tjholowaychuk: xerox i wrote one called lingo a while back but natural has a lot more cool stuff :D [18:14] tjholowaychuk: xerox: i didn't write the jscov library, just tweaked it to run on node [18:14] stagas_ has joined the channel [18:15] reid has joined the channel [18:15] NickABusey: Anyone have any idea when Heroku will add support for Websockets? Or a suggestion for an alternative host that does support them that also has free dev accounts? [18:15] xerox: tjholowaychuk: do you know if it is possible to run it on code without tests, to check what parts of the source are never used? (instead of what part of the source is not tested) [18:15] explodes: Hi, just installed vows with some tests. [18:15] tjholowaychuk: xerox yeah for sure [18:15] xerox: tjholowaychuk: wow that would really make my day [18:15] tjholowaychuk: xerox though I warn you it adds a lot of bulk to the library [18:15] tjholowaychuk: (the instrumentation) [18:15] tjholowaychuk: so it will be slower [18:16] explodes: er, and made some tests. Running vows in my src directory (which has a test directory) says there are no tests to be found. There is a file test_datetime.js ... [18:16] `3rdEden: chapel it uses a new websocket encoding [18:16] `3rdEden: we don't support it yet [18:16] Bonuspunk has joined the channel [18:16] chapel: ok [18:16] chapel: just making sure I wasn't crazy [18:16] `3rdEden: :) [18:16] chapel: thought it was a bug in the code, lol [18:16] `3rdEden: Nope, [18:16] idef has joined the channel [18:16] xerox: tjholowaychuk: understood. I want to use it from time to time to check that (a) I haven't got completely wasteful code and (b) to check pull requests for the same [18:16] chapel: whats the difference? [18:16] chapel: good change? [18:16] `3rdEden: FF5> and latest chromium use websocket specs that we don't support yet [18:16] `3rdEden: different handshakes [18:16] chapel: ah [18:16] `3rdEden: different encodings [18:17] tjholowaychuk: xerox cool :D yeah should be easy enough to do that [18:17] chapel: well xhr-polling is adequate [18:17] chapel: and most people dont run dev [18:17] xerox: tjholowaychuk: I poked around and compiled and tried but I can't get it to do what you said is possible, would you mind walking me through? or something : ) [18:17] xerox: I'm excited! [18:17] `3rdEden: chapel basically we need to write 2 more websocket parsers for socket.io [18:17] chapel: fun [18:17] `3rdEden: one for spec:7 and spec:8, not that much fun :p [18:17] jbrokc: if you supply a cwd to child_process.exec's 2nd paremeter of options, will it change to that directory? [18:17] chapel: well, it was sarcasm [18:17] bradleymeck: more specs more fun!~ [18:17] `3rdEden: ;D [18:17] tomtomaso has joined the channel [18:17] tjholowaychuk: xerox no time sorry man [18:18] bnoordhuis: jokil: yes [18:18] xerox: tjholowaychuk: I understand, no problem [18:18] `3rdEden: i'm so gonna have rauchg do that :p I'll pass for wrting websocket parsers [18:18] xerox: tjholowaychuk: at least I have again a little glimmer of hope [18:18] xerox: I'll just do something else : ) [18:19] othiym23 has joined the channel [18:19] abourget has joined the channel [18:19] jokil: bnoordhuis: I've been trying it and I can't get much meaningful data out of it. I only see very rough numbers. I would like it to show the specific runtimes for each function in the system and perhaps how many times it was called [18:19] abourget: Is there anything similiar to python's "virtualenv" with node.js ? [18:19] jokil: is it capable of that? [18:20] zeade has joined the channel [18:20] darshanshankar has joined the channel [18:20] bnoordhuis: jokil: the v8 profiler samples at a 2ms interval [18:20] bnoordhuis: jokil: so it doesn't have ultra-high precision [18:21] idefine has joined the channel [18:21] bnoordhuis: jokil: it's for pinpointing bottlenecks, not per-function tracing [18:21] jellosea: how do oi make sure that strings are added in 'binary' format [18:21] jellosea: added meaning concatenated [18:22] jokil: bnoordhuis: ah. is there something that allows me to do that without adding lots of hooks in my code everywhere? [18:22] jerrysv: jokil: if you want to see how many times something is called, jscoverage can help with that, but it does not include any timings, and instrumenting your code will throw off profiling [18:22] blup has joined the channel [18:22] Croms has joined the channel [18:23] bnoordhuis: abourget: nave? [18:23] Croms_ has joined the channel [18:23] bnoordhuis: jokil: what jerrysv said - apart from that not much [18:24] avalanche123 has joined the channel [18:24] Xeon06_ has joined the channel [18:25] jokil: do you guys suppose I could use jscoverage to find often used functions, and then specifically instrumenting those with some high-res profiling timer? [18:26] booo has joined the channel [18:26] idefine has joined the channel [18:26] fangel has joined the channel [18:26] jerrysv: jokil: that's a good idea, or if you can isolate parts of code, maybe use benchmark.js to get real timings and comparisons, but that really only makes sense if you can decouple completely [18:28] Billbad has joined the channel [18:28] jellosea: how do oi make sure that strings are concatenated in 'binary' format [18:29] mscdex: jellosea: you should avoid the 'binary' string format [18:29] idefine has joined the channel [18:29] bradleymeck: use buffers instead of strings for binary anything [18:29] albert has joined the channel [18:29] jellosea: mscdex: yeah i know [18:29] jellosea: but is there a way i can do this [18:30] pandeiro has joined the channel [18:30] doctorm has joined the channel [18:30] bnoordhuis: jellosea: what bradleymeck said [18:30] markmarkoh has joined the channel [18:30] bnoordhuis: strings != binary [18:30] doctorm: What's the pattern for getting a singleton / global from a module? Like a db connection. [18:31] Bonuspunkt has joined the channel [18:31] mscdex: doctorm: export it? [18:31] jellosea: okeydokey [18:31] jellosea: meow [18:32] bksf has joined the channel [18:32] idefine has joined the channel [18:32] doctorm: mscdex: So if it's required from two seperate places, in the module you would check to see if it already exists? That's the part I'm stumbling on [18:32] Nuck: Sometimes, deviantART chat worries me for the sake of all humanity. [18:32] Nuck: 11:21:34 AM <7inchcock> I'm a model who can't type worth a crap. My huge cock is getting in the way. [18:32] Nuck: ACTION facepalms [18:33] Cleer has left the channel [18:33] john_c has joined the channel [18:33] NickABusey: So I have this set for all environments: io.set('transports', ['flashsocket', 'htmlfile', 'xhr-polling', 'jsonp-polling']); but Firefox is still trying to use websockets.. any thoughts? [18:33] sambasiva has joined the channel [18:33] dreamdust: Wait… binary strings in JS? [18:33] jbrokc has joined the channel [18:34] markwubben has joined the channel [18:34] gaba has joined the channel [18:34] jbrokc: shouldn't path.extname strip the "." out of the extname? [18:34] bnoordhuis: Nuck: does 7 inches count as large these days? [18:34] Nuck: bnoordhuis: Seriously, I was wondering that too. [18:34] bnoordhuis: you kids have it so much easier [18:34] Nuck: No kidding lol [18:35] Nuck: I think it's the weaboo culture. The more wapanese they get, the more their penises shrink. [18:36] mscdex: NickABusey: my bet is the flashsocket transport checks for the global websocket object [18:36] Nuck: Wonder if there's any relation to Gary Busey? [18:36] NickABusey: I wish. That would be the best crazy uncle ever [18:36] Nuck: lol [18:37] Nuck: NickABusey: Until Big Wednesday pops out :/ [18:37] Nuck: Then he becomes a creepy uncle. [18:37] NickABusey: haha [18:37] Nuck: ACTION still can't believe Gary Busey named his penis after a day of the week [18:38] doctorm: Ok, so I guess modules naturally act as singletons. Does that mean if I create a connection like - exports.myconn = new Memcached(127.0.0.1:11211) that connection won't be recreated if the module is required in multiple places? [18:39] NickABusey: mscdex: Thanks, removing flashsocket fixed it. [18:39] srid has joined the channel [18:39] srid has joined the channel [18:40] mscdex: doctorm: correct, modules are cached [18:40] doctorm: mscdex: awesome, thanks [18:40] matbee: has anyone had success using socket.io with ios/android native clients? [18:40] mscdex: matbee: should work (at least long poll), why? [18:41] NickABusey: I just got mine working with ios, but not using websockets [18:41] matbee: ah [18:41] NickABusey: (because I'm on heroku) [18:41] matbee: NickABusey, nodester allows websockets... [18:41] m00p has joined the channel [18:41] NickABusey: I signed up, haven't gotten a coupon code yet [18:42] matbee: ah ok [18:43] mbrevoor_: isaacs: was thinking today that it would be nice if instead of having to replicate the entire NPM couchdb db, it would be nice to be able to layer and proxy npm registries or maybe just add a namespace to packages so you can map a namespace to a particular registry [18:43] thriple has joined the channel [18:43] isaacs: mbrevoor_: you can do that with a replication filter, i'm told [18:44] isaacs: mbrevoor_: but since npm already has the functionality to look somewhere else for a given package, it'd be nice to just replicate in { url: "http://registry.npmjs.org/pkgname" } for a package [18:45] bksf: i have a socket.io/node.js app. it's pretty brief. working locally is fine so far - yet on heroku i get errors sometimes causing crashes. the code is pretty brief - http://pastebin.com/DEt2D52X the error is http.js:572 [18:45] bksf: 2011-07-27T18:39:42+00:00 app[web.1]: throw new Error("Can't render headers after they are sent to the client.") [18:46] sweetd has joined the channel [18:46] bksf: im relatively new to nodejs but not web, headers etc i dont see anywhere where i am setting headers ... [18:46] mbrevoor_: isaacs: not following completely, so npm can look somewhere else for the actual package, right? but, correctly if I'm wrong, there can be only one registry [18:46] sridatta: anyone know what's happened to nithub? [18:47] isaacs: mbrevoor_: yes, you are correct. [18:47] isaacs: mbrevoor_: but a package entry can be { "name" : "foo", "url" : "http://foo-registry.com/foo" } [18:47] isaacs: mbrevoor_: oh, also needs maintainers. [18:47] mscdex: sridatta: have you seen http://blago.dachev.com/modules ? [18:47] isaacs: mbrevoor_: but then the registry will send a 301 response. [18:48] blueadept: why is this function not returning a value? http://www.pastie.org/2280809 [18:48] jonaslund: isaacs: hey, are you moderating nodejs-dev ? [18:48] isaacs: mbrevoor_: there's no way at this time in the npm client to publish a hyperlink to the registry [18:48] isaacs: jonaslund: i can, i believe, why? [18:48] RC1140 has joined the channel [18:48] tomtomaso has joined the channel [18:48] isaacs: jonaslund: you're approved! [18:48] sridatta: mscdex: thanks! [18:49] mscdex: blueadept: it's async? [18:49] shapeshed has joined the channel [18:49] jonaslund: isaacs: i think(not sure of about the interface) sent a msg i reply to the typedbuffers thread and i wonder if it went down the drain or is still stuck (or rejected?) [18:49] gaba has joined the channel [18:50] isaacs: jonaslund: i just let i tthrough [18:50] mbrevoor_: isaacs: yeah, would be nice if the packages were separate from the registry so a replica registry would be much smaller and could still download public packages from the public registry [18:50] isaacs: mbrevoor_: yep. [18:50] jonaslund: ahh [18:50] isaacs: mbrevoor_: i don't know if there's a way to do that with a replication filter. [18:50] isaacs: mbrevoor_: it'd be nice, though [18:51] mscdex: blueadept: you need to pass in a callback that gets executed inside Patient.count()'s callback, with the `count` value [18:51] mbrevoor_: isaacs: though that could be an issue for someone using a replica because they dont have outbound network access to the public registry [18:51] bksf: bump [18:51] isaacs: babump [18:51] jonaslund: isaacs: i made some regexps,etc that solved most of my formatting issues [18:51] AvianFlu has joined the channel [18:52] bartt has joined the channel [18:52] ekryski has joined the channel [18:52] mscdex: blueadept: or do something like this: https://gist.github.com/132d31d2ffda9664befd [18:52] jonaslund: isaacs: in regards to the API help,etc [18:52] mbrevoor_: isaacs: I also like the idea of having a namespace for packages and in the npm client being able to say for namespace "private" use this registry, otherwise use public... causes lots of trouble for search and the like. similar to what you can do with maven [18:53] blueadept: mscdex: ah ok, coo, ty! [18:53] isaacs: hm, yeah, what you really want is to use two registries. [18:53] isaacs: mbrevoor_: ie, "use this local one first, but if it's not there, then check the public one" [18:53] isaacs: and collate the search results from both [18:53] isaacs: it's not trivial. [18:53] mbrevoor_: isaacs: yeah, that's what I meant by "proxy" earlier [18:54] isaacs: even if we put redirect docs in the local registry, search still wouldn't know what to do with that [18:54] Swizec has joined the channel [18:55] mbrevoor_: isaacs: yup, federate search would be a pisser [18:56] mbrevoor_: isaacs: but when the number of packages increases by an order of magnitude, replication is going to become more challenging for someone who simply wants to augment the public registry with private packages [18:57] AvianFlu_ has joined the channel [18:57] mscdex: bksf: i think the default path for socket.io is '/socket.io' and not '/socket' [18:57] mbrevoor_: isaacs: willing to do the work if we could settle on a design... would need to be well thought out and weighed however [18:57] matomesc has joined the channel [18:57] isaacs: mbrevoor_: exactly [18:58] tokumine has joined the channel [18:58] bksf: mscdex: that just a text route never being hit [18:58] isaacs: mbrevoor_: getting the design right is the hard part. couch is actually a pretty good tool here, but i think we're just bumping into some incompatibility between 1.1 and 1.0 [18:58] admc has joined the channel [18:58] mscdex: bksf: oh [18:58] bksf: i can even remove it - it has to do with some sort of socket.io / heroku timeouts? [18:58] isaacs: mbrevoor_: are you able to update your couch to 1.1? [18:58] bksf: how can i test for a poll timeout? [18:58] rfay has joined the channel [18:58] dambalah has joined the channel [18:59] jspiros has joined the channel [18:59] level09 has joined the channel [18:59] brez has joined the channel [19:00] mbrevoor_: isaacs: yes... will try to do that later today [19:00] bksf: ahh https://github.com/LearnBoost/socket.io/issues/404 [19:01] markmarkoh has joined the channel [19:01] jspiros has joined the channel [19:02] thalll has joined the channel [19:03] wadey has joined the channel [19:03] spcshpopr8r has joined the channel [19:04] john_c has joined the channel [19:04] Xeon06_ has joined the channel [19:05] patrickjst has joined the channel [19:05] slajax has joined the channel [19:06] sveimac has joined the channel [19:06] sveimac has left the channel [19:06] jonaslund: bnoordhuis: there's a small bug in that code [19:07] jonaslund: bnoordhuis: the plesk code will fault on big-endian machines [19:07] bnoordhuis: jonaslund: yes? [19:08] bnoordhuis: jonaslund: i should add that so far i've barely audited the code [19:08] jonaslund: bnoordhuis: it assumes a little endian machine [19:08] jonaslund: bnoordhuis: it's simple to fix [19:09] xicubed has joined the channel [19:09] jonaslund: union { byte isLittle; short data; } endian; endian.data=1; if (endian.isLittle && swiz) { (instead of if (swiz) { at line 611 in the .cc file [19:10] bnoordhuis: jonaslund: right [19:10] bnoordhuis: jonaslund: i'd probably turn that into a compile-time check [19:10] jonaslund: yeah if there's an endian define or make one from the configure script [19:11] jonaslund: (ah and at line 600 aswell) [19:11] jonaslund: for set/get [19:12] tomtomaso has joined the channel [19:12] bnoordhuis: jonaslund: i'm trying to follow the getValue/setValue logic [19:13] bnoordhuis: jonaslund: is swizzle() a roundabout way of doing a byte swap? [19:13] bnoordhuis: jonaslund: or to reverse a string of bytes? [19:14] stuk1 has left the channel [19:14] jonaslund: bnoordhuis: i guess the intent is to make a generic byte swap [19:14] jonaslund: for 1,2,4,8 byte entities [19:15] jonaslund: see set/get generic just below [19:15] _bat has joined the channel [19:15] jonaslund: and the proxies below that [19:15] sveisvei has joined the channel [19:15] explodes: What am I doing wrong with my vows test... I can run "node test_datetime.js" just fine, but I cant run "vows" [19:16] Dreamer3 has joined the channel [19:16] explodes: It says "Could not find any tests to run." in big bold letters [19:16] jonaslund: bnoordhuis: a slight optimization that could be done is that the byte swap could work as a copy and then remove one of the memcpy's from get/set value [19:17] bnoordhuis: jonaslund: i suspect there's still a fair bit of cleanup / optimization to be done anyway [19:17] bnoordhuis: jonaslund: i profiled and benchmarked it yesterday [19:17] jonaslund: haha yes :) [19:17] bnoordhuis: jonaslund: it's a sliding scale: the larger the data type, the slower it becomes [19:18] bnoordhuis: int8/uint8 is on par with node's buffer type though [19:18] yhahn has joined the channel [19:18] jonaslund: bnoordhuis: with the explicit int32Array types or with the DataView functions ? [19:18] AvianFlu_ has joined the channel [19:19] kjeldahl_ has joined the channel [19:20] bnoordhuis: jonaslund: the former [19:21] bnoordhuis: jonaslund: not a completely fair benchmark though; a 25M entry int32buffer is 4 times as large as a 25M int8buffer [19:21] jonaslund: heh [19:21] jonaslund: bnoordhuis: try scaling the number of entries depending on the type size then ? [19:21] jonaslund: bnoordhuis: to avoid caching effects and such [19:22] bnoordhuis: jonaslund: yep - but it was 5 am by then [19:22] jonaslund: since apperantly "modern" v8 versions should know how to optimize accesses [19:22] bnoordhuis: so says mraleph [19:22] bnoordhuis: and he should know, right? [19:23] harth has joined the channel [19:23] Marak has joined the channel [19:24] meelash_ has joined the channel [19:25] meelash_: gf3: ping [19:25] gf3: meelash_: pong [19:26] jonaslund: bnoordhuis: well.. if it wasn't optimized i think the number of writes/reads should be the big factor.. not the entry size [19:26] else-: anyone got the "client not handshaken" error with socket.io before? i can't seem to be able to connect (the 'connect' event is never fired) although socket.io is properly loaded. also, it's working locally. socket.io log: http://pastebin.com/YMKa3ikN [19:26] supster has joined the channel [19:26] vns has joined the channel [19:26] meelash_: gf3: using irc-js, works well, thanks, but seems like list is incomplete? [19:26] Xeon06_ has joined the channel [19:27] jonaslund: bnoordhuis: btw.. did you see my "use node buffers as typed array backing store" suggestion ? [19:27] bnoordhuis: jonaslund: for reasons that aren't entirely clear to me yet, typed array benchmarks seem to spend 25% of their time in v8::internal::ScavengeVisitor::VisitPointers() [19:27] gf3: meelash_: list is an ugly beast that I am actually working on right now [19:27] tomtomaso has joined the channel [19:27] gf3: meelash_: if possible I would avoid doing a giant /list on a server like Freenode, it can take a long time [19:28] bnoordhuis: jonaslund: well, buffers are nothing more than a slab of memory, just like typed arrays [19:28] bnoordhuis: in theory anyway [19:28] jonaslund: exactly :) [19:28] tomtomaso has joined the channel [19:28] NetRoY has joined the channel [19:28] fermion has joined the channel [19:29] bradleymeck: mmm im le lazy but might need to actually bother some v8 ppl about the debugger... grrr / arg [19:29] meelash_: gf3: yeah, I was planning to keep the list cached and use it for searching for rooms, etc [19:29] gf3: meelash_: good idea [19:30] gf3: meelash_: so you say the list is incomplete? [19:30] montylounge has joined the channel [19:30] meelash_: gf3: I mean it doesn't seem like /list is ever actually called in the function- there's no this.raw(something) in that function [19:31] meelash_: maybe I'm missing something [19:31] markmarkoh has joined the channel [19:31] meelash_: gf3: anyway, the "hollaback" <- :) is never being fired [19:32] seanouimet has joined the channel [19:33] eee_c has joined the channel [19:33] gf3: meelash_: GOOD LORD [19:33] gf3: meelash_: you are right [19:33] gf3: meelash_: Can I trouble you to file an issue? [19:33] meelash_: gf3: no trouble at all [19:34] Drake_ has joined the channel [19:35] ben_alman_ has joined the channel [19:35] xtianw has joined the channel [19:35] meelash_: gf3: I imagine I can fix it for my purposes by just adding return this.raw( 'LIST') [19:35] meelash_: ? [19:38] patrickjst has joined the channel [19:39] gf3: meelash_: let me double check [19:39] xtianw has joined the channel [19:39] __directory: lemmeee smangggg itttt [19:40] jonaslund: bnoordhuis: hmm.. try wrapping the iterations into a function to ensure arr, i and j are local [19:40] jonaslund: bnoordhuis: oh and k [19:40] tomtomaso has joined the channel [19:40] cjm has joined the channel [19:40] jonaslund: bnoordhuis: var X; in the global scope doesn't really do anything [19:40] mikedeboer has joined the channel [19:40] jonaslund: bnoordhuis: (in terms of what the compiler can do) [19:41] gf3: meelash_: yes, that should work for now [19:41] sveisvei has joined the channel [19:43] MikhX has joined the channel [19:44] patcito has joined the channel [19:44] bpierre has joined the channel [19:46] sveimac has joined the channel [19:46] Xeon06_ has joined the channel [19:47] sveimac has left the channel [19:48] jewgonewild has joined the channel [19:48] jewgonewild: Hey guys, anyone running node on ec2.. quick question about what instance type to run it on. [19:49] Charuru: it doesn't matter [19:49] Charuru: whatever you can afford [19:49] jewgonewild: 64 or 32 bit? [19:50] Charuru: depends on the instance [19:50] Charuru: the smaller ones 32 the bigger ones 64 [19:50] jewgonewild: Ubuntu 11.04 [19:50] jewgonewild: the 32's go from micro,small, medium ... the 64 go from micro straight to large ... [19:51] kaww has joined the channel [19:51] MikhX has joined the channel [19:51] jewgonewild: I guess my question is will there be any performance implications running node on 32 bit instances? [19:51] Xeon06_: Anyone else going to the Ottawa meetup tonight? [19:51] meelasha has joined the channel [19:53] gozala has joined the channel [19:54] jvduf has joined the channel [19:54] mcluskydodallas has joined the channel [19:56] explodes: there is no way to chmod +x a .js file, and run it, is there? [19:56] explodes: i.e. #!/bin/node [19:56] k0stask has joined the channel [19:56] zilch_ has joined the channel [19:56] zilch has joined the channel [19:58] explodes: because it is invalid syntax.. [19:59] maushu has joined the channel [19:59] rfay has joined the channel [19:59] kkaefer: explodes: there is [20:00] kkaefer: explodes: as a shebang, use #!/bin/env node [20:01] brownies has joined the channel [20:01] AvianFlu: explodes: it would be either #!/usr/bin/env node [20:02] AvianFlu: or #!/usr/local/bin/node for the default path [20:02] AvianFlu: both work [20:03] matt_taylor_ has joined the channel [20:04] Xeon06_ has joined the channel [20:05] __directory: /lastlog jesus [20:05] __directory: is fun to type [20:06] elliottcable has joined the channel [20:07] brian has joined the channel [20:07] brownies has joined the channel [20:09] meelash_: gf3: k, thanks for your help [20:09] gf3: meelash_: np, I'll get on that, too [20:09] gf3: meelash_: btw, lots of great updates coming soon in 2.0 [20:09] meelash_: cool [20:09] supjeff has joined the channel [20:10] supjeff: hey node [20:10] supjeff: how should I protect against javascript injections? [20:10] balaa has joined the channel [20:11] supjeff: or is that a ridiculous question [20:11] elijah has joined the channel [20:11] level09 has joined the channel [20:11] jonaslund: into node or cross-browser ? [20:11] supjeff: into node [20:11] Bonuspunkt: dont eval? [20:12] supjeff: haha [20:12] supjeff: I'll try [20:12] c_t has joined the channel [20:13] PizzaYum has joined the channel [20:13] supjeff: so, if I ash for a user's name in an html form and they put in something like "; console.log('derp')" [20:13] PizzaYum: Hey guys, is there a way using the crypto lib to get the md5 or sha1 of a string? [20:13] tjholowaychuk: supjeff typically you just escape the output, most template engines will do this by default [20:15] supjeff: tjholowaychuk: yeah, I plan on using express, but I'm wondering how that would work on a primitive level [20:16] tjholowaychuk: supjeff: typically people convert < > & " etc to their html entity codes [20:16] tjholowaychuk: supjeff: but it's not a bad idea to strip more than that, since you can still do say "javascript:alert('rawr')" in an attribute [20:16] tjholowaychuk: if you are setting the attribute to something the user may modify etc [20:16] level09: the new jsdom doesn't seem to work fine [20:16] Xeon06_ has joined the channel [20:16] kuya has joined the channel [20:17] supjeff: tjholowaychuk: ok, thanks [20:17] escii has joined the channel [20:18] gaba has joined the channel [20:18] dberlinger has joined the channel [20:18] nerdfiles has joined the channel [20:19] nerdfiles has left the channel [20:19] malkomalko has joined the channel [20:19] malkomalko: anyone using the latest node native driver? I think there may be a bug with connections not closing when running map reduce.. anyone run into that? [20:20] harthur has joined the channel [20:20] jakehow has joined the channel [20:20] matbee: http://websocket.org/echo.html cannot connect to socket.io, any idea? warn - client not handshaken client should reconnect [20:21] harjinder has joined the channel [20:21] harjinder: hi [20:22] tar__ has joined the channel [20:22] dgathright has joined the channel [20:23] leeeb has joined the channel [20:24] TheJH has joined the channel [20:24] eee_c1 has joined the channel [20:24] jellosea: `3rdEden: are you there? i have another weird erro [20:25] Aikar: malkomalko: native driver for what DB? lol [20:25] jellosea: `3rdEden: if i do some work in memcached.command function... liek even a couple print statements.. the memcached get fails.. [20:25] svenlito has joined the channel [20:25] tomtomaso has joined the channel [20:26] qcom has joined the channel [20:26] malkomalko: lol [20:26] malkomalko: mongo [20:28] CStumph has joined the channel [20:31] esteth has joined the channel [20:32] kaww has joined the channel [20:32] mscdex: matbee: probably because socket.io uses special stuff in the url path when connecting [20:33] mscdex: matbee: like the /socket.io/ path, etc [20:34] amiller has joined the channel [20:34] rfay has joined the channel [20:35] eldios has joined the channel [20:35] patrickjst has joined the channel [20:36] liquidproof has joined the channel [20:37] dreamdust has left the channel [20:37] hwinkel has joined the channel [20:37] context: malkomalko: look up mongoose [20:38] context: err nm [20:38] Wa has joined the channel [20:39] peburrows has joined the channel [20:39] CStumph has joined the channel [20:39] zackattack has joined the channel [20:42] peburrows: having an issue where, after a certain period of time, calling .end() (or .destroy() or .destroySoon() or anything else) on a Writable Stream is no longer closing the underlying file descriptor [20:43] tar_ has joined the channel [20:43] reid has joined the channel [20:46] tilgovi has joined the channel [20:48] darshanshankar has joined the channel [20:48] Xeon06_ has joined the channel [20:49] peburrows: essentially, I'm calling this code asynchronously (right now with five concurrent requests): https://gist.github.com/feeee3869130276cd97a [20:50] peburrows: works fine for about 1200 requests, and then just stops closing file descriptors [20:50] peburrows: and I eventually get "Error: EMFILE, Too many open files" [20:50] cl0udy has joined the channel [20:51] MikhX has joined the channel [20:54] peburrows: I've tried just about everything to fix — that latest version attempts to manually close the fd after calling .end() on the stream [20:54] peburrows: still doesn't work [20:54] peburrows: (or, rather, it works for a while, and then just stops properly managing descriptors) [20:55] patcito_ has joined the channel [20:55] Hosh: General question: how does Node.js stack up against mongrel2's intrinsic long-polling (or maybe this is the other way around)? [20:55] guidocalvano: anyone here with some knowledge about the waf build script of node? [20:56] brolin has joined the channel [20:56] brianm has joined the channel [20:57] explodes: in a standard request object, how do i get a header? [20:57] hassox has joined the channel [20:58] peburrows: explodes: request.headers() [21:00] jacobolu_ has joined the channel [21:00] peburrows: anyone with any guidance on the file descriptors issue I mentioned above? [21:01] explodes: peburrows: request.headers = {...} ~ var contentType = request.headers['Content-type'] || request.headers['content-type']; [21:01] bnoordhuis: peburrows: what os? [21:02] peburrows: Mac OS X [21:02] qcom: What are the advantages of using connect-redis over connect's built-in session memory? [21:02] peburrows: and, BTW, I don't want to up the ulimit — I want to fix the underlying problem [21:02] zeade has joined the channel [21:03] tjholowaychuk: qcom: one scales one doesn't :p [21:03] tjholowaychuk: one persists and one doesn't [21:03] wookiehangover has joined the channel [21:03] __class__ has joined the channel [21:03] tjholowaychuk: the memory store is meant for testing/local dev only [21:04] bnoordhuis: peburrows: does `strace -e open,close` confirm that it stops closing fds? [21:04] qcom: tjholowaychuk: alright [21:04] qcom: and I've heard redis is fast af [21:05] harthur has joined the channel [21:05] peburrows: don't have strace installed on this system, but checking the output of `lsof` does confirm [21:05] admc has joined the channel [21:06] john_c1 has joined the channel [21:06] dreamdust1 has joined the channel [21:06] bnoordhuis: peburrows: how do i run it? [21:06] bnoordhuis: peburrows: iow, can you make a standalone test case out of it? [21:07] peburrows: bnoordhuis: I'll have to put something together. the original script is project-specific [21:08] bnoordhuis: peburrows: if you're sure it's a bug in node, open an issue [21:09] bnoordhuis: peburrows: oh, and maybe test it against both 0.4.10 and master (if you haven't already) [21:09] peburrows: bnoordhuis: I will once I've got a test script to reliably reproduce [21:09] peburrows: bnoordhuis: was hoping someone knew of a solution [21:10] kaww has joined the channel [21:10] alnewkirk has joined the channel [21:11] nerdfiles1 has joined the channel [21:12] fangel has joined the channel [21:14] cccaldas has joined the channel [21:14] fostah has joined the channel [21:14] kurtz has joined the channel [21:16] thriple has joined the channel [21:18] yhager has joined the channel [21:18] ekryski has joined the channel [21:18] Xeon06_ has joined the channel [21:18] tristanseifert has joined the channel [21:19] pieterv has joined the channel [21:20] softdrink: wheeeeeee: http://dl.dropbox.com/u/543400/flipper.html (view in chrome) [21:20] Sebastien-L has joined the channel [21:23] arkx has joined the channel [21:23] bpwnr has joined the channel [21:24] CIA-65: libuv: 03Tom Hughes 07master * r6203c93 10/ src/eio/eio.c : Fix memleak in libeio. - https://github.com/joyent/libuv/commit/6203c932d4d38617489d6569128baf88088fa879 [21:25] tomh- has joined the channel [21:25] tomh-: hey anyone had 'warn - unknown transport: "undefined"' before using socket.io? [21:25] CIA-65: node: 03Tom Hughes 07v0.4 * reab8beb 10/ deps/libeio/eio.c : Fix memleak in libeio. - https://github.com/joyent/node/commit/eab8bebcedd2d6ae46a25166964974bca263e616 [21:25] hwinkel has joined the channel [21:25] reid has joined the channel [21:30] theCole has joined the channel [21:30] davidwalsh has joined the channel [21:30] tomtomaso has joined the channel [21:31] hwinkel1 has joined the channel [21:31] theCole_ has joined the channel [21:31] k0stask has joined the channel [21:31] fly-away has joined the channel [21:33] supjeff: what's the best way to upgrade node? [21:35] dshaw_ has joined the channel [21:35] materialdesigner has joined the channel [21:37] monokrome: supjeff: If you're compiling it yourself, then compile and install again. If you're using a package manager, then it'll update it. [21:38] monokrome: But using a package manager also probably means that it'll be out of date :) [21:38] newy_ has joined the channel [21:38] tbranyen: not if you aren't using a crappy package manager :-p [21:38] Xeon06_ has joined the channel [21:39] tokumine_ has joined the channel [21:39] monokrome: tbranyen: It doesn't depend on the package manager. The package maintainer would be the "crappy" one. [21:39] tbranyen: which are one in the same [21:40] monokrome: Sure, if you ignore that they aren't. [21:40] tbranyen: monokrome: the maintainer dictates the policies [21:40] dgathright has joined the channel [21:41] monokrome: You've got it backwards, and this isn't #semantics - so, back to coding. [21:41] tbranyen: you mean painting your bikeshed? [21:41] blup has joined the channel [21:42] monokrome: No? [21:43] tbranyen: oh sorry i meant i'm painting mine [21:43] SubStack: the bike shed doesn't need paint at all [21:44] michaelhartau has joined the channel [21:44] jerrysv: don't have a bike shed [21:44] skohorn has joined the channel [21:45] monokrome: ACTION wonders who hangs out on IRC while painting their bike shed [21:46] isaacs: aluminum siding doesn't need painting, and is cheaper than wood. [21:46] isaacs: for most reasonably priced bikes, provided they don't need to be safe over night, that's plenty fine. [21:46] yozgrahame has joined the channel [21:47] isaacs: ACTION once had a bike stolen from his shed [21:47] skohorn has joined the channel [21:47] ctide: i've been thinking about painting my bike porch [21:47] jerrysv: our bikes live in the garage with the car [21:48] Guest39570 has joined the channel [21:48] Ramosa has joined the channel [21:49] nerdfiles1 has left the channel [21:50] adrianmg has left the channel [21:50] losing has joined the channel [21:50] supjeff: monokrome: ok, thanks [21:50] Nuck: I don't have a bike [21:51] Nuck: I just, ya know, walk. [21:51] sfoster has joined the channel [21:52] chapel: does anyone know why the initial connection using socket.io 0.7 seems so slow? [21:54] monokrome: chapel: Your browser and/or server probably aren't providing connects via websockets. [21:54] kevwil has joined the channel [21:54] eduarbo has joined the channel [21:54] monokrome: It's probably using Flash or XHR polling. Have you checked? [21:55] broofa has joined the channel [21:55] chapel: xhr-polling [21:56] chapel: chrome dev changed websockets [21:56] chapel: 0.6 was fast even with xhr [21:56] chapel: so thats why I was wondering [21:57] markmarkoh has joined the channel [21:57] meandi has joined the channel [21:58] zeade has joined the channel [22:02] technoweenie has joined the channel [22:02] toxico has joined the channel [22:02] technoweenie has joined the channel [22:04] __directory: need to refuckulate my carbs [22:04] Xeon06_ has joined the channel [22:05] eldios has joined the channel [22:06] jetienne has joined the channel [22:06] mscdex: chapel: really? what version of websockets is being used? [22:07] technoweenie: hey is there a way to get `npm install` to work on servers that dont have outbound http access [22:07] chapel: chrome dev, umm idk, but socket.io doesn't have the parser written for them [22:07] technoweenie: oh maybe i point to a local dir in the app's package.json [22:07] chapel: firefox5 also has newer websockets [22:09] brian has joined the channel [22:09] brianseeders has joined the channel [22:10] mscdex: chapel: go to http://websocketstest.com/ in chrome [22:10] mscdex: chapel: that should report the version [22:10] AvianFlu has joined the channel [22:11] mscdex: well, at least through 07 [22:11] mscdex: :S [22:11] yhahn has left the channel [22:12] technoweenie: dannng i need to be able to specify a local dir/tarball in package.json [22:12] chapel: WebSocket protocol version hybi-draft-08 [22:12] mscdex: ah [22:12] sfoster has left the channel [22:14] overra has joined the channel [22:16] Xeon06_ has joined the channel [22:17] mscdex: oh neat, i just discovered chrome://net-internals/ [22:17] mscdex: :-D [22:18] __directory: ooo gurl [22:18] jbrokc has joined the channel [22:18] TheFuzzball has joined the channel [22:19] kulor-uk has joined the channel [22:19] jbrokc: is child_process.exec() asynchronous? that is, if i have another child_process.exec() on the line below it, it could fire before the one before? [22:19] CStumph has joined the channel [22:19] andihit has joined the channel [22:20] mgv has joined the channel [22:22] kadiks has joined the channel [22:22] Platff has joined the channel [22:22] mscdex: jbrokc: yep, they're async [22:22] andihit: when I use apache2 in front of node.js, I dont get any performance improvement, but when I use nginx, I do, right? [22:23] mscdex: andihit: well, it's somewhat better since nginx uses an event loop, but nginx proxying still lacks some things [22:23] mscdex: like http 1.1, websockets, etc [22:23] jbrokc: mscdex: balls seriously? god i'm starting to dislike callback hell. hey can I do child_process.exec('foo', function(error) { console.log("whoops!" + error); }); as in just specify one variable in the callback and get the error? [22:23] michaelhartau has joined the channel [22:23] mscdex: although with newer versions of the websocket protocol, that should change [22:24] jbrokc: i've seen that in other parts of the docs / examples before but i've never quite understood the optional number of parameters for callbacks [22:24] reid has joined the channel [22:24] andihit: mscdex: but there is no other way, right? all my current projects use apache, and I don't want to redirect users with a port in the URL [22:24] mscdex: andihit: put node in front and proxy to apache if need be :p [22:25] mscdex: jbrokc: you can just have the error parameter in your callback if you want [22:25] mscdex: jbrokc: if you don't care about the stdout and stderr output from the process [22:26] mscdex: jbrokc: but if that's the case it might be better to use spawn and just not listen on stdout and stderr because exec buffers output [22:26] mscdex: jbrokc: but that's only an issue if the process is spewing out a lot of output [22:27] markmarkoh1 has joined the channel [22:27] eee_c has joined the channel [22:29] ncb000gt has joined the channel [22:29] beawesomeinstead has joined the channel [22:29] chunhao has joined the channel [22:29] jshaw has joined the channel [22:29] bradwright has joined the channel [22:29] rpflo has joined the channel [22:29] beawesomeinstead has joined the channel [22:31] secoif has joined the channel [22:31] skm has joined the channel [22:31] Kai` has joined the channel [22:31] eirikurn has joined the channel [22:31] terite has joined the channel [22:32] Kai` has joined the channel [22:32] terite has joined the channel [22:33] brianc1 has joined the channel [22:33] CStumph has joined the channel [22:38] catshirt has joined the channel [22:38] Xeon06_ has joined the channel [22:39] srid has joined the channel [22:40] zmbmartin has joined the channel [22:40] devdazed has joined the channel [22:40] lightcap has joined the channel [22:40] aaroninfidel has joined the channel [22:41] mgv has left the channel [22:41] bengl has joined the channel [22:41] aaroninfidel: hi, can someone point me to a doc on how to install the latest build of node? [22:41] shanebo: brew install node? [22:42] aaroninfidel: shanebo, is it recommend to install brew? [22:42] unlink has joined the channel [22:42] aaroninfidel: recommended* [22:42] shanebo: all OS X people I know use it [22:42] shanebo: it's really great [22:42] aaroninfidel: k [22:43] bradwright has joined the channel [22:43] nerdfiles1 has joined the channel [22:44] Sorella has joined the channel [22:44] Kai` has joined the channel [22:44] daleharvey has joined the channel [22:44] ajsie has joined the channel [22:44] whoops has joined the channel [22:44] nerdfiles1 has left the channel [22:44] patrickjst has joined the channel [22:44] aaroninfidel: shanebo how can I install latest using brew? [22:45] devdazed has joined the channel [22:45] devdazed has left the channel [22:45] shanebo: http://stackoverflow.com/questions/5056115/how-to-install-latest-version-of-node-using-brew [22:45] metadaddy has joined the channel [22:46] shanebo: so basically, install brew [22:46] shanebo: update brew (should already be up to date), then brew install node [22:47] footyfish has joined the channel [22:48] dekz has joined the channel [22:50] daleharvey has joined the channel [22:50] tomh- has joined the channel [22:50] tomh- has joined the channel [22:50] tomh- has joined the channel [22:50] dekz has joined the channel [22:50] htoothrot: wow, there's already a windows release? [22:50] _ralph has joined the channel [22:52] zeade has joined the channel [22:52] kulor-uk has joined the channel [22:53] booo has joined the channel [22:53] bengl has joined the channel [22:53] terite has joined the channel [22:57] ezmobius has joined the channel [22:57] markmarkoh has joined the channel [22:59] ngs has joined the channel [22:59] tjgillies has joined the channel [22:59] tjgillies has left the channel [23:04] CStumph has joined the channel [23:04] nibblebot has joined the channel [23:05] mikeycgto has joined the channel [23:05] mikeycgto has joined the channel [23:05] losing has joined the channel [23:05] WarriorSl has joined the channel [23:06] jbrokc: hi - can anyone help me determine why exec isn't working at all for me? https://gist.github.com/b64d03b2ca0615e19c4d [23:06] jbrokc: i followed the docs as much as i could [23:06] mbrevoor_: isaacs: I upgraded to 1.1.0 and I'm trying to replication and getting this error : Replication failed: {bad_term,<0.20798.0>} [23:07] dgathright has joined the channel [23:07] brianm has joined the channel [23:07] bnoordhuis: jbrokc: exec('haml --no-escape-attrs #{f} > #{path.basename(f)}' [23:07] mbrevoor_: isaacs: replicating from https://isaacs.iriscouch.com/registry/ [23:07] brianm has joined the channel [23:08] jbrokc: bnoordhuis: it's from coffeescript and should be interpolated.. [23:08] newy_ has joined the channel [23:08] isaacs: mbrevoor_: ah, yeah, seems like mine fell over eventually, too [23:09] bnoordhuis: jbrokc: the file is called fs.js [23:09] isaacs: mbrevoor_: {bad_term,{nocatch,{invalid_json,<<>>}}} [23:10] mcluskyd_ has joined the channel [23:10] mbrevoor_: isaacs: I get that error straight away when I start replication. Both with an existing database and with a new blank one [23:10] ank has joined the channel [23:10] CStumph has joined the channel [23:10] isaacs: mbrevoor_: hm, weird [23:10] isaacs: mbrevoor_: maybe it's time to do another good old fashioned "downlaod all the tarballs and republish to the new registry" [23:10] mscdex: jbrokc: i think you may need a closure to capture the value of `f` [23:10] jbrokc: nevermind. thanks bnoordhuis [23:10] ap3mantus has joined the channel [23:10] mscdex: jbrokc: in the for-loop [23:11] jbrokc: the problem was using single quotes [23:11] mscdex: :S [23:11] isaacs: mbrevoor_: can you try replicating from http://isaacs.ic.ht/reg2? [23:12] isaacs: hm, nvm, i hit the same bug with that one [23:12] isaacs: this is odd [23:12] matomesc has joined the channel [23:13] mbrevoor_: isaacs: I just flipped back over to 1.0.2 and I'm able to start replication (eventually fails on design docs) - just wanted to check. [23:13] saschagehlich has joined the channel [23:13] mbrevoor_: isaacs: yeah, let me flip back and try that [23:13] malkomalko has joined the channel [23:14] [[zz]] has joined the channel [23:14] ralphholzmann: heyo, when I leave my app on overnight, I wake up to a bunch of '(node) Hit max file limit. Increase "ulimit -n"'. Google says this could be file descriptors or http requests, is that accurate? [23:15] mbrevoor_: isaacs: seems to be working, at least initially with http://isaacs.ic.ht/reg2 (13Mb and 2 docs and counting) [23:16] TechCel has joined the channel [23:16] minimal has joined the channel [23:17] necrodearia has joined the channel [23:17] neorab has joined the channel [23:17] mscdex: ralphholzmann: yeah [23:17] mscdex: ralphholzmann: file descriptors [23:18] ralphholzmann: mscdex: cool, I'm currently using fs.readFile to do file reading -- would you recommend switching to fs.open/read/close to remedy this? [23:20] mscdex: ralphholzmann: a file descriptor is still being used in either case [23:20] cliffano has joined the channel [23:20] joshthecoder has joined the channel [23:20] ralphholzmann: right .. I just thought explicitly closing it would help ... [23:22] tcurdt has joined the channel [23:22] CrisO has joined the channel [23:23] bradleymeck has joined the channel [23:24] ekryski has joined the channel [23:25] tristanseifert has joined the channel [23:25] mscdex: ralphholzmann: readFile automatically closes the file descriptor after having buffered the file contents [23:26] nibblebo_ has joined the channel [23:26] AvianFlu_ has joined the channel [23:26] klovadis has joined the channel [23:26] cl0udy has joined the channel [23:26] Drakonite has joined the channel [23:27] markmarkoh1 has joined the channel [23:28] mcluskydodallas has joined the channel [23:28] jellosea: whats the difference between writing a string to a stream and a buffer? [23:29] jellosea: other than the obvious [23:29] jellosea: that its a buffer lol [23:29] bradleymeck: string may need to be copied as utf/etc. if its going into Buffer/OS [23:29] bradleymeck: buffer wont need a copy [23:30] jbpros has joined the channel [23:30] boehm has joined the channel [23:31] bradleymeck: ryah, you got a min about the autodiscovery of ports for servers? [23:31] jellosea: bradleymeck: so when i'm writing a buffer to the stream - whcih is a connection to a memcache server. i don't get a response back. i'm wiresharking the data and you are right, if i just send the string, it messes up the bytes, the problem is, the server responds even though i send up messed up bytes.. but when i write a buffer to the stream, it just hangs and i don't get a response back from the server [23:31] bradwright has joined the channel [23:31] jbrokc: if i have an exec within the callback of another exec, would they loop if the inner one failed? [23:32] bradleymeck: idk about memcache but the string is being encoded into a buffer at some port [23:32] bradwright has joined the channel [23:32] mscdex: jbrokc: huh? loop? [23:32] bradleymeck: some point* [23:33] mbrevoor_: isaacs: I get this error when I try to replicate over https: "Replication failed: {bad_term,<0.13736.0>}" but over http it seems to have worked... I at least have the design docs now [23:34] isaacs: hm yeah, i've been doing it all over just http [23:34] Kai` has joined the channel [23:35] isaacs: mbrevoor_: it works fine to replicate the file locally [23:35] jbrokc: mscdex: stick with me and read through it (coffeescript) https://gist.github.com/1ceffcc75e476745a3ca [23:35] isaacs: mbrevoor_: so i think we're hitting some odd bug in couchdb. especially since it keeps failing in different ways, judging from the logs [23:35] jbrokc: what happens is on saving a *.haml file, it will keep compiling it (going through that loop) even though I'm not changing it at all! is this because it fails? [23:35] paulwe has joined the channel [23:36] bengl has joined the channel [23:36] bradwright has joined the channel [23:37] jbrokc: shit [23:37] Kai` has joined the channel [23:37] ajsie has joined the channel [23:37] mbrevoor_: isaacs: however, I am getting this error when I try to GET a document from the registry "reason": "function raised error: (new TypeError(\"Object.keys is not a function\", \"\", 44) [23:37] jbrokc: i know why - it's because the file is on dropbox and when i save it, dropbox modifies it, then it saves it again, then dropbox modifies it again... [23:37] isaacs: mbrevoor_: update spidermonkey [23:37] isaacs: mbrevoor_: or patch it to add the Object.keys shim in more places. [23:37] isaacs: mbrevoor_: but really, get spidermonkey 1.8 [23:37] jbrokc: nope nevermind, that's not the issue [23:38] daleharvey has joined the channel [23:38] avian__ has joined the channel [23:39] mbrevoor_: isaacs: ok... ah... I had pull down the source and compiled but had trouble getting the couchdb build to find it in the configure so eventually used apt-get to install all of the deps [23:39] _ralph has joined the channel [23:40] monokrome has joined the channel [23:40] tomh- has joined the channel [23:40] tomh- has joined the channel [23:40] tomh- has joined the channel [23:41] footyfish has joined the channel [23:41] Nuck: God trying to use Bundler in ruby makes me long for NPM. [23:41] terite has joined the channel [23:41] Nuck: Thank god we had isaac [23:42] isaacs: :D [23:42] tristanseifert has joined the channel [23:42] patrickjst has joined the channel [23:42] Nuck: It's seriously installing old versions of gems that are needed by ChiliProject, despite me having newer versions [23:42] Nuck: And the end result is that it gets confused. [23:42] Nuck: NPM has NEVER done anything that stupid for me. [23:43] mbrevoor_: isaacs: did you build couchdb 1.1 with spidermonkey 1.8.5? [23:43] metadaddy has joined the channel [23:43] CIA-65: node: 03Ryan Dahl 07master * r1ca5b6c 10/ (wscript tools/nodejs.pc.in): Remove pkg-conf file - https://github.com/joyent/node/commit/1ca5b6cd0552e2c2b943876e878393d72104a62a [23:43] CIA-65: node: 03Ryan Dahl 07master * r497fe79 10/ src/node.js : [23:43] CIA-65: node: Speed up startup time [23:43] CIA-65: node: Reverts 2a05fe784d. - https://github.com/joyent/node/commit/497fe79f9759ff83161ff0620c47a6bdb7a205fe [23:43] dekz has joined the channel [23:44] AvianFlu: Nuck: my last linux build, I had three separate versions of ruby installed, because random stuff I'd install would have specific ruby version dependencies [23:44] wao: smuggling new node [23:44] whoops has joined the channel [23:44] isaacs: mbrevoor_: not sure, but that sounds about right [23:44] Cromulent has joined the channel [23:44] isaacs: mbrevoor_: can you replicate from http://admin.npmjs.org:5984/registry? [23:46] roidrage has joined the channel [23:47] iaincarsberg has joined the channel [23:48] Nuck: AvianFlu: Eww [23:48] avalanche123 has joined the channel [23:48] Nuck: AvianFlu: This is why my first internal project in my startup is gonna be a Node-based Project Management System. [23:48] Xeon06_ has joined the channel [23:49] Nuck: Thinking it might be a good thing to open-source even. [23:49] whynoyum has joined the channel [23:49] mbrevoor_: issacs: Replication failed: could not open http://admin.npmjs.org:5984/registry/ [23:49] whynoyum: How can I set the unlimit of files on osx Lion? [23:49] chunhao has joined the channel [23:49] chunhao has joined the channel [23:49] chunhao has joined the channel [23:50] bradleymeck: whynoyum `ulimit ...` in terminal doesnt work? [23:50] mbrevoor_: isaacs: I can curl it fine from my laptop but can't seem to connect from my server [23:51] mbrevoor_: isaacs: strange, i can ping it though [23:51] beawesomeinstead has joined the channel [23:51] whynoyum: ulimit -n 16192 -bash: ulimit: open files: cannot modify limit: Operation not permitted [23:51] HeikkiV_ has joined the channel [23:51] jbrokc has joined the channel [23:51] ctide: that's an invalid number [23:52] ctide: try 8192 [23:52] whynoyum: Currently its 8096 [23:53] whynoyum: So I figured 8096 x 2 = 16192 [23:53] mscdex: whynoyum: you need to be root [23:53] ctide: there's probably some upper bound then [23:53] ctide: i don't have to be root to change it [23:53] mscdex: eh? [23:54] Dreamer3 has joined the channel [23:54] mscdex: that's generally what "Operation not permitted" means [23:54] mscdex: but who knows [23:54] whynoyum: Yeah 8096 seems to be the max [23:55] whynoyum: Thats horse shit, no that many, doing benchmarking and setInterval and writing to a socket every 3 ms and getting too many open files [23:55] mscdex: isn't there an unlimited setting? [23:55] nibblebot has joined the channel [23:55] whynoyum: I can set to 0 [23:55] whynoyum: Is that unlimited? [23:56] isaacs: The value of limit can be a number in the unit specified for the resource or one of the special values [23:56] isaacs: hard, soft, or unlimited, which stand for the current hard limit, the current soft limit, and no limit, respectively. [23:56] AvianFlu_ has joined the channel [23:56] jbrokc: my exec under a fs.watchFile keeps looping for some reason without my modifying - that is, it keeps getting updated. is there an option I can add to have some sort of restriction? [23:56] isaacs: (from man bash. seriously, everyone should read this) [23:56] mscdex: whynoyum: ulimit -n unlimited [23:56] mscdex: iirc [23:56] whynoyum: ohhshit [23:56] thepatr1ck has left the channel [23:56] whynoyum: I gotta reboot, ulimit -n 0 made system very unhappy [23:56] thepatr1ck has joined the channel [23:56] ericzz has joined the channel [23:57] mscdex: heh [23:57] isaacs: you can't have an open file limit of "unlimited" [23:57] Alex_R has joined the channel [23:57] isaacs: -n The maximum number of open file descriptors (most systems do not allow this value to be set) [23:57] whynoyum: ANybody else Lion to test this? [23:57] isaacs: or anything, actually [23:57] dnyy has joined the channel [23:57] ctide: ulimit isn't system wide whynoyum [23:57] jeremyselier has joined the channel [23:57] ctide: you can close that terminal session and start a new one :) [23:57] ncb000gt has joined the channel [23:57] bnoordhuis: isaacs: can too! [23:58] markmarkoh has joined the channel [23:58] mattly has joined the channel [23:58] eventualbuddha_ has joined the channel [23:58] bnoordhuis: i always set my fd limit to unlimited + 1, just in case [23:58] thepatr1ck: whynoyum: try editing /etc/launchd.conf or running: launchctl limit maxfiles 400000 unlimited [23:58] eirikurn has joined the channel [23:59] dscape has joined the channel [23:59] thepatr1ck: er, the line to add to launchd.conf is "limit maxfiles 400000 unlimited" [23:59] isaacs: bnoordhuis: oh, wild, in mac (snow leopard) you can set it up *once* in the session, and then it's not allowed to beincreased again