[00:00] mraleph: unlink: I think node.js HEAD already has V8 with this fixes. [00:00] Figaroo: echosystm, the point is that it's more ideal to have tabs than to have spaces. [00:00] unlink: mraleph: OK... I'm using the latest tag. [00:01] mraleph: unlink: no I was wrong [00:01] echosystm: you should be more concerned about things like how classes are defined or naming conventions - they have an actual productivity impact [00:01] Mike_Rice: echosystem, it's not pointless, there are very valid points and opinions from both sides. I didn't mean to bring that discussion in here. It was a joke comment. [00:01] mraleph: unlink: just checked 3.0.10 will be valgrind friendly :-) [00:02] softdrink has joined the channel [00:02] tim_smart: mraleph: Oh, all good then :) [00:02] echosystm: ie. some people write classes that dont use the prototype, which makes them a pain in the butt to extend etc. [00:02] lumino: i like spaces [00:02] Figaroo: echosystm, what do you mean they don't use the prototype? [00:02] lumino: :) [00:03] arpegius has joined the channel [00:03] Mike_Rice: echosystem, one more thing and I'm done, tabs can very much be a productivity thing as far as creating cross platform compliance with customizabiltiy by the end-developer. Done... [00:03] mraleph: tim_smart: I am just trying to eat some dogfood, so I am rewriting small personal wiki from Lua to CoffeeScript+node.js [00:03] echosystm: a class that you need to extend, but cant, is a much bigger problem ;) [00:03] Mike_Rice: agreed about classing, naming, etc. [00:03] sh1mmer has joined the channel [00:04] pdelgallego has joined the channel [00:04] saschagehlich has joined the channel [00:04] Figaroo: echosystm: explain what you mean by the *wrong* way to create a class, that way I can avoid it. [00:05] pdelgallego_ has joined the channel [00:05] Figaroo: Is joyent free web hosting? [00:05] Figaroo: Like, could I build a site on top of joyent? [00:05] Solsys has joined the channel [00:06] Aikar: joyent is the company funding node/ryan, no.de is the site they offer for node hosting [00:06] Mike_Rice: figaroo, I thought it was akin to Google App Engine [00:06] Mike_Rice: a platform more than a webhost [00:06] sh1mmer: felixge: ping [00:06] felixge: sh1mmer: gnip [00:07] mscdex: hah [00:07] Figaroo: Mike_Rice, this concept is foreign to me. It's a platform, hmm... What does this mean? [00:07] echosystm: joyent does PaaS (no.de) and the usual IaaS stuff [00:07] echosystm: its on the home page [00:07] ROBOTARMY has joined the channel [00:08] mscdex: i thought it was AaaS -- Awesomeness as a Service [00:08] Figaroo: So it's like a web host with a inforced stack? [00:08] Mike_Rice: platform meaning you can build web services, batch processing, web front end, anything... then the "Platform" auto-scale it based on load and thresholds [00:08] Mike_Rice: figaroo, sort of [00:09] Mike_Rice: figaroo, http://en.wikipedia.org/wiki/Google_App_Engine [00:09] echosystm: like i said, they do both PaaS and IaaS [00:09] Aikar: no its not gonna auto scale it for you [00:09] felixge: sh1mmer: sup? [00:09] ryah_: piscisaureus: is tls working for you? [00:09] echosystm: Figaroo: http://en.wikipedia.org/wiki/Cloud_computing [00:09] Mike_Rice: Aikar, correct. Most require you to write admin jobs that scale it [00:10] sh1mmer: felixge: I'll get back to you about the email thread [00:10] sh1mmer: but I'm also doign some perf testing [00:10] felixge: sh1mmer: which email thread? [00:10] Aikar: you still have to design your app to be distributed, design code that auto spawns up new instances, auto joins the new instance to the distributed network, and spawn down as load lowers [00:10] sh1mmer: but I thought I might see if you had any thoughts about how to maximize throughput [00:10] unlink: I'm still stumped at the right way to package C++ extensions with a javascript file [00:10] sh1mmer: felixge: the PR one [00:10] unlink: "right" [00:11] sh1mmer: or where the bottlenecks with throughput might be [00:11] Aikar: unlink: for npm? [00:11] unlink: Aikar: yes. [00:11] felixge: sh1mmer: *confused*. What kind of throughput? [00:11] Aikar: check out 'fork' [00:11] sh1mmer: felixge: file transfers [00:11] Aikar: thats a binary based npm module [00:11] felixge: sh1mmer: I have not heard of any file transfer bottle necks [00:12] felixge: sh1mmer: you're tom right? [00:12] sh1mmer: felixge: well on a single core I'm getting about 150mb/s on a 2gb joyent machine [00:12] piscisaureus: ryah_: I don't compile with openssl. [00:12] sh1mmer: felixge: yeah [00:12] felixge: sh1mmer: would you expect your hard drive to be faster than that? [00:12] sh1mmer: felixge: that's from memory [00:13] piscisaureus: ryah_: will try if I can get that to work [00:13] felixge: sh1mmer: are you running the formidable benchmark included in the module? [00:13] sh1mmer: which module? [00:13] Mike_Rice: how often do most node package dev's publish fixes to npm? [00:13] felixge: sh1mmer: node-formidable [00:13] felixge: sh1mmer: I have no idea what you are talking about I think [00:13] sh1mmer: felixge: just in general via node [00:14] felixge: sh1mmer: yeah, but you were referring to some email thread, I don't remember it [00:14] sh1mmer: isaac pointed out you probably have the most experience using node for big lumps of data [00:17] piscisaureus: ACTION compiling openssl on mingw. pray. [00:18] unlink: Aikar: That's strange, it doesn't seem to mention the extension anywhere outside of the "node-waf configure build" [00:18] Aikar: unlink: wscript [00:19] unlink: Aikar: yes, right, what about ti? [00:19] Aikar: youll see def build do obj.target = fork and obj.source='fork.cc' [00:19] Aikar: thats where it issues the build [00:19] unlink: right but where does it install the .node [00:19] Aikar: build/default/fork.node i believe [00:19] Aikar: then you link to that [00:19] unlink: that's where it *builds* the module [00:20] Aikar: you then do in a .js file module.exports = require('./build/default/mymodule'); [00:20] Mike_Rice: git newb question, what is the git command to overwrite existing code locally from a hub? initially I did "git clone http://", what is it if i want to update to the current code? [00:21] unlink: Aikar: aha. I'm trying to install the .node module at the root level as well. [00:21] Aikar: well you could add a move command right after the build [00:21] unlink: Aikar: move where? [00:21] Aikar: but an index.js to include it would suffice [00:21] Aikar: mv ./build/default/blah ./blah ? [00:22] unlink: Aikar: my goal is to be able to require('foo') and require('bar') where foo is .js and bar is .node [00:23] felixge: ACTION gn8 [00:23] Aikar: unlink: oh um thatll be a lil more difficult [00:23] Mike_Rice: nevermind, git pull [00:23] unlink: Aikar: ah, I haven't discovered a way of accomplishing this via package.json [00:24] iFire` has joined the channel [00:24] unlink: perhaps I should stop framing JS packaging in terms of Python setuptools [00:27] Figaroo: I watched a video on Google App Engine. In the video, he created an app and then deployed it to the appspot.com server. I still don't understand how this is different from a regular VPS? [00:27] gkatsev: on a VPS you can do whatever you want [00:28] gkatsev: app engine is a slighly more advanced web host [00:28] Mike_Rice: Figaro, GAE is either Python or Java [00:28] Mike_Rice: Java is customized to their platform [00:28] Aria: Yeah. It runs apps all in their own containers -- very lightweight, flexible virtualization [00:28] Lorentz: My guess is there's no OS overhead per program instance on GAE? [00:28] Mike_Rice: I believe it is auto-scaling [00:28] Aria: (Kinda like no.de) [00:28] bmizerany has joined the channel [00:29] Mike_Rice: I believe they also strip out access to file system, local processes, etc. [00:29] cainus: what about no.de is auto-scaling? [00:29] Mike_Rice: I don't think it is [00:29] Mike_Rice: but don't take that as fact [00:30] Mike_Rice: ryah can answer [00:30] echosystm: auto-scaling would not be a good idea [00:30] cainus: I don't see anything node-specific that 'auto-scaling' would apply to [00:30] Mike_Rice: echosystem, why? [00:30] echosystm: it requires them to restrict the platform too much [00:30] ryah_: no, not auto-scaling [00:30] shiawuen has joined the channel [00:30] echosystm: ie. how do you auto-scale a websocket server in a generic way? you can't [00:31] echosystm: its application dependent, thus it should be controlled by the application [00:31] Lorentz: What IS auto-scale [00:31] Mike_Rice: echosyste, what about a web app [00:31] Figaroo: So, is it that there is no filesystem that you write to; instead you deploy your app and GAE stores it in a special, virtualized manner? [00:31] cainus: what would be the advantage of no.de over just running node on a vps? [00:31] ryah_: piscisaureus: are there not binary openssl packages for windows? [00:31] Mike_Rice: cainus, someone already said, you can do whatever you want [00:31] wookiehangover has joined the channel [00:31] Figaroo: cainus: good question. I double that question. [00:31] Mike_Rice: you have root access [00:31] piscisaureus: ryah_: didn't find any. but compiling is not the issue, but getting it to the right locations is. [00:32] cainus: Mike_Rice: so no advantage? [00:32] echosystm: yes, plain HTTP web applications can be scaled easily, but i dont think anyone would want no.de to be restricted to that just so some people can have automatic scaling [00:32] Aria: Simplicity. git push to run. [00:32] Aria: It's that much less infrastructure to maintain. [00:32] piscisaureus: ryah_: that is what coapp tries to solve :-) [00:32] Mike_Rice: cainus, a platform can give you advantages, such as auto-scaling for web apps [00:32] cainus: there's that word auto-scaling again :) [00:33] ryah_: piscisaureus: does windows have its own ssl implementation? [00:33] Mike_Rice: auto-scaling = increase performance or availability through additional processes, servers, or other mechanism [00:33] jchris has joined the channel [00:33] piscisaureus: ryah_: I don't know. but using openssl on windows is very common, so I guess not [00:33] cainus: that sounds like scaling in general... what's automatic about it? [00:33] Figaroo: So these platforms like AWS, GAE and joyent, they just abstract the VPS administration from you a bit? [00:34] Aria: Windows does, I believe in the sockets libraries. But I imagine they're pain. [00:34] ryah_: piscisaureus: that's good [00:34] Aria: Figaroo: Yes. [00:34] Aria: (AWS less so.) [00:34] cainus: GAE has an elastic datastore as well [00:34] ryah_: it'd be nice to find out where openssl is usually installed on windows [00:34] Mike_Rice: cainus, example. If you have a web app that converts images of foo's to bar's and slashdot says it's the best foo => bar converter out there, you suddently get a spike traffic. Auto-scaling will either add servers or memory, etc. so you don't go down or slow-down [00:34] ryah_: and be able to use that [00:34] echosystm: Figaroo: you need to read that cloud computing wiki i pasted you earlier [00:34] ryah_: we could hack wscript to look there [00:35] echosystm: IaaS and PaaS are two different things [00:35] Figaroo: Makes it a bit easier I guess. But if you were a company that wanted to do you're own scaling in the way you want, then VPS might be a better choice for you. [00:35] cainus: Mike_Rice: for node, that would mean automatically firing up new processes? [00:35] Figaroo: echosystm, PaaS or IaaS? [00:35] ryah_: i guess windows people don't have header files installed usually [00:35] Mike_Rice: cainus, I don't know Node.js well enough yet [00:35] Mike_Rice: figaroo, use Amazon or other "cloud" server provider [00:35] cainus: yeah it's hard to imagine what about node could auto-scale [00:35] Ari-Ugwu has joined the channel [00:37] Mike_Rice: cainus, the scenario that I can think (a high performance web app) would have a smart load-balancing front-end and fire up more processes/servers on-demand and dole out the requests [00:37] robtmr has joined the channel [00:37] Mike_Rice: that can be implemented on Amazon or Rackspace, etc. [00:37] cainus: yeah that makes sense I guess [00:37] saschagehlich: what's the best way to stop a http.ClientResponse from fetching more and more data? my use case: a user starts a download, the server downloads it to the server. as soon as the client disconnects, I want the download to stop immediately [00:37] cainus: looks like they have an API for that exactly [00:37] Mike_Rice: I'm using Rackspace right now for Node.js development [00:38] cainus: RS has a similar API, no? [00:38] Mike_Rice: yes, I believe they're trying to come up with a common API so Amazon, et al can share common standards [00:38] cainus: neat [00:38] echosystm: no [00:39] echosystm: everyone just tries to be EC2 compatible [00:39] Mike_Rice: "they" are working on a common API [00:39] Mike_Rice: so Amazon isn't the Microsoft in the pond [00:39] echosystm: what standard is that? [00:40] echosystm: i know rackspace and nasa are working on openstack [00:40] echosystm: but afaik, amazon have no involvement, nor eucalyptus [00:40] Mike_Rice: http://occi-wg.org/ [00:40] forzan has joined the channel [00:40] cainus: is th3e idea that some monitoring script can use the API to fire up new servers when necessary? [00:41] Mike_Rice: cainus, yes [00:41] Figaroo: What is a RESTful API; is it not just a API over the HTTP protocol? [00:41] Mike_Rice: Figaroo, yes [00:41] cainus: Figaroo: there's much more to it than that [00:41] Mike_Rice: cainus, but it sums it up in one line [00:41] cainus: soap is over http [00:41] cainus: and not even close to restful [00:41] echosystm: so amazon are _actually_ implementing OCCI? [00:42] Mike_Rice: echosystem, I don't know [00:42] Mike_Rice: I said "they", being a generic of someone. [00:42] echosystm: oh [00:42] Figaroo: But it's just a standardized protocol over HTTP. [00:42] piscisaureus: ryah_: whicj openssl version should I use? [00:42] Mike_Rice: Figaroo, yes, it uses Get, Put, Delete... [00:43] Mike_Rice: and Post [00:43] cainus: Figaroo: hypermedia ends up being one of most import parts [00:43] echosystm: $10 says amazon don't implement OCCI :P [00:43] echosystm: vendor lock-in baby! [00:43] Figaroo: But, I can use HTTP's methods and stuff anyway, why conform to the protocol? [00:43] cainus: ie, your api responses link to one another [00:43] Mike_Rice: Figaroo, are you trolling? [00:44] Figaroo: Mike_Rice: not intentionally. :\ Does it seem like I'm trolling? [00:44] Mike_Rice: Figaroo, it just seemed you were dragging it out, but if you're serious, I'll answer your questions [00:45] cainus: Figaroo: uniform interface, discoverability, cacheability... I'm mostly into it for the simplicity [00:45] [[zz]] has joined the channel [00:45] Mike_Rice: Rest is a loose specification [00:45] Mike_Rice: vs Soap, which is very defined [00:45] Mike_Rice: with XML and other crap [00:45] cainus: well there's no standard or spec for rest AFAIK [00:45] Figaroo: Oh, so it's just a name for something like Ajax? [00:46] cainus: Figaroo: maybe you should read up on the basics first :) [00:47] EyePulp has joined the channel [00:47] abraham has joined the channel [00:47] Mike_Rice: cainus, it's a general acceptance type of standard. Implementation is defined by the implementor. [00:47] Figaroo: Well, I know the twitter API is a RESTful API, but that only means that it's over HTTP -- in other words, it's not an API for a programming language. [00:48] Mike_Rice: any mediocre programming language can use a Rest API/web services [00:48] cainus: fielding's dissertation lays out some hard rules though [00:48] cainus: particularly HATEOAS [00:48] Mike_Rice: most of it is already defined in HTTP RFC's [00:48] Mike_Rice: e.g. Get, Post [00:49] cainus: REST doesn't even need to use http though [00:50] Mike_Rice: it's generally accepted to be HTTP/URI based [00:50] Figaroo: Mike_Rice: right, because the API isn't in one specific language. The API is in HTTP, so any language that can do HTTP can use the API. [00:50] Mike_Rice: figaroo: right [00:50] cainus: yeah people generally do it wrong though ;) [00:50] Figaroo: Okay, got it now. :) [00:50] cainus: saying it uses http doesn't differentiate it from soap, xml-rpc, etc [00:50] q_no has joined the channel [00:50] Mike_Rice: cainus: yes, that's why it's a democracy. Otherwise it would be a dictatorship [00:51] cainus: well one guy invented the concept ;) [00:51] ezmobius has joined the channel [00:51] Mike_Rice: yes, but he didn't patent it, license it, etc. [00:52] Kenta has joined the channel [00:52] Figaroo: I'm saying REST *is* an HTTP API. [00:52] cainus: no... but he's the one who says when people get it wrong [00:52] cainus: Figaroo: yeah that's wrong ;) [00:52] Figaroo: cainus, how so? [00:52] c4milo1 has joined the channel [00:52] Mike_Rice: cainus: Lol, I'm too tired to debate, I was up til 4AM working on this damn Node.js job [00:53] cainus: because you can make a restful api with or without http, and you can make http apis with or without rest [00:53] dgathright has joined the channel [00:53] cainus: I've never seen anyone use anything but http for a restful, because of the hypermedia requirement, http just makes the most sense [00:54] cainus: but all kinds of people make non-restful apis in http [00:54] cainus: soap, xml-rpc, etc [00:54] airhorns has joined the channel [00:55] cainus: http://en.wikipedia.org/wiki/HATEOAS <-- what most people miss [00:55] Mike_Rice: true, all I said was Figaroo summed it up in one line, yes we lost the implementation details, but it's a HTTP spec [00:56] Figaroo: I'm not saying HTTP only has one API. SOAP, xml-rpc, and things are also in HTTP. What I was saying is that RESTful APIs are just done in HTTP, in a way to abstract the actual code from the software using the API (e.g. GET /api/get/post instead of a using a function in a language or something). [00:57] cainus: yeah they don't tunnel over just POST, like SOAP... no disagreement [00:58] Mike_Rice: good, we're all in agreement [00:58] Mike_Rice: beers for all [00:58] cainus: yeah I could use one of those [00:58] Figaroo: Now, you're saying that REST APIs are not limited to HTTP, theoretically. Which I would suppose is true; the REST concepts could be easily ported to another transfer protocol in the future, maybe like WebSockets. [00:59] Mike_Rice: same here. I've got 18 beers in the fridge, but I've got 3 days to drop 5 more pounds. :-( [00:59] cainus: haha... got some competition? [00:59] Mike_Rice: self-imposed [00:59] Figaroo: Mike_Rice: Yeah, I think this subject has worn itself out. I'll take a beer, even though I'm not old enough. haha [00:59] Mike_Rice: I've got to be in shape for a race Thursday [00:59] cainus: just turn up the heat and wear garbage bags ;) [00:59] mynyml has joined the channel [01:00] Mike_Rice: Lol, I did that when i wrestled in highschool [01:00] Mike_Rice: while drinking beer? That could work though [01:00] cainus: then once you drop the 5 lbs try rehydrating with that beer :) [01:00] Mike_Rice: extreme drunk. Like drinking in a hot tub [01:00] cainus: haha [01:00] echosystm: coffee + vodka, you will wake up the next morning shredded [01:00] echosystm: true story [01:00] ShizWeaK_: anything + vodka = shredded [01:00] Mike_Rice: redbull + vodka [01:01] Lorentz: Depends on how much vodka [01:01] Mike_Rice: wake up not knowing what happened [01:01] Mike_Rice: video and photos will be the only "memories" [01:01] Figaroo: echosystm: cool story bro. [01:01] ShizWeaK_: if the camera makes it home in one piece Mike_Rice [01:01] Mike_Rice: sd cards, damn near indestructable :-) [01:02] Figaroo: Anyone ever tried 2host.com? [01:02] Mike_Rice: lost many a good camera to the drop, but 99/100, the card is still recoverable [01:02] Mike_Rice: <-- love solid state [01:03] Mike_Rice: OK, I haven't lost 100 cameras [01:04] Figaroo: I was thinking of using the cheapest end of 2host.com VPS for a Node or PHP project, but I'm not sure of their support. My partner trusts GoDaddy, but they're shared, unless you want to pay $20 for their equivelent VPS option. [01:04] Mike_Rice: I'm loosing it, is anyone good/familiar with http-agent? [01:04] Lorentz: I never liked godaddy [01:05] Lorentz: I've used linode and vpslink, probably am gonna try 2host too soon [01:05] piscisaureus: ryah_: win is fckd up, all http tests time out now :-( [01:05] Mike_Rice: linode, wasn't that the windows/linux rip off? :-) [01:05] Mike_Rice: no that was Lindows [01:06] skm has joined the channel [01:07] Figaroo: this review says their support isn't good http://vpshostingindex.com/2host-com-review-average-but-slow-support/ [01:07] Figaroo: a lot of people seem to use linode [01:07] Figaroo: there's fanaticalVPS [01:08] cainus: I use linode.. no complaints [01:09] saschagehlich: how can I check whether a file descriptor is still there / writable / closed? [01:09] Figaroo: cainus, yeah but I'll looking for something under or at $10 [01:10] Figaroo: hmm, I'll figure it out. :P [01:10] Figaroo: I'm out. Peace fellas [01:11] dekz: umm, anyone know the cause of Cannot read property 'isTTY' of undefined [01:11] Mike_Rice: figaroo: later [01:12] dekz: using readline.js [01:12] zentoooo has joined the channel [01:12] logicpath has joined the channel [01:14] pHcF has joined the channel [01:14] piscisaureus: ryah_: ping [01:14] skm has joined the channel [01:14] piscisaureus: dekz: the API of readline has changed [01:14] dekz: gah [01:15] m64253 has joined the channel [01:15] piscisaureus: dekz: it's not really a public api I think ... see the source [01:15] saul_: can i read the cookies returned from http.get()? [01:15] saul_: i'm looking through the response and i don't see them [01:16] piscisaureus: ryah_: when you're there, please call me, i'll be here for another half an hour or so [01:16] Lerchmo has joined the channel [01:17] nejucomo has joined the channel [01:17] mikeal has joined the channel [01:18] jacobolus has joined the channel [01:20] somebody has joined the channel [01:21] nejucomo: I cannot get signatures to work with crypto. I made a simplest test case here (with output): http://codepad.org/ANdj1gJt [01:21] nejucomo: Does anyone see the bug? [01:21] saul_: when i tried using SSL with node.js a month ago, i was told that it was broken [01:22] saul_: i don't know if it's been fixed yet [01:22] nejucomo: I noticed I can call verifier.verify('fakey non-PEM key', 'garbage') and it returns 0 without an exception. [01:22] nejucomo: That seems like a dangerous behavior for a crypto api. [01:22] nejucomo: I see. [01:22] nejucomo: Were told on this channel or the mailing list? [01:23] saul_: on this channel [01:23] nejucomo: hrm. Did they specify what is broken? [01:23] saul_: 22:17 < ryah> Zem: https is broken [01:24] saul_: 22:18 < ryah> Zem: working on it. probably by january it will be usable [01:24] nejucomo: Thanks. [01:25] zentoooo has joined the channel [01:26] zentoooo has joined the channel [01:27] sonnym has joined the channel [01:29] bmizerany has joined the channel [01:31] ossareh has joined the channel [01:32] ryah_: saul_: when was that? [01:32] saul_: Mon Dec 13 [01:33] saul_: is it working now? [01:34] saul_: i see "HTTPS server" in the changelog for 0.3.4 on 01.08 [01:34] MikhX has joined the channel [01:34] saul_: but i don't know what that means [01:37] nejucomo: Oh wow. Maybe it's time to run "git fetch" on my node. The latest tag I have looks like 0.1.102, whereas I see there's now 0.3.6. [01:40] dthompson has joined the channel [01:41] thepose has joined the channel [01:43] echosystm: http://www.silassewell.com/blog/2010/06/03/node-js-https-ssl-server-example/ [01:43] echosystm: i just tried this [01:43] echosystm: whenever i have HTTPS enabled, the server just hangs whenever a request comes in [01:43] echosystm: as soon as i comment out serSecure, it works (obv without SSL) [01:43] echosystm: any ideas? [01:44] echosystm: no errors printed out etc. [01:44] saul_: echosystm: i had the same problem in december, i think https is broken [01:44] echosystm: ah, nevermind, i found the prob [01:44] saul_: oh what was it? [01:44] echosystm: i typed certificate: instead of cert: [01:44] echosystm: :P [01:44] saul_: and now it works? [01:45] echosystm: yep [01:45] saul_: oh wow [01:45] saul_: well i guess i should get some dinner then [01:48] bingomanatee has joined the channel [01:48] dekz: z = [ 'a': [ c: 'c', d: 'd'] ] should I not be able to do z[0] to then be able to get c? [01:49] bingomanatee: you can't blend array notation and object notation like that. [01:49] dekz: z.length = 0 [01:50] dekz: easiest way to get the 'first' then from that object? or more regex :P [01:50] bingomanatee: are you familiar with the repl mode? you can type "node" with no parameters and do direct tests of javascript in real time [01:50] piscisaureus: ryah_: ping [01:52] bingomanatee: var foo = {a: 1, b: 2, c: 3} ; for(var index in foo){ console.log("first item is " + foo[index]); break; } [01:52] boogyman has joined the channel [01:53] laheadle: anybody got a code sample of node.io jobs setting the output of one job as the input of another? [01:54] bingomanatee: Sounds like a job for SubStack's work queue - or amqp [01:55] echosystm: does anyone know if connect supports https? [01:55] echosystm: do i just add setSecure or is there some connect-specific way? [01:57] benburkert has joined the channel [01:57] grim_fandango has joined the channel [01:59] joelklabo has joined the channel [02:00] SubStack: laheadle: you mean async flow control? [02:01] joelklabo: i keep running into this problem where i want to do something after a callback is finished in another function. The only way i can think to do it is put all my code in the callback from request. Which doesn't seem right. I would appreciate any guidance on it [02:01] Aria: Emit another event! [02:01] SubStack: named functions, event emitters, flow control [02:02] SubStack: lots of ways [02:02] joelklabo: ok, time to go read [02:02] joelklabo: thanks [02:02] abraham has joined the channel [02:03] ShizWeaK_: async.js, waterfall if i remember correctly [02:03] skm has joined the channel [02:04] bradleymeck has joined the channel [02:04] ryah_: piscisaureus: yo [02:05] ryah_: saul_: yes, it's working [02:05] piscisaureus: ryah_: tls seems to work on windows [02:05] joelklabo: what about passing varibles around? if something gets assigned in my request callback, and i want to assign it to another variable in another function [02:05] ryah_: piscisaureus: awesome! [02:05] piscisaureus: but this is very strange ... INADDR_ANY does not work ? [02:05] ryah_: piscisaureus: did you have to hack it much? [02:05] ryah_: undefined symbol? [02:06] kawaz_air has joined the channel [02:06] piscisaureus: ryah_: no much stranger [02:06] spetrea: just found out this cool piece of code somehwere [02:06] spetrea: http://pastie.org/1491542 [02:06] spetrea: can you figgure out what it prints without compiling it ? [02:07] piscisaureus: ryah_: i can create a server that listens on inaddr_any, and then if I try to connect to it... [02:07] ryah_: [ { name: 0 }, { name: 1 }, ... ] [02:07] piscisaureus: ryah_: the connecting sockets says there is a connection, but I the server end doesn't do anything [02:07] ryah_: piscisaureus: hm [02:08] ryah_: piscisaureus: is the server accepting the connection? [02:08] piscisaureus: ryah_: binding to loopback works [02:08] piscisaureus: ryah_: well, in node, net Appect() is never called [02:08] piscisaureus: *Accept [02:08] ryah_: piscisaureus: in the server? [02:08] piscisaureus: yeah [02:09] piscisaureus: but the client does emit a 'connect' event [02:09] piscisaureus: if the server never starts at all, the client says 'connection refused' like it should [02:09] ryah_: strange [02:10] piscisaureus: ryah_: the only thing I can come up with is select not working on inaddr_any bound sockets [02:10] piscisaureus: it makes me pissed [02:10] ryah_: could that really be the case? [02:10] piscisaureus: ryah_: I hope not. I really hope not. [02:10] ryah_: that seems like a really strange error to have [02:11] ryah_: what's inaddr_any defined as? [02:11] piscisaureus: 0 [02:11] laheadle: SubStack: yes, with multiple jobs reading and writing to inputs and outputs for each other [02:13] ryah_: piscisaureus: you should just hack it to say 127.0.0.1 [02:13] Lorentz: I wonder if I can port nodejs to something like baremetal OS [02:13] piscisaureus: ryah_: that's cool. but it's not as if inaddr_any is useless :-/ [02:14] bingomanatee: Noogle is coming along. Got the indexing down - now I just need to get the search and dsiplay running and we are up and away! [02:14] necromancer has joined the channel [02:14] ryah_: piscisaureus: true, but that'll make it run for most people [02:14] aconbere has joined the channel [02:14] necromancer: is there a way to write to the filesystem using node? [02:14] ryah_: piscisaureus: maybe printf and error there [02:14] ryah_: piscisaureus: "Note 0.0.0.0 is broken on windows" [02:14] necromancer: i'm looking to create a script that's meant to be run in the command line on a file [02:15] necromancer: how would i do this with javascript? [02:15] piscisaureus: ryah_: hmm. ok. better than nothing [02:15] ShizWeaK_: laheadle: check out http://caolanmcmahon.com/async.html [02:18] echosystm: does anyone know if there are any potential security issues with the current WSS spec or the socket.io implementation of it? [02:18] Mike_Rice: does request handle get parameters inline, e.g. /test.php?q=My+Search+String or do they have to be passed in a special way? [02:18] Lorentz: Looks like I'm not the first to mix baremetal os and node [02:19] laheadle: ShizWeak_ That's cool. gonna stick with node.io for now though. [02:20] Lorentz: (baremetal is a single threaded OS, meant to be speedy, thought it might go well with nodejs since it also is (for now) a single process) [02:20] Lorentz: But it's not exactly posix or anything, so hrm [02:20] Lorentz: It'd be an interesting project [02:20] nejucomo has joined the channel [02:20] russell_h: https://github.com/ry/node/blob/master/lib/http.js#L542 <-- does that look wrong to anyone else? [02:21] russell_h: pretty sure that'll break repeat calls to addTrailers [02:21] sudoer has joined the channel [02:21] bmizerany has joined the channel [02:22] ossareh has joined the channel [02:22] shiawuen has left the channel [02:26] shiawuen has joined the channel [02:28] jpld has joined the channel [02:30] brianm has joined the channel [02:31] Moo has joined the channel [02:34] charlenopires has joined the channel [02:34] bmizerany has joined the channel [02:35] ROBOTARMY has joined the channel [02:40] allengeorge has joined the channel [02:41] shaunau has joined the channel [02:43] ryah_: russell_h: hm, yeah [02:44] ryah_: russell_h: modify test/simple/test-http-set-trailers.js to demostrate it? [02:44] russell_h: ryah_: yeah, working on that now [02:44] russell_h: it looks like there's something wrong in the client too, trying to figure out what [02:44] walkah has joined the channel [02:45] maru_cc_ has joined the channel [02:48] shiawuen has joined the channel [02:52] Coal has joined the channel [02:58] mikeal has joined the channel [03:01] zentoooo has joined the channel [03:01] Lerchmo has joined the channel [03:02] meso has joined the channel [03:03] russell_h: ryah_: this doesn't seem to be something I'm qualified to fix, but from the looks of things its only possible to get one trailer back from the parser (or at least the binding) [03:03] russell_h: https://github.com/ry/node/blob/master/lib/http.js#L106 [03:04] ROBOTARMY has joined the channel [03:04] piscisaureus: hey ryah_: I can work around the inaddr_any issue [03:05] piscisaureus: ryah_: something else, test-http-agent and test-tls-client-verify just hang :-( [03:05] piscisaureus: ryah: should solve that another time tho, it's too late already [03:06] lukegalea has joined the channel [03:06] nejucomo has joined the channel [03:06] lukegalea: hey, is anyone using the NG branch of Mongoose yet? [03:10] piscisaureus: ryah_: looks like tls client doesn't always emit the end event propertly [03:11] skm has joined the channel [03:12] ttpva has joined the channel [03:12] statim has joined the channel [03:13] dgathright has joined the channel [03:14] necromancer has joined the channel [03:18] necromancer has joined the channel [03:18] lukegalea has joined the channel [03:18] echosystm: the websocket security issue, for which firefox and operator decided not to implement websocket... does that apply even for WSS? [03:20] hassox has joined the channel [03:20] kawaz_air has joined the channel [03:20] echosystm: s/operator/opera/ :P [03:22] piscisaureus has joined the channel [03:22] whyme has joined the channel [03:22] mscdex: i don't know, i just work here [03:24] jwcooper has joined the channel [03:24] shiawuen has joined the channel [03:25] jwcooper: anyone know how to set the base path in express to domain.com/something? To avoid having '/something' in every route? [03:26] yhahn: jwcooper: you can probably add a custom middleware in front of your router that removes such a portion from the request path [03:26] jwcooper: aah, good idea, that would work. Was hoping it was built in to express, but might not be. [03:27] flazz has joined the channel [03:27] yhahn: not that i know of but i may be wrong [03:27] jwcooper: I initially thought 'app.set('home', '/something');' would work, but didn't. [03:27] flazz: kiwi vs npm, what's the skinny? [03:28] benburkert has joined the channel [03:28] jwcooper: flazz: I think npm is pretty much the standard now. [03:29] dspree has joined the channel [03:29] flazz: jwcooper: all i wanted to know [03:29] flazz: thanks [03:29] Ls_Away has joined the channel [03:29] necromancer has joined the channel [03:29] flazz: and express is the 800lb Sinatra? [03:30] jwcooper: flazz: yup, express is solid, and actively developed [03:31] lukegalea has joined the channel [03:31] flazz: nice [03:31] cainus: kinda hard to call it 800lbs :) [03:31] flazz: i know, unintentional irony [03:31] flazz: but i'll take it [03:31] piscisaureus: ryah_: ping [03:31] fairwinds: hi. assembling some forms with express. decided to try using names in form inputs such as name="user[username]". It retrieves data in req.body as "user[username]: 'some user' as example. I have express body decoder installed. [03:31] fairwinds: Should be able to get user object from req.body ie. req.body.user but not so. If I just use regular names such as name="username". These are in in request body and can access like req.body.username. [03:32] flazz: is coffeescript becomming very popular? [03:33] cainus: flazz: they hooked me [03:34] fairwinds: not sure where going wrong. bring decoder into app using app.use(express.bodyDecoder()); [03:34] flazz: cainus: any big caveats? [03:34] cainus: nope... not yet [03:34] jchris has joined the channel [03:35] cainus: there's a way to fallback to js in your .coffee file if necessary, but I've never found a reason [03:36] cronopio has joined the channel [03:36] ryah_: piscisaureus: pong [03:36] Lorentz: echosystm: Something to do with bad implementation of transparent proxies, meaning they can be poisoned? [03:36] piscisaureus: ryah_: ah :-) [03:37] piscisaureus: ryah_: test-http-agent works fine when I set maxSockets to 1, but with bigger numbers it 'hangs' [03:37] ryah_: huh [03:37] piscisaureus: ryah_: what is the failure mode for that? [03:37] ryah_: do you think that's a windows problem? [03:37] piscisaureus: ryah_: umm no actually [03:37] piscisaureus: well maybe there's a bug in my net code ... [03:38] Lorentz: echosystm: And to solve an issue that really has to do with how most proxies are implemented by fixing the protocol itself [03:38] Lorentz: Not sure if it gets solved by using wss [03:38] piscisaureus: the last thing that NODE_DEBUG=http gives me is "Agent connected" [03:38] piscisaureus: then... nothing [03:39] Lorentz: echosystm: Considering it's because of Upgrade header, wss might be affected too, but I'm not 100% sure. [03:39] sudoer has joined the channel [03:39] ryah_: piscisaureus: connection errors are actually req emits an error [03:39] ryah_: the socket or connection error [03:40] piscisaureus: yeah but then that test should just die right? [03:40] zemanel: is there a couchdb connect session store around? [03:41] ryah_: piscisaureus: yeah [03:42] Ond has joined the channel [03:44] fairwinds: cainus: coffeescript looks a lot like python. like the classes implementation also [03:45] fairwinds: will have to give it a whirl, looks great really for readability also [03:45] viirya has joined the channel [03:46] cainus: yeah seems like a nice mix of ruby and python [03:47] cainus: it fixes a few js idiosyncrasies too [03:47] fairwinds: cainus: cool [03:48] Mike_Rice: ::Slaps Self:: I figured out, why I haven't been able to get my node.js screen scraper to work for the last 24 hours... Incorrect URL [03:48] fairwinds: Mike_Rice: that's sad :-) [03:49] Mike_Rice: I was digging through library code, trying to figure out why it wasn't passing the Get parameters properly [03:49] Mike_Rice: :-( [03:49] Mike_Rice: sometimes... it's the simplest things [03:49] fairwinds: yeah [03:49] fairwinds: think everyone has had those kind of days [03:49] piscisaureus: ryah_: looks like this is actually a node bug [03:51] piscisaureus: after connect fails with EINPROGRESS the watcher is modified to only respond to read [03:52] jimt has joined the channel [03:54] DTrejo has joined the channel [03:55] mike5w3c has joined the channel [03:56] x0xMaximus has joined the channel [03:56] DTrejo: hey everyone :) [03:59] flazz: function calls that take no args must have () in coffee-script? [04:02] ryah_: piscisaureus: where? [04:02] jimt has joined the channel [04:03] piscisaureus: ryah_: I don't know but putting a fprintf in ev_select.c, I can see that select_modify(fd, 2, 1) is called after connect fails with that fd [04:03] ossareh has joined the channel [04:03] ryah_: ok [04:04] ryah_: er, that sounds right [04:04] ryah_: the server fd ? [04:04] piscisaureus: no the client fd [04:06] piscisaureus: it's probably my own stupid-ness that I'm overlooking somewhere [04:06] ryah_: i think that's also okay.. [04:10] djacobs7 has joined the channel [04:11] cloudhead has joined the channel [04:12] piscisaureus: ryah_: hmm. you are probably right just as always. I will try again some other day. Just too frustrated right now... [04:14] Evet: future of node.js: http://en.wikipedia.org/wiki/Naked_objects [04:16] echosystm: SubStack: i'm getting "Failed to load resource" with DNode - :8080/socket.io/xhr-polling//12312311221etc [04:16] echosystm: any ideas? [04:17] SubStack: gist it [04:17] echosystm: wait, i think ive found the problem [04:17] EyePulp has joined the channel [04:18] echosystm: sorry, ive fixed it [04:21] clarkfischer has joined the channel [04:21] cloudhead has joined the channel [04:22] dgathright has joined the channel [04:25] charlenopires has joined the channel [04:26] ryan[WIN] has joined the channel [04:28] DTrejo: What do you guys think of this updated node readme? https://github.com/DTrejo/node/blob/master/README.md [04:28] DTrejo: (just the resources for newcomers stuff at the bottom) [04:28] DTrejo: I'd be happy to add links for "how to contribute" and other important things, but I don't know where to find them [04:29] jesusabdullah: I know what I think of when I see your name! [04:29] jesusabdullah: http://en.wikipedia.org/wiki/Danny_Trejo [04:29] DTrejo: ryan_: ^ thoughts? [04:29] jesusabdullah: Had to think about it for a while [04:29] DTrejo: :) [04:33] DTrejo: What do you guys think of this updated node readme? https://github.com/DTrejo/node/blob/master/README.md (see the resources for newcomers at the bottom). I'd be happy to add links for "how to contribute" and other important things, but I don't know where to find them. [04:36] braddunbar has joined the channel [04:38] nejucomo1 has joined the channel [04:39] Figaroo has joined the channel [04:43] echosystm: exit [04:43] echosystm: ugh [04:43] echosystm: fml [04:49] micheil has joined the channel [04:51] saschagehlich_ has joined the channel [04:52] opengeard has joined the channel [04:54] tk has joined the channel [04:55] jpld has joined the channel [04:56] piscisaureus: ryah_: ok. it is a bug in how libev does select on windows. [04:56] piscisaureus: ACTION leaves [04:56] joelklabo has joined the channel [04:58] zentoooo has joined the channel [05:01] jchris has joined the channel [05:06] Elephanter has joined the channel [05:08] joelklabo: I am confused about some pretty basic js stuff: https://gist.github.com/792860, its so basic i dont even know how to ask the question, anyone have time to look? [05:09] joelklabo: there are comments in there [05:09] mikeal has joined the channel [05:11] sprout has joined the channel [05:11] aconbere has joined the channel [05:14] ShizWeaK_: joelklabo: whats the issue? [05:16] joelklabo: i am trying to get a value from the callback to be assigned to a variable in another function. [05:16] joelklabo: how do i assign it without putting all that code inside of the callback [05:17] joelklabo: or i guess i could use a global but it seems like there should be a better way [05:20] jacobolus has joined the channel [05:21] ezmobius_ has joined the channel [05:21] DTrejo: joelklabo: hey, I'll help in just a second, and show you some example code which should make things cleaer [05:21] DTrejo: *clearer. one second though [05:21] joelklabo: sweet thanks [05:22] piscisaureus has joined the channel [05:25] tg has joined the channel [05:26] themiddleman has joined the channel [05:26] zemanel: im doing some groundwork on a tron-like game @ https://github.com/zemanel/megatorn [05:26] zemanel: hope i dont make any kitten die with the code, been ages since i mess up with node [05:28] wkmanire has joined the channel [05:28] DTrejo: joelklabo: here you are! https://gist.github.com/792876 [05:28] wkmanire: Howdy folks. [05:28] DTrejo: joelklabo: let me know if that raises any questions [05:29] joelklabo: DTrejo: awesome, checking it out now... [05:29] tim_smart: DTrejo: How are babies formed? [05:29] mike5w3c has joined the channel [05:30] Figaroo: Who here recommended 2host to me a while back? [05:30] wkmanire: What is a good way to model code so that it can be used both by node.js and the client. Essentially, it needs to be able to provide a model to nodejs and a namespace to closure-compiler. [05:31] DTrejo: tim_smart: hi? with callbacks and by passing functions around? [05:31] wkmanire: I have a working experiment that checks to see if typeof module === 'undefined' to decide whether to goog.provide the namespace. Is this a good idea? [05:31] liar has joined the channel [05:31] tim_smart: DTrejo: I was just being a troll. [05:31] warz has joined the channel [05:32] DTrejo: tim_smart: is that something that danny trejo answered? [05:32] iMAN has joined the channel [05:32] DTrejo: joelklabo: just updated it to make it clearer: https://gist.github.com/792876 [05:33] joelklabo: DTrejo: so in the callback i pass in i could just 'return "something"' and it would get assigned to results, because it will wait for the request callback to move past that point? [05:33] joelklabo: ok.. [05:33] pkrumins: gonna go to sleep kit [05:33] iMAN: hello, got an error when I ran the tests for the first time "Command failed: /bin/sh: curl not found" [05:33] iMAN: what package do I need to get? [05:34] DTrejo: joelklabo: well, sorry, look at the updated version [05:34] tim_smart: iMAN: curl [05:34] pkrumins: wrong channel [05:34] wkmanire: iMAN: which os? [05:34] Utkarsh_ has joined the channel [05:34] iMAN: ubunto [05:34] joelklabo: DTrejo: ok, i think i get it. [05:34] wkmanire: iMAN: sudo aptitude install curl [05:34] wkmanire: then try again [05:34] iMAN: ty [05:34] joelklabo: DTrejo: let me see if i can make it work, thanks for the help [05:35] DTrejo: joelklabo: passing a callback is like saying "when you're done doing work, execute my code again please." except that when you're inside that callback you can't get back out, in that you still have access to global variables, but "return" is not useful, because you can only go "deeper" into the nest of callbacks [05:35] DTrejo: joelklabo: I dunno if that's a helpful explanation [05:36] Aria: Or more simply, "run this bit later. Remember the context for it, please?" [05:36] wkmanire: A callback might be called periodically during execution as well... [05:36] jchris has joined the channel [05:37] iMAN: thanks wkmanire! ever test worked [05:37] Figaroo: Could anyone here recommend a cheap, but good, VPS? [05:37] iMAN: do people generraly use eclipse? [05:37] wkmanire: iMAN? no problem. [05:37] iMAN: whats the best IDE for a person who needs a debugger? [05:37] wkmanire: oops meant to put a colon not a question mark. [05:38] joelklabo: Dtrejo: it is, that's what i was looking for. what would you call that subject? if one were to look for information about it [05:38] zentoooo has joined the channel [05:38] tim_smart: iMAN: I'm guessing most people use a text editor of some kind around here, with node-inspector as a debugger. [05:38] iMAN: ahhh [05:39] tim_smart: I personally debug my code with console.log and friends. [05:39] iMAN: nice friends [05:39] wkmanire: iMAN: emacs in js2-mode. [05:39] tim_smart: vim <3 [05:39] wkmanire: :) [05:39] brianc: emacs w/ espresso mode here [05:39] iMAN: ty [05:40] wkmanire: brianc: How is espresso? I haven't tried it. [05:40] brianc: wkmanire: awesomeness [05:40] Figaroo: espresso > coda? [05:40] wkmanire: brianc: Does it do real-time linting? [05:40] brianc: wkmanire: no, but you can set up lint-mode for that outside of either js2-mode or espresso mode [05:41] DTrejo: joelklabo: just got back from brushing my teeth: it's called callback passing style I think? [05:41] brianc: wkmanire: what I like about espresso mode is it uses tabs in a very very sane way [05:41] joelklabo: DTrejo: cool, ty [05:41] brianc: wkmanire: so you can c-c n to clean up tabs in the entire buffer and it's all beautifully tabbed [05:41] wkmanire: nice [05:41] Figaroo: Can no one read my messages? [05:42] DTrejo: joelklabo: an article that looks like it'll be good: http://matt.might.net/articles/by-example-continuation-passing-style/ [05:42] tim_smart: Figaroo: Subject to opinion. [05:42] Figaroo: tim_smart: haha [05:42] tim_smart: Figaroo: Try emacs + expresso mode and see what you think. [05:42] tim_smart: (I don't use it personally) [05:43] Figaroo: espresso is a mac only application though. I R using Windoze. xP [05:43] tim_smart: Figaroo: I think you are getting emacs + expresso mixed up with something else. [05:43] brianc: Figaroo: no, espresso is a major-mode for editing javascript buffers within emacs [05:44] DTrejo: yeah that's a pretty good article joelklabo, glad I found it, for future referene [05:44] DTrejo: *reference [05:44] joelklabo: sick [05:44] Figaroo: tim_smart, brianc: oh, never heard of it [05:44] tim_smart: Figaroo: emacs is GNU software and generally runs on all platforms. [05:45] Figaroo: emacs, is a terminal editor? [05:45] tim_smart: It has a GUI version as well. [05:45] brianc: Figaroo: it runs in terminals and in native os gui windows [05:45] tim_smart: I use vim, a terminal editor for my daily editing needs. [05:45] brianc: Figaroo: the gui versions integrate with operating system clipboards and various other OS things [05:45] wkmanire: Figaroo: You can get a windows distribution of emacs. I'll find a link for you. [05:46] mscdex: ugh, gmail's imap server is being non-rfc compliant >.> [05:46] wkmanire: Figaroo: It takes some time to get used to. Also VIm is well liked and I think you can get it for windows as well. [05:46] tim_smart: Figaroo: Another good windows editor (if you like textmate) http://www.e-texteditor.com/ [05:46] brianc: Figaroo: emacs and vim both run basically any *nix terminal as well as integrating into windows, os x, and gnome [05:46] Figaroo: e-texteditor = $ [05:47] mscdex: i sent it a NOOP and it sends me a tagged "OK Success" response instead of a tagged "NOOP Completed" [05:47] mscdex: :S [05:47] wkmanire: Figaroo: http://ftp.gnu.org/gnu/emacs/windows/ [05:47] muk_mb has joined the channel [05:47] wkmanire: notepad++ is nice for quick edits. [05:47] wkmanire: It has syntax highlighting and a lot of plugins. [05:47] brianc: Figaroo: but both emacs and vim have a very steep learning curve...what you gain in the end is being generally way more effecient and some nerd cred ;) [05:47] wkmanire: Kind of like gedit for windows, but it does a little more. [05:47] brianc: yeah notepad++ is pretty nice [05:47] mscdex: i use notepad++ on windows [05:47] mscdex: using it right now :-D [05:48] softdrink has joined the channel [05:48] mscdex: i just wish gedit had some of its features [05:48] mscdex: like auto-highlighting all instances of the current selection in the current document [05:48] Figaroo: brainc, I think I looked into them before. IIRC, something like you use your letter keys to navigate and stuff. I don't see why this would make you more efficient? [05:49] wkmanire: its about getting your hand off the mouse and keeping it in the home position. [05:49] wkmanire: Every time you move your hand over to the arrow keys you are wasting time and effort. [05:50] wkmanire: Once you get used to emacs you almost always have your hands in the home position, also helps to swap your ctrl key and your capslock key. [05:50] Elephanter has left the channel [05:50] wkmanire: sharpkeys for windows will help you with that, on most linux distros there is built in software to help you configure your keyboard. [05:51] brianc: Figaroo: yeah and it gets better for example in vim you have this line in your code: "var boom = 'something' + 'something else'" [05:51] Elephanter has joined the channel [05:51] brianc: youc an type: 3t'd2f'Oy [05:52] brianc: and you've just extracted "somethign else" to a line above [05:52] brianc: so you end up moving text around a lot faster which allows you to think about typing less and thing about your code more [05:52] Figaroo: extracted? [05:52] brianc: but it takes a lot of practice [05:53] brianc: you can check out the "smash into vim" peepcode broadcast for more info [05:53] wkmanire: brianc: Yeah it does. he he he. [05:53] brianc: I personally perfer emacs but can get around in both emacs and vim [05:53] Figaroo: to bad you couldn't just drag it around with your fingures... [05:54] mikeal has joined the channel [05:54] brianc: once you get a nice setup with a text editor you're comfortable with and gnu screen [05:55] brianc: I've found you stop thinking about the programs you're running and can totally focus on the programs you're writing [05:55] brianc: which is the whole point. :) [05:56] brianc: if you achieve that through textmate + terminal windows or notepad++ and cygwin or visual studio or eclipse or whatever, as long as your text editor isn't in your way, I think you're on the right track. [05:58] saul_: how long have you been programming, brianc? [05:58] mscdex: yay! message streaming in node-imap! [05:58] brianc: saul_: since about 9:00 pm [05:58] mscdex: \o/ [05:58] saul_f: brianc: ^^ [05:58] brianc: hehe [05:58] saul_f: it's 10pm here in seattle [05:59] brianc: Uhh not that long. maybe 7 years [05:59] saul_f: i'm reading the guide to expressjs [05:59] Aria: Sweet, mscdex! [05:59] saul_f: long enough [05:59] brianc: mscdex: awesome! [05:59] brianc: mscdex: node-gmail? [05:59] mscdex: node-imap ;-) [05:59] mscdex: but i am testing agianst gmail [05:59] brianc: mscdex: hotness. just what i wanted to hear [06:00] brianc: oh must go to sleep now. have work early. night. [06:00] saul_f: night [06:01] warz has joined the channel [06:04] wkmanire has left the channel [06:05] halfhalo has joined the channel [06:06] mikeal has joined the channel [06:06] kawaz_air has joined the channel [06:08] void_ has joined the channel [06:09] Figaroo: I believe that the future isn't in console editors. [06:09] Figaroo: Watching some tutorials on emacs, not my style. [06:11] mscdex: i always use nano for quick editing from the console :p [06:11] hassox has joined the channel [06:11] fallsemo has joined the channel [06:13] echosystm has joined the channel [06:14] beawesomeinstead has joined the channel [06:14] echosystm: SubStack: when i use dnode with connect, it seems to stop other middleware modules from working [06:14] echosystm: ie. i have basicAuth and staticProvider in the rack [06:14] echosystm: whenever dnode listens on the same http server, basicAuth stops working [06:15] SubStack: odd! [06:15] wkmanire has joined the channel [06:15] wkmanire: I'm back. [06:15] SubStack: echosystm: do you have some code so I can make a test? [06:15] echosystm: i can write some [06:15] echosystm: give me a few minutes [06:15] SubStack: excellent [06:17] dgathright has joined the channel [06:18] EyePulp has joined the channel [06:19] echosystm: i just tested my code again and it seems to be working now, despite me not changing anything :/ [06:22] echosystm: well, im stumped [06:23] echosystm: that wasnt working for the better part of an hour [06:25] SubStack: code ghouls! [06:25] echosystm: i think it might be something to do with virtualbox [06:25] echosystm: some networking stuff seems to screw up now and then [06:27] echosystm: anywho, home time [06:27] echosystm: sorry to have bothered you [06:27] echosystm: ciao [06:28] halfhalo has joined the channel [06:28] wkmanire has left the channel [06:31] guybrush: is there a lib to create less-files? [06:31] pedrobelo has joined the channel [06:31] brainproxy: there's less.js [06:31] brainproxy: not sure if that's what you mean [06:31] bingomanatee has joined the channel [06:32] guybrush: less.js will parse less-files and create css [06:32] brainproxy: ah, i see [06:32] brainproxy: so you're wanting to generate less automatically [06:32] wkmanire has joined the channel [06:32] guybrush: i want to create less-files out of json for example [06:32] guybrush: right [06:32] brainproxy: you could try using a javascript templating tool for that [06:32] brainproxy: I like shotenjin [06:32] brainproxy: but ymmv [06:32] guybrush: its not that hard to do it, just wanted to check if there isnt already some work done [06:34] guybrush: i guess i will do it with mustache [06:34] guybrush: style.json -> stylesheet.mu -> stylesheet.less -> stylesheet.js is kinda weird? lol [06:34] brainproxy: :) [06:35] guybrush: style.json -> stylesheet.css will do it [06:35] brainproxy: sounds like a lot of overhead [06:35] guybrush: style.json -> stylesheet.mu -> stylesheet.css will do it [06:35] deepthawtz has joined the channel [06:38] micheil: voodootikigod: you about? [06:39] halfhalo_ has joined the channel [06:42] GasbaKid has joined the channel [06:44] Figaroo has joined the channel [06:46] halfhalo has joined the channel [06:48] ph^ has joined the channel [06:48] joelklabo: can i use ECMAscript 5 stuff in node? [06:48] admc has joined the channel [06:49] DTrejo: joelklabo: YES! [06:49] joelklabo: cool, ty [06:50] DTrejo: joelklabo: in case you havent discovered this: https://github.com/ry/node/wiki/_pages [06:50] DTrejo: in particular: https://github.com/ry/node/wiki/ECMA-5-Mozilla-Features-Implemented-in-V8 [06:52] joelklabo: nice, thanks [06:53] DTrejo: joelklabo: we need to do a better job with surfacing information on the main wiki page, and on the repo home page, and on the site, it'll get better soon I hope, I semi-started working on it [06:54] MrTopf has joined the channel [06:55] ezmobius_ has joined the channel [07:02] pomodoro has joined the channel [07:06] meso_ has joined the channel [07:08] ossareh has joined the channel [07:12] riven has joined the channel [07:15] skm has joined the channel [07:20] balaa has joined the channel [07:20] kawaz_ai_ has joined the channel [07:21] saul_f: http://marcorogers.com/blog/01-22-2011/nodejs-community-could-use-some-tlc [07:21] DTrejo: saul_f: exactly [07:22] saul_f: yeah i thought this was spot on [07:22] saul_f: node.js IS awesome [07:22] DTrejo: saul_f: my pull request to help with this a bit: https://github.com/ry/node/pull/579 [07:22] DTrejo: feedback appreciated [07:22] micheil: fwiw, I was doing some of the docs stuff, but i haven't had time to work on it recently [07:23] pquerna: hmm? why does the format matter [07:23] micheil: DTrejo: hmm, I don't think that there really helps [07:23] saul_f: DTrejo: it's a good start, i'd swap the two main sections though [07:23] springify has joined the channel [07:23] DTrejo: micheil: where would be the best place to start? [07:24] micheil: probably the thing that needs the most work is making sure the documentation is complete [07:24] DTrejo: micheil: (I'm only talking about the docs / intro issue) [07:24] micheil: one moment [07:24] saul_f: https://github.com/senchalabs/connect#L30 [07:25] micheil: for example, is this acurate? https://github.com/ry/node/blob/master/doc/api/synopsis.markdown [07:25] saul_f: i was trying to find the possible substitutions allowed in express.logger [07:25] micheil: that's pretty much the first thing I think people should see after installing node [07:26] saul_f: that's good, micheil [07:26] DTrejo: micheil: but only because it is on nodejs.org, correct? [07:26] jpld has joined the channel [07:26] pquerna: er... correct? [07:26] micheil: personally I'd love to see the documentation take on the form of a book; such as the couchdb documentation. I've never really used couch, but I've read and understood their docs. [07:27] brainproxy: anyone looking at OrientDB? [07:27] brainproxy: i mean anyone here :) [07:27] micheil: in that synopsis, there should possibly be a bit of a what's next; right, I've read the synopsis, now what? [07:27] DTrejo: ACTION agrees [07:27] saul_f: yup [07:28] saul_f: Maintain an FAQ [07:28] DTrejo: also, you're right that that pull request doesn't really address things at all, it is too small scale [07:28] micheil: FAQs are awesome, serious, purely because no-one ever thinks to read them. [07:28] saul_f: i read them all the time [07:28] saul_f: it's like my third stop [07:29] saul_f: i skim the questions to see the level of maturity of the product [07:29] micheil: I'd rather they be the last stop; have actual good stuff in between, then there wouldn't be any frequently asked questions [07:29] saul_f: like are they going to be relevant to me, or is it obscure stuff that i may only need in a weird corner case? [07:29] zemanel: i'm trying out socket.io (for the 1st time) and everytime i refresh the browser, the client gets a new id [07:29] saul_f: that presupposes that one path through the material will work for everyone [07:29] micheil: zemanel: that's working as expected [07:30] saul_f: in some ways a FAQ is a toplevel dispatcher [07:30] zemanel: micheil: my question is, if youre building a game having a new id may mess session up? [07:30] micheil: saul_f: not at all; The documentation should guide the user through various things. For instance, a Getting started section. [07:30] saul_f: like, what about the FAQ: "why doesn't https work for me?" [07:30] DTrejo: micheil: do you have an idea of what story / path we want to take people on after the intro? [07:30] mscdex: FAQs can be good for determining ahead of time what possible situations you may find yourself in when using the product [07:30] zemanel: or a chat? [07:31] saul_f: yeah but getting started isn't actually the issue [07:31] mscdex: things to watch out for [07:31] saul_f: it's just past getting started that it's completely uncharted [07:31] micheil: things like why doesn't https work for me is something that yes, should go in a FAQ, I guess [07:31] saul_f: we need cartographers! [07:31] DTrejo: but where should it go? is the site under version control? [07:31] micheil: well, to be honest, we don't really have a getting started. [07:31] micheil: the site lives entirely in /doc/ [07:32] DTrejo: oh, see I didn't know that, I suppose I haven't been as diligent as I should have been [07:32] DTrejo: also, fun note [07:32] mscdex: another good FAQ would be about openssl support, what debian/centos/rhel packages are needed, etc [07:32] mscdex: stuff like that [07:32] DTrejo: marcorogoers aka polotek also didn't know site was in /doc/ [07:32] mscdex: common problems [07:32] zemanel: so how does my question relate to a user session ? [07:33] saul_f: yeah, how would anyone know that? [07:33] DTrejo: saul_f: if you're talking about the site being in /doc/, they'd just have to explore the repo [07:33] DTrejo: I think [07:33] saul_f: yes, i am, and i haven't done that yet [07:34] tg has joined the channel [07:34] saul_f: it did not occur to me that /doc would be the primary place for the documentation to live [07:34] micheil: I might just do up an outline of what I think we should have; but at the same time, it should possibly be run past ryah_ first [07:34] tk has joined the channel [07:34] saul_f: oh, sure [07:34] micheil: DTrejo: yeah, the documentation / site is kinda obscure at the moment [07:35] saul_f: do you know enough about the material to write the sections? [07:35] micheil: saul_f: have a look on the contributor list; I'm that miksago person :) [07:35] saul_f: okay =) [07:35] bingomanatee has joined the channel [07:35] micheil: https://github.com/ry/node/contributors [07:36] saul_f: then you are more than qualified [07:36] zemanel: perhaps the community should build an improved nodejs.org [07:36] DTrejo: micheil: how can we help you? [07:36] saul_f: yeah seriously [07:36] micheil: https://github.com/miksago/node/issues [07:37] micheil: have a look at those [07:37] DTrejo: I have some confusion about the difference in css formatting from the main site and the docs links on the left [07:37] saul_f: I don't know anything about those [07:37] saul_f: i'm brand new here [07:37] DTrejo: saul_f: It's a great way to learn! [07:37] saul_f: i could edit something you wrote.. [07:37] micheil: that's only temporary. when I did the new documentation, I just threw together a quick stylesheet, as I'd been told a new site was coming, but it didn't eventuate. [07:37] wkmanire has joined the channel [07:37] DTrejo: a friend of mine knew 0 about mootools, then wrote docs for it and read the source, and now he's a core contributor (I think) [07:38] micheil: this one should be fairly straight forward: https://github.com/miksago/node/issues#issue/14 [07:38] saul_f: that seems like a lot of busy work and not very important [07:38] mscdex: i still think it'd be neat to have a portable API definition in json or something [07:38] micheil: the documentation is written in markdown, with one added feature (@include for sections) [07:39] saul_f: i know how to `man 2 readlink` [07:39] mscdex: something that's easily parseable [07:39] mscdex: content-wise [07:39] micheil: saul_f: you might, but to be honest, when I first started programming stuff in node, and learning C/C++, I didn't know how to work `man` [07:40] saul_f: how many hours of work do you think it would be to go through and make links for all the readlink(2)? [07:40] muhqu has joined the channel [07:40] micheil: saul_f: probably not long, find & replace style stuff, it'd also be a good way to find any other issues [07:40] micheil: the biggest problem with documentation is that no-one wants to spend the time to work on it. [07:41] saul_f: ah hah, yup [07:41] saul_f: how come that is? [07:41] DTrejo: micheil: I agree that it would be very helpful to work on the docs that you have outlined there. And I'd be happy to spend some time on it, b/c then I'd learn how node actually works [07:41] saul_f: i experience the same thing at my job, i'm trying to figure it out there too [07:42] micheil: saul_f: the only way to improve documentation is to work on it. [07:42] DTrejo: micheil: shall we talk about how to improve the initial intro experience? or the post-intro experience? [07:42] DTrejo: *the post intro experience [07:42] micheil: DTrejo: one sec, let me do that outline for what I'm thinking [07:42] DTrejo: cool [07:42] yozgrahame has joined the channel [07:42] DTrejo: if you care to share, when you've got the outline together, http://typewith.me/improve-node-docs [07:43] micheil: sure thing. [07:43] polotek has joined the channel [07:44] DTrejo: polotek :) [07:44] polotek: yessir [07:44] DTrejo: we're talking about TLC, and micheil is outlining how to improve the post-intro experience [07:44] micheil: hey marco [07:45] polotek: sup micheil [07:45] micheil: DTrejo: currently just the intro-experience [07:45] saul_f: micheil: yes, but why does no one want to work on it? [07:46] saul_f: why do the main contributors not see the exponential leverage in maintain reasonable documentation? [07:46] micheil: saul_f: I have no idea, but If i did. I think I could make a lot of money out of it :P [07:46] DTrejo: saul_f: coder's like to code, and there are fewer of us who like to write words as well as code? [07:46] micheil: the main contributors often don't have time to work on documentation [07:46] saul_f: good documentation pays dividends [07:46] pquerna: the pattern of 'main contributors' not contributing to docutmation is common in most open source projects. coders like to code. some of them also have other full time jobs, and the docs just are always at the end of a never ending todo list :) [07:46] micheil: they are often incredibly busy trying to improve node, doing stuff that most people wouldn't think of doing [07:47] pquerna: ie, consider php, apache httpd, etc [07:47] pquerna: they all have separate documentation teams [07:47] saul_f: ah so maybe it needs financial sponsorship [07:47] pquerna: groups who just focus on documentation [07:47] ph^ has joined the channel [07:47] saul_f: oh! so how can we form a documentation team? [07:47] micheil: for example, before november, I was the only person on the list of contributors within the top 10 slots that wasn't full-time employed. [07:47] pquerna: http://httpd.apache.org/docs-project/ [07:47] pquerna: for example [07:48] saul_f: micheil: after november did you get a job, or did someone else lose theirs? [07:48] micheil: no, I got a job [07:48] polotek: I'm definitely employed [07:48] polotek: and my girlfriend also needs TLC ;) [07:48] micheil: so most of us are pretty busy; things come up and we can't always contribute [07:49] micheil: so, that's why when things are contributed, the two most common things ryan pings people back about are: tests & documentation [07:49] pquerna: yes; But he hasn't blocked commits for docs really.. mostly just tests. [07:49] polotek: The other issue is that code is something that takes longer stretches of time [07:49] polotek: docs are not [07:50] polotek: they can worked on little by little [07:50] polotek: and what's more [07:50] polotek: once you start getting docs up [07:50] polotek: even if they are incomplete or erroneous in places [07:50] polotek: people will point that out and help fix [07:50] ph^ has joined the channel [07:50] micheil: polotek: hopefully. [07:50] saul_f: erroneous is bad though, you should give points for docfixing [07:50] wkmanire: polotek: bad docs are worse than no docs. [07:50] wkmanire: Even if they only claim 1 victim [07:51] polotek: wkmanire: no they aren't [07:51] polotek: they are just a different kind of bad [07:51] polotek: and like I said [07:51] polotek: they can be fixed [07:51] DTrejo: should we set a mini agenda for the next 15 minutes as to what we want to talk about? [07:51] polotek: no docs can't [07:51] saul_f: DTrejo: whyfor? [07:51] SamuraiJack has joined the channel [07:51] saul_f: do you want to turn this into an official meeting? [07:51] boaz has joined the channel [07:51] DTrejo: it's easy to get distracted? [07:51] saul_f: propose something [07:51] saul_f: change the /topic [07:51] DTrejo: mmk nvm [07:52] DTrejo: m is leading [07:52] wkmanire: Is there a lot of undocumented stuff in the new version of node? [07:53] polotek: wkmanire: 0.3 has several key changes from 0.2 [07:53] pquerna: http://nodejs.org/docs/v0.3.6/api/ [07:53] polotek: especially recent point releases [07:53] pquerna: for example, the https client & server [07:53] pquerna: is not ducomented there yet [07:53] pquerna: oops, https server is [07:53] pquerna: see, its already being fixed, kinda :P [07:54] wkmanire: I'm pretty new to node. I've basically started with the unstable version. [07:54] wkmanire: Out of curiosity, why aren't the docs in a wiki? [07:54] polotek: well I also think the api docs are the most full featured part of node [07:54] polotek: other parts are in much more need of attention [07:54] saul_f: wkmanire: seems like most of it is undocumented :) [07:54] pquerna: right, lots of getting started / theory of operation / best practices [07:54] pquerna: could be written [07:54] polotek: a full tutorial is first and foremost I think [07:54] wkmanire: So far, I've found the documentation to be satisfactory. [07:55] micheil: my ideas so far: http://typewith.me/improve-node-docs [07:55] davidc_ has joined the channel [07:55] Gruni has joined the channel [07:55] micheil: wkmanire: in some ways, they should be, in others, they shouldn't. [07:55] polotek: micheil: what do you mean shouldn't? [07:56] micheil: in the sense that wiki's are great, but if the wiki is in the repository, then a patch can be replied with "please add documentation" [07:57] TomY has joined the channel [07:57] wkmanire: polotek: What kind of tutorial are you thinking would be appropriate? [07:58] fangel has joined the channel [07:58] DTrejo: micheil: aren't the github wiki's part of the repo? or something? I know they can be accessed via git now [07:58] polotek: the github wiki is in a repository [07:58] killfill has joined the channel [07:58] polotek: separate from src repository though [07:58] micheil: DTrejo: not really, they are more a fork / branch [07:58] DTrejo: ah [07:58] DTrejo: which makes it more difficult for the case you note above [07:59] polotek: wkmanire: gimme a sec [07:59] polotek: as for wiki docs [07:59] wkmanire: polotek: sure [07:59] polotek: I've taken a dual approach with libxmljs [07:59] polotek: I've got docs in the github wiki [07:59] polotek: but I also pull that repo into the main src repo [07:59] polotek: I'm actually using "fake git submodules" [07:59] polotek: a la felixge [08:00] polotek: So, the tutorial I'm envisioning starts at the beginning [08:00] polotek: installation, this is where a lot of people get frustrated [08:00] polotek: we won't be able to do much about that because node is still very new [08:01] wkmanire: polotek: Really? nodejs has practically no dependancies. [08:01] tim_smart: Fake submodules <3 [08:01] wkmanire: polotek: I was able to install from source in less than 5 minutes. [08:01] polotek: wkmanire: not true, they are easy to get [08:01] pquerna: er [08:01] pquerna: it just bundles them all :) [08:01] polotek: but it does have deps [08:01] pquerna: it has a ton od deps :) [08:01] DTrejo: polotek: why can't we do much about it? do you mean b/c of wierd config problems? [08:01] saul_f: yeah installation was pretty easy [08:01] wkmanire: polotek: npm is nice, but it whines about running uner sudo. [08:01] saul_f: maybe there should be a "submit your documentation request" form [08:02] wkmanire: the thing is, it wants to work on folders that require root access or special permissions being granted... [08:02] polotek: DTrejo: no I just mean that with node still changing so often things will continue to be unstable [08:02] wkmanire: under* [08:02] DTrejo: ah [08:02] polotek: so the installation tutorial will run through common scenarios [08:02] polotek: but point to more extensive troubleshooting [08:02] DTrejo: wkmanire: did you use the semi-official node install gist that no one knows about? [08:02] polotek: once you have node and npm installed you can get to the fun stuff [08:02] GasbaKid has joined the channel [08:03] pquerna: streams aren't a core concept dammit :P [08:03] DTrejo: wkmanire: this is my go to install guide: joyeur.com/2010/12/10/installing-node-and-npm/ [08:03] wkmanire: DTrejo: hmm? [08:03] polotek: pquerna: ? [08:03] DTrejo: wkmanire: contains a ton of good info, such as a link to the gist that shows you how to use npm without sudo: joyeur.com/2010/12/10/installing-node-and-npm/ [08:03] wkmanire: DTrejo: I just downloade source tar balls and README'd my way to success. [08:03] wkmanire: downloaded* [08:03] saul_f: something saying that the READMEs are awesome would be good [08:04] polotek: if you're on linux the install process is pretty smooth [08:04] pquerna: i dunno, i kinda think Streams as they are today, aren't usable enough. [08:04] pquerna: too inconsistent between types [08:04] polotek: you've gotta get openssl if you want ssl/tls [08:04] polotek: that's non obvious [08:04] pquerna: the pause/resumeness is still messy [08:04] DTrejo: wkmanire: I suppose I'm saying that for people who don't have that much CLI experience [08:04] wkmanire: DTrejo: looking... [08:04] pquerna: anyways, i'm sure we will get em right someday. [08:04] polotek: pquerna: I'd be interested in hearing more about that [08:04] polotek: I feel the same, but can't think of how they need to be improved [08:05] micheil: pquerna: but they still should be documented, so that when you get told, "Oh, http.OutgoingMessage is a stream or something, people know what to expect [08:05] polotek: there isn't a enough control [08:05] polotek: either they work of they don't [08:05] wkmanire: DTrejo: I understand that, but all programmers *need* to be good on the CLI. thats my opinion. [08:05] polotek: micheil: agreed [08:05] polotek: we need lots more info out there about streams [08:05] polotek: wkmanire: incorrect [08:05] meso_ has joined the channel [08:06] micheil: as in, they need to be able to expect that it'll have certain events, that it'll be an Events.EventEmitter [08:06] micheil: etc. [08:06] DTrejo: wkmanire: building node builds a lot of confidence, what I'm saying is that guides help you get there if you don't have that already, that's all [08:06] wkmanire: DTrejo: I see. [08:06] polotek: you start with the async nature of node [08:07] polotek: then you talk about events and lead to EventEmitters [08:07] DTrejo: for example I'd say you were ahead of the game wkmanire , before node I have very very little CLI expreience [08:07] polotek: then you bring eventemitters together into the stream paradigm [08:07] polotek: oh and the event loop needs to fit in there somewhere [08:07] polotek: understanding the event loop is critical [08:07] pquerna: first :) [08:07] DTrejo: (funny that I still don't really get the stream thing, though I do understand that'd you'd get data coming through in a stream and then events are thrown as special cases are hit, or certain data comes thorugh) [08:07] polotek: pquerna: hard to put it first [08:07] pquerna: actually a decent dciussion of concurrency models [08:08] polotek: most people understand async from the browser [08:08] pquerna: maybe [08:08] polotek: talk about that first [08:08] pquerna: most javascript people undrstand it from the browser... [08:08] polotek: then explain how the node event loop works in relation to it [08:08] pquerna: its lots of different audiences [08:08] wkmanire: DTrejo: Ahead of the game? ... probably not. I'm just comfortable on linux. [08:08] polotek: no they understand how callbacks work in the browser [08:08] polotek: lots of people still don't understand the concept of the event loop [08:08] mAritz has joined the channel [08:09] polotek: and even if they know what event loops are [08:09] polotek: we need to explain the semantics of the node event loop [08:09] polotek: I know there was an aha moment when I got a good mental model of control flow in node [08:10] polotek: and even though i'm not as smart or experienced as some others [08:10] polotek: I'm able to get around in node really well [08:10] philipharrison has joined the channel [08:10] polotek: only because of that solid mental model [08:11] polotek: I have a diagram in my head, I'm just not skilled enough to create a visualization [08:11] pquerna: i guess i disagree with micheil [08:11] pquerna: the documenation defines the culture of the software. [08:12] pquerna: so, define it how you want it to be [08:12] bingomanatee: polotek: what are you trying to visualize? [08:12] micheil: pquerna: I think there is some standard, but it's largely influenced by npm; the idea of having a lib/ and doc/ and a package.json [08:12] pquerna: yes [08:12] wkmanire: polotek: How about some pre-requisites? A lot of PHP and especially ASP.Net guys get shielded from HTTP protocol. [08:12] pquerna: i think the docs should encourage using that layout [08:12] pquerna: it brings sanity to the hundreds of node projects [08:12] micheil: pquerna: right; but it should still be near the modules system. [08:12] wkmanire: I love how node.js makes it easy to get right at the request and response. No crap in the way. But, I have some co-workers who would get confused by that. [08:12] DTrejo: ACTION agrees [08:13] DTrejo: ^ about the dir structure [08:13] pquerna: maybe, where NPM is in the list is too early [08:13] micheil: it's not really a core concept, it's more "how can I share my code?" [08:13] bingomanatee: wkmanire: let them focus on using jQuery to flip tabs and drop menus [08:13] wkmanire: bingomanatee: he he he [08:13] pquerna: to me core concept section is, "okay I buy node.js is cool, what are the 10 things I need to know to post my first project on github" [08:13] pquerna: and I'd include fileysstem layouts in that [08:13] micheil: pquerna: with that listing of npm there, it's really to say: hey, you don't actually need to write everything from the ground up; there is prior-art. [08:13] bingomanatee: ACTION dangles an icon design project like a set of shiny keys [08:13] polotek: pquerna: maybe we need a quick start and a full tutorial [08:14] polotek: man, hard to follow this document and the conversation here :P [08:14] micheil: how about a section: Using other peoples stuff / Sharing my stuff? [08:14] bingomanatee: polotek: I'm working on that [08:15] mikeal has joined the channel [08:15] pquerna: the thing to me is, its not just about NPM -- its about code style, its about setting the cultural imprint in a direction that is sensible [08:15] micheil: rather then splintering off, we need to work as one, with clear goals. [08:16] micheil: packages aren't really core to node; they are an addon though [08:17] micheil: evenin' mikeal [08:17] mikeal: heya [08:17] pquerna: right, but when you are building on node, there should be a suggested order to things [08:17] mikeal: you ever do the mix down on those podcasts? [08:17] pquerna: even if you aren't worried about packages [08:17] DTrejo: mikeal: http://typewith.me/improve-node-docs [08:17] micheil: pquerna: exactly, which is why I'm going with that structure [08:17] pquerna: maybe they are just 'best practices' [08:17] micheil: mikeal: haven't had a chance yet. [08:17] pquerna: things like (err, data..) [08:17] pquerna: fall into the same area to me as file system layout [08:18] polotek: I'm not sure what the debate is here [08:18] pquerna: (and even promoting a JS style guide like Googles -- or having a list of 2-3, telling peple to pick one and stick to it) [08:18] polotek: pquerna: I'm not concerned with programming style [08:18] mikeal: by far the hardest thing for people to figure out is when to use event emitters vs callbacks in their own code [08:18] polotek: but module/package structure is important [08:18] mikeal: and figuring out why they can't do callback IO inside a listener on an event emitter [08:18] micheil: pquerna: well, I think that really comes under best practices, not core ideas [08:18] polotek: people should be able to reason about where to find things [08:19] mikeal: i see it over and over again [08:19] philipharrison has joined the channel [08:19] micheil: mikeal: example? [08:19] javajunky has joined the channel [08:19] DTrejo: mikeal: I still don't know when to use an event emitter [08:19] wkmanire: mikeal: I'm one of those people. [08:19] polotek: mikeal: yeah we talked about core concepts [08:19] DTrejo: I have a foggy idea I suppose, but.. [08:19] polotek: the idea is core concepts lead to best practices [08:19] javajunky: poloek. [08:20] polotek: there's a gray area though [08:20] mikeal: i hate style guides [08:20] javajunky: ugggh mornings, polotek, you rang [08:20] polotek: javajunky: hey man [08:20] polotek: what tz are you in? [08:20] guybrush: ACTION uses eventemitter if the code looks to ugly with callbacks :) [08:20] javajunky: GMT [08:20] javajunky: literally [08:20] polotek: ah [08:20] polotek: cool [08:21] polotek: I was going to try your gist again [08:21] micheil: personally, I think everyone has their own favourite way of coding, and node can't necessarily change that. [08:21] micheil: I mean, a lot of people come from browser-side javascript [08:21] polotek: micheil: +1 [08:21] polotek: I'm not advocating dictating to people [08:21] pquerna: it doens't matter if you hate style guides, just promote 2-3 fo them, say 'we suggest you think about it a little bit, but pick the one you like' [08:21] polotek: I want them to get the concepts [08:21] polotek: so even if they're screwing things up [08:22] mikeal: formailzing a style guide for the community is a thankless task, but having one that illustrates the guide for getting code in to core would be quite useful [08:22] polotek: they know why exactly :) [08:22] guybrush: and please dont say anything about semicolons and stuff like that in the docs [08:22] mikeal: isaacs has one for npm [08:22] guybrush: do not even mention stuff like that [08:22] micheil: pquerna: maybe just a few recommendations, how to submit a bug report, how to share your code, etc. [08:22] mikeal: pquerna: i think the community is already doing that, npm has a well defined style guide, it's just core that is missing one [08:22] DTrejo: mikeal: probably the most important one is the core one, and we could just put that one into the docs, less work for everyone [08:22] micheil: yes, a "contributing to node" guide would be good. [08:23] polotek: mikeal: I've never seen the npm styleguide [08:23] polotek: I don't think people are looking for one [08:23] polotek: at least not a lot of people [08:23] DTrejo: polotek: I looked for one, but I'm not normal maybe [08:23] mikeal: if you want to contribute to npm you have to follow it's style guide [08:23] polotek: yeah, that's what makes this hard [08:23] polotek: difficult to guage the most important needs [08:23] micheil: people aren't looking for a styleguide. People are looking for answers, I've got this problem: "I want to be able to read a file out to a network socket" [08:23] mikeal: it's more clearly defined than core :) [08:23] polotek: styleguide is not one [08:23] polotek: it's not keeping people from coding [08:23] pquerna: its just like python has PEP-8 [08:24] polotek: pquerna: I wrote a lot of python without ever reading PEP-8 [08:24] micheil: pquerna: did PEP-8 ever stop someone from just bashing shite into a text editor? [08:24] mikeal: there are standard lib modules that violate PEP-8 :) [08:24] pquerna: no, and its fine [08:24] mikeal: look [08:24] mikeal: this is going nowhere [08:24] mikeal: we need a core style guide because ryan won't take patches that don't follow it [08:24] polotek: mikeal did you look at the document [08:25] saul_f: yeah if we had all spent the past 30 minutes writing a paragraph or two of documentation.. [08:25] mikeal: someone needs to write that up, because it's the guide for core it'll probably gain some popularity [08:25] teemow has joined the channel [08:25] polotek: okay, step back [08:25] micheil: the thing is, you can try to have a styleguide, but in the end, everyone has their own style. This is one of those conversations were everyone is highly opinionated [08:25] polotek: we've got a few different things happening [08:25] mikeal: but npm style also has traction so I'd expect other projects to also be influential, and we can just let that shake out in the community [08:25] polotek: I think what we were focusing on is outlining core documentation needs [08:26] polotek: it doesn't matter how much we need a styleguide [08:26] javajunky: I've always dreamed of a world where the VCS maintains an abstract syntax tree as the native format, and checking-out formats to the local style of the checkout-ee, oh happy days ;) [08:26] polotek: we need one at some point [08:26] polotek: put it on the list [08:26] polotek: and let's move on [08:26] micheil: I'm going to reduce that document down a bit. [08:26] DTrejo: micheil: it's getting a bit unwieldy [08:26] mikeal: in my head i'm trying to imagine all the stuff that would be in the contributing to core document [08:27] polotek: javajunky: you should get started on that :) [08:27] mikeal: "talk to ryah on IRC, see if that is a good idea" [08:27] polotek: mikeal: I would say post to node-dev and ask [08:27] micheil: mikeal: how about: raise it on the mailing list; if ryan wishes, he can reply [08:27] javajunky: polotek: I suspect that if it was do-able/feasable somebody would've :) [08:27] mikeal: "at the last minute it might be decided that this doesn't really need to happen right now and your patch will languish" [08:27] polotek: but I know some people want that to stay simpler [08:28] alexhq has joined the channel [08:28] polotek: javajunky: definitely doable and feasible, all the tools are there. [08:28] polotek: it's just a long thankless project [08:28] saul_f: how can we make it not thankless? [08:28] mikeal: "Path to becoming a committer: Become Ryan Dahl" [08:28] javajunky: polotek: aren't most ? ;) [08:28] polotek: saul_f: we're talking about hte code formatting thing, not node docs [08:28] polotek: sorry for muddling the convo [08:28] saul_f: ah [08:28] javajunky: polotek: instead we rely on lint + hooks etc :) [08:28] saul_f: no worries [08:29] pquerna: http://us2.php.net/manual/en/ [08:29] mikeal: it makes me happy that micheil picked upt his doc stuff, since that's the only way all the other doc improvments actually got done :) [08:29] pquerna: if not the order, the contents seem similiar [08:29] alexhq: Is it possible to http.createClient and bind it to specific address? [08:30] jetienne has joined the channel [08:30] javajunky: ACTION decides not to wade in with his opinions on this one  [08:30] saul_f: alexhq: check the FAQ [08:31] polotek: alexhq: createClient takes a port and a host [08:31] wkmanire: Is it not required to include documentation with contributions? [08:31] alexhq: polotek: I need to send requests from specific address, I know how to create request to google.com for example. [08:32] polotek: alexhq: if you are working off master or v0.3.6 there is some quirkiness there [08:32] polotek: alexhq: what problems are you having? [08:33] polotek: javajunky: your gist is taking command line args [08:33] polotek: I'm assuming you're taking the request tokens and passing them back in for the access call [08:33] alexhq: polotek: I need to modify "20 lines of code http proxy" and teach it to send requests by itself from address X.X.X.X [08:33] mscdex: i don't believe there is currently a way to specify a networking interface to use [08:33] javajunky: yeah, its to demonstrate it works, I only had 10 minutes spare so didn't want to faff with taking a break for human input [08:33] javajunky: polotek: yes, that is correct. [08:33] javajunky: polotek: *AND* the pin [08:34] polotek: alexhq: not sure what you need. have you tried something? can you send some code? [08:35] polotek: javajunky: the pin is specific to the request tokens right? so it changes each time you get new ones? [08:35] mscdex: polotek: i think he's wanting to send from a different IP/network interface [08:35] javajunky: polotek: yah [08:35] javajunky: polotek: but I think it is pretty long lived [08:35] javajunky: polotek: so if you have one, skip the request stage [08:36] javajunky: polotek: …unless it fails to auth :) [08:36] polotek: javajunky: yeah I think that's my problem, my gist is requesting new tokens but trying to use the first PIN I grabbed [08:36] polotek: they won't match [08:36] [AD]Turbo has joined the channel [08:36] javajunky: polotek: yeah that'd do it [08:36] polotek: alexhq: I don't know how to make http.Client bind to a different interface. [08:37] alexhq: mscdex exactly [08:37] javajunky: each request invalidates the previous ones [08:37] mscdex: yay, finally a new ncurses release is coming.. 5.8! [08:37] mscdex: :-D [08:37] javajunky: polotek: FYI now https has landed in node 0.3ish I'm going to be looking towards moving master towards running on 0.3 . just so you know :) [08:38] polotek: javajunky: cool, I'm running on npm release version anyway [08:38] polotek: and I'm updating evented-twitter too [08:38] polotek: I'll be following your updates [08:38] [AD]Turbo: hi there [08:39] mscdex: hola [08:40] ivanfi has joined the channel [08:40] ncursestest86 has joined the channel [08:40] ncursestest86: :-D [08:41] jetienne has joined the channel [08:41] tc77 has joined the channel [08:42] q_no has joined the channel [08:44] alexhq has left the channel [08:44] wkmanire: whew... time to sleep. Good night. [08:44] wkmanire has left the channel [08:45] stephank has joined the channel [08:45] aklt has joined the channel [08:46] Evet has joined the channel [08:47] Druid_ has joined the channel [08:47] tim_smart: mscdex: I remember a few months ago having problems with node-ncurses on Ubuntu [08:47] gattuso has joined the channel [08:47] tim_smart: I might re-pull and try again [08:47] bingomanatee: no sleep! keep noding! [08:48] tim_smart: mscdex: "Error opening terminal: xterm" [08:48] tim_smart: :/ [08:53] pquerna has joined the channel [08:56] philipharrison has joined the channel [08:58] matjas has joined the channel [08:58] polotek: javajunky: success! [08:58] polotek: kickass [08:58] polotek: I wish I would've been able to figure this out yesterday [08:59] polotek: now it's 4am and I have to work in 4 hours :( [08:59] saul_f: =( [08:59] awenkhh has joined the channel [09:00] javajunky: polotek: congrats :) and doh! [09:02] ROBOd has joined the channel [09:02] polotek: javajunky: thanks for your help [09:02] polotek: evented-twitter is well on the way to not sucking [09:02] javajunky: polotek: np. [09:02] farhadi has joined the channel [09:03] chapel: javajunky: what is your module? [09:05] javajunky: chapel: Ive a few [09:05] javajunky: github.com/ciaranj [09:05] chapel: oh [09:05] chapel: oauth [09:05] chapel: :) [09:06] chapel: the name didn't hit me [09:06] javajunky: chapel: yeah thats the one we were talking about :) [09:06] micheil: javajunky: that is always so so confusing.. [09:06] micheil: github.com/votizen also has a twitter api client. [09:06] chapel: if you were ciaranj I would have known :) [09:06] adambeynon has joined the channel [09:06] DTrejo: javajunky: you should rename yourself ;) [09:06] javajunky: ;) the javajunky nic has been with me a looooong time :) [09:07] chapel: heh [09:08] chapel: I may remember [09:08] chapel: but I am glad https is here [09:08] chapel: cause I have needed it for a few apps [09:08] hij1nx has joined the channel [09:09] meso_ has joined the channel [09:09] farhadi: when I run all tests using "make test-all" I get an error on "simple/test-http-agent" test [09:09] torvalamo has joined the channel [09:10] farhadi: does any body else has this issue? or its something with my configuration? [09:10] polotek: farhadi: lots of changes on master recently [09:10] polotek: I'm sure some tests are breaking [09:10] farhadi: so that's normal [09:10] Danny_ has joined the channel [09:10] micheil: farhadi: yeah, try on 0.2 branch [09:10] polotek: if you're trying to get something done, try dropping back to 0.3.5 release [09:11] Danny_: Anyone successfully built v0.3.6 on windows7 in cygwin? (64 bit) [09:12] farhadi: I wanted to use new http agent approach in production but seems its not ready yet. [09:13] polotek: Danny_: someone spent a loooong time trying to do that yesterday [09:13] polotek: have you looked at the troubleshooting page? [09:14] polotek: https://github.com/ry/node/wiki/Building-node.js-on-Cygwin-(Windows) [09:14] Danny_: yup... gone through it all... python was saying env didn't have key ['os'] somewhere in SConstruct [09:14] polotek: farhadi: no, no definitely wouldn't use 0.3.6 in production [09:14] polotek: the 0.3.x branch is considered "unstable" [09:14] polotek: it alternates [09:15] polotek: when 0.4.0 drops that will be considered stable [09:15] Danny_: I set it manually to 'win32' which got past that..... but had a ton of other errors [09:15] polotek: Danny_: yeah that's in there too [09:15] polotek: did the fix not work? [09:15] polotek: I've never built on cygwin so don't have first hand experience [09:16] Danny_: nope. my $SHELL was already correct [09:16] polotek: but the guy the person from yesterday was able to get past that problem [09:16] farhadi: polotek: yeah, but there are some really cool features in 0.3.x that I can't wait for them [09:16] Danny_: trying 0.3.5 [09:17] margle has joined the channel [09:17] Danny_: 0.3.5 seems to be compiling [09:18] polotek: Danny_: if it is an issue with 0.3.6 please submit a ticket or drop by the mailing list and report your findings [09:18] polotek: I'm out of here folks [09:18] polotek: later [09:18] polotek has left the channel [09:21] x0xMaximus has joined the channel [09:21] q_no has joined the channel [09:22] margle has joined the channel [09:24] abraham has joined the channel [09:29] sriley has joined the channel [09:30] guid has joined the channel [09:30] virtuo has joined the channel [09:39] xla has joined the channel [09:41] torvalamo: man, i've gone two months without noding :p what's changed? [09:41] skm has joined the channel [09:42] clarkfischer: man [09:42] clarkfischer: why does node-yuicompressor have to suck so bad [09:42] skm has joined the channel [09:43] nook has joined the channel [09:45] bingomanatee: in mongodb native, what are date values returned as? [09:46] javajunky has left the channel [09:48] Evet: Evet_: if you think the http class is ineffecient and you could do better, then fork node, implement changes and send it to ryan :) [09:48] Evet: Aikar: im thinking something else :) [09:53] glenngillen has joined the channel [09:54] glenngillen has left the channel [09:54] rjack: can someone explain why sha1+base64 in node differs from sha1+base64 in shell? http://pastebin.com/fHXXLrMh I'd expect lines 4 and 6 to have the same value. Am I wrong? [09:55] w0rse has joined the channel [09:55] x0xMaximus has joined the channel [09:56] farhadi: rjack: node's sha1 is binary but shell sha1 is hex I guess [09:57] pquerna: rjack: consdier the output of openssl sha1 [09:57] pquerna: rjack: its already in hex form coming from openssl [09:57] pquerna: so... change node to 'hex' [09:57] torvalamo: clarkfischer, is that compressing client side code through node, or is it compressing node code? [09:57] pquerna: and it should match the output of the opnessl sha1 command [09:58] bzinger has joined the channel [09:58] pquerna: rjack: or try openssl sha1 -binary [09:59] rjack: ok, so I need to do var = hex = sha1.update("foo").digest("hex"); and then encode this var to base64 [09:59] rjack: er, var hex = .... [10:00] rjack: because I need the base64 encoding of the hex value of sha1 [10:00] rjack: thansk [10:02] pquerna: right, so.. you could pass it via a buffer I guess.. if you didn't ahve other js code to do it... (new Buffer(hex)).toString('base64') [10:04] markwubben has joined the channel [10:06] d0k has joined the channel [10:08] karboh has joined the channel [10:09] rjack: pquerna: works perfectly, thanks [10:12] mytrile has joined the channel [10:12] janne has joined the channel [10:18] romeo_ordos has joined the channel [10:18] romeo_ordos has left the channel [10:20] lumino has joined the channel [10:21] codetonowhere1 has joined the channel [10:26] bpedro has joined the channel [10:32] sriley has joined the channel [10:34] awenkhh has joined the channel [10:36] hwinkel has joined the channel [10:36] bingomanatee: I got noogle working for basic single line searches -- [10:37] bingomanatee: I should have it up in a few days online. [10:37] Throlkim has joined the channel [10:39] Roelven has joined the channel [10:40] herbySk has joined the channel [10:41] jimt_ has joined the channel [10:42] andrzejsliwa has joined the channel [10:43] javajunky has joined the channel [10:46] daglees has joined the channel [10:46] daglees has joined the channel [10:47] altamic has joined the channel [10:50] MikhX has joined the channel [10:54] common has joined the channel [10:55] liar has joined the channel [10:56] hellp has joined the channel [10:57] shaunau has joined the channel [10:57] farhadi has left the channel [10:57] bpedro has joined the channel [11:02] ttpva has joined the channel [11:06] bpedro has joined the channel [11:07] Coal has joined the channel [11:09] Jonasbn_ has joined the channel [11:11] tanepiper: cool bingomanatee [11:13] mike5w3c has joined the channel [11:15] javajunky has left the channel [11:16] mraleph has joined the channel [11:18] clarkfischer has joined the channel [11:20] kgf_ has joined the channel [11:21] cce has joined the channel [11:21] cce has joined the channel [11:22] [AD]Turbo has joined the channel [11:25] mikedeboer has joined the channel [11:30] iskren has joined the channel [11:30] iskren: Hello [11:32] clarkfischer: v8> typeof true [11:32] v8bot: clarkfischer: "boolean" [11:32] iskren: Is there any standard way to use js code in the backend (node.js) and in the frontend [11:34] omarkj has left the channel [11:34] iskren: Because node uses commonJS for the format of the files (exports.sth and require), but you normally won't use these in the front end [11:34] HerrTopf has joined the channel [11:35] jankoprowski has joined the channel [11:35] chapel: iskren: you should check out dnode [11:35] chapel: http://github.com/substack/dnode [11:37] mnbvasd: ohh dnode is quite nice. [11:38] iskren: hm, so this is like putting the shared code in the server, and then RPC-ing it tru dnode? [11:38] micheil: iskren: yeah [11:38] micheil: as for using node.js files in the browser, it's a bit awkward really [11:39] micheil: although, you could use a form of ajax request and a closure to execute [11:41] Athox has joined the channel [11:41] micheil: var exports = {}; var foo = new Function(contents); foo.apply(exports, [exports, require, module, __filename, __dirname]); [11:42] micheil: I think would work. [11:42] iskren: well… I can write a build script that will wrap the real code in something different depending on weather it is for the front end or for the back end. [11:42] rjack: I need a querystring parser/stringifier that works with deep nested objects (like the one in 2.x). Is there an equivalent external module for node 3.x? [11:42] iskren: rjack: is json (module) not working for you? [11:42] fermion has joined the channel [11:42] micheil: rjack: I think it's in npm now; the one in 0.2.x was really messy and buggy, try checking out the yui3 code base, I think it has one [11:43] rjack: micheil: I'll look, thanks [11:43] mytrile has joined the channel [11:43] iskren: micheil: I can't quite understand that, but I guess I should read more about CommonJS before trying that :) [11:44] micheil: iskren: basically all the modules, when loaded, they get loaded from a file, then that contents gets wrapped with a function call, "var wrapper = [11:44] micheil: '(function (exports, require, module, __filename, __dirname) { ' + [11:44] micheil: content + [11:44] micheil: '\n});';" [11:44] micheil: then that gets evaluated [11:45] iskren: oook [11:46] iskren: but in your code you were exporting the expors, require .. etc, why? [11:46] bingomanatee: tanepiper: yeah with word frequency analysis as well. [11:46] micheil: because, that's exactly what node does. [11:47] micheil: I'm not actually exporting anything. [11:48] unomi has joined the channel [11:48] unomi has joined the channel [11:49] tc77 has joined the channel [11:49] pgte has joined the channel [11:49] eikke has joined the channel [11:49] zorzar_ has joined the channel [11:50] iskren: Oh, I'm starting to understand- with this code the global object will be exports, so all global object will be exported, and the other 5 ones will be available. So if I wrap all my front end code in that everything will live in exports.* but the code won't feel the difference. [11:51] cwo has joined the channel [11:51] iskren: but I should use this everywhere (because window is the default) [11:54] iskren: micheil: thanks very much for the info! [11:55] micheil: iskren: in order to understand how the module system works, you really need to read src/node.js [11:55] dsirijus has joined the channel [11:55] torgeir has joined the channel [11:56] micheil: I think someone did write an automatic wrapper though; try searching on the mailing list [11:57] iskren: I'll do that :) [12:00] texodus has joined the channel [12:09] eirikb has joined the channel [12:10] eirikb: Hey. If I start a setTimeout which recursively calls itself, that will not block my server in any way? When I trye it I can't see any issues [12:11] eirikb: Like this: (function test(){setTimeout(test, 1000)})() [12:13] eirikb: I thought node was single threaded and this would cause havoc, although it does not? [12:15] cainus: don't you really want setInterval() ? [12:15] sriley: well it will just call its self every second(ish) other stuff will happen during that other time [12:16] micheil: why don't you use setInterval? [12:16] eirikb: Probably, I have no idea how to do this. I just found setTimeout (over setInterval) in the docs. [12:16] micheil: timers get pushed on-to a linked list thing, which stores them, they get triggered by an ev_timer loop [12:16] eirikb: Yeah, so setInterval does the same, just forever? [12:17] cainus: or until you clearInterval() [12:17] micheil: eirikb: rather than trying to break node, have a problem you need to solve? [12:17] eirikb: micheil: I'm not trying to break it? I want a timer to run forever [12:17] cainus: setTimeOut() calling itself will still work though [12:17] micheil: setInterval isn't the same, but at any rate, these don't really block the loop, as long as what you do in the callback to them isn't synchronous [12:17] cainus: it works because it doesn't block [12:18] eirikb: micheil: Why is setInterval not the same? (Except it's repeated) [12:18] micheil: cainus: yes, setTimeout() calling itself does similar, only it's a lot less efficient, as it get's unenrolled from the timer queue and then re-enroled [12:18] eirikb: cainus: Yeah, the non-blocking got me curious [12:18] cainus: yeah that's why I suggested setInterval() :) [12:19] micheil: eirikb: what do you want to do, that prompted this question? [12:19] micheil: or is it just something philosophical? [12:19] eirikb: micheil: What I just said, I want a timer to run forever [12:19] micheil: or theoretical? [12:19] micheil: okay, setInterval is what you want then [12:19] eirikb: Yes [12:20] cainus: just try not to put so much work into it that it piles up [12:20] eirikb: I got that part when cainus mentioned it the first time about 5 minutes ago :D [12:20] eirikb: cainus: In that case I could actually use setTimeout [12:21] eirikb: cainus: But it will have a timeout on about 3-5s, so no problem [12:21] allengeorge has joined the channel [12:21] cainus: well what's the point in setting a timeout to 30 ms when the wok takes 100 ms ? [12:21] cainus: so set an interval to 3-5s...same thing [12:22] eirikb: It's really not a issue, since there is close to no workload [12:22] cainus: sounds like setInterval() is still what you want [12:23] pdelgallego has joined the channel [12:23] pdelgallego_ has joined the channel [12:24] eirikb: Don't think I have argued about that ever since you first mentioned it :D [12:24] astoon has joined the channel [12:24] cainus: cainus: In that case I could actually use setTimeout [12:24] eirikb: Yes, because it would have to be dynamic [12:24] eirikb: But it will never be a issue, I only replied a solution to your case :P [12:24] eirikb: Why are we even talking about this [12:25] cainus: :) [12:25] clarkfischer: For an NPM package, if it has built-in test cases using vows, should I include vows as a dependency? [12:25] eirikb: Thanks for the help cainus and micheil :) [12:25] clarkfischer: Not all users will be running the tests, and not all users will want vows to be installed... [12:25] cainus: clarkfischer: seems like a lot of packages don't [12:25] eirikb has left the channel [12:26] cainus: which seems okay to me [12:26] clarkfischer: Cool [12:26] micheil: clarkfischer: to be honest, I'm not sure on that, I believe there is a developDependencies field [12:26] micheil: but I don't know for sure [12:26] micheil: there's also a npm test module [12:27] micheil: rather, an `npm test module` [12:27] okuryu has joined the channel [12:29] benvds has joined the channel [12:31] mike5w3c has joined the channel [12:32] CrazyGoogle_ has joined the channel [12:32] bradleymeck has joined the channel [12:36] skohorn has joined the channel [12:38] adambeynon has joined the channel [12:40] Fandekasp has joined the channel [12:40] vyvea has joined the channel [12:41] luke` has joined the channel [12:42] clarkfischer: hrm... [12:42] clarkfischer: I'm going to go ahead and leave it out of the dependencies [12:44] lukegalea has joined the channel [12:48] awenkhh has joined the channel [12:49] ilpoldo has joined the channel [12:51] zzak has joined the channel [12:51] zzak has joined the channel [12:56] micheil: clarkfischer: try asking isaacs when he's about [12:56] MrTopf has joined the channel [12:59] jetheredge has joined the channel [12:59] clarkfischer: I definitely will [13:03] herbySk has joined the channel [13:03] TigerMunky has joined the channel [13:04] hellp has joined the channel [13:06] clarkfischer: Man, JSDOM ruins my night once again.... [13:07] GasbaKid has joined the channel [13:09] mscdex: tim_smart: have you tried again recently? [13:11] chapel: http://news.ycombinator.com/item?id=2134985 [13:11] xSmurf: mroing all [13:11] xSmurf: hmmmmm hmmmmm [13:12] xSmurf: -35°C, only 5 more than we're reaching the point were we will meet with °F [13:12] mnbvasd: ohh toasty.. [13:12] mnbvasd: where are you from? [13:12] xSmurf: not many places where it's -35°C right now :p [13:12] gregerolsson has joined the channel [13:13] tanepiper: haha, Dnode is so awesome - just wrote a handler on SIGINT that catpures, it, and sends a message to all clients that tell the server is shutting down in 60 seconds, then calls process.exit after 60 seconds :D [13:13] gregerolsson has left the channel [13:13] xSmurf: Russia, Alaska, Canada, Sweden and Iceland is my guess :p [13:13] mnbvasd: cool.. [13:13] mnbvasd: ACTION smurfs xSmurf  [13:13] xSmurf: tanepiper: what I want to do it SIGHUP to restart the app [13:13] xSmurf: mnbvasd: ouch! :p [13:21] pagameba has joined the channel [13:23] micheil: xSmurf: I think I'll stick with the weather of SF, I quite liked it when I was there [13:24] shaver: it's OK [13:24] shaver: south bay is better weather, actually [13:24] shaver: though I guess SF has a bunch of different weather [13:24] chapel: Weather for Spokane, WA · 28°F (-2°C) · Humidity: 96% · Overcast · Wind: North at 0 mph · Last Updated on January 24, 4:53 AM PST [13:24] xSmurf: uggg that's worst weather ever [13:24] chapel: Weather for San Francisco, Argentina · 84°F (29°C) · Humidity: 63% · Clear · Wind: NE at 10 mph · Last Updated on January 24, 9:00 AM ART [13:24] micheil: shaver: okay, well, I quite liked the weather near the mozilla offices, if that helps? :P [13:24] shaver: it was -33C with wind chill when I landed in Toronto yesterday afternoon [13:24] chapel: Weather for San Francisco, CA · 46°F (8°C) · Humidity: 86% · Partly Cloudy · Wind: South at 5 mph · Last Updated on January 24, 4:56 AM PST [13:24] shaver: micheil: yeah, exactly! [13:24] xSmurf: I'll take -30 over freezing humid rain anytime to bike in [13:25] xSmurf: shaver: you don't want to go to toronto [13:25] xSmurf: but it's not because of the cold [13:25] micheil: shaver: good damn are you up early.. [13:25] shaver: I live in Toronto, normally [13:26] shaver: micheil: I'm in Toronto right now :-) [13:26] xSmurf: http://www.youtube.com/watch?v=_TQGsrNlj2k [13:26] xSmurf: They don't have bagels [13:26] xSmurf: they have edible oil products [13:26] xSmurf: they have a tower that controls minds [13:26] xSmurf: people don't have faces in toronto they have cigarettes ads instead [13:26] shaver: yeah, but my house is here! [13:26] micheil: shaver: just realised that. ;) [13:26] xSmurf: shity version though, sorry [13:26] xSmurf: shaver: poor you, move? :p [13:26] shaver: :-P [13:27] pagameba: anybody using node-seq ? [13:27] micheil: not I [13:27] micheil: but the author probably is, if they are about. [13:27] xSmurf: that song should be Toronto anthem :p [13:28] bpedro has joined the channel [13:28] perlmonkey2 has joined the channel [13:28] xSmurf: "I don't want to leave Toronto! The tower says I must stay!" [13:28] xSmurf: :p [13:29] shaver: heh [13:30] MattJ has joined the channel [13:31] xSmurf: hey MattJ [13:33] charlenopires has joined the channel [13:33] MattJ: Hi xSmurf [13:37] heavysixer has joined the channel [13:37] virtuo has joined the channel [13:42] chrischris has joined the channel [13:43] chrischris has joined the channel [13:43] hassox has joined the channel [13:45] skohorn has joined the channel [13:47] jankoprowski has joined the channel [13:48] nook has joined the channel [13:51] claudiu__ has joined the channel [13:51] fallsemo has joined the channel [13:52] mscdex: node.js rules! [13:52] xSmurf: yes it does! [13:55] flazz has joined the channel [13:57] caolanm has joined the channel [13:57] djanowski has joined the channel [13:58] ntelford has joined the channel [13:59] lukegalea: xSmurf, shaver: I too am freezing my ass off in Toronto. [14:00] xSmurf: lukegalea: I'm freezing my ass off, but thank fsm I'm not in Toronto [14:00] lukegalea: aah. I misread. [14:00] xSmurf: and I'm eating bagels not made of edible oil products [14:00] xSmurf: :P [14:00] Lorentz: Newspaper bagels? [14:02] xSmurf: I'm not from NYC either ;P [14:03] pjackson: xSmurf Village? [14:03] xSmurf: pjackson: exactly! [14:03] xSmurf: we're all blue here [14:03] fairwinds has joined the channel [14:03] xSmurf: but it might just be the cold ;P [14:03] pjackson: Is there just one female too? [14:04] pjackson: Must have been odd dynamics in that group. [14:04] mnbvasd: in the world? [14:04] awenkhh has joined the channel [14:06] lukegalea: I assumed there was one female in every village [14:06] lukegalea: hopefully the new movie will clear that up. [14:07] xSmurf: lol [14:07] Coal has joined the channel [14:07] mscdex: the new movie is a documentary? [14:07] mscdex: ;-) [14:10] antris has joined the channel [14:11] antris: uhh, i'm trying to use a node+expressjs+jade stack. i'm rendering a view, but i only get the layout.jade [14:11] antris: how do i tell in the template where the view should go [14:11] Fandekasp has joined the channel [14:12] [AD]Turbo has joined the channel [14:12] xSmurf: mscdex: no, it's a porno :p [14:13] jlecker has joined the channel [14:13] lukegalea: again [14:14] messju_: ich hab mit twm angefangen [14:14] balaa has joined the channel [14:15] messju_: (ups!, sorry!) [14:15] mnbvasd: messju_: me too. [14:15] messju_: :) [14:15] xSmurf: Ich spreche nicht Deutsch [14:16] arpegius has joined the channel [14:17] mnbvasd: ich spreche klein deutsch.. [14:19] Manuel_ has joined the channel [14:20] benvds has joined the channel [14:21] montylounge has joined the channel [14:26] adambeynon has joined the channel [14:30] zzak has left the channel [14:30] Ari-Ugwu has joined the channel [14:30] zzak has joined the channel [14:31] unomi has joined the channel [14:32] WaterCooled has joined the channel [14:35] herbySk has joined the channel [14:36] fallsemo has joined the channel [14:37] kristsk has joined the channel [14:41] piscisaureus has joined the channel [14:41] pair has joined the channel [14:43] antris: lol, there's some !{body} tag that works by magic or something [14:44] antris: that i can't find in any of the tutrials [14:44] antris: well played. [14:45] bzinger has joined the channel [14:46] thepose has joined the channel [14:46] eee_c has joined the channel [14:46] dgathright has joined the channel [14:49] mAritz has joined the channel [14:49] cwo: hey guys. does node already have a dtrace provide in place? [14:51] boaz has joined the channel [14:52] Aikar: cwo: should ask 'does node have any tracing tools availible' instead of naming a specific implementation in another lang :P [14:52] Aikar: but i dont know of any [14:53] Aikar: but that doesnt mean it doesnt exists [14:53] Aikar: could be built into v8 [14:54] Aikar: cwo: i know there is debugging utils, but ive not seen anything for profiling/tracing [14:55] Aikar: cwo: maybe this will help https://github.com/bnoordhuis/node-profiler [14:55] paulrobinson has joined the channel [14:55] bradleymeck has joined the channel [14:55] cwo: Aikar: I found an article about dtrace and since I'm running on Solaris my question was kind of specific. ;-) [14:55] cwo: Aikar: article about dtrace provider for node ;-) [14:56] amacleod has joined the channel [14:56] ianward has joined the channel [14:56] texodus has joined the channel [14:57] Aikar: ah, i never heard of 'dtrace' specifically so when i googled it it looked like a Java utility :P [14:58] sivy has joined the channel [14:59] Astro has joined the channel [14:59] bits58 has joined the channel [15:00] antares_ has joined the channel [15:00] awenkhh has joined the channel [15:01] cwo: Aikar: http://dtrace.org/blogs/bmc/2010/08/30/dtrace-node-js-and-the-robinson-projection/ [15:02] garrensmith has joined the channel [15:02] cferris has joined the channel [15:03] antares_ has left the channel [15:04] micheil: ryah_: could you ping me when you're about? [15:06] davidsklar has joined the channel [15:06] jamesarosen has joined the channel [15:07] garrensmith has joined the channel [15:07] bpedro has joined the channel [15:09] mraleph: no dtrace probes in V8 [15:10] temp01 has joined the channel [15:10] herbySk has joined the channel [15:12] halfhalo has joined the channel [15:15] shiawuen has joined the channel [15:16] baoist has joined the channel [15:19] andrzejsliwa has joined the channel [15:20] losing has joined the channel [15:21] wakawaka has joined the channel [15:21] jherdman has joined the channel [15:22] wakawaka: hi all, anyone know how to get the present directory of the script? so i can do something like DIR+'/whatever/etc/etc/' [15:22] Mike_Rice has joined the channel [15:22] tanepiper: __dirname [15:22] tanepiper: eh __filename sorry for the script, __dirname from where you are running it from [15:22] tanepiper: http://nodejs.org/docs/v0.3.6/api/globals.html [15:23] jakehow has joined the channel [15:23] wakawaka: awesome thanks tanepiper [15:25] Aikar: hmm. a 30mb .sh file just seems very silly to me lol. (Netbeans for Linux) [15:26] bartt has joined the channel [15:26] garrensmith: when creating a secret for a session should it be a UUID or whats best practice? [15:26] tanepiper: garrensmith: a UUID is going to be long and pretty unique [15:27] xSmurf: garrensmith: depends [15:27] garrensmith: tanepiper: is it good for it to be unique? [15:27] bastianalbers has joined the channel [15:27] xSmurf: if you want to prevent replay attacks you will need hashes and hmac [15:27] garrensmith: is the secret just used to encrypt and decrypt? [15:27] awenkhh has joined the channel [15:28] Kingdutch has joined the channel [15:28] matt_c has joined the channel [15:29] tapwater has joined the channel [15:30] garrensmith: xSmurf: I'm just using the session to store a little bit of data about the data but nothing private [15:30] benburkert has joined the channel [15:31] xSmurf: then UUID would likely be fine [15:32] c4milo has joined the channel [15:32] djacobs7 has joined the channel [15:32] piscisaureus has joined the channel [15:32] benburkert has joined the channel [15:32] astoon has joined the channel [15:33] garrensmith: xSmurf: great thanks [15:33] evl has joined the channel [15:33] evl has joined the channel [15:33] colinclark has joined the channel [15:34] mynyml has joined the channel [15:37] devrim has joined the channel [15:37] fumanchu182 has joined the channel [15:38] Evet: is it reasonable to fork nodejs as a seperated project? [15:39] mscdex: Evet: for what reason? [15:41] Evet: sorry, not to fork [15:41] Evet: but another networking framework built on top of v8 [15:43] DracoBlue has joined the channel [15:44] mnbvasd: Evet: erm? why are you asking? it's free software isn't it? [15:44] MaDrense has joined the channel [15:44] MaDrense: Hi all [15:44] MaDrense: has anybody got a "operation not permitted" error when running nodejs on cygwin ? [15:44] mnbvasd: does anyone run node.js on cygwin? [15:45] tanepiper: surprisingly, i'm seeing it more and more on here and on twitter [15:46] sth: me too [15:46] jamund has joined the channel [15:46] chapel: yeah tanepiper [15:46] andrzejsliwa: Hi Guys, could you tell me which version of node.js you prefer for daily development ? [15:46] chapel: its kind of sad [15:47] nonnikcam has joined the channel [15:47] chapel: not because windows sucks, but because for a linux focused development platform like node.js, it just is not targeted to windows at all [15:47] andrzejsliwa: 0.2.x or 0.3.x ... which is recomended ? [15:47] texodus has left the channel [15:47] chapel: andrzejsliwa [15:47] softdrink has joined the channel [15:47] chapel: 0.2.6 = stable [15:47] chapel: 0.3.x = experimental/unstable [15:47] mnbvasd: I prefer unstable, it keeps you on your toes more ;) [15:48] andrzejsliwa: that is reason why I have problems :) ... I have used 0.3.x :) [15:48] tanepiper: chapel: yea, i mean i'm on windows, but i just stick on vmware and create lots of VM's to break :D [15:48] balaa has joined the channel [15:48] chapel: yeah tanepiper [15:48] chapel: I would prefer that [15:48] chapel: Im on osx, so I rarely have issues [15:48] danoyoung has joined the channel [15:49] losing_ has joined the channel [15:49] aconbere has joined the channel [15:50] tanepiper: i was on linux, but damn broadcom wifi drivers and intel i915 drivers are shitty, so i had more problems than it was worth [15:50] tanepiper: and i won't buy apple [15:51] chapel: hackintosh here [15:51] chapel: Mac CPU: Intel Core2 Quad Q9400 2.66GHz @ 2.7GHz [SSE3/SSSE3/PAE/XD/EST/VMX/EM64T] L2 Cache: 3072K FSB: 1332MHz RAM: 2.69GB/4.0GB Speed: 800MHz Disk: 51.75GB/74.21GB Display: ATI Radeon 4870 Series (PCIe) [1024MB] 1920x1080@60Hz and 1680x1050@60Hz Audio: Apple HDA OS: Mac OS X 10.6.6 (10J567) Kernel: Darwin 10.6.0 Uptime: 17 days 22:26 Client: Linkinus 2.2.1 (24629) [15:51] bpedro has joined the channel [15:51] softdrink: "I could have an iPhone without giving any money to Apple. I'D BE LIVING THE DREAM" — Moss [15:53] evl has joined the channel [15:53] evl has joined the channel [15:54] tk has joined the channel [15:56] pair: Good morning, all. Battling with Read and Write Streams. Here's the gist: https://gist.github.com/793373. Ultimately, we need to do some massaging of the data, but right now, we are just outputting whatever we get as input. We are finding that, for a large number of requests (425 files), with 20 simultaneous requests at any given time, a small number of files are ending up with corrupt data. I don't think the stream [15:56] pair: code could be any simpler than this. Any idea what's going on? [15:58] BillyBreen has joined the channel [15:59] jdalton has joined the channel [15:59] jdalton has left the channel [16:00] jchris has joined the channel [16:01] JohnnyL has joined the channel [16:01] dgathright has joined the channel [16:03] EyePulp has joined the channel [16:04] mscdex: pair: where do you close the writestream? not sure that'd solve your problem though [16:04] ph^ has joined the channel [16:04] ROBOTARMY has joined the channel [16:05] pair: mscdex: We actually don't. ;) The garbage characters are always somewhere in the middle, though. Should we call ws.close in the rs.on('end'...) handler? [16:05] jstemmer has joined the channel [16:05] narph has joined the channel [16:05] mscdex: pair: i would, if you are finished writing [16:05] narph: hey guys. does anyone know a module that provides support for shell globs (/foo/**.bar) besides asyncjs? [16:06] mscdex: pair: what version of node are you using btw? [16:06] mscdex: narph: have you seen this?: https://github.com/isaacs/node-glob [16:07] pair: mscdex: 0.2.4 [16:07] colinclark has joined the channel [16:07] Me1000 has joined the channel [16:07] narph: mscdex: oh dude i totally love you. asyncjs implementation is broken :( [16:08] pair: mscdex: also, not sure if this matters, but we are using the default bufferSize [16:08] _jdalton has joined the channel [16:09] mscdex: pair: what if you comment out line 8 and 15-17, does that make any difference in the output? [16:09] devrim has joined the channel [16:10] pair: mscdex: haven't tried that. I thought checking to make sure that the ws was flushed was best practices to keep memory low. [16:10] foo-bar- has joined the channel [16:10] mscdex: pair: it is, but it's just something to check [16:10] yonkeltron has left the channel [16:11] pair: mscdex: thanks. I'll try that on the next run. Any significant differences between 0.2.4 and 0.2.6? [16:11] foo-bar-: Hello, I'm getting a build error on cygwin {task: libv8.a SConstruct -> libv8.a} after exporting SHELL=/bin/bash, any ideas? [16:11] sonnym has joined the channel [16:12] dguttman has joined the channel [16:12] jamesarosen has joined the channel [16:12] mscdex: pair: possibly for what you're doing. i'd upgrade to 0.2.6 just to be sure [16:13] daniellindsley has joined the channel [16:13] pair: mscdex: yep. makes sense. Will try *that* after the next run. Currently running with the ws.close and a larger buffer in place. It takes about 13 minutes to do all 425 files. [16:14] Yuffster has joined the channel [16:15] chapel: pair: when an upgrade to 0.2.x happens, it is a bug fix [16:15] chapel: so you should always upgrade stable [16:15] desaiu: server = http.createServer(); server.on('request', function (req, res) {...}); confuses me [16:16] technoweenie has joined the channel [16:16] desaiu: I thought strings were in quotes [16:16] desaiu: i understand the concept, what's going on, i just don't understand the internals [16:16] desaiu: was hoping someone could help this poor bloke understand [16:17] diaswrd has joined the channel [16:17] mscdex: desaiu: strings in javascript can be double quoted or single quoted [16:17] chapel: yeah [16:17] chapel: server.on is an event call bac [16:18] desaiu: What is 'request'? [16:18] mscdex: an event name [16:18] chapel: request is when someone conneccts to the server [16:18] chapel: but yeah [16:18] chapel: its an event name [16:18] Evet: is there a disadvantage of running an http server per application? [16:18] chapel: the http.Server will do an .emit('request') [16:18] chapel: when someone connects [16:18] chapel: and if there is a .on('request') it will fire whats inside of that [16:19] kristsk: Evet, what do you mean by "server per application"? [16:19] wdperson has joined the channel [16:19] desaiu: so the on method requires a name for the event name, and does it require an anonymous function, because i always see this pattern. [16:20] chapel: desaiu [16:20] desaiu: a string for the event name* [16:20] bradleymeck has joined the channel [16:20] diaswrd: Hello everybody, anyone knows a simple node.js tutorial explaining how I can change DOM elements in my website and another connected person see this alterations in real time? [16:20] chapel: the callback can be an anon function, or a named function [16:20] pair: chapel: thanks [16:20] desaiu: oh [16:20] chapel: so server.on('request', namedFunction) [16:20] diaswrd: I only read hello worlds tutorials [16:20] Evet: kristsk: embedded http server in application; http.createServer [16:21] chapel: and namedFunction = function(req, res) { } [16:21] chapel: diaswrd: node itself doesn't interact with the client in ajax [16:21] mscdex: or: function namedFunction(req, res) { } [16:21] mscdex: :> [16:21] chapel: you would need client side code to handle that [16:21] chapel: you could have node update using lets say socket.io [16:21] chapel: but again client side stuff [16:22] diaswrd: Oh I understood [16:23] diaswrd: node itself don't handle that client side stuff [16:23] chapel: no [16:23] diaswrd: I need something like socket.io [16:23] diaswrd: to do that [16:23] chapel: you can make it work with the client [16:23] chapel: well diaswrd [16:23] desaiu: where is the res.writeHead method being inherited from? [16:23] chapel: look at dnode http://github.com/substack/dnode [16:23] wkmanire has joined the channel [16:23] mscdex: desaiu: res is an instance of the http module's ServerResponse [16:23] chapel: diaswrd: dnode is pretty cool, and uses socket.io [16:23] desaiu: in server.on('request', function(req, res) { res.writeHead(200, {...}}); [16:23] kristsk: Evet - afaik http server in node is not terribly expensive, so - although I can not imagine a clear reason why - but, yeah, you could run multiple servers in one node process. [16:24] kristsk: given that they listen to differnet ports/sockets [16:24] mscdex: desaiu: and req is an instance of ServerRequest [16:24] diaswrd: I'll read that [16:24] diaswrd: thank you very much chapel [16:24] chapel: its worth checking out [16:24] chapel: also can be used between other node processes [16:25] diaswrd: oh nice [16:25] diaswrd: thx dude [16:25] chapel: check out the http example [16:25] chapel: browser example I mean [16:26] Evet: kristsk: no, i want to run one node process per application, and all applications have its own http server [16:26] Me1000 has joined the channel [16:26] kristsk: Evet - and how many applications? [16:26] Evet: kristsk: ~100 [16:26] GasbaKid has joined the channel [16:26] kristsk: pff [16:26] mscdex: jeesh [16:27] kristsk: and reason you want 100 separate node processes instead of 1 is ? [16:27] Evet: maintainability? [16:27] chapel: Evet: what are the applications? [16:28] Aikar: Evet: you need an FD passing parent [16:28] kristsk: um, why, Aikar? [16:28] kristsk: if those servers/apps have seaparet functions, then doing this would make a big mess [16:28] Evet: chapel: web applications with built-in db [16:29] chapel: built in db? [16:29] Evet: chapel: tokyo cabinet binding [16:29] chapel: built into the app? server? [16:29] Aikar: kristsk: if he wants to have multiple http servers all listening on 80.. [16:29] kristsk: huh, i am not sure what Evet wants heh [16:30] Evet: Aikar: no, different IPs [16:30] Aikar: oh [16:30] chapel: even still, whats the point? [16:30] chapel: how different are they? [16:30] Aikar: trying to build some 'shared host' or 'quickly throw up a new site' infrastructure? [16:30] chapel: are they different at all? [16:31] Evet: its easier to 'quickly throw up a new site' [16:31] astoon has joined the channel [16:31] Aikar: Evet: imo it would be easier to read HOST header and then route the request to a diff function to route the request, so youll have 1 func per 'domain' then that function routes it [16:32] bradleymeck: anyone here familiar with the cloud9 codebase? [16:32] Aikar: so new site = throw a new .js file into a directory [16:32] wkmanire: Is there a good tutorial for working with Crypto? [16:32] desaiu: is req and res specified in in the http module? [16:32] Aikar: yes [16:32] wkmanire: I want to do a one way salted hash. [16:33] Aikar: hashes are always 1 way unless you use md5 [16:33] Aikar: or weaker [16:33] chapel: Evet: you could use dnode for that :) [16:33] Evet: Aikar: hmm sounds reasonable [16:33] jetienne: arf [16:33] wkmanire: Aikar: Well, I'm sure you know what I mean. [16:33] Aikar: since md5 is broken [16:34] piscisaureus: ACTION happy again [16:34] piscisaureus: ryah_: awake already? [16:35] kristsk: mhh [16:35] piscisaureus: hey pquerna, any news? [16:36] malkomalko has joined the channel [16:36] kristsk: isn't hmac-md5 quite safe? [16:37] mscdex: desaiu: yes, they are http.ServerRequest and http.ServerResponse respectively [16:37] Aikar: wkmanire: require('crypto').createHmac('sha1', SALTHERE).update(DATAHERE).digest('hex'); [16:37] xSmurf: Aikar: it's not like sha1 is much better than md5 in that regards [16:37] Aikar: have they broken sha1 too O.o? [16:37] mscdex: git uses sha1 doesn't it? [16:38] Aikar: it gets exponentially harder... im unaware of sha1 being broken [16:38] wkmanire: Aikar: Thank you. [16:39] xSmurf: Aikar: they've detected a high potential for collisions yes [16:39] sprout has joined the channel [16:39] Aikar: xSmurf: source? [16:39] jetienne: git doesnt use sha1 for security [16:39] xSmurf: "A 2008 attack by Stéphane Manuel breaks the hash function, as it can produce hash collisions with a complexity of 251 operations" [16:39] xSmurf: wikipedia [16:39] kristsk: there is no security in git [16:39] xSmurf: http://eprint.iacr.org/2008/469.pdf [16:40] jetienne: after that, for security, DO NOT DO IT YOURSELF [16:40] xSmurf: Stéphane Manuel. Classification and Generation of Disturbance Vectors for Collision Attacks against SHA-1. [16:40] jetienne: you will fail :) [16:40] mraleph: using hash functions for security is wrong in any case. [16:40] jetienne: aka if you need to know md5 or sha1, you are doing it wrong, except if you are a security engineer [16:40] Aikar: alright then, i guess sha256 it is from now on :P [16:40] xSmurf: 2005 http://www.rsa.com/rsalabs/node.asp?id=2927 [16:41] xSmurf: Aikar: depends how long you think your data will last [16:41] flippyhead has joined the channel [16:41] wink_: mraleph: whew, i thought this place had gone crazy for a sec [16:41] xSmurf: if you expect it to last a few years, I'd suggest you plan ahead [16:41] kristsk: sha-3 algo is in final rounds [16:41] JusticeFries has joined the channel [16:41] kristsk: should last a while [16:41] chapel: mraleph: what should you use? [16:41] xSmurf: salted hashes? ;) [16:41] dmcquay has joined the channel [16:42] jetienne: chapel: use a solution designed by a security person [16:42] kristsk: mhhh [16:42] chapel: well why doesn't someone make one for node? [16:42] briznad has joined the channel [16:42] chapel: where are the security people here?! [16:42] philipharrison has joined the channel [16:42] xSmurf: "security people" tell me properly salted hashes aren't so terrible ;) [16:42] kristsk: they know better thant to speak up, i suppose. [16:43] mraleph: chapel: PKC? [16:43] xSmurf: of course, now that the govt is after them... [16:43] xSmurf: so much for free speech [16:43] wink_: any hash will have collisions, you should expect it to occur [16:43] mraleph: chapel: in any case approach always depends on what are you trying to achieve. [16:43] muk_mb has joined the channel [16:43] chapel: yeah [16:43] chapel: just was asking [16:43] kristsk: well, quiestion is if you can come up with a way to find those collisions without brute force [16:44] chapel: since you brought it up :) [16:44] chapel: anything can be broken [16:44] jetienne: http://tools.ietf.org/html/rfc2898#page-9 <- pkcs5 docs about password derivation [16:44] chapel: eventually[ [16:44] chapel: with unlimited time and computing power [16:44] xSmurf: wink_: it's a matter of how long you expect the data to last vs how long you expect it to become trivial to generate collisions for a specific hash method [16:44] Aikar: kristsk: well for sha1 yeah its harder to brute force, but md5 has become trivial to bruteforce [16:44] jetienne: chapel: pkcs is done by security people [16:44] mraleph: I am by no means security expert, I am humble compiler engineer with math background :-) [16:44] wink_: absolutely, but given that you are unlikely able to predict when functional attacks exist (if they don't already) [16:44] Aikar: theres some tool that can modify a file to make it match an exact md5 [16:45] wkmanire has left the channel [16:45] xSmurf: jetienne: and it only supports md5 and sha1? [16:45] wink_: assuming anything else is asking for trouble [16:45] ajpiano has joined the channel [16:45] jetienne: xSmurf: nope [16:45] matt_c: use bcrypt use bcrypt use bcrypt? :) [16:46] jetienne: well i have broken enougth security to advice against doing custom one :) [16:46] xSmurf: matt_c: wasn't blowfish broken ages ago [16:47] jetienne: and btw if your security is as good as the underlying algo (sha1,md5, blowfish etc...) you are in really good shape :) [16:47] cwo: a (real) random stream of bits and xor will do the job ;-) [16:47] matclayton has joined the channel [16:48] matt_c: xSmurf: http://en.wikipedia.org/wiki/Blowfish_(cipher)#Cryptanalysis_of_Blowfish ? [16:49] jetienne: still the same, if you have to use an encryption algo, use aes. because this is the most studied [16:49] xSmurf: cwo: easy enough, make your own TRNG you probably have almost all the parts at home ;) [16:49] desaiu: where can i find the source code for the http module? I grepped in node/src/ but didn't find any method called response. I'm thinking that maybe that function will help me understand what's going on. [16:49] matt_c: ACTION likes the "you decide the work factor" of bcrypt. [16:49] Aikar: desaiu: /usr/local/lib/node/ [16:49] Aikar: i think [16:49] cwo: xSmurf: yeah. but the problem is to find the right bit order again to decrypt the stuff ;) [16:50] xSmurf: wasn't AES broken too? I remember the DoD saying to stop using it [16:50] desaiu: aha [16:50] xSmurf: cwo: who talked about decryption here? :p [16:50] jetienne: https://github.com/ry/node/blob/master/lib/http.js <- desaiu [16:50] Aikar: nvm not there [16:50] cwo: there was a kind of weakness with certain prerequisites [16:50] Aikar: its in the node src folder [16:50] Aikar: check under lib/ [16:50] cwo: in aes [16:50] cwo: xSmurf: It's like talking about backup. no on talks about restore. just backup :D [16:50] Aikar: yeah node/lib/http.js [16:51] xSmurf: cwo: rofl [16:51] xSmurf: http://www.schneier.com/blog/archives/2009/07/another_new_aes.html "Another New AES Attack" [16:51] Aikar: thats one thing that kinda urks me, why does node link to the source checkout instead of copying those .js files to /usr/local/lib/node - if ya blew away your source dir or moved it, would break node :/ [16:52] yhahn has joined the channel [16:54] dguttman has joined the channel [16:54] mikeal has joined the channel [16:55] TigerMunky_ has joined the channel [16:55] tokumine has joined the channel [16:55] cwo: xSmurf: my former crypto prof made an article for a german newspaper about aes. if you're capable of german, he is quite good in explaining real world examples ;-) [16:55] strmpnk has joined the channel [16:56] xSmurf: sadly my German is barely existing :( [16:56] xSmurf: I wished [16:56] mnbvasd: Aikar: really? it'd break it? I thought the files were statically included in the binary? [16:56] mnbvasd: Aikar: try: strings `which node` | less [16:56] Aikar: oh are they? [16:57] Aikar: ah ok [16:57] Aikar: i didnt know they were linked in [16:57] Aikar: i just noticed they existed nowhere else [16:57] xSmurf: cwo: maybe immersion at CCC Camp will help ;) [16:57] xSmurf: already counting the days weeks [16:58] gattuso: hi [16:58] cwo: xSmurf: hm. it's kind of hard to translate. ;-) maybe I find a english paper but I doubt it. his english is kind of crappy. I heart him once talking english when Weizenbaum visited our university [16:58] mnbvasd: Aikar: I got confused and cheked and that's what I concluded iirc. [16:58] xSmurf: lol [16:58] gattuso: someone knows if the less.js channel exists? [16:58] isaacs has joined the channel [16:59] cwo: xSmurf: my buddy is at the camp. he asked me too but I rather spend my holidays with...well...doing nothing computer related :D [16:59] xSmurf: there'll be tons of non computer related stuff to do I'm sure ;) [17:00] jankoprowski has joined the channel [17:00] dgathright has joined the channel [17:00] isaacs: holy moly. just got the backlog, seems like people were talking about npm all weekend. [17:00] desaiu: I'm not seeing the method anywhere unless that's it at the top in config.log: http://pastebin.com/raw.php?i=vaF8zwwF [17:00] isaacs: never gotten so many notes from ircretary [17:01] isaacs: ryah_: you about? [17:01] micheil: hey isaacs [17:01] isaacs: micheil: yo [17:02] heavysixer has joined the channel [17:02] tjholowaychuk has joined the channel [17:02] jetienne: node needs a simple way to do sequencial commands [17:03] micheil: userland. [17:04] isaacs: NODE NEEDS THREADS AND COROUTINES YOU SHOULD POST IT ON THE DEV LIST OMGLOLZ [17:04] astoon has joined the channel [17:04] mraleph: lol [17:04] jetienne: nope, just need a better api [17:04] piscisaureus: everyone wants to see ryah. we should have multiple [17:04] isaacs: hehe [17:04] jetienne: this is even in the basic requirement of node [17:04] jetienne: "need to fit unix hardcore personn" [17:04] case__: :) [17:04] mraleph: isaacs: oatmeal style :-) [17:04] micheil: jetienne: everyone has a favourite way to handle it, hence the reason it's in userland [17:04] isaacs: jetienne: that's really not a basic requirement of node. [17:05] jetienne: and nobody will write small scripts with pure async [17:05] vineyard has joined the channel [17:05] isaacs: jetienne: write small scripts in bash. [17:05] jetienne: isaacs: well this is one claimed by ryah_ [17:05] isaacs: it's better for that anyway [17:05] jetienne: isaacs: arfg [17:05] jetienne: isaacs: i wish it was :) [17:05] isaacs: jetienne: i mean, yeah, it's a basic requirement, but the requirement to do it without changing their habits? not a priority. [17:05] micheil: isaacs: is node on HEAD building for you? [17:05] isaacs: the basic requirement is to fit them onc they bend to the model of async [17:05] micheil: via cmake, that is, make -f Makefile.cmake [17:05] isaacs: micheil: yeah, but the http changes broke npm abit. [17:06] isaacs: micheil: i don't have cmake [17:06] micheil: oh. [17:06] micheil: brew install cmake? [17:06] jetienne: well i disagree [17:07] isaacs: jetienne: disagree that it's a priority, or that it should be? [17:07] jetienne: just make step official, or something similar [17:07] micheil: jetienne: it's something that should stay in userland, it's not worth even trying to make it official. [17:07] micheil: however, it is something that should be documented. [17:07] jetienne: isaacs: i think ryah_ original goals, there were 2 from memory. one of them was "do not disturb hardcore unix personn". [17:08] jetienne: micheil: by userland you mean library ? (node being all userland i mean) [17:08] isaacs: jetienne: have you seen the jsconf.eu video? [17:08] jdalton has joined the channel [17:08] jetienne: isaacs: yes [17:08] isaacs: jetienne: especially the part where he's all "We've been doing I/O wrong forever. This is a better way. We're going to do it like this now." [17:08] micheil: isaacs: http://typewith.me/improve-node-docs [17:09] isaacs: jetienne: in teh context of node, "userland" usually means "not compiled into node itself". yeah, of course, it's not a kernel program, it's all userland. [17:09] jetienne: src/ is userland too ? [17:09] mikeal has joined the channel [17:10] d0k has joined the channel [17:10] jetienne: if so, just put step (or other alternatives) in src/ [17:10] jetienne: thus node will be much easier to use when not doing IO [17:10] dgathright has joined the channel [17:11] kristsk: Step ftw [17:11] piscisaureus: jetienne: you don't need callbacks when you're not doing io [17:11] piscisaureus: no need to make node easier then heh [17:11] jetienne: mouamoua [17:11] tjholowaychuk: its fine / easy the way it is [17:11] brianm has joined the channel [17:11] jetienne: the cour :) [17:12] jetienne: tjholowaychuk: take any of your git bash script and convert it to node [17:12] tjholowaychuk: why? [17:12] jetienne: tjholowaychuk: i bet you double the amount of lines :) [17:12] tjholowaychuk: yeah [17:12] tjholowaychuk: of course [17:12] silence has joined the channel [17:12] tjholowaychuk: shell scripts are extremely terse [17:12] tjholowaychuk: I wouldnt expect that from node [17:12] Me1000 has joined the channel [17:12] jetienne: so the "easier enougth" being worst than bash... doesnt seem to fit by definition of easy [17:13] trotter has joined the channel [17:13] jetienne: well this is ok, i just think node should be easier to code than bash [17:13] kristsk: or perl! [17:13] kristsk: (runs for cover) [17:14] matclayton has left the channel [17:14] isaacs: jetienne: bash is great for shell scripts. it is a language designed around shell scripting. why would you expect javascript to be terser at that task? [17:14] jetienne: isaacs: "bash is great" [17:14] ajpiano has joined the channel [17:14] isaacs: jetienne: yeah :) [17:14] isaacs: it is :) [17:14] micheil: jetienne: please, read the mailing list and search on npm, there's literally a hundred different ways to manage async programming; node should not have one style that is the way it's done. [17:15] jetienne: isaacs: sure :) [17:15] isaacs: micheil: well, node HAS one style. that style is the simplest that we could come up with that suits node's purposes. [17:15] jetienne: isaacs: which one ? [17:15] isaacs: you can build promises or sugar-fibers or whatever on top of that. [17:15] isaacs: jetienne: callbacks. [17:15] tjholowaychuk: yeah i agree with micheil [17:15] tjholowaychuk: i for one dont like any of them lol [17:15] isaacs: micheil++ tjholowaychuk++ [17:15] tjholowaychuk: so no one will ever agree [17:15] warz has joined the channel [17:15] isaacs: hahah [17:16] isaacs: tjholowaychuk: that's why i just use callbacks in npm [17:16] isaacs: it's awesome [17:16] jetienne: and you will always be wrong :) [17:16] isaacs: jetienne: you just proved micheil's point. [17:16] tjholowaychuk: haha [17:16] jetienne: relax guys [17:16] micheil: if no-one can agree on one method, you either need a dictator or none of them [17:16] micheil: jetienne: sorry, but people get a little annoyed at rehashing the same stuff all the time. [17:16] isaacs: cps IS a method [17:17] isaacs: that's what node has [17:17] isaacs: it's awesom. [17:17] jetienne: micheil: i think people overreacted because of this [17:17] piscisaureus has joined the channel [17:17] isaacs: jetienne: people overreacted to being told no. then some others overreacted to the reaction. [17:17] isaacs: so much of software development is primatology. [17:18] andrzejsliwa has joined the channel [17:18] jetienne: btw still no project of doing a node-libs project ? [17:18] jetienne: like some official libraries ? [17:18] isaacs: jetienne: http://registry.npmjs.org/ [17:18] jetienne: php/python/perl/ruby etc... they all got one [17:18] isaacs: node is different :) [17:18] kristsk: there is ext-stomthing [17:18] jetienne: isaacs: unfortunatly this is diferent [17:18] jetienne: npm is just a package repo [17:19] jetienne: nothing on the code quality, stability, documentation, compatibility [17:19] kristsk: https://github.com/visionmedia/ext.js [17:19] isaacs: jetienne: write a package.json that depends on the packages and versions you think should be included. call it "node-libs". publish it. [17:19] isaacs: npm install node-libs [17:19] jetienne: isaacs: hehe [17:19] jetienne: isaacs: you dont even read what i write :) [17:19] tjholowaychuk: kristsk: that project is kinda defunct [17:19] pyrotechnick has joined the channel [17:19] pyrotechnick: evening lads [17:19] tjholowaychuk: kristsk: I dont think it even installs properly from npm haha [17:19] isaacs: jetienne: you want something that's compiled into node? [17:19] isaacs: jetienne: fork it. [17:19] isaacs: drop some stuff into ./lib/ [17:19] isaacs: done [17:20] pyrotechnick: isaacs++ [17:20] v8bot: pyrotechnick has given a beer to isaacs. isaacs now has 9 beers. [17:20] jetienne: :) [17:20] isaacs: jetienne: the goal is actually to have node itself be very very small. http is about pushing it. [17:20] dguttman has joined the channel [17:20] isaacs: anything bigger/higher-level than that will probably not be included. [17:20] jetienne: isaacs: so you mean no, there are no project which gives libraries stable, backward compatible, well documentated [17:21] jetienne: isaacs: i understand the principle. this is why i proposed a node-core being current node [17:21] jetienne: and a node-libs being the stable documented, compatible set of libraries [17:21] Thorn has joined the channel [17:21] isaacs: jetienne: so, you mean, you would like there to be a group of people who manage a stable, documented, backwards-compatible set of libraries? [17:21] mike5w3c has joined the channel [17:22] isaacs: jetienne: that sounds awfully lawful. javascript tends a bit more chaotic than that. [17:22] isaacs: jetienne: but there are a few private efforts going on [17:22] jetienne: isaacs: yep i would like node to get stable, documented, running, libraries [17:22] isaacs: look at learnboost or nodejitsu, for instance [17:22] isaacs: jetienne: build them, or just wait a few years. [17:22] Ori_P has joined the channel [17:22] isaacs: node is *2 years old* [17:23] aurynn has joined the channel [17:23] isaacs: php and ruby had hardly anything like this after 2 years of development. [17:23] romainhuet has joined the channel [17:23] jetienne: things were different in early 90 :) [17:23] isaacs: not even, really, its birthday is next month [17:23] xSmurf: jetienne: mollets were cool? [17:23] isaacs: it's only 23 months [17:24] khs4473 has joined the channel [17:24] ROBOTARMY has joined the channel [17:24] tlynn_ has joined the channel [17:24] jetienne: well i will repropose the project stable/documented/backward compatible libraries later. i do that every 2 months or so :) [17:24] isaacs: what i'm saying is, yes, i agree with your desire, and it's an interesting challenge. but i think that where we're heading is actually better overall than php's or ruby's or python's notion of a bundled standard library [17:25] isaacs: how would such a project work, exactly? [17:25] isaacs: just saying "I want stable documented backwards compatible libraries" is nice, but not super helpful as far as making it actually happen. [17:25] jetienne: isaacs: you get a bunch of experienced, recognized people and they start assemble the bunch [17:25] tlynn_: does anyone know what version of libpcap node_pcap uses? (on ubuntu) [17:25] isaacs: tlynn_: whichever you've got, i think [17:25] jetienne: isaacs: http client was crappy for a long time. everybody reimplemented its own [17:26] herbySk has joined the channel [17:26] Kingdutch has joined the channel [17:26] isaacs: jetienne: i don't think anyone was actually taking a TCP client, and parsing http themselves [17:26] jetienne: isaacs: no idead what you are talking about [17:26] jetienne: micheil: isnt that you do did a html client ? [17:27] micheil: what? [17:27] binarypie has joined the channel [17:27] jetienne: or it was another nick with a m [17:27] micheil: mikeal? [17:27] micheil: he's behind request [17:27] isaacs: jetienne: yeah, but request is also just a much higher level API [17:28] isaacs: it's still around [17:28] jetienne: micheil: ah yes. my bad for the confusion [17:28] chapel: micheil: I want a podcast !!! [17:28] piscisaureus: jetienne: btw node is very much bound to the 90s, as cramforce pointed out. http://www.youtube.com/watch?v=AVmq9dq6Nsg [17:28] mikeal: i'm here [17:28] steffkes has joined the channel [17:28] mikeal: what's up [17:28] micheil: chapel: soon, my friend. I'm busy doing stuff for my new-isj job [17:28] chapel: thats fine :) [17:28] jetienne: isaacs: https://github.com/jeromeetienne/node-helpers/blob/master/ez_http.js my own. i guess you get yours :) [17:28] chapel: just saying [17:29] jetienne: isaacs: what i want is to avoid this duplication. and people can do a node-libs. there are a bunch of widly recognized, experience people on node [17:29] tapwater has joined the channel [17:29] jetienne: you get 5 to put their name on the project [17:30] kristsk: wildly recognized! [17:30] jetienne: widely :) [17:30] isaacs: jetienne: yep. problem is that they're all busy building the libs that will go in that library, and none of those things are stable. [17:30] isaacs: *node* isn't stable yet. [17:30] zomgbie has joined the channel [17:30] isaacs: you're asking the thing to drive before it's even out of diapers yet. [17:31] chapel: heh [17:31] jetienne: isaacs: you cant start node-libs only once node-core is completed. this will loose a lot of time [17:31] isaacs: this way is better. it's agile. we're exploring, and responding to actual needs. [17:31] mikeal: also, a lot of people are writing frameworks and libraries as their first node code [17:31] chapel: its almost like node should have incubated a little bit before getting so popular [17:31] chapel: :) [17:31] antris has left the channel [17:31] isaacs: mikeal: exactly [17:31] jetienne: isaacs: node-core is not stable. sure but it is quite. largely enougth to start writing code on it [17:31] chapel: or hosting platforms [17:31] isaacs: so a lot of these libs and frameworks suck. [17:32] mikeal: i've been using node for over a year and i'm still figuring out better ways to structure node code and solve problems [17:32] chapel: hosting = new hello world [17:32] isaacs: yep [17:32] isaacs: jetienne: ask again in 2014. [17:32] chapel: then again [17:32] mikeal: haha [17:32] chapel: hosting is hugely different [17:32] mikeal: even request, which is super simple [17:32] chapel: than when rails came out [17:32] isaacs: mikeal: yeah, tell me about it [17:32] jetienne: isaacs: nah, i will just ask again in 2 months :) [17:32] mikeal: i just recently decided to rework it for some nicer API changes I want to get in [17:32] isaacs: mikeal: i'm gonna have to rewrite a few big parts of npm's guts soon. [17:33] isaacs: (in the process, actualy) [17:33] piscisaureus: we should stop developing node, rename the project and go on in secrecy. [17:33] mikeal: i saw that [17:33] isaacs: but, proper permissions! [17:33] isaacs: coming soon! [17:33] isaacs: sudo won't complain! [17:33] jetienne: isaacs: nice :) [17:34] jetienne: last time i complained about npm install, i got flamed here :) [17:34] isaacs: haha [17:34] piscisaureus: isaacs: awesome. I an a *ix noob but I fell for the sudo trap [17:34] nerickson has joined the channel [17:34] isaacs: i do still maintain that if you're not going to manage permissions properly, you shouldn't do it at all. [17:35] isaacs: which is why npm is currently dangerous as root [17:35] creationix has joined the channel [17:35] jetienne: isaacs: why not copy the rvm install model ? [17:35] mikeal: i just chown'd /usr/local [17:35] aconbere has joined the channel [17:35] jetienne: i mean rvm seems to work well [17:36] isaacs: jetienne: sure, it does. [17:36] isaacs: jetienne: most pm's do. [17:36] isaacs: and they all do it a little bit differently, but have a similar end result. [17:36] isaacs: run scripts as a de-perm'ed user, which requires that the parent process be run as root so it can change its UID. [17:36] creationix: jetienne: nvm + npm ftw [17:37] isaacs: chow n the package stuff to nobody, and everything else is root-owned. [17:37] isaacs: etc. [17:37] piscisaureus: isaac: (OT) your iterm is making fun of you again [17:37] piscisaureus: you work for the same company as ryah. does that mean he is at the desk next to you usually? [17:38] kuya has joined the channel [17:38] isaacs: my iterm? [17:38] piscisaureus: chow [0x08]n? [17:38] kuya: hello, does anyone know of an alternative to google analytics done with node? [17:38] isaacs: piscisaureus: except when i'm in oak land or he's in teh mission, yeah [17:38] sprout has joined the channel [17:38] isaacs: piscisaureus: sorry, chown [17:38] isaacs: that's colloquy [17:39] isaacs: ok, speaking of which, gotta run. [17:39] piscisaureus: good riddens :p [17:39] softdrink: riddance [17:40] piscisaureus: my english is improving here :-) [17:40] q_no has joined the channel [17:40] softdrink: hehe [17:40] piscisaureus: should have been here in high school :-) [17:40] sivy has joined the channel [17:41] sWORDs has joined the channel [17:42] yozgrahame has joined the channel [17:42] piscisaureus: although I wonder whether asking for a roflol kewl coke gets me anywhere in real life [17:42] jakehow has joined the channel [17:42] softdrink: mental institution, most likely. [17:44] ceej has joined the channel [17:45] sriley has joined the channel [17:45] piscisaureus: "Welcome to you second session, sir. Tell me more about these imaginary 'nerds' you are seeing." [17:45] noahcampbell has joined the channel [17:46] tanepiper: damn i missed isaacs [17:47] tanepiper: anyone done any npm postinstall scripts that install to /etc at all? I don't want to run as root, but i want my app to install an upstart script [17:47] ilpoldo has joined the channel [17:48] ROBOTARMY has joined the channel [17:48] jetienne: tanepiper: you need root to install it [17:49] tanepiper: jetienne: yea, what i feared - maybe have to write a bash script that runs npm then installs what it needs with root [17:49] djacobs7 has joined the channel [17:49] pomodoro has joined the channel [17:49] jetienne: tanepiper: as isaacs just said he will change the permission system, you should ask him [17:50] tanepiper: oh right, i should scroll up :D [17:51] jetienne: tanepiper: personnaly i will go for the "sudo cp balabla /etc/init" idea meanwhile [17:53] kristsk: and whats wrong with installing it in respective users home ? [17:53] gaYak: mm.. offtopic, what's the cheapest airline to fly inside US? [17:53] gaYak: (from coast to coast) [17:55] Max-Might has joined the channel [17:55] kjeldahl has joined the channel [17:56] mikeal has joined the channel [17:57] MikhX has joined the channel [17:58] akahn has joined the channel [17:59] herbySk has joined the channel [17:59] akahn has left the channel [18:00] svens_ has joined the channel [18:00] dahankzter has joined the channel [18:01] svens has left the channel [18:02] peol has joined the channel [18:02] peol has joined the channel [18:03] tanepiper: kristsk - no, can't it has to live in /etc/init - upstart needs to wait till the filesystem mounts [18:03] tanepiper: oh, he's gone :| [18:04] jetienne: tanepiper: what are you doing which need a upstart script ? [18:04] tanepiper: starting my nodejs app :) [18:04] aconbere has joined the channel [18:05] jetienne: tanepiper: usually, i do a Makefile in the package root. and in the Makefile, you get make install, make uninstall [18:05] jetienne: tanepiper: npm is not exactly as apt and such [18:05] creationix: you could probably just put sudo in the npm install script [18:05] creationix: not run npm as root [18:05] creationix: but run the cp /etc/init as root [18:06] tanepiper: jetienne: basically the software is pulled via git to /home/nodejs, nodejs user has full permissions on /usr/local [18:06] creationix: but since upstart is platform specific, you might do better simply making deb packages [18:06] dahankzter has joined the channel [18:06] tanepiper: i do npm install . to install the app, then that gives me the cli admin tool [18:07] tanepiper: creationix: ugh debs are horrible to make and maintain [18:07] creationix: write a node module to automate it? [18:07] creationix: or not, just a suggestion [18:07] jetienne: tanepiper: becarefull with "user has full permissions on /usr/local", dont change your system security without expert advice [18:07] tanepiper: i wouldn't really know where to start tbh [18:07] pyrotechnick: SubStack: are you around? [18:07] tanepiper: jetienne: the machine only has two users, ubuntu for full sudo, and nodejs to run the app [18:07] chapel: :) [18:08] jetienne: tanepiper: let just hope you wont add other users then :) [18:08] _jdalton has joined the channel [18:08] tanepiper: it's also probably a really good topic for a blog post at some time [18:08] tanepiper: jetienne: oh i won't, and the machines will be running in a vlan behind a firewall [18:08] tbranyen has joined the channel [18:09] _jdalton has left the channel [18:09] tbranyen: Can't seem to find a room for express help. I'm trying to send a 304 back, doing res.send(304) checking the output shows a 304, but the browser interprets a 200 [18:09] tbranyen: seems weird [18:09] tbranyen: especially since the whole request is being sent [18:10] micheil: tanepiper: for what it's worth, this is the upstart script we're using at work: https://gist.github.com/793633 [18:10] micheil: works quite well. [18:11] andrzejsliwa has joined the channel [18:11] micheil: umask 007 allows it to bind to priviledged ports [18:11] pyrotechnick: how insane would it be to try and make dnode work over UDP? [18:11] xSmurf: another option would be to run a proxy as root [18:12] xSmurf: or iptables port forward [18:12] tbranyen: oh baller it has to do with my nginx proxy forwarding [18:13] tbranyen has left the channel [18:13] tanepiper: micheil: how do you emit the webapp-up event? I know it's initctl you use, but i haven't got that far with upstart yet [18:13] micheil: initctl emit webapp-up [18:14] micheil: there's a good blog post series on it. [18:14] tanepiper: yea, but what do you get to fire it on startup? [18:14] cwo has joined the channel [18:14] pair: mscdex: 0.2.6 seems to have done the trick. The change notes talk about fixes to streams. [18:14] micheil: hmm? [18:14] micheil: it starts automatically on server boot [18:14] jetienne: tanepiper: the issue is more who install the upstart script [18:14] tanepiper: well it's a custom event, not something system based like filesystem or runlevel [18:14] micheil: or it starts when you call `initctl emit webapp-up` [18:15] tanepiper: ahh [18:15] micheil: see the OR block [18:15] jetienne: tanepiper: no need to be npm. it can be your own distinct script [18:16] tanepiper: jetienne: npm is really just for handling dependencies and installing the admin script, but i suppose i could just ssh in, pull the script and run it [18:16] piscisaureus has joined the channel [18:16] tanepiper: idealy, i'd like to have the whole thing be fire-and-forget in that when i create a new instance our hosting it does it [18:17] tanepiper: i.e. apt-get update && apy-get upgrade, restart, install system deps, install nodejs + npm, install npm deps then our app then start it [18:17] jetienne: tanepiper: you can do the ssh in the deployement procedure. this is what i do [18:18] MikhX has joined the channel [18:18] awenkhh has joined the channel [18:18] tanepiper: i also had the crazy idea of not even starting the app, but having a proxy that when the user hits it, it spawns an app on a unique subdomain for only that session and redirects the user to it [18:19] jetienne: tanepiper: you can do with with xinetd [18:19] ryah_: piscisaureus: hey [18:19] jetienne: hmmm not sure if http server is able to handle that tho [18:20] sh1mmer has joined the channel [18:20] jetienne: http://nall.com/tedx/2010/06/node-js-server-and-xinetd/ <- tanepiper this seems to be what you are looking for [18:20] ryah_: piscisaureus: https://github.com/ry/node/wiki/Building-node.js-on-mingw [18:21] eddanger has joined the channel [18:21] losing has joined the channel [18:21] piscisaureus has joined the channel [18:21] tanepiper: jetienne: i'll check it out [18:21] piscisaureus: ryah_: hey [18:22] piscisaureus: ryah_: will look at it later tonight, maybe try to get ssl going as well [18:22] creationix: ryah_: thanks [18:22] deedubs has joined the channel [18:23] tanepiper: micheil: i take it with your server you installed nodejs to /usr/local as root, hence the env settings? [18:23] deedubs: Are there any good nodejs redis ORMS or is the party line to roll your own? [18:23] ryah_: creationix: i'm sure there are some gotchas - but it wasn't terribly difficult for me to get it going [18:23] ryah_: creationix: cnsidering i never use windows [18:23] creationix: ryah_: lol, same here [18:23] ryah_: i had to modify my path to have python in it [18:24] micheil: tanepiper: hmm, not sure. [18:24] ryah_: which required opening some GUI dialog box [18:24] creationix: I haven't used windows as my machine since win98 [18:24] creationix: ryah_: good to know, thanks [18:24] piscisaureus: ryah_: it's more common to have problems getting git going in mingw-bash tho [18:24] ryah_: piscisaureus: i didn't get that working [18:24] piscisaureus: resolved the same way tho [18:24] creationix: git isn't required to compile though? [18:24] ryah_: i had to use git in a different window [18:24] piscisaureus: no no [18:25] piscisaureus: no need for git [18:25] Thorn has left the channel [18:25] creationix: I noticed the cygwin instuctions use git [18:25] creationix: which is fine I guess since it's easy to install there [18:25] piscisaureus: ryah_: can you pick this: https://github.com/piscisaureus/node/commit/27208a6960a141aa0b8403a83c3429faa0e5a65c [18:25] piscisaureus: it was the reason I banged my head against the wall yesterday [18:25] pagameba has joined the channel [18:25] wilmoore has joined the channel [18:26] piscisaureus: ryah_: maybe this as well, while we wait for it to be refactored: https://github.com/piscisaureus/node/commit/b46da59a746871a01edcb80eac8970c8ac7f607a [18:26] creationix: piscisaureus: are you aiming for mingw or msvc or both? [18:27] piscisaureus: creationix: I'm aiming for msvc [18:27] micheil: ryah_: by branch, did you mean my fork, or a branch on the main repo? [18:27] ryah_: piscisaureus: are you going to send this upstream? [18:27] piscisaureus: creationix: but it doesn't work there yet, and you shouldn't install msvc [18:27] ryah_: micheil: your fork [18:27] micheil: okay. [18:27] piscisaureus: creationix: installing msvc confuses waf and scons. [18:27] creationix: piscisaureus: no, I doubt I'll ever install msvc, but I will glady take the final binaries once it's done [18:28] creationix: I'll bet [18:28] piscisaureus: ryah_: I can try to push it upstream, but marc is really stubborn and doesn't really want to accept patches at all [18:28] jwcooper has joined the channel [18:28] ryah_: piscisaureus: yes, i know. but please try? [18:28] piscisaureus: ryah_: there is a much more obvious problem that I solved on windows and he doesn't even want to land that [18:29] kriszyp has joined the channel [18:30] CrypticSwarm has joined the channel [18:30] cloudhead has joined the channel [18:31] Druid_ has joined the channel [18:31] piscisaureus: ryah: ok i'll try. but I'm not happy to do a great deal of discussing with him. He'll probably just tell me I'm stupid and the such anyway. [18:32] piscisaureus: ACTION off to dinner now [18:33] creationix: ryah_: when installing mingw, that packages are needed? C++ compiler for sure, but what else [18:33] adambeynon: how can i alter the display names for functions in a error stack trace? [18:34] creationix: adam do they have a name now? [18:34] creationix: or are they all anonymous [18:34] creationix: adambeynon: ^^ [18:34] abraham_ has joined the channel [18:34] adambeynon: all anonymous [18:35] ryah_: creationix: python [18:35] creationix: ok, that easy, just give them names when defining them [18:35] tokumine has joined the channel [18:35] creationix: var myfun = function () {} -> var myfun = function namedFun() {} [18:35] creationix: ryah_: that's not part of mingw itself is it? [18:36] piscisaureu_ has joined the channel [18:36] adambeynon: thats the problem, i cant name them. they are the result of generated code and their names wont be known until runtime [18:36] ryah_: creationix: no [18:36] adambeynon: i thought there was a function.name property, but that doesnt seem to be fdoing it [18:36] adambeynon: doing* [18:36] mikeal: micheil: hey [18:36] jetienne: adambeynon: you want to display the names of functions, but you dunno what to name them ? bug :) [18:37] mikeal: on the linting front [18:37] micheil: mikeal: I heard the news about 4pm/. [18:37] creationix: adambeynon: there are ways, but not pretty [18:37] mikeal: shhh [18:37] jetienne: adambeynon: there is a arguments... not sure if it is in it [18:37] creationix: adambeynon: and you will lose any closures [18:37] CIA-99: node: 03Bert Belder 07master * r25d0e38 10/ (deps/libev/ev.c deps/libev/ev.h src/node_net.cc): (log message trimmed) [18:37] CIA-99: node: Workaround for libev handle caching bug on windows [18:37] CIA-99: node: The windows socket api uses handles, not fds. Libev caches the handle [18:37] mikeal: so [18:37] mikeal: on linting [18:37] mikeal: the dude at disqus, who I'm trying to find on github now [18:37] creationix: basically involves toStringing, string munging and re-compiling [18:38] mikeal: he is working with Paul Irish [18:38] mikeal: to fork jslint [18:38] mikeal: and modularize i [18:38] micheil: okay [18:38] mikeal: er it [18:38] mikeal: so you can turn on/off any check [18:38] micheil: sweet. [18:38] mikeal: and add new checks easily [18:38] creationix: modularized mikeal, that would be cool :P [18:38] ryah_: micheil: we've got a lint [18:38] micheil: I'll definitely use it over gjslint any day then. [18:38] ryah_: mikeal: i meant [18:38] mikeal: so, hopefully, we can describe different style guides in terms of options [18:39] jetienne: v8: (function wow(){}).name [18:39] v8bot: jetienne: "wow" [18:39] mikeal: ryah_: that's just for the core style guide, and it throws TONS of warnings about things you don't care about :) [18:39] jetienne: adambeynon: look my last v8 message [18:39] ryah_: mikeal: no, i just haven't updated it [18:39] piscisaureu_ has joined the channel [18:40] mikeal: so @antonkovalyov is doing the fork [18:40] mikeal: trying to find his github [18:40] adambeynon: jetienne: interesting.. just tried that, but it still prints them as anonymous in a stack trace :| hmmm. il keep trying, thanks though (Y) [18:41] micheil: mikeal: rule of finding people: most obvious: https://github.com/antonkovalyov/ [18:41] creationix: adambeynon: yeah, I don't think you can change the name of an existing function, only replace it with a new function [18:41] mikeal: https://github.com/jshint/jshint [18:41] mikeal: he created an account for the project tho [18:41] mikeal: so it was harder than it should have bene [18:41] micheil: https://github.com/jshint/jshint [18:41] micheil: damn. [18:41] micheil: >_> [18:41] jetienne: yuck [18:42] jetienne: i think it is impossible to write a clean parser :) [18:42] andrzejsliwa has joined the channel [18:44] mjr_ has joined the channel [18:44] Country has joined the channel [18:44] virtuo has joined the channel [18:44] adambeynon: oohh, Error.prepareStackTrace sorts the problem out [18:45] davglass has joined the channel [18:45] jetienne: adambeynon: how ? [18:45] perlmonkey2 has joined the channel [18:46] adambeynon: when it wants to print a stack trace, if you redefine that method, it gives you an array of all the functions, line numbers etc in the stack, and you return your own array of strings, so i can grab the .name properties there [18:47] adambeynon: http://code.google.com/p/v8/wiki/JavaScriptStackTraceApi [18:47] creationix: adambeynon: interesting, never heard of that [18:47] jetienne: adambeynon: good catch [18:47] astoon has joined the channel [18:48] creationix: the coffeescript guys need to hook into that [18:49] tjholowaychuk: creationix: you can implement __line with that + a global getter haha [18:49] tjholowaychuk: such a hack [18:49] tjholowaychuk: but neat [18:49] Ori_P has joined the channel [18:50] jetienne: i would love a _FILE_ _LINE_ [18:50] pyrotechnick: same [18:50] pyrotechnick: is it too slow? [18:50] Aikar: you mean __filename ? [18:50] pyrotechnick: well line [18:50] felixge has joined the channel [18:51] pyrotechnick: i guess [18:51] pyrotechnick: you could do like [18:51] pyrotechnick: line() [18:51] pyrotechnick: which throws, reads the stack etc [18:51] tjholowaychuk: __line is easy [18:51] Aikar: jetienne: __filename exists, just need __line [18:51] TheEmpath2 has joined the channel [18:51] tjholowaychuk: temporarily overriding captureStackTrace blah blah [18:51] pyrotechnick: yeah [18:51] jetienne: gnu even got _FUNCTION_ :) [18:52] pyrotechnick: u cud do that too [18:52] pyrotechnick: with TJs way [18:52] pyrotechnick: someone make a library [18:52] jetienne: _function too ? [18:52] pyrotechnick: yep [18:52] jetienne: _line and _function would be very usefull [18:52] mw has joined the channel [18:52] tjholowaychuk: yeah anything on CallSite [18:52] pyrotechnick: TJ have you done it anywhere [18:52] pyrotechnick: publically accessible [18:52] tjholowaychuk: a gist way back [18:53] tjholowaychuk: few months ago [18:53] pyrotechnick: on visionmedia? [18:53] tjholowaychuk: yeah [18:53] pyrotechnick: ill have a look [18:53] brianmario has joined the channel [18:54] tjholowaychuk: pyrotechnick: you can also have __stack to expose the stack and then implement __line with that [18:54] mnbvasd: can somebody help me with a problem, or tell me if there's no solution? [18:54] mnbvasd: https://gist.github.com/793708 [18:54] brapse has joined the channel [18:54] mnbvasd: I want to pass an array to a function, then split the array into arguments for another function to call.. [18:55] awenkhh has joined the channel [18:55] chrisdickinson: mnbvasd: function def(a, b) { cde[a].apply(cde, b); } [18:55] pyrotechnick: damn you have alot of gists TJ [18:56] Coal has joined the channel [18:56] tjholowaychuk: pyrotechnick: yeah good luck finding that lol [18:56] pyrotechnick: might have to write a search engine [18:56] mnbvasd: chrisdickinson: cool thanks, that's exactly what I was looking for :) [18:56] technoweenie has joined the channel [18:56] chrisdickinson: mnbvasd: no prob! [18:57] pyrotechnick: omg php tj [18:57] pyrotechnick: no wonder you write so much node [18:57] pyrotechnick: you have alot to make up for ;) [18:57] jetienne: https://gist.github.com/663919+ [18:57] jetienne: https://gist.github.com/663919 [18:57] evl has joined the channel [18:58] creationix: pyrotechnick: https://github.com/creationix/rack-php [18:58] CIA-99: node: 03Ryan Dahl 07master * r9e976ab 10/ (11 files in 2 dirs): lint - http://bit.ly/humFzM [18:58] pyrotechnick: that's nuts [18:58] pyrotechnick: cool but nuts [18:58] pyrotechnick: i like it [18:59] ryah_: mikeal: ---^ [18:59] danoyoung has left the channel [18:59] tjholowaychuk: pyrotechnick: woot, you found it [18:59] jetienne: pyrotechnick: make a clean documented lib out of it ? :) [18:59] pyrotechnick: i didnt find it [18:59] pyrotechnick: jetienne did [18:59] tjholowaychuk: oh lol [18:59] pyrotechnick: i was too busy trying to hack into github to delete your php gists [19:00] tjholowaychuk: i have php gists? [19:00] pyrotechnick: just one [19:01] pyrotechnick: but one is all it takes [19:01] pyrotechnick: to reveal your dark secret [19:01] jetienne: pyrotechnick: do you get the code ? "err.stack;" totally eludes me [19:02] mikedeboer has joined the channel [19:02] jetienne: oh got it. this is the getter calling itself [19:03] pyrotechnick: yes [19:03] pyrotechnick: it sets up __stack to call an override of catch sorta [19:03] pyrotechnick: forces a throw that's caught with the overrided catch [19:04] pyrotechnick: yeah these would be nice in a support lib [19:04] pyrotechnick: what's yours TJ? are you still devving it? [19:04] jetienne: pyrotechnick++ :) [19:04] farhadi has joined the channel [19:04] tjholowaychuk: pyrotechnick: nope, that was just an example [19:04] tjholowaychuk: I havent used it for anytihng [19:04] pyrotechnick: i mean you have a support lib [19:04] jetienne: pyrotechnick: maybe even in a console.stack or close [19:05] tjholowaychuk: you could improve console.trace() with something like that [19:05] ericnakagawa has joined the channel [19:05] ossareh has joined the channel [19:05] pyrotechnick: jetienne: i'm going to make a lil support lib in coffee with these few things, you can port it to js if you like [19:06] pyrotechnick: activesupport for JS, i'm sure there's others around, i've seen them, thought you had one TJ [19:06] tjholowaychuk: yeah i had something but I want to split it into smaller modules [19:06] tjholowaychuk: eventually [19:07] pyrotechnick: https://github.com/visionmedia/ext.js [19:07] creationix has left the channel [19:07] tjholowaychuk: weird, latest node console.log() fails to output the frames [19:08] virtuo has joined the channel [19:08] jdalton has joined the channel [19:08] pyrotechnick: it also fails to work against almost everyone of our projects because they all have repls ;( [19:09] pyrotechnick: although i much like the new API [19:09] pyrotechnick: node++ [19:09] v8bot: pyrotechnick has given a beer to node. node now has 1 beers. [19:09] bartt has joined the channel [19:10] Coal has joined the channel [19:10] arpegius_ has joined the channel [19:10] wkmanire has joined the channel [19:10] romainhuet_ has joined the channel [19:12] kiddphunk_ has joined the channel [19:12] niklasfi has joined the channel [19:12] dguttman has joined the channel [19:13] kiddphunk has joined the channel [19:13] niklasfi: i have a node program that does not create an httpserver. how can i keep it running so that it can wait for incoming events [19:14] evl has joined the channel [19:15] jetienne: niklasfi: ? wait for this event, in theory, node should not exit if you wait for an event [19:17] niklasfi: jetinenne: ok... what i am basically doing is piping an http.ClientResponse to an fs.writeStream ... this process is commonly known as downloading... but its not working until now... i will try some more [19:17] torgeir_ has joined the channel [19:17] maushu has joined the channel [19:18] torgeir_ has joined the channel [19:19] pyrotechnick: i'm mustering support for a disapora like social network in node if anyone's interested [19:19] joelklabo has joined the channel [19:19] Me1000 has joined the channel [19:19] admc has joined the channel [19:20] tjholowaychuk: pyrotechnick: have you tried it? looked like a huge fail [19:20] jdalton has left the channel [19:20] pyrotechnick: in terms of? [19:20] pyrotechnick: concept or implementation [19:21] micheil: niklasfi: try creating a http://gist.github.com of your code, that way you'll get more appropriate responses to your questions [19:21] tjholowaychuk: implementation [19:21] pyrotechnick: we have solutions for both ;) [19:21] maushu: Stop making social networks dammit! [19:21] cronopio has joined the channel [19:21] pyrotechnick: yeah it is a massive failure. have you seen the videos of the devs? [19:21] tjholowaychuk: nope [19:21] pyrotechnick: maushu: the world deserves better than facebook [19:21] pyrotechnick: tjholowaychuk: ill link you sec [19:21] niklasfi: micheil: thank you... i'm fine at the moment. will try around a bit. i will get back to you if i fail [19:21] micheil: pyrotechnick: making social networks is hard, so good luck with that. [19:21] pyrotechnick: i dont want to spam this channel with social networking or rants on diaspora so is there somewhere we can go? [19:22] pyrotechnick: thankyou micheil [19:22] pyrotechnick: we take a challenge and good luck in our stride [19:22] micheil: ACTION tried it once about 3 years ago. [19:22] pyrotechnick: ahh but you didn't have many things on your side 3 years ago [19:23] pyrotechnick: http://www.quora.com/Why-is-Diaspora-built-on-Ruby-on-Rails-instead-of-Node-js-which-is-way-faster [19:23] langworthy has joined the channel [19:23] pyrotechnick: i think any adept noder can refute all pro-rails arguments in this thread [19:23] chrisdickinson: totally out of curiosity, but is there a preferred proxy to run node/socket.io behind? (for instance, you couldn't use nginx if you wanted to support websockets) [19:23] pyrotechnick: nor apache for that matter [19:24] evanmeagher has joined the channel [19:24] pyrotechnick: chrisdickinson: i assume you mean something not written in node? [19:24] pyrotechnick: as a buffer to malformed requests? [19:24] pyrotechnick: as a security precaution? [19:24] chrisdickinson: pyrotechnick: basically. [19:25] pyrotechnick: the consensus, and it's been said by ry himself is that you do proxy it, that was a while ago and node has very much been in heavy production since then [19:25] tjholowaychuk has joined the channel [19:25] pyrotechnick: take palm/webos for example [19:25] pyrotechnick: but in saying that, to actually answer your question, perhaps something like squid? [19:25] chrisdickinson: pyrotechnick: thought so -- I had heard ry mention that it should be proxied to, for security concerns, hence the question [19:25] dgathright has joined the channel [19:25] pyrotechnick: i am simply not aware of any proxies that can in fact do websocket [19:26] pyrotechnick: which is interesting, it really shows how much node is progressing [19:26] pyrotechnick: it's moving so much faster than native dev [19:26] pyrotechnick: it's been hard for apache and nginx to keep up [19:26] chrisdickinson: i know there's one nginx module out there that adds support, I think [19:26] pyrotechnick: and i am convinced it will still be along time until they can support websocket let alone the other things that have come out of platforms like node [19:26] technoweenie has joined the channel [19:26] pyrotechnick: really? [19:26] niklasfi: micheil: have a look at https://gist.github.com/793773 and tell me what i am doing wrong [19:27] pyrotechnick: if there is we owe you one [19:27] sudoer has joined the channel [19:27] banjiewen has joined the channel [19:27] pyrotechnick: is there an ssjs channel? [19:27] micheil: niklasfi: uhhh... [19:28] chrisdickinson: pyrotechnick: perhaps I was hallucinating it. I'll look around a bit, though. [19:28] pyrotechnick: ok [19:28] pyrotechnick: anyway chrisdickinson are you looking to go into production ASAP? [19:28] pyrotechnick: or already there? [19:28] chrisdickinson: it'd be especially helpful in cases where there is already an established stack (say, django) [19:28] chrisdickinson: already there [19:28] pyrotechnick: it's really only a concern once you're in production [19:28] pyrotechnick: okay then you're quite happy to be at least initially running it raw in production? [19:28] pyrotechnick: but would rather it be proxied? [19:28] micheil: niklasfi: what do you get when running that? [19:28] chrisdickinson: pyrotechnick: yep. [19:29] pyrotechnick: chrisdickinson: try a "lighter" proxy rather than "webservers" like apache or nginx [19:29] pyrotechnick: so something actually tailored towards proxying [19:29] chrisdickinson: i've been running it raw alongside a django stack for a while now with no real problems, but it'd be nice to have an avenue for proxying. [19:29] niklasfi: micheil: the console outputs "Got response: 200" but nothing else. a file "file" is created but it is empty [19:29] pyrotechnick: it's only a problem when the proxy starts looking too deep into the communication where problems arise [19:29] micheil: hmm.. [19:29] micheil: odd [19:30] pyrotechnick: but in saying that, if the proxy isn't interrogating the traffic there's no point of running a proxy anyway [19:30] micheil: oh, wait. [19:30] richcollins has joined the channel [19:30] astoon has joined the channel [19:30] micheil: it's res.on("data") [19:30] micheil: not cr.on("data") [19:30] pyrotechnick: so essentially it will be until nginx/apache support websocket before you can get the benifits of running it behind them [19:30] pyrotechnick: you will gain some comfort from running behind a transparent proxy, but actually no security [19:31] pyrotechnick: i have worked for a few houses quite happy to run node in heavy production [19:31] pyrotechnick: one has 4 million clicks a day (adservers) [19:31] desaiu: where is the streams api? [19:31] pyrotechnick: desaiu: net? [19:32] pyrotechnick: http://nodejs.org/docs/v0.3.6/api/streams.html [19:32] pyrotechnick: http://nodejs.org/docs/v0.3.6/api/net.html [19:32] desaiu: oh i see [19:32] pyrotechnick: or do you mean the actual code? [19:32] desaiu: http://nodejs.org/api.html [19:32] pyrotechnick: yep [19:33] niklasfi: micheil: i thought there must be something odd [19:33] desaiu: hmm, sys.pump [19:33] desaiu: someone mentioned it just now [19:33] chrisdickinson: pyrotechnick: cool, thanks. I'm myself fairly comfortable running it raw, but I wanted to see if there was an avenue to proxying -- or at the least, if things have changed since last I had heard [19:33] desaiu: i'm listening to someone talk about node.js [19:33] micheil: niklasfi: minds you, you may be able to do: res.pipe(ws) [19:34] pyrotechnick: tjholowaychuk: http://www.kickstarter.com/projects/196017994/diaspora-the-personally-controlled-do-it-all-distr — this video and the whole project are sickening. they are immature to say the least [19:34] pyrotechnick: to take 200 000 from people and then bahave like that in a "thankyou" video is appalling [19:34] mraleph has joined the channel [19:35] niklasfi: micheil. that is what i intended in the first place, but i like the extra control. i can't keep track of download rates and completion status otherwise [19:35] micheil: niklasfi: okay :) [19:36] micheil: pyrotechnick: to be honest, I think diaspora may have been a hoax. [19:36] pyrotechnick: no it's happening [19:37] pyrotechnick: the dev is actually quite active [19:37] pyrotechnick: it's all on github [19:37] pyrotechnick: but it's all very unsound and ungrounded [19:37] niklasfi: micheil: and if you look at the code... pipe isn't doing that much magic either [19:37] pyrotechnick: i don't enjoy bashing other people's projects. i really dont. but i feel in this instance it's warrented [19:38] micheil: niklasfi: true, it just looks sexy. :P [19:38] tmzt: pyrotechnick: are they running it now? [19:38] pyrotechnick: in production? [19:38] Utkarsh has joined the channel [19:39] tjholowaychuk: wtf [19:39] tmzt: looks like haproxy is getting better ws support [19:39] pyrotechnick: i take it you watched the video [19:39] pyrotechnick: tjholowaychuk: ? [19:39] tjholowaychuk: haha [19:39] tjholowaychuk: yeah [19:39] pyrotechnick: they're a bunch of apes [19:40] pyrotechnick: it's just really disheartening, we are putting a project on kickstarter and i feel ashamed to have things like that on the same site [19:40] tmzt: pyrotechnick: if proxies cant do websocket whats this argument about it causing security problems with them? you mean reverse proxies specifically? [19:40] Coal has joined the channel [19:40] Aikar: tmzt: there is no security flaw in websockets in regards to proxies [19:40] pyrotechnick: tmzt: yeah, the proxies they speak of are not reverse proxies [19:40] pyrotechnick: they mean proxies run by ISPs [19:41] codetonowhere has joined the channel [19:41] pyrotechnick: i simply dont know enough to disclose the architecture of ISP proxies but they are not apache/nginx [19:41] codetonowhere has left the channel [19:41] Aikar: the flaw is that some implementations of transparent caching proxies are insecurely accepting data to cache without verifying it [19:41] pyrotechnick: i think they're more like cahcing/blocking/transparent proxies like squid [19:41] pyrotechnick: yep [19:41] Aikar: the flaw is 100% on the proxys side [19:41] pyrotechnick: but [19:41] pyrotechnick: if opera and mozilla were serious [19:41] farhadi has left the channel [19:41] pyrotechnick: they would remove java and flash [19:41] rburhum has joined the channel [19:41] pyrotechnick: they both have proxies and have the same vulnerabilities [19:41] pyrotechnick: it's an attack on websocket [19:42] pyrotechnick: it doesn't matter how much they try to twist the argument, it's an attack on websocket and i have no idea why [19:42] bmizerany has joined the channel [19:42] mjr_: I suggested that on the Mozilla blog, and nobody responded. [19:42] pyrotechnick: there's a very simple solution that was proposed even before the problem arised and it still hasn't been given serious consideration [19:42] Aikar: the flaw can be abused using _ANY_ TCP connection [19:42] Aikar: so did i [19:42] Utkarsh_ has joined the channel [19:43] pyrotechnick: yeah it's a complete joke. this is why we target chrome [19:43] pyrotechnick: they very rarely make decisions as silly as this [19:43] mjr_: Don't get me wrong, I think WS is pretty poorly designed, but it is so much better than long polling, and we need better web browser networking to do good realtime apps. [19:43] Aikar: anything that can initiate a TCP connection can abuse said flaw, websocket is just 1 implementation of a TCP stream [19:43] pyrotechnick: yeah [19:43] pyrotechnick: anyone who knows even the slightest bit about websocket knows all of this [19:44] pyrotechnick: and yet we have the tech companies making moves like this [19:44] mjr_: iOS even has WS now, which is amazing. [19:44] pyrotechnick: it's strange [19:44] awenkhh has joined the channel [19:44] Aikar: well really its almost a pure raw TCP stream, my only gripe is that they added framing to it which breaks being able to implement a TCP spec on your own IE IRC Client [19:44] pyrotechnick: IE? [19:44] Aikar: so performance wise its not bad, its only an extra 2 bytes [19:45] Aikar: and the header was designed that way so http servers could 'pass the connection along' to a another process like apache -> something else [19:45] mjr_: If they didn't put framing in, everybody would struggle to get framing right in JS, and it would lead to all sorts of tricky bugs. [19:45] pyrotechnick: it's almost as if they have made a pact with oracle and adobe to try and muffle "html5" [19:45] Kingdutch: What's with .md in the github? Why not just README files? [19:45] Aikar: mjr_: true, but imo an unframed version should of been added [19:45] pyrotechnick: Kingdutch: because there's many markup languages [19:45] mjr_: Kingdutch: you can put styling in markdown, which makes it look nice. [19:45] Aikar: Kingdutch: means markdown [19:46] Kingdutch: Aah ok thanks :) [19:46] pyrotechnick: yeah [19:46] Aikar: although githubs parser of markdown doesnt really match others :/ [19:46] CrabDude has joined the channel [19:46] pyrotechnick: it's github flavour [19:46] pyrotechnick: they say that quite clearly [19:46] Aikar: what looks good to me in markdown showdown doesnt look alright in github [19:46] Aikar: and the wiki even more so [19:46] pyrotechnick: i have found it to be almost a completely true superset [19:47] pyrotechnick: what's an example of something that's different? [19:47] mjr_: I guess in the end, the WS debate will resolve itself somehow, just like the video codec debate. [19:47] mjr_: Someone's agenda will succeed, and someone else's will fail. [19:47] Aikar: githubs own "live preview of markdown" doesnt match their github readme parser lol [19:47] ryah_: piscisaureus: we really got to clean up these ifdefs in src/node_net.cc [19:47] ryah_: it's really bad [19:47] mjr_: But eventually, we'll get both good video and good networking in web browsers. [19:47] micheil: pyrotechnick, mjr_, Aikar: for what it is worth: opera, chrome, chromium, and firefox are all disabling websockets for now. [19:47] pyrotechnick: what [19:47] ryah_: piscisaureus: i'll try to do someting about that today... [19:47] pyrotechnick: since when [19:47] Aikar: since when has chrome? [19:47] Aikar: still works for me [19:47] pyrotechnick: yeah since when man [19:47] micheil: this is the word from the lead evangelist at mozilla that I was talking to a few weeks ago [19:48] Aikar: i was thinking chrome was actually smart... [19:48] pyrotechnick: i use chromium nightlies [19:48] lucca_ has joined the channel [19:48] Aikar: only morons who dont know how to read are disabling websockets [19:48] mjr_: I thought Chrome said that they would consider disabling it if there were exploits in the wild. [19:48] micheil: or atleast, that is what's been said to me. [19:48] zachleat has joined the channel [19:48] lucca_ has left the channel [19:48] micheil: safari is also likely to disable it. [19:48] Aikar: it boils down to some exec receives a pdf saying "ZOMG I THINK WEBSOCKETS ARE INSECURE!" [19:48] pyrotechnick: micheil: sounds like a rumour bro, i'll believe it when chromium nightly disables them [19:48] stride: Aikar: a malicious pdf? [19:48] pyrotechnick: yeah [19:48] Aikar: and the exec panics and says 'disable it' w/o fully understanding the situation and realizing the entire PDF is wrong [19:48] pyrotechnick: with a rootkit in it [19:49] Utkarsh__ has joined the channel [19:49] wdperson has joined the channel [19:49] micheil: Aikar: not at all. The people doing this work are actually sensible and reasonable people. [19:49] Aikar: stride: no, some "security" guy released a "bulletin" stating websocket was insecure [19:49] pyrotechnick: that adobe pdf ready happily executes [19:49] tanepiper: pyrotechnick: nope, ff4 will have websockets disbaled by default [19:49] pyrotechnick: tanepiper: i didnt mention ff4 [19:49] tanepiper: you can change a flag to enable them, but it's not guarenteed [19:49] micheil: pyrotechnick: I tend to trust my source [19:49] Aikar: and some exec reads it and accepted it blindly [19:49] pyrotechnick: micheil: you may trust your source, i trust sourcecode [19:49] stride: Aikar: I know. that proxy BS.. that was more like a joke on the insecurities of PDF (viewers) [19:49] void_ has joined the channel [19:50] tlrobinson_ has joined the channel [19:50] tanepiper: or the client side, WebSocket was to be implemented in Firefox 4, Google Chrome 4, Opera 11 and Safari 5, as well as the mobile version of Safari in iOS 4.2.[1] However, although present, support is now disabled by default in Firefox and Opera, due to concerns over security vulnerabilities [19:50] pyrotechnick: right [19:50] micheil: as for the reasons, only part of it is due to that "insecurity" the other part is that they want to be able to fully flesh out and work out the protocol first [19:50] tanepiper: it's not a far stech to belive it'll be disabled in webkit too [19:50] micheil: this is in the best interests for developers [19:50] russ_nyc has joined the channel [19:50] lucca_ has joined the channel [19:50] pyrotechnick: they mention chrome inaccurately [19:50] tanepiper: at least socket.io has fallback [19:50] Aikar: i thought it was established already [19:50] pyrotechnick: tanepiper++ [19:50] lucca_ has left the channel [19:50] v8bot: pyrotechnick has given a beer to tanepiper. tanepiper now has 1 beers. [19:50] Aikar: nothing really wrong with the current format, it works [19:51] pyrotechnick: hooray for abstraction layers! [19:51] pyrotechnick: one has finally paid off [19:51] stride: screw fallbacks.. let's all do it more securely with silverlight.. [19:51] stride: :> [19:51] micheil: Aikar: the protocol has never left draft stages, it's never been ratified [19:51] pyrotechnick: yeah man [19:51] tanepiper: stride-- [19:51] v8bot: tanepiper has taken a beer from stride. stride now has 0 beers. [19:51] pyrotechnick: let's use activex [19:51] Aikar: ah [19:51] pyrotechnick: i think we should develop ie frame [19:51] stride: tanepiper: ;/ [19:51] tanepiper: stride: i knwo :p [19:51] pyrotechnick: an extension for safari, webkit, chrome, firefox [19:51] stride: tanepiper: hmkay ;) [19:51] pyrotechnick: that lets you run activex [19:51] pyrotechnick: that way we can edit the registry from our webapps [19:52] micheil: pyrotechnick: sounds like you're filling up your plate quite quickly [19:52] pyrotechnick: and install rootkits [19:52] Aikar: but disabling it still sucks, it just keeps firefox behind chrome [19:52] Aikar: you guys dont have him on ignore? [19:52] pyrotechnick: good. [19:52] pyrotechnick: Aikar: drop it mate. [19:52] zachleat: Anyone running a new tag of node.js in Cygwin? Having trouble with v0.3.5 and v0.3.4, wondering how far back I should try [19:52] pyrotechnick: dont start this again [19:52] Utkarsh_ has joined the channel [19:53] GasbaKid has joined the channel [19:53] Aikar: zachleat: try master? i saw some commit about windows today [19:53] jesusabdullah: zachleat: I'd help you if I could, but I'm a lennox guy [19:53] Coall has joined the channel [19:53] pagameba: anybody around that understands node-seq? [19:53] tanepiper: who remembers activex on the desktop ..... MS's worst idea [19:53] Fandekasp has joined the channel [19:53] pyrotechnick: tanepiper: active wallpapers thing? [19:53] tanepiper: pyrotechnick: yea [19:53] Aikar: im going to make a blog post about getting ubuntu setup with virtualbox and installing node soon >< [19:53] pyrotechnick: man those were rad [19:53] zachleat: The github docs say that master usually fails, but I'll try it [19:53] ryah_: zachleat: 0.3.1 [19:54] romainhuet has joined the channel [19:54] aheckmann has joined the channel [19:54] Aikar: usually fails? [19:54] tanepiper: the implementation was horrible tho [19:54] ryah_: i'll boot into windows today and port cygwin [19:54] Aikar: ryah_: lol does docs say that? [19:54] fission6 has joined the channel [19:54] pyrotechnick: tanepiper: no way man. ieframe all the way [19:54] Aikar: masters never failed me [19:54] fission6: looks like https is supported again? [19:54] zachleat: "It is recommended you checkout a stable tag since most of the time building master fails." https://github.com/ry/node/wiki/Building-node.js-on-Cygwin-(Windows) [19:54] Aikar: i dont think ryan commits broken code >_> [19:54] ryah_: but i feel this is annoying. windows people should port thier own softwrae [19:55] pyrotechnick: ryah_: we liked it better when you supported unix and only unix [19:55] tanepiper: ryah_: no one should run servers on Windows [19:55] stride: ryah_: while you're at it, port cygwin to run on linux.. [19:55] Aikar: ryah_: imo should just drop windows support so you can focus more on the real world production OS's :P [19:55] tanepiper: also: VM's [19:55] zachleat: Well, it isn't a huge deal, just wanted to play around with it on my work box [19:55] stride: like Mac OS.. [19:55] stride: :D [19:55] pyrotechnick: it's unanimous [19:55] fission6: anyone confirm the https [19:55] mjr_: Getting node to run well on Windows would be really helpful for node. LOTS of people run Windows. [19:55] pyrotechnick: fission6: yes, it's been working a while [19:55] mjr_: But yeah, I'd be happier with good HTTPS. [19:55] Aikar: i wouldnt consider Mac a "production OS" either but i wouldnt advise dropping support since it is at least nix based :P [19:56] stride: I should stop making jokes today.. [19:56] bradleymeck: *nix compatible [19:56] Aikar: mjr_: yeah and those 'lots of people' can run a VM or get into a VPS and do development on a proper environment [19:56] tanepiper: mjr_: really the only advantage would be doing something like titanium/air on the desktop, IIS is a joke [19:56] fission6: pulling latest code, so i guess we'll see thanks! [19:56] pyrotechnick: stride: yeah you dont want Aikar to mute you [19:56] skampler: i hear bacon is now production ready [19:56] Aikar: im a windows user, but i have VM's and full dedicated boxes to use :) [19:57] pyrotechnick: it makes perfect sense now [19:57] Evet: socket.io \o/ [19:57] malkomalko has joined the channel [19:57] pyrotechnick: DNode \o/ [19:57] mjr_: There are tons of devs that have Windows laptops running Apache, PHP, and MySQL so they can deploy on Linux. [19:57] tanepiper: DNOE! [19:57] tanepiper: *DNODE [19:57] ryah_: bert is doing a great job of getting a real windows port [19:57] pyrotechnick: THREE CHEERS FOR DNODE [19:57] tanepiper: man, my keyboard is sucking tonight [19:58] ryah_: we should just drop cygwin support [19:58] pyrotechnick: ryah_: YES! [19:58] mjr_: yeah, cygwin is a disaster [19:58] pyrotechnick: ryah_: you never even wanted it. you said it many times. you just caved into the sheeple [19:58] torgeir__ has joined the channel [19:58] pyrotechnick: ryah_: we understand why. it's alot of pressure [19:58] CIA-99: node: 03Ryan Dahl 07master * rcc5e913 10/ src/node_file.cc : fs.open should set FD_CLOEXEC - http://bit.ly/dWM67Q [19:58] pyrotechnick: but do the right thing for node [19:59] pyrotechnick: at the end of the day. windows can be posix compliant [19:59] pyrotechnick: that's a better avenue to persue than direct or indrect (cygwin) support [19:59] mjr_: Or Windows can be Windows, and just have a node port. [19:59] Ori_P has joined the channel [20:00] tanepiper: port windows to node [20:00] pyrotechnick: just keep buying macs, using linux, playing cross platforms games etc [20:01] pyrotechnick: making sane decisions... [20:01] bingomanatee: I used to develop on Windows but it was too damn easy so now I develop on my PSP [20:02] jherdman has joined the channel [20:02] matjas has joined the channel [20:02] pyrotechnick: bingomanatee: i dev on my atari ST [20:02] bingomanatee: The stylus makes all the difference. [20:02] bingomanatee: You're too young to have an Atari. [20:02] pyrotechnick: no, i'm not [20:02] bmizerany has joined the channel [20:02] pyrotechnick: atari ST was my first computer [20:03] bingomanatee: 'dyou inherit it? [20:03] jmartin has joined the channel [20:03] andrzejsliwa has joined the channel [20:03] tanepiper: real men develop on Altairs [20:03] lukegalea: my first was a COCO 2.. (Radio Shack variant of TRS-80) [20:03] stephank has joined the channel [20:04] pyrotechnick: bingomanatee: yes i did, they were around 4 years before i was born but they had a very long life [20:04] balaa: cloud9ide.com [20:04] pyrotechnick: balaa that still needs to run node [20:04] lukegalea: but re: windows - I dunno, it seems everywhere I look it seems everyone is bending over backwards to support windows. Why not just provide a vagrant image for windows users? [20:04] balaa: real men develop in the cloud [20:04] lukegalea: It'll still be smaller than a visual studio install. [20:05] pyrotechnick: balaa you still need POSIX under cloud9 [20:05] xSmurf: could9 from smoggy space? [20:05] tanepiper: the problem with cloud9, can't develop from private repos :( [20:05] tanepiper: at least the hosted one [20:05] pyrotechnick: hack it [20:05] balaa: sorry i jumped onthe end of this discussion what was the constraint in this context? [20:05] pyrotechnick: windows [20:05] tanepiper: pyrotechnick: on local it's not a problem [20:05] pyrotechnick: ryah is considering dropping cygwin support [20:06] bingomanatee: DO IT! [20:06] bingomanatee: for gods sake. [20:06] pyrotechnick: he will [20:06] bingomanatee: it just a time sink. [20:06] pyrotechnick: he knows that [20:06] pyrotechnick: he knew it all along [20:06] pyrotechnick: he said it over and over and put it on the site and everything [20:06] pyrotechnick: he just got sick and tired of the windows crowed accosting him [20:06] bingomanatee: no s**t. [20:07] pyrotechnick: i can just imagine what his inbox looks like [20:07] jmar777 has joined the channel [20:07] bingomanatee: BTW am indexing the IRC logs - it takes like 2 hours to wordindex all the backlogs but Noogle is basically working. [20:07] tanepiper: bingomanatee: release it already [20:07] bingomanatee: The only part I need to finish is to extend a single hit into a conversation and to lock the maintenance stuff behind a user login. [20:07] pyrotechnick: anyone in their right mind would tire of it, and just want to shut them all up and add cygwin support but IMHO it was the wrong thing to do for node [20:08] bingomanatee: Its checked in but I plan to put it online in the next 48 hours. [20:08] svenlito has joined the channel [20:08] niklasfi: where in the doc is the part about the console module [20:08] pyrotechnick: noogle lol [20:08] pyrotechnick: you're going to get sued david [20:08] russ_nyc: hi all, i am having a problem cloning the expresso project. is there anything special that needs to be done? [20:08] pyrotechnick: niklasfi: util [20:08] _jdalton has joined the channel [20:08] bingomanatee: by who, getscape? [20:09] _jdalton has left the channel [20:09] zachleat: 0.3.1 worked in Cygwin, thanks ryah [20:09] pyrotechnick: call it face [20:09] pyrotechnick: see if facebook can actuall sue people [20:09] bingomanatee: nope - already boot noogle.io [20:09] tanepiper: David Hasselhoff is now following you on Twitter! [20:09] tanepiper: OH MAN, MY DAY HAS BEEN MADE! [20:09] balaa: bingomanatee: whats noggle [20:09] balaa: noogle [20:09] pyrotechnick: google [20:09] pyrotechnick: in node [20:09] bingomanatee: noogle. I'm search-indexing these chat logs. [20:10] niklasfi: pyrotechnick: but why can i call console.log but i have to call util.debug? [20:10] bingomanatee: Its a spider framework targeting these IRC logs. [20:10] pyrotechnick: niklasfi: are you using coffee? [20:10] balaa: link? [20:10] bingomanatee: Not online yet. [20:10] niklasfi: pyrotechnick: no. [20:10] pyrotechnick: niklasfi: it must be a deprecated API maybe [20:10] pyrotechnick: niklasfi: that or console will always remain [20:10] pyrotechnick: ask ryah_ [20:11] niklasfi: pyrotechnick: http://nodejs.org/docs/v0.3.6/api/util.html#util.debug [20:11] pyrotechnick: i am aware of util yes [20:11] pyrotechnick: console if a bit of a special case, it's documented in the globals section i think [20:11] pyrotechnick: let me find it [20:11] bingomanatee: pyrotechnick: if I grabbed a noogle.com domain I might be concerned - but its going to have clear branding and its a much smaller scale operation. [20:11] pandark_ has joined the channel [20:12] MikhX has joined the channel [20:12] pyrotechnick: bingomanatee: i was joking. they cant sue you [20:12] bingomanatee: I might grab bing's branding just to be ironic [20:12] bingomanatee: Anyone can sue anyone. [20:12] pyrotechnick: ning lol [20:12] pyrotechnick: it wont be a damages case itll just be a cease and desist letter man [20:12] jherdman has joined the channel [20:12] bingomanatee: Keep in mind that a lawsuit is like a bullet. You don't always shoot to kill - sometimes you just shoot to influence people's decision making process. [20:12] pyrotechnick: i doubt theyd do it [20:13] pyrotechnick: i like you're similes [20:13] pyrotechnick: you're a good poet [20:13] bingomanatee: Its like the WikiLeaks thing - Julian Assange (sp?) never was in purely legal jeapordy but by dragging him into the court the US government reframed the debate. [20:13] bingomanatee: (or by having him drug in) [20:14] Qbix1 has joined the channel [20:14] pyrotechnick: niklasfi: i see your point, it is undocumented. which is strange since it's used in every second example in the docs [20:15] bingomanatee: Legal hazards and scale are always a concern in Silicon Valley. There is a lot of spurious legal action here - often its a bout a big fish trying to wear out a small fish and make them weaker and easier to take over. [20:15] pyrotechnick: that's so unaustralian [20:15] stepheneb has joined the channel [20:16] bingomanatee: You're lucky. Courts have long since been a political or corporate bludgeon in the US. [20:16] pyrotechnick: niklasfi: what were you wondering exactly? just if it was official API? [20:16] bingomanatee: Its unfortunate. [20:16] pyrotechnick: you gotta be feisty man [20:16] bingomanatee: or too small to fail. [20:17] pyrotechnick: that's what it means ;) [20:17] pyrotechnick: they cannot take what you "do not have" [20:18] pyrotechnick: hell we dont even have a website ;) [20:18] niklasfi: pyrotechnick: i was asking myself how to output to stderr. and then i thought that it must certainly have something to do with the console object [20:18] mdoan has joined the channel [20:18] pyrotechnick: niklasfi: process.stderr.write [20:18] jengstrm has joined the channel [20:18] niklasfi: pyrotechnick: util.debug() [20:19] pyrotechnick: niklasfi: console.debug will work, but it's undocumented and blocking [20:19] pyrotechnick: same with util.debug [20:19] pyrotechnick: it's docced but blocking [20:19] pyrotechnick: better to use the streams [20:19] bingomanatee: by the way https://gist.github.com/793878 is the word frequency count of the IRC channel. Still need a better stopword filter but still, pretty cool. [20:19] virtuo has joined the channel [20:20] niklasfi: pyrotechnick: i am not really using node for performance reasons. I just like the style of programming... so i don't care for one blocking call.. actually the idea of writing to stderr is that it is blocking [20:20] pyrotechnick: lol @ ryah [20:20] pyrotechnick: where is "node" [20:20] russ_nyc: tjholowaychuk: regarding expresso, it seems that if i have 2 async exports, only the first one will run. is there a way around this? [20:21] pyrotechnick: bingomanatee: really? node is said 2000 less times than ryah? [20:21] pyrotechnick: bingomanatee: are you rooting things like ryah_ to ryah? [20:22] pyrotechnick: stemming or whatever it's called [20:22] pyrotechnick: tokenizing even [20:23] baoist has joined the channel [20:24] niklasfi: pyrotechnick: console.debug does not work for me Object # has no method 'debug' [20:24] pyrotechnick: yeah i may have made a mistake with that [20:24] pyrotechnick: i meant utils [20:24] bingomanatee: The words are not stemmed [20:24] pyrotechnick: anyway util.debug is blocking if that matters to you, use the streams [20:25] pyrotechnick: process.stderr.write [20:25] pyrotechnick: that's the "node" way [20:25] bingomanatee: they are /[\w]*/ filtered. [20:25] pyrotechnick: is _ in \w? [20:25] pyrotechnick: i cant rememeber [20:25] bingomanatee: I think so. [20:25] bingomanatee: I am only using simple word indexing in mongodb [20:26] Evet: bingomanatee: use tokyo cabinet for word indexing [20:26] bingomanatee: interesting [20:26] pyrotechnick: yeah \w includes _ [20:26] niklasfi: pyrotechnick: i am sorry to report that ther is no stderr in process [20:26] pyrotechnick: argh really? [20:27] niklasfi: pyrotechnick: http://nodejs.org/docs/v0.3.6/api/process.html [20:27] niklasfi: and it does not work either [20:27] piscisaureus: ryah_: creationix: https://github.com/ry/node/wiki/Building-node.js-on-mingw [20:27] piscisaureus: did I forget anything? [20:27] piscisaureus: ryah_: what will you do about the ifdefs? [20:27] pyrotechnick: haha piscisaureu_ now is a bad time to be talking windows support [20:27] zomgbie has joined the channel [20:28] pagameba: is using 'global' to store a configuration object or database connection that several modules will need considered good practice? [20:29] wdperson has joined the channel [20:29] piscisaureus: pyrotechnick: why? [20:29] pyrotechnick: read ^^ [20:29] pyrotechnick: when ryah_ was talking [20:30] pyrotechnick: im not sure if he was referring to just cygwin or mingw too or windows in general [20:30] piscisaureus: pyrotechnick: bert is doing a great job of getting a real windows port [20:30] piscisaureus: is that what u mean :-) [20:30] pyrotechnick: yeah [20:30] pyrotechnick: like a port port [20:30] pyrotechnick: not support for windows in node [20:30] trotter has joined the channel [20:30] pyrotechnick: but a port port [20:31] piscisaureus: and what makes mingw different from a port port? [20:31] pyrotechnick: as in [20:31] bingomanatee: Anyone have a good stemming library in JavaScript? [20:32] piscisaureus: pyrotechnick: as in ... ? [20:32] bingomanatee: I will probably bring lucene into the picture sooner or later [20:33] bingomanatee: Well how to recude plurals / tense to their canonical form [20:33] bingomanatee: singing == sings >> sing [20:33] pyrotechnick: as in i dont know ask ryah, he said "dropping windows" whatever that means to mingw and cygwin "ports" [20:33] pyrotechnick: dont really know enough to say [20:33] bgilbert has joined the channel [20:33] piscisaureus: pyrotechnick: cygwin is a posix emulation layer on windows. mingw is gcc for windows [20:34] bingomanatee: I think if you just built up no.de and documented it so it doesn't confuse people you'd be good. [20:34] piscisaureus: cygwin sucks, on that we all agree. [20:34] desaiu: http://pastebin.com/Gkmrg1As that is the output i get, this is the file it references: http://pastebin.com/RtyjLZX4 I'm not seeing what's wrong. [20:35] aklt has joined the channel [20:35] pyrotechnick: bingomanatee: i think the consensus is that you use sphinx [20:35] pyrotechnick: bingomanatee: node adapter https://github.com/kurokikaze/limestone [20:35] bingomanatee: I say make the official position: "We are sticking to the 'smart people' platform and will put node on the 'stupid people' platforms when we're done with it." [20:36] desaiu: i changed pastevar to var [20:36] pyrotechnick: bingomanatee: im glad you said that and not me [20:36] desaiu: still no luck [20:36] pyrotechnick: Aikar: he's being a troll. quick. mute him! [20:36] desaiu: i'm stupid [20:36] pyrotechnick: no desaiu [20:36] desaiu: probably the dumbest guy here [20:37] pyrotechnick: no man [20:37] derferman has joined the channel [20:37] bingomanatee: What do I have to worry about? It's not like there's a search engine out there that will make me accountable for my statements on the IRC channel.... [20:37] pyrotechnick: you' [20:37] pyrotechnick: lol [20:37] pyrotechnick: you should write a procedure [20:37] bingomanatee: Although once noogle is up we can rank members by smart comments ... stupid comments [20:37] pyrotechnick: called hates() [20:38] pyrotechnick: hates('pyrotechnick', 'php') [20:38] pyrotechnick: and if i've said i hate it [20:38] pyrotechnick: then it returns true [20:38] pyrotechnick: but yeah bingomanatee check out sphinx [20:38] bingomanatee: I tend not to get emotionally charged about inanimate objets. [20:38] bingomanatee: I will. [20:39] pyrotechnick: it's basically a full-text search server, nothing else [20:39] bingomanatee: Once the basic version is up and running a DB upgrade is definately something I want to move towards. [20:39] pyrotechnick: well i mean [20:39] bingomanatee: Also looking at Solr. [20:39] pyrotechnick: instead of going for stemming in node [20:39] pyrotechnick: let something like sphinx handle that all for you [20:39] niklasfi: pyrotechnick: and even worse: console.log and util.log have different meanings [20:39] pyrotechnick: it's just a matter of giving sphinx the bodies, it's not a complete rewrite [20:40] bingomanatee: Yeh the only reason to JS stem is that I'm using the worst possible repo when it comes to text searches. Honestly - even MySQL would have been a better choice. [20:40] pyrotechnick: niklasfi: yes it's been a very painful beginning for node. i am confident those things will be smoothed out [20:40] pyrotechnick: there'll be a way to write to stderr via a stream [20:40] desaiu: aha, missing a comma [20:40] bingomanatee: oh it is a stream -- it just doesn't BEHAVE like a stream. [20:40] bingomanatee: :D [20:41] pyrotechnick: it's not exposed to node [20:41] bingomanatee: we'll get there. [20:41] pyrotechnick: as far as we can tell [20:41] kjeldahl has joined the channel [20:41] bmavity has joined the channel [20:41] pyrotechnick: only util.debug can write to stderr [20:41] niklasfi: pyrotechnick: i know... i have been following the project from very early on. i just thought there might be people out there who have not noticed this [20:41] pyrotechnick: as far as things are documented [20:41] pzich has joined the channel [20:42] bingomanatee: There are a lot of areas where the node implementation of low - level system metaphors is not perfect - the best we can do at this point is try not to depend on the few areas that just don't operate as one would hvae them. [20:42] pyrotechnick: no the best thing is to submit pull requests [20:42] pyrotechnick: what you suggest is the second best [20:43] bingomanatee: ACTION satisfies his own pull requests [20:43] pyrotechnick: haha [20:43] bingomanatee: gotta go TTYL [20:43] pyrotechnick: nobody needs your filth anyway [20:44] margle has joined the channel [20:45] omid has joined the channel [20:45] wkmanire has left the channel [20:46] fission6 has joined the channel [20:46] fission6: do i have to explicitly use https or can i use http and pass in a security flag - i think this is how it once was [20:46] fission6: for createClient [20:49] orospakr has joined the channel [20:49] orospakr: Hi! Is there a nodeish way to pretty-print a javascript object? [20:49] orospakr: ah, util.inspect() [20:49] orospakr: heh. [20:49] Aikar: orospakr: or console.dir [20:50] fission6: can probably use a json module too [20:50] jimt has joined the channel [20:50] Aikar: console.log also works for low depth [20:53] jbwiv_ has joined the channel [20:54] ericnakagawa has joined the channel [20:54] fission6: do you need to use https explicitly in the latest https support, it looks like http.createClient doesnt have a secure flag [20:54] niklasfi: when using fs.createWriteStream, can i pass length and position in the options? [20:56] matjas_ has joined the channel [20:57] jimt_ has joined the channel [20:57] hellp has joined the channel [21:01] creationix has joined the channel [21:02] jimt has joined the channel [21:02] brianmario has joined the channel [21:03] Aikar: fission6: there is a new https class [21:03] djanowski: mde: ping [21:05] fission6: right so no longer do i want to use http.createClient(...,secure) i need to explicitly use https [21:07] micheil: niklasfi: perhaps. [21:07] aklt has joined the channel [21:08] ericnakagawa has joined the channel [21:08] cloudhead: fission6: yes [21:08] cloudhead: and the API is different too now [21:08] cloudhead: you use https.request() [21:09] ericnakagawa has joined the channel [21:09] cloudhead: createClient doesn't work the same [21:09] matjas_ has joined the channel [21:09] mediacoder: ryah_: hehe .. i was about to clean up the wikipages .. there are so many duplicated, empty or outdated things (unfortunately there is no pull-request for wikis [21:09] jdalton has joined the channel [21:10] tanepiper: micheil: great news! [21:10] micheil: it is! [21:10] bpedro has joined the channel [21:12] Jungian has joined the channel [21:12] Jungian: How would one go about running php from node.js? [21:12] torgeir_ has joined the channel [21:13] lukegalea: Jungian: you could just launch a process and call it from there.. via spawn. [21:13] ajashton has joined the channel [21:13] Jungian: Javascript's ability to embed code in HTML is very useful for putting together structure in a flexible way. [21:13] piscisaureus: Jungian: run php using require('child_process'). Look for something like node-cgi or node-fastcgi [21:13] Jungian: I've been using exec, but it's probably pretty slow. [21:14] piscisaureus: * spawn [21:14] piscisaureus: Jungian: spawn could be slightly faster because it doesn't buffer the output, it just emits data events [21:14] Jungian: So that's executing the php process every request. Seems bad. [21:14] piscisaureus: but it's about as good as it gets [21:14] piscisaureus: Jungian: what do you think apache does? [21:15] Jungian: fast_cgi could work [21:15] Jungian: piscisaureus, loads PHP as a module? [21:15] ROBOTARMY has joined the channel [21:15] piscisaureus: yeah, that's true, though in most configurations it's spawned like a child process [21:15] ryah_: mediacoder: i think you can just edit them? [21:16] Jungian: I'm writing a web server in node.js as a personal experiment that I'm going to throw up on github / Google Code [21:16] mediacoder: yea, but i think its easier to do it locally and push to it, like to a normal repository..atleast for me its much simpler [21:16] piscisaureus: Jungian: because mod_php has security issues, it has to run with the same privileges as apache itself [21:16] willwhite has joined the channel [21:17] Jungian: I want the web server to serve .html and .php files async [21:17] mediacoder: ryah_: i think i cant delete pages.. in the repository, i can (for example, duplicate or outdated pages) [21:17] piscisaureus: ACTION ponders why his university has blocked the libev mailing list [21:18] Jungian: How do you serve a binary like a .png file? Does the fs module allow that? I'd need to set a certain header with response and some hwo write the binary data [21:18] lukegalea_ has joined the channel [21:18] piscisaureus: Jungian: www.nodejs.org [21:19] altamic has joined the channel [21:20] Ond has joined the channel [21:20] Jungian: Where would I look for a binary response.write()? [21:20] piscisaureus: stuff a buffer in there [21:20] niklasfi: Jungian: response.write is by default binary [21:20] micheil: response.write(Buffer, "binary") [21:20] micheil: or, yeah, as niklasfi says [21:21] Jungian: So I just need to get the Buffer from fs? [21:21] Jungian: I've done this for text files [21:21] piscisaureus: which it will, by default [21:21] Jungian: But response.writeHead() will need to have a header to tell the browser what it is [21:21] Kingdutch: Anyo f you knew about node tuts on dailyjs.com? I foudn them through some other tuts but they look nice :) [21:21] niklasfi: michelli: i actually once got errors because i specified "binary" on a binary file. it worked without the "binary" option [21:21] piscisaureus: ryah_: my best bet: http://lists.schmorp.de/pipermail/libev/2011q1/001288.html [21:22] Kingdutch: ryah_: IF not already, I wanna suggest http://dailyjs.com/2010/11/01/node-tutorial/ as extra tutorial material for newcomers [21:22] skampler has joined the channel [21:23] micheil: or, create in new Buffer() check the documentation: http://nodejs.org/docs/v0.3.6/api/buffers.html [21:23] Jungian: Does node.js have a way to grab port 80 as root, then demote itself? [21:23] lukegalea: Jungian: you can use authbind [21:24] micheil: Jungian: short answer: not really [21:24] mikeal has joined the channel [21:24] micheil: there is: http://nodejs.org/docs/v0.3.6/api/process.html#process.setgid [21:24] Jungian: lukegalea, so that will listen on the port and then when a client connects, it fires up node.js to handle it? [21:24] Jungian: micheil: interesting. [21:24] slickplaid: any reason not to use a reverse proxy (nginx, squid, apache) for that job of port 80? and just redirect traffic to the unprivledged port that nodejs uses? [21:25] micheil: as to the practicality and security of it, I've not used it. [21:25] micheil: slickplaid: websockets? [21:25] slickplaid: websocket delcaration of the port is uses is in the javascript so it shouldn't matter at all afaik [21:26] slickplaid: reverse proxy serves up the data, client sees it needs to connect to X port for websockets and does so [21:26] micheil: most reverse proxies break on websockets [21:26] slickplaid: the websocket bypasses the proxy though, it never touches it [21:26] micheil: websockets often run on :80 along side the standard http data [21:26] Kingdutch: Jungian: Just sudo run your node.js file, in your file just use the process.setpid('nobody'); and process.setgid('nobody'); to move down to lower abilities [21:27] slickplaid: oh, i always set mine to something else [21:27] zilt has joined the channel [21:27] micheil: :) [21:27] slickplaid: that would be why :D [21:27] lukegalea: Kingdutch: that's a good idea. I was just running: "authbind --deep spark2 -p 80 blah.js" [21:27] Kingdutch: Jungian: Alternatively give some config options to run as a certain user [21:28] lukegalea: then you don't need sudo access, but authbind needs to be configured to allow that user access to that port. [21:28] Kingdutch: lukegalea: It's how I solved it for my port 80 thing, I think that's the easiest way to do it (Dunno if it's the best, but it hasn't failed me yet) [21:28] Kingdutch: Right ok, never heared of it [21:28] micheil: ACTION currently just runs node with a umask of 007 [21:28] Kingdutch: o.o [21:28] Kingdutch: oh [21:30] davglass has joined the channel [21:31] yhahn has left the channel [21:31] mscdex: 007! [21:31] mscdex: bond.js [21:32] mscdex: with the 'js' being short for james [21:33] stephen_mcd has joined the channel [21:33] Jungian: mscdex lol [21:34] willwhite has joined the channel [21:34] andrzejsliwa has joined the channel [21:39] losing_ has joined the channel [21:39] jimt has joined the channel [21:41] Qbix1 has joined the channel [21:42] richcollins has joined the channel [21:42] desaiu: mikeal: just finishing your talk @ jsconf.eu, thank you. [21:45] admc has joined the channel [21:47] ezmobius_ has joined the channel [21:47] jherdman has joined the channel [21:47] NemesisD has joined the channel [21:48] NemesisD: any express or connect users here? i'm trying to figure out how to rig staticProvider to serve static files from multiple dirs [21:48] bradleymeck: ACTION flops [21:49] tjholowaychuk: NemesisD: multiple staticProviders is fine [21:52] hunterloftis has joined the channel [21:52] yozgrahame has joined the channel [21:54] hunterloftis: tjholowaychuk: Debugging some jade. "Unexpected identifier" at Object.Function, unknown source, pretty large .jade, no idea which line is causing the issue - any tips other than copy paste parts out of the file? [21:54] tjholowaychuk: hm [21:54] tjholowaychuk: can I see a stack trace? [21:54] hunterloftis: coming right up [21:55] jdalton has left the channel [21:55] mjr_: We are headed for a 500 person channel. That's pretty amazing. [21:56] hunterloftis: http://pastebin.com/7agiT8cL [21:58] hunterloftis: tjholowaychuk: Just edited the line, I'm gonna log the function jade is creating, should be obvious what's up [21:58] dekz has joined the channel [21:58] tjholowaychuk: hunterloftis: yeah that will give you a better idea, debug: true might do that for you [21:58] tjholowaychuk: i cant remember [21:59] hunterloftis: Already got debug: true on (that's where that buffer stuff is from) [21:59] tjholowaychuk: syntax errors are hard to report on [21:59] tjholowaychuk: well real syntax errors [22:00] tlrobinson__ has joined the channel [22:01] hunterloftis: tjholowaychuk: Oh damn, this is hard to figure out too - huge function [22:01] Athox has joined the channel [22:01] tjholowaychuk: unfortunately there is not much i can do with them [22:02] mikedeboer has joined the channel [22:04] jimt has joined the channel [22:04] matjas has joined the channel [22:05] Kingdutch: Good night folk [22:05] colinclark has joined the channel [22:05] Kingdutch: s [22:05] dylang has joined the channel [22:06] dylang: No.de question: What's the correct way to upgrade the version of node used in ssh and npm? [22:08] hunterloftis: tjholowaychuk: Yeah that makes sense; generated code is always hard to debug [22:08] Me1000 has joined the channel [22:08] springify has joined the channel [22:08] hornairs has joined the channel [22:09] konobi: dylang: isaacs is your man there [22:10] hunterloftis: tjholowaychuk: Do you think this might be confusing it? ==> div('data-bind'='template: {name: "commentsTemplate", data: comments}') [22:10] hunterloftis: When I lint the function it spits out, I get an unterminated string literal, although I don't see it myself [22:10] joelklabo has joined the channel [22:10] tjholowaychuk: hunterloftis: probably, it gets a little messed with splitting on ':' [22:11] hunterloftis: tjholowaychuk: Ah that's right, I'll just convert to = [22:11] tjholowaychuk: some day when I have time I will have to go through and actually parse js expressions [22:11] hunterloftis: Or something. I'm trying to use KnockoutJS which will require the : [22:12] fission6 has joined the channel [22:12] Mike_Rice has joined the channel [22:12] fission6: I got knocked off before when asking, do i need to explicitly now use the new https module or can i use http.createClient(port, host, secure) <- this i think no longer exists right? [22:13] neynenmo has joined the channel [22:13] konobi: dylang: to set the node version used by the service, you can add a "config.json" file to your repo and specify the version number in there as "version": "v0.3.3" or whatever [22:13] konobi: as for how npm gets configured, not sure [22:13] dylang: konobi: thanks, i did that for the app, but it doesn't help npm. [22:14] awenkhh has joined the channel [22:14] tim_smart: Hot http://gpl.internetconnection.net/ [22:15] torvalamo has joined the channel [22:15] herbySk has joined the channel [22:16] Aikar: fission6: i think you cant do that anymore, i saw a commit saying secure flag removed [22:16] fission6: right ok [22:16] fission6: thank you ik [22:16] fission6: Aikar: [22:16] konobi: dylang: oh.. you might just need to switch the symlink in your ~/local directory [22:17] saikat has joined the channel [22:17] aphelion has joined the channel [22:17] dylang: konobi: i checked that, but it's not a symlink. going to replace with one.... fingers crossed... [22:17] dylang: konobi: whoops yes it is a symlink, easy fixing - thanks for the help! [22:18] aphelion: is there a version of the node REPL that doesn't completely suck? if i call into it normally, i get weird behavior and as soon as it needs to wrap, none of the displayed text makes sense anymore. if i wrap with rlwrap, that works but i lose tab completion. [22:18] hunterloftis: tjholowaychuk: http://pastebin.com/nH0FDM8s <-- I think the issue may be that jade is splitting on commas, even if commas are inside of an attribute string [22:18] tjholowaychuk: hunterloftis: yeah thats the thing, we need to parse js expressions to handle ':' and ',' within attrs better [22:18] hunterloftis: tjholowaychuk: Or http://pastebin.com/wzFe5KrQ <-- better [22:19] Aikar: fission6: exports.createClient = function(port, host) { [22:19] Aikar: yeah there is no 3rd flag on http.js [22:19] hunterloftis: tjholowaychuk: Gotcha. I might make a quick patch for that, not to parse but just to do a ghetto style check [22:19] fission6: right nice thanks [22:19] tjholowaychuk: hunterloftis: everyone wants it but no one wants to spend the time doing it :) haha [22:20] tjholowaychuk: even a small subset would be useful [22:20] tjholowaychuk: no one really does foo: (foo, bar, baz) [22:20] tim_smart: tjholowaychuk: Tried dox, and there was a few bugs here and there. [22:20] felixge: ryah_: ping [22:20] tjholowaychuk: tim_smart: more than a few [22:20] tjholowaychuk: haha [22:20] felixge: ryah_: what do you think about this: https://github.com/felixge/node/commit/fa1d1494b3dbe54a51cb60732d5044d0f760e5a7 ? [22:20] tim_smart: Do you use it often? [22:21] tjholowaychuk: not really [22:21] tim_smart: It is just that the official JSDoc generator is lame. [22:21] fission6: Aikar: how come that method isn't listed in http://nodejs.org/docs/v0.3.6/api/http.html [22:21] tim_smart: Uses Java and stuff. [22:22] ryah_: felixge: oh man. [22:22] ryah_: felixge: so. you want to be one of those "friendly" projects. [22:22] felixge: ryah_: hah [22:22] ryah_: where source code is readable and we have comments [22:23] tlrobinson_ has joined the channel [22:23] Aikar: fission6: iono looks like ryans deprecating it? ryan http.createClient being removed? [22:23] felixge: ryah_: I went very easy on the comments [22:23] felixge: ryah_: but readable code seems like an interesting concept :) [22:23] JimBastard has joined the channel [22:23] tjholowaychuk: +1 for comments [22:23] fission6: its odd cause its no longer documented but its in the code may be for backwards compatibility for a while [22:23] felixge: ryah_: we can get rid of the first comment if you think it takes away too much mystery from figuring things out the first time :P [22:23] tjholowaychuk: especially for stuff that is not public api [22:24] stepheneb has joined the channel [22:24] Aikar: fission6: yeah looks like http.request is new method? [22:24] stepheneb has joined the channel [22:24] fission6: right [22:25] felixge: ryah_: I did make sure that startup time is not impacted so, I ran the benchmark all the time to verify that [22:25] GasbaKid has joined the channel [22:25] losing has joined the channel [22:26] ShizWeaK_ has joined the channel [22:26] felixge: ryah_: But yeah, I think src/node.cc was more readable than src/node.js before this refactor, which is kind of fucked up :) [22:26] eee_c has joined the channel [22:27] ryah_: felixge: can you come up with a better name for Startup.startup() ? [22:27] ryah_: Startup.start() ? ;/ [22:28] felixge: ryah_: run ? [22:28] felixge: or main [22:28] ryah_: sure [22:28] felixge: but run seems to be good [22:28] felixge: because at that point it's mostly running stuff [22:28] ryah_: also rebase [22:28] felixge: yip [22:29] brapse has joined the channel [22:30] dylang: konobi: I also had to do a manual re-install of npm on no.de because it had some problems recognizing the new version of node. [22:31] felixge: ryah_: https://github.com/felixge/node/commit/4b17bad7b0b5266af4e835939ea6abbea7c210c5 [22:32] warz has joined the channel [22:32] Aikar: ryah_: what do you think of https://github.com/ry/node/pull/575 - merge may not work right since the code was moved in a recent commit, but its a super tiny change. [22:33] Aikar: file: foo/index.js node foo would load foo/index.js [22:34] jimt has joined the channel [22:34] Aikar: tested and works, even fs.js node fs still works as expected and loads fs.js in cur dir [22:34] Aikar: so it doesnt conflict with natives [22:34] jacobolus has joined the channel [22:36] Evet: ryah_: when will you release 0.4? [22:36] ryah_: Evet: before feb 5 [22:37] nonnikcam has joined the channel [22:37] mjr_: wow [22:37] mjr_: That's awesome [22:37] felixge: Aikar: I don't think the top script should be so smart [22:37] felixge: ryah_: holy shit, so if I want to break some more APIs, I better hurry? [22:37] felixge: :) [22:38] chewbranca has joined the channel [22:38] ryah_: felixge: can you rebase - there is something strange [22:39] felixge: ryah_: ok [22:39] jimt_ has joined the channel [22:39] felixge: ah I thought you meant rebase on my own branch [22:39] micheil: ryah_: I've started work on the proposed restructure of docs [22:39] felixge: (as in, merge the two patches together via rebase -i) [22:39] ryah_: felixge: no, onto ry/master [22:39] micheil: so far not much to show yet. [22:40] Evet: ryah_: great! [22:40] felixge: ryah_: I see, resolving [22:40] tsyd has joined the channel [22:40] felixge: ryah_: Jslint, grrr [22:40] felixge: :) [22:42] evl has joined the channel [22:42] Aikar: anyone know how after ive forked a repo on github, how to update it with the latest commits from the parent (ie node) [22:42] Aikar: have to pull down locally then push up? [22:44] ryah_: git rebase ry/master && git push -f [22:44] ryah_: :) [22:44] felixge: ryah_: this one will apply: https://github.com/felixge/node/commit/884a43234c6bad13f246cedc7c544c0b33c54fec [22:44] ryah_: ^-- troll smile [22:45] pdelgallego has joined the channel [22:45] pdelgallego_ has joined the channel [22:45] felixge: ryah_: was a minor whitespace thingy [22:46] tokumine has joined the channel [22:46] ericnakagawa has joined the channel [22:46] jetienne has left the channel [22:46] ryah_: felixge: why is Startup capitalized? [22:47] felixge: ryah_: because it's a Singleton that also serves as an initial function. *ducks* [22:48] torvalamo: ACTION hands ryah_ the rocket launcher [22:48] brapse: anyone having problems compiling with mksnapshot freezing? [22:48] felixge: ryah_: I can lowercase it [22:49] Aikar: ryah_: so i do that on my own local checkout of MY fork right? [22:49] Aikar: ill mess with it when i get home [22:50] ryah_: Aikar: i can just do the change - it's just one line [22:51] Aikar: k, but i was just more so wanting to know how for future contributions [22:51] Aikar: as id rather apply changes to 'current' tree [22:52] Aikar: surprised github doesnt have this rebase support built in :/ [22:52] CIA-99: node: 03Felix Geisendörfer 07master * r91cc2d8 10/ (2 files in 2 dirs): [22:52] CIA-99: node: Restructure src/node.js startup code [22:52] CIA-99: node: This patch introduces a logical structure and sequence for the [22:53] ryah_: felixge: thanks. verbosity is a bit too much, but it's better than current [22:53] mikedeboer has joined the channel [22:53] felixge: ryah_: well, it should be easy to combine a few things going forward. [22:53] ryah_: nod [22:53] felixge: ryah_: but now I can actually navigate the file without getting headaches [22:53] felixge: :) [22:54] felixge: ryah_: thanks for merging [22:54] clarkfischer has joined the channel [22:54] isaacs has joined the channel [22:55] echosystm has joined the channel [22:56] isaacs: heyheyhey [22:57] isaacs: who's talkin about running npm as root? [22:57] isaacs: that's gonna work awesome soon! [22:57] isaacs: tanepiper, creationix ^^ [22:58] creationix has joined the channel [22:58] jimt has joined the channel [23:00] echosystm: does anyone know if TLS websockets (wss) suffer the same security problem as normal websockets? [23:00] overthemike has joined the channel [23:00] Aikar: isaacs: always worked for me :p [23:00] echosystm: some proxy injection issue, which is why firefox and opera dont support it [23:01] overthemike has left the channel [23:01] Aikar: echosystm: websockets dont have a security vulnerability, mozilla and opera disabled it without investigating if the 'security vuln' was even valid, which its not. [23:02] Aikar: there is a vulnerability in the proxys code yes, but it has absolutely nothing to do with websockets [23:02] Aikar: but such is life when men in suits flip switches [23:04] Aikar: mozilla got a big thumbs down from me for doing that. [23:04] Aikar: time to go home :O [23:05] hunterloftis: tjholowaychuk: Why does jade use regex to split attributes instead of a JSON.parse or an eval? [23:05] broofa has joined the channel [23:05] hunterloftis: I guess json.parse would fail on the =s [23:05] ryah_: how is one supposed to test if the current module is the main? [23:05] tjholowaychuk: hunterloftis: yeah, and for bools input(type='checkbox', checked) etc [23:05] Yuffster has joined the channel [23:06] tjholowaychuk: ryah_: we usually do if (!module.parent) [23:06] ryah_: tjholowaychuk: is there another way? [23:06] tjholowaychuk: dunno [23:06] ryah_: ok [23:06] ryah_: Aikar: there's a problem with your patch [23:06] brapse: ryah_: process.args [23:06] ryah_: Aikar: it makes the main module have a parent... [23:07] ryah_: Aikar: this can be seen by running "./node test/simple/test-cli-eval.js" [23:07] ryah_: Aikar: i rebased and modified it - but i'd want you to fix that before merge [23:07] ryah_: let me paste you what i hve [23:07] dguttman_ has joined the channel [23:07] felixge: ryah_: I think you can test: module === require.mainModule [23:08] ryah_: Aikar: https://gist.github.com/794180 [23:09] ryah_: Aikar, felixge: i think we should support TJ's pattern so as not to break code [23:09] felixge: ryah_: sure, I don't even know what this is about [23:09] felixge: just looked it up in module.js :) [23:09] brianmario_ has joined the channel [23:09] rauchg_ has joined the channel [23:10] ryah_: felixge: it's about doing "node somedirectory" and having it run somedirectory/index.js [23:10] brianmario_ has joined the channel [23:10] ryah_: i.e the argument is resolved in the same way that require() works [23:11] felixge: ryah_: I c, yeah that sounds a little too fantastic for my test [23:11] felixge: but if you want it, go for it : ) [23:11] tanepiper: isaacs: cool :) yea, i want to install an upstart script on postinstall [23:11] ryah_: it's minimla [23:11] sonnym has joined the channel [23:11] tanepiper: and that needs to go in /etc/init, so needs root - sounds good! [23:11] isaacs: tanepiper: you shook hook into "activate" instead of "install" [23:11] isaacs: tanepiper: since you might try to install multiple versions, but only the "active" one is probably the one you want hooked into upstart [23:12] mscdex: haha @ http://www.xtranormal.com/watch/7991991/ [23:12] heavysixer has joined the channel [23:12] isaacs: ryah_, tjholowaychuk: I usually use `if (module === require.main)` [23:12] aconbere has joined the channel [23:12] tanepiper: isaacs: won't matter much, the app installs a qm-admin bin file anyway, and i just exec that, but yea i can stick it there too then call initctl to start it [23:13] isaacs: tanepiper: hooking into activate/deactivate is the proper way to do this. [23:13] rhyolight has joined the channel [23:13] isaacs: tanepiper: that's what we do with smf stuff here. [23:13] isaacs: (here == joyent) [23:13] tanepiper: the app won't be published, it's a private git, npm just handles the deps and installs the bin file [23:13] isaacs: tanepiper: pk [23:14] mike5w3c_ has joined the channel [23:14] isaacs: tanepiper: even still, doing it correctly will avoid potential pitfalls [23:14] joelklabo has joined the channel [23:14] rhyolight: I have a really dumb question... [23:14] ecto has joined the channel [23:14] tanepiper: yea. npm best practices would be another good blog post me thinks ;) [23:14] rhyolight: fs.mkdirSync("./out", 0777) keeps creating a file with these permissions: rwxr-xr-x [23:14] tmzt: what does node need a non explicit global for? [23:15] rhyolight: Should be rwxrwxrwx, right? [23:15] ecto: hey guys. just wrote a new tutorial, can you give me some feedback? [23:15] ecto: redd.it/f8d31 [23:15] ecto: or http://news.ycombinator.com/item?id=2137169 [23:16] astoon has joined the channel [23:16] tanepiper: ecto: first really quick pass, looks good - i like blog posts that actually build something :) [23:17] brianmario_ has joined the channel [23:17] ecto: thanks :) spent all day on it [23:18] tanepiper: ACTION loves javascript, it's so easy to just read and not go WTF [23:19] ryah_: rhyolight: uh - yeah [23:19] SubStack: javascript is so wrong, but it feels so right [23:19] tanepiper: That might be my byline, "English is my first language, JavaScript is my second" [23:19] tanepiper: JavaScript Mother F*cker, DO YOU SPEAK IT? [23:19] tmzt: close to it, learned js in 1996 [23:19] isaacs: ryah_: hey, looks like the repl doesn't like pastes [23:20] isaacs: does weird things. [23:20] isaacs: (er, does "nothing") [23:20] tjholowaychuk: ecto: cool man, I would de-tab the gist though [23:20] tjholowaychuk: the indentation is wack [23:20] tmzt: after BASIC, vba, wb, ab, and vbscript [23:20] tmzt: sadly [23:21] SubStack: I started messing with javascript in 1999. I was 12. [23:21] shaver: I started in 1995, I was...not 12 [23:21] shaver: (18, I guess) [23:22] tanepiper: isaacs: just looked at flurp - thats nice! clean site, uses readme properly! [23:22] tmzt: shaver: howd you end up at mozilla? [23:22] isaacs: tanepiper: and if you have a doc folder with markdown in it, it showsthat nicely, too [23:22] shaver: tmzt: helped found it :-) [23:22] isaacs: tanepiper: evanmeagher did most of the styling and markup [23:22] jdalton has joined the channel [23:23] tmzt: I lived on netscape live for a while [23:23] isaacs: tanepiper: http://flurp.no.de/npm/0.2.15/registry [23:23] jdalton has left the channel [23:23] tmzt: er now I forget what it was called [23:23] tmzt: became dmo [23:23] isaacs: tanepiper: http://flurp.no.de/npm/0.2.15/install [23:23] shaver: dmoz [23:23] echosystm: does anyone know how i can capture the basic auth information from socket.io ? [23:23] shaver: oh [23:23] shaver: devedge [23:23] tmzt: yes [23:23] tmzt: thats it [23:23] shaver: yeah [23:24] tanepiper: <3 couchdb for being able to do replication and not bugger up local stuff as well :D although it's a big db now to replicate [23:24] echosystm: i need to be able to associate each socket with a user [23:24] tanepiper: isn't it over 1Gb? [23:24] blueadept has joined the channel [23:24] tmzt: enterprise scripting beans look a lot like commonjs [23:24] piscisaureus: ryah_: ping [23:24] desaiu: tanepiper: what's your setup with couchdb? [23:24] kriszyp has joined the channel [23:24] tmzt: though with added xml 'goodness' [23:25] Utkarsh has joined the channel [23:25] tanepiper: desaiu: currently using CouchOne for dev, but moving to self-hosted within a vlan shortly [23:25] tanepiper: no traffic cost within vlan, and can set it up behind a firewall [23:26] tanepiper: will be a Master -> Master backup, which will itself be rsync backedup on appended changes [23:26] desaiu: awesome, maybe i should try it via couchone first. I'm not sure yet. [23:27] mscdex: ryah_: i got a fix for that mkdir permission issue [23:27] beilabs_ has joined the channel [23:27] tanepiper: desaiu: yea, it's free and easy to set up, and nodejs <3 couchdb [23:28] tanepiper: there is a specific module like cradle, or you can just use http client, or mikeals `request` library [23:28] tanepiper: he even includes a couchdb example [23:28] jacobolu_ has joined the channel [23:29] superdug_ has joined the channel [23:30] desaiu: at 20:16 does mikeal say put it in "redis"? http://blip.tv/file/4596036/ [23:31] superdug_: okay, hello everyone. My knowledge of node is derived from the many videos online that Mr. Dahl has given. I have learned two things from these videos. 1.) What node.js is and does 2.) Mr. Dahl needs to knock down 2+ beers before giving a talk :-) [23:31] tanepiper: desaiu: possibly talking about sessions? [23:32] superdug_: desaiu: is that the CouchDB _changes in node talk? [23:32] tanepiper: afaik reddis will always trump couchdb as a session store [23:32] piscisaureus:  ++ [23:32] desaiu: superdug_: yes [23:33] superdug_: desaiu: What I could gather was that his application of the email document and node handler for it was a perfectly reasonable and workable solution, but that for as tanepiper said with distribution of actual sessions and session data, couchdb couldn't perform anywhere near the level that redis could [23:34] tanepiper: desaiu: basically if you listen he talks about network saturation [23:35] dguttman has joined the channel [23:35] tanepiper: couchdb has no binary or socket drivers, it's just http requests [23:35] tmcw has joined the channel [23:35] tim_smart: Hmmm node repl doesn't let me paste :/ [23:36] skm has joined the channel [23:36] desaiu: i know nothing about databases [23:36] desaiu: i want to learn [23:36] desaiu: network saturation is new terminology for me [23:37] torvalamo: that's not database theory [23:37] tanepiper: desaiu: ever used bittorrent? [23:37] torvalamo: that's couchdb specific [23:37] desaiu: sessions i'm guessing are user sessions for some application [23:37] desaiu: tanepiper: all the time [23:37] tanepiper: desaiu: ever tried to use BT to dl 10 things at once, AND surf the web? [23:37] mscdex: ryah_: sent you the mkdir permissions patch [23:38] desaiu: tanepiper: yes, while limiting the download rate of course :) [23:38] desaiu: 25Kb/s ftw ;) [23:38] mscdex: QoS! [23:38] mscdex: :> [23:38] desaiu: Hehe, QoS was handy at my last job. [23:39] desaiu: so sessions are like the torrent downloads? [23:39] ezmobius_ has joined the channel [23:39] superdug_: desaiu: however, it should be noted that if you use node as more of a helper for non-browser based processing (sending emails, moving files, or performing some out of program task) in my experience it's much easier to do that in node than it is to do it as a CouchDB external process [23:39] desaiu: wait, are sessions what is referred to when we are talking about non-blocking communication between processes? [23:39] Lorentz: QoS on router level is nice. [23:40] brianmario has joined the channel [23:40] tanepiper: desaiu: no, i just mean you can only have so many http connections open, and couchdb is all http [23:40] superdug_: desaiu: sessions are connections and the remembering who connected and what they were doing [23:40] tanepiper: POST/PUT/GET [23:40] tanepiper: so if you have lots of other stuff flying about AND your doign that, you'll hit saturation [23:41] superdug_: tanepiper: no, it's more about raw throughput, couch at the end of the day is still a database and does database stuff that takes more time than an all-in-memory key-value store [23:41] tsyd has left the channel [23:41] superdug_: tanepiper: couch still does a lot of disk stuff [23:42] mirkok has joined the channel [23:42] tanepiper: superdug_: yes, true - which is why it suits documents that need to saved and secure, while reddis and memcached suit session stuff better because that has a higher entropy [23:42] evl has joined the channel [23:42] desaiu: so saturation is where your system can hardly function? [23:42] superdug_: tanepiper: there ya go ! couch is an http database that just happens to be freaking awesome [23:42] jchris has joined the channel [23:42] desaiu: system(s) [23:43] superdug_: desaiu: or lags [23:43] desaiu: got it [23:44] ezmobius_ has joined the channel [23:44] superdug_: the idea is to take a connection, fulfill whatever request comes in, and move on, whic is what node excels at [23:44] superdug_: couchdb however, allows for master-master replication out of the box [23:44] echosystm: is there any way to use basic authentication with socket.io? [23:45] perezd has joined the channel [23:45] tanepiper: echosystm: not that i've come across yet, but i hope someone will come up with a solution [23:45] torvalamo: what do you mean by basic authentication? [23:45] GasbaKid has joined the channel [23:46] echosystm: http basic authentication [23:46] torvalamo: then no [23:46] tanepiper: at the moment i'm basically keeping all sessions in a hash in memory with the current connection id [23:46] superdug_: okay I'll bite [23:46] echosystm: sessions scare me [23:46] superdug_: torvalamo: when is the answer yes? [23:46] torvalamo: when you make your own [23:46] torvalamo: non-http [23:46] tanepiper: and just passing auth requests over a callback, which doesn't seem secure [23:46] desaiu: i've seen two talks now where mikeal refers to couch apps. I'm not sure what type of apps these client-side heavy scripts are, and i'm not sure where a traditional framework would be better suited. [23:46] superdug_: :-) [23:47] desaiu: I've seen previous talks by the sammy.js author speaking on this as well [23:47] dguttman_ has joined the channel [23:47] torvalamo: i just create a guid that i pass through the socket and store in a cookie [23:47] torvalamo: or uuid [23:47] torvalamo: whatever the right term is [23:47] superdug_: desaiu: couchapps are 100% javascript, with the way the sandbox is laid out in couchdb allowing the serving of static files, any app that you can do entirely in javascript, can be a couch app [23:48] tanepiper: you encrypt the password with it before sending? [23:48] bpedro has joined the channel [23:48] torvalamo: encrypt the password with a uuid? [23:48] torvalamo: it's a uuid [23:48] tanepiper: well as a salt [23:48] torvalamo: it's not related to anything [23:48] superdug_: torvalamo: I like the OpenAuth approach where you just let the auth be handled by a third party app all together (or facebook, twitter, or google) [23:49] torvalamo: i don't think that's the issue here [23:49] tanepiper: the passwords in my db are stored bcrypt, but the form just gets the values as plaintext and sends them over socketio as plaintext [23:49] superdug_: torvalamo: no, not for the simple solution of http://username:password@server.ip:8080/ no [23:49] tanepiper: i was thinking of maybe at least doing a sha1 encryption with a salt both the client and server know [23:50] banjiewen has joined the channel [23:50] torvalamo: you can run socketio over https or secure websockets [23:50] superdug_: tanepiper: yeah, you can even do something simple like SHA1+salt on the URI even [23:51] tanepiper: torvalamo: not with my app currently, not until connect is at least updated to 0.4.0 and supports SSL :( [23:51] torvalamo: well that's your problem, isn't it? :p [23:51] torvalamo: not socket.io's fault [23:51] evl has joined the channel [23:52] superdug_: out-of-spec feature [23:53] desaiu: okay, i have more questions, but i'll reserve them and try to figure it out as i go along [23:53] pHcF has joined the channel [23:53] desaiu: thank you for the help tonight [23:53] torvalamo: there are no stupid questions, only stupid people [23:53] torvalamo: :p [23:54] desaiu: ..who don't ask questions? in that case ;) [23:54] superdug_: I got a question, how do you explain what node.js is, to someone who doesn't know anything about it? [23:55] echosystm: connect doesnt support SSL? [23:55] desaiu: superdug_: i think it depends on their level of understanding [23:55] w0rse has joined the channel [23:55] desaiu: of programming in general [23:56] echosystm: tanepiper: since when does connect not support SSL? [23:56] tanepiper: echosystm: show me a document that says it does [23:56] echosystm: i'm using it right now over ssl... [23:56] tanepiper: behind a proxy like ngnix? [23:56] rauchg_ has joined the channel [23:57] echosystm: no, just plain node.js [23:57] torvalamo: magic [23:57] torvalamo: i call shenanigans [23:57] tanepiper: nodejs 0.3.6? [23:57] echosystm: ? [23:57] echosystm: 0.2.6 [23:57] echosystm: or 0.2.4 or whatever the stable is [23:57] torvalamo: 0.3.6 won't even compile for me [23:57] torvalamo: not .5 either [23:58] NemesisD: hi all, i need to store my exit status somewhere during the execution of my program and then ensure whenever the process exits that it uses that status. how do i do that? [23:58] echosystm: why would you use ngnix tanepiper ? [23:58] torvalamo: static server [23:58] echosystm: whats wrong with the connect one? [23:58] Lorentz: Does ssl over websocket work with self-signed certs? [23:58] NemesisD: i know about the process exit event bu i can't call exit in there without getting in a nasty recursive loop [23:58] tanepiper: echosystm: well i've never seen connect documented as working with ssl [23:58] Lorentz: I never got it working [23:58] Lorentz: And I figured it was that [23:58] torvalamo: NemesisD, why would you call exit in the exit event? [23:59] torvalamo: just return [23:59] Lorentz: Well, websocket over ssl, whichever, you know what I mean. [23:59] echosystm: tanepiper: do you understand how connect works? it just sits on top of the inbuilt http [23:59] NemesisD: torvalamo: i told you why i *don't* want to ;) i need to preemptively set up what my exit code is going to be [23:59] echosystm: if you setSecure() on your http object, connect has no choice but to run over ssl [23:59] tanepiper: echosystm: yea, but i couldn't get ssl to work on 0.2.x with static content, my JS would just cut off at 64kb