[00:00] rauchg__ has joined the channel [00:01] JimBastard has joined the channel [00:01] softdrink has joined the channel [00:01] tjgillies: can you do threading with nodejs? [00:01] JimBastard: hey tjholowaychuk or creationix , do you know if anyone is working on a connect / express plugin for doing user accounts. like user signup and login form. i know of express-auth [00:02] JimBastard: i have this roles code already, would make sense to do users [00:02] JimBastard: and wrap it all up with connect [00:02] tjholowaychuk: i know ciaran is working on connect-auth [00:02] creationix: JimBastard: not that I know of [00:02] JimBastard: tjholowaychuk: so like auth is like warden? [00:02] creationix: tjgillies: only in c code [00:02] JimBastard: warden doesnt do users [00:02] JimBastard: right? [00:02] creationix: threads aren't exposed to js [00:02] JimBastard: you keep auth and users decoupled [00:02] tjgillies: creationix, ok thnx [00:02] tjholowaychuk: JimBastard: not sure i havent tried it yet, but no it doesnt do form stuff or anything i dont think [00:03] JimBastard: im talking to someone right now who needs that stuff, i might build it [00:03] JimBastard: shouldnt be very hard i think [00:03] JimBastard: just a matter of figuring out the best way to integrate [00:03] JimBastard: you think thats a good idea? [00:03] creationix: JimBastard: go for it [00:03] creationix: then link to your module on the connect wiki [00:04] JimBastard: well, im going to see whats up with this project first. but yes, cool beans. hopefully we'll get that moving [00:05] _announcer: Twitter: "dmagicgdl Hello! going to be a contest node.js weekend in August. Allow teams. We enter with me? :)" [es] -- Hugo Estrada. http://twitter.com/hugoestr/status/19033108096 [00:05] tjgillies: creationix, if i require a file twice does it reload it? [00:05] creationix: tjgillies: nope, it's cached [00:05] tjgillies: creationix, what function can i use to reload a file. trying to reload internal config stuff without stopping/starting process [00:06] lachlanhardy has joined the channel [00:06] creationix: tjgillies: fs.readFile + eval ? [00:06] creationix: or find where node keeps the cache and break it [00:06] _announcer: Twitter: "@ Myfreeweb I and Perl can parse rss, but for the evening and node.js do something. a matter of principle the organization. it - beautiful design" [ru] -- or_not. http://twitter.com/ibobrik/status/19033214761 [00:07] JimBastard: bradleymeck_: i always forget, is it possible to translate the !tweet text in one command? [00:07] charlenopires has joined the channel [00:14] cirwin: has anyone looked into adding support for http keep-alive to the client? [00:15] cirwin: heh, me looks at mailing list [00:15] cirwin: sorry for the noise [00:16] creationix has joined the channel [00:18] _announcer: Twitter: "Getting my #nodejs on — at Austin JavaScript http://gowal.la/r/UvLQ" -- Daniel Hedrick. http://twitter.com/dcoder/status/19033912871 [00:21] isaacs: yikes. it was just brought to my attention that fs.realpath is Doing It Wrong. [00:22] isaacs: ryah: would you accept a patch that did fs.realpath right? [00:22] tjgillies: is there a function to return objects methods? [00:22] creationix: tjgillies: yes [00:22] ryah: isaacs: yes [00:22] Apage43 has joined the channel [00:22] tjgillies: creationix, oh, what is it? :) [00:22] isaacs: great. [00:22] creationix: well "methods" don't exist in js [00:22] creationix: but properties can be functions [00:22] isaacs: ryah: any reason why it's not just a wrapper around realpath(3)? [00:22] creationix: and constructors can have prototypes [00:23] tjgillies: creationix, ok properties [00:23] ryah: isaacs: not sure [00:23] creationix: Object.keys(obj) will show the enumerable keys [00:23] isaacs: ryah: if we need it to be done in js, that's fine, but in that case, it needs like a bagillion tests to make sure it handles all the edge cases right. [00:23] creationix: Object.getOwnPropertyNames(obj) will show all keys [00:23] tjgillies: reminds me of pythons object.__dict__.keys() [00:23] creationix: Object.getOwnPropertyNames(Array.prototype) will show the "methods" of Array instances [00:23] isaacs: ryah: well, it'll be instructive to do it anyway. i'll send the patch and we can see if anyone gripes. [00:23] tjgillies: creationix, thnx [00:24] creationix: tjgillies: does that make sense? [00:24] tjgillies: creationix, yes [00:24] ryah: isaacs: it seems i requested a pure js version [00:24] isaacs: hehe [00:24] ryah: i forget why [00:24] isaacs: i suggest you change your mind :) [00:24] isaacs: doing it in js would be fun, but more likely to be broken, as we can see here. [00:25] ryah: it might be that one of the platforms is missing the c version [00:25] isaacs: aha [00:26] isaacs: in that case, then the solution is to write a bagillion tests. [00:26] ryah: i'm not sure- i can't recall [00:26] steadicat has joined the channel [00:26] isaacs: it's pretty standard posix. [00:26] isaacs: i think it even works on cygwin [00:28] r1ngzer0: note that realpath() behaviour does vary across unixes. [00:30] ryah: maybe that's why we did a js version [00:30] tjgillies: heh just learned theres a big difference between obj.toString and obj.toString() [00:30] tjgillies: console.log(obj.toString); made me 'wtf' [00:30] r1ngzer0: bsds (and linux) will always return absolute paths regardless if the argument is relative. sysv derivatives will return relative resolved_path when given a relative pathname. [00:30] mattly has joined the channel [00:32] benburkert has joined the channel [00:33] _announcer: Twitter: ""josi is heavily influenced by ASP.NET MVC, and to a lesser extent by Ruby on Rails and Django"??? Built for node.js : http://is.gd/dA2Ui" -- scitesy. http://twitter.com/railcar88/status/19034826380 [00:34] ryah: isaacs[working]: it was probably the linux man page: [00:34] ryah: Avoid using this function. It is broken by design since (unless using the non-standard [00:34] ryah: resolved_path == NULL feature) it is impossible to determine a suitable size for the output buf- [00:34] ryah: fer, resolved_path. According to POSIX a buffer of size PATH_MAX suffices, but PATH_MAX need [00:34] ryah: not be a defined constant, and may have to be obtained using pathconf(3). And asking path- [00:34] ryah: conf(3) does not really help, since on the one hand POSIX warns that the result of pathconf(3) [00:34] ryah: may be huge and unsuitable for mallocing memory. And on the other hand pathconf(3) may return [00:34] ryah: -1 to signify that PATH_MAX is not bounded. [00:34] ryah: The libc4 and libc5 implementation contains a buffer overflow (fixed in libc-5.4.13). Thus, [00:34] ryah: set-user-ID programs like mount(8) need a private version. [00:34] tekky has joined the channel [00:36] mjr_: ryah: man, programming is hard. [00:37] ryah: fuckin a [00:37] [[zz]] has joined the channel [00:39] mattly_ has joined the channel [00:40] murz has joined the channel [00:41] murz: Where did the Connect page go? This page seems to have disappeared: http://github.com/extjs/Connect [00:43] saikat has joined the channel [00:43] JimBastard: murz: sencha [00:44] JimBastard: http://github.com/senchalabs/connect [00:44] JimBastard: lol, how many times did they move that thing [00:44] murz: nice, thanks... for some reason github search stil pulling up the old url [00:47] khug has joined the channel [00:50] webandy: what is the easiest way to have sinatra style routing to make a node endpoint, either built in with a standard module, or a third party module, I'm trying to figure out the "standard" way of specifying a url to list for POST requests on [00:50] JimBastard: yeah github search is as bad as reddit search [00:50] JimBastard: webandy: theres like a million for node. [00:50] JimBastard: webandy: there are full stack implementations [00:50] webandy: JimBastard: what is the most bare bones? [00:50] JimBastard: or my favorite, a JSON router [00:50] JimBastard: http://github.com/cloudhead/journey [00:51] JimBastard: ^^ [00:51] webandy: k checking it out [00:51] JimBastard: ONLY returns JSON [00:51] JimBastard: i use it to build json webservices [00:51] webandy: this looks good, thanks [00:53] cirwin has joined the channel [00:54] _announcer: Twitter: "Heh, interesting. RT: @railcar88: "josi is heavily influenced by ASP.NET MVC" built for node.js : http://is.gd/dA2Ui" -- tarnacious. http://twitter.com/tarnacious/status/19036147630 [00:56] polotek has joined the channel [00:56] tjgillies: does nodejs have udp support? [00:57] cirwin: yes, see dgram [00:57] _announcer: Twitter: "I have a rudimentary Cocoa chat app connecting and interacting with my rudimentary node.js chat server. #proudofmyself" -- Josh Lindsey. http://twitter.com/lesmothian/status/19036302268 [00:57] polotek: are write streams supposed to take a format string and variable args [00:57] polotek: like console.log does? [00:57] tjgillies: cirwin, thanks! [00:58] maushu: Who the hell named udp as dgram. [00:58] maushu: Oh, wait. [00:58] mjr_: Me, I think? [00:58] maushu: It allows other sockets besides udp. [00:58] mjr_: Maybe pquerna. [00:59] polotek: is there an sprintf like module? [00:59] maushu: Is there a way to simplify windows deployment? [00:59] polotek: maushu: don't do it? [00:59] maushu: BUT I MUST! [01:00] maushu: Maybe a cygwin-to-exe or something. [01:00] maushu: Hmm, a packager might work. [01:00] creationix: maushu: submit a binary to uvy-bin [01:00] creationix: *ivy-bin [01:00] maushu: hmm? [01:01] creationix: embed git too [01:01] creationix: not sure I want to maintain that, but some could have a window fork of ivy [01:01] creationix: *windows [01:02] cirwin1 has joined the channel [01:02] maushu: I see. [01:03] davidwalsh has joined the channel [01:04] polotek: http://github.com/tlrobinson/narwhal/blob/master/lib/printf.js [01:06] creationix has left the channel [01:08] _announcer: Twitter: "Follow @clickdummy for updates to my site built on #nodejs #expressjs too!" -- Aaron Heckmann. http://twitter.com/aaronheckmann/status/19037024501 [01:12] _announcer: Twitter: "> Multi-Core HTTP Server with NodeJS (Yahoo! Developer Network Blog): http://bit.ly/cg9D00" -- Paulo Morgado. http://twitter.com/PauloMorgado/status/19037294054 [01:13] EyePulp has joined the channel [01:15] devongovett has joined the channel [01:15] _announcer: Twitter: "@joemccann Here's a nodejs gist: http://gist.github.com/483884" -- Daniel Hedrick. http://twitter.com/dcoder/status/19037482558 [01:17] Wandrewvious has joined the channel [01:19] bean0r1___ has joined the channel [01:19] Blink7 has joined the channel [01:23] isaacs: ryah: so... no realpath(3)? [01:23] tjgillies: what does this mean?: Uncaught, unspecified 'error' event. declared from: throw new Error("Uncaught, unspecified 'error' event."); [01:24] isaacs: ryah: i guess i'll just write a bagillion tests for it tonight then [01:24] isaacs: that's a shame. [01:25] polotek: tjgillies: need more context [01:25] polotek: short answer is there is an uncaught error [01:26] polotek: probably thrown from some async function [01:27] SamuraiJack has joined the channel [01:27] ditesh|cassini has joined the channel [01:27] tjgillies: polotek, so do i need to make an event listener that listens for "error"? is that my problem? [01:27] polotek: yeah, try that [01:28] polotek: but again, I dont' know what you're actually doing [01:28] zapnap has joined the channel [01:28] polotek: you could send a gist or pastebin [01:28] rixius has joined the channel [01:29] mjr_: Here's an exciting new error: (libev) select: Invalid argument [01:29] tjgillies: polotek, http://gist.github.com/483895 [01:29] mjr_: I think that means it's time to go home. [01:30] polotek: did you just add the error handler? [01:30] polotek: what does the message say? [01:30] Blink7 has joined the channel [01:31] isaacs: ACTION just registered the "node.by" domain [01:32] _announcer: Twitter: "Want 2 see the future of the web? Google: node.js & visit http://pusherapp.com-super low (server) resource use, realtime updating web pages" -- Nate Johnson. http://twitter.com/skylennard/status/19038504380 [01:34] cloudhead has joined the channel [01:34] panosru has joined the channel [01:35] _announcer: Twitter: "@bradohearne pusherapp.com (for a quick and easy try it out **for free** to boot) and nodejs.org for a granular server you can install" -- Nate Johnson. http://twitter.com/skylennard/status/19038728883 [01:37] EyePulp has joined the channel [01:37] rixius: what's being used to push the related tweets into the chatroom? [01:37] tjgillies: im guessing either xmpp,redis,amqp, or udp [01:38] rixius: >.< now there's a list of options... [01:38] rixius: Thanks though [01:38] mklappstuhl has joined the channel [01:38] panosru: hello I have installed node.js into my osx but I really need a beginners guide for it, could you suggest me anything easy to follow? [01:38] MikeSmith has left the channel [01:38] JimBastard: panosru: howtonode.org [01:39] rixius: /\-what he said [01:39] panosru: Thank you Jim! I will check it out now :) [01:40] polotek: tjgillies: did you get anything going? [01:40] mscdex: rixius: maushu could tell you exactly [01:40] tjgillies: polotek, emergency server maitenance for other project, had to put it on hold for a sec [01:40] victorstan has joined the channel [01:40] maushu: I KNOW NOTHING. [01:41] rixius: mscdex: I don't know, I guess I was hoping the person who set it up was here... >.> a bit far-fetched I admit [01:41] maushu: rixius, twitter stream. [01:41] maushu: rixius, the bot connects to the twitter http stream, thats all. [01:42] rixius: makes sense. sorry if I came across as rude... it honestly wasn't my intention [01:42] panosru: silly question: does anyone used node.js with php? [01:43] rixius: panosru: not me, sorry [01:43] tjgillies: panosru, i use php ruby and nodejs on the same server, is that "together"? [01:43] maushu: rixius, http://dev.twitter.com/pages/streaming_api [01:44] JimBastard: whats pho [01:44] JimBastard: whats php [01:44] JimBastard: trollfail [01:44] panosru: no, I was most curious for any example of using node.js with php [01:44] polotek: pho is vietnamese noodle soup [01:44] maushu: I don't see how php and node.js combine... but... [01:45] polotek: panosru: define "with" [01:45] maushu: http://github.com/felixge/node-ugly [01:45] maushu: Knock yourself out. [01:45] jah_: can the node repl be used in a lispy manner (e.g. redefining functions while code is running)? [01:45] panosru: polotek: well how else to explain it ? :P I mean how to connect php with node.js any example of how to make use of node.js with php :) [01:46] maushu: jah_, it should work. [01:47] polotek: panosru: you can "connect" them over tcp/http [01:48] polotek: you can't run php "under" node. as in have the node process execute a php script. [01:48] maushu: Hmm, I need to talk to felixge. [01:48] panosru: polotek: yes this is understandable :) [01:48] polotek: unless you use something like node-ugly like maushu suggested [01:48] panosru: thanks I will search for any example online :) [01:48] polotek: but that just does a system call in a child process [01:49] panosru: no actually I want to make use of node.js to provide some live data [01:49] panosru: but since I never used any comet server I'm really not familiar on how to proceed with that :) [01:51] _announcer: Twitter: "why switching from Ruby / Sinatra to Node.js http://bit.ly/cdbOYP" -- Rho. http://twitter.com/darkrho/status/19039733453 [01:51] polotek: panosru: you can run a separate node service [01:51] polotek: that pulls from your database or whatever [01:52] _announcer: Twitter: "Epic web socket demo failure on my part. But hopefully sum of the rest of the presentation on #node.js was worthwhile." -- Joe McCann. http://twitter.com/joemccann/status/19039786127 [01:53] polotek: panosru: otherwise it's trickier because you don't want node polling your php app in real time [01:54] panosru: polotek: node.js is able to pull data from database with dbslayer module? or I got it completely wrong? ( I will read the docs too just asking some basic questions to have a general overview ) [01:55] polotek: you can use dbslayer. there is also a postgres module, mongodb, redis, other stuff [01:55] polotek: there are direct mysql modules but last time I checked, none of them were really viable yet [01:56] polotek: because they're not fully asynchronous [01:56] panosru: hm.. I see [01:57] panosru: lately I'm reading about NoSQL like mongo-db and how they make use of key-value speed with RDBMS power but its a bit foreign to me for now :) [01:57] siculars has joined the channel [01:58] mjr_ has joined the channel [01:58] polotek: mongodb is awesome for node. returns results as pure json [01:59] WALoeIII has joined the channel [02:00] EyePulp has joined the channel [02:00] _announcer: Twitter: "Bad news: the @AustinJS node.js demo failed. Good news: it was probably not node.js that failed :) @joemccann" -- Kyle Simpson. http://twitter.com/getify/status/19040316784 [02:01] meso has joined the channel [02:02] mikeal has joined the channel [02:03] panosru: polotek: I'm thinking about if is it worth of using mongodb for node.js -> php communication and MySQL for the other data as we do so many years do you think that it would be better to go fully into mongodb and drop mysql? [02:04] polotek: panosru: it really depends heavily on what type of app you're talking about [02:04] tjgillies: polotek, ok got around to testing. was missing "error" event listener [02:04] polotek: there are definitely downsides to using mongodb for your critical data [02:04] polotek: tjgillies: word [02:05] polotek: using mongodb just for the real-time portion is a good option [02:05] panosru: polotek: data like bank data ? [02:05] polotek: panosru: like any data that you would be really upset if you lost :) [02:05] panosru: ah I see [02:05] _announcer: Twitter: "@getify @AustinJS @joemccann and thus node.js may or may not be production ready :P" -- Karl Tiedt. http://twitter.com/ktiedt/status/19040681629 [02:05] polotek: they recommend you run mongodb on multiple servers for reliability [02:06] panosru: so in other words it isnt stable yet ? [02:06] polotek: replicated that is [02:06] polotek: it's plenty stable from my experience and what I've read [02:06] polotek: but it has a different idea about durability [02:07] satori_ has joined the channel [02:07] polotek: panosru: http://blog.mongodb.org/post/381927266/what-about-durability [02:08] polotek: panosru: depending on what kind of real-time data you're dealing with, I might go with Redis instead [02:08] panosru: polotek: sorry for too many questions btw I just like to get another persons opinion too not just reading the manual and conclude in my opinion :) [02:08] tjgillies: the answer is always redis [02:08] mikeal: haha [02:08] mikeal: redis is the answer to many problems [02:08] polotek: I don't mind questions [02:08] mikeal: it's just too damn awesome [02:08] tjgillies: s/many/all/ [02:08] mikeal: no, not all [02:08] panosru: radis is another NoSQL ? [02:09] mikeal: the reason they are good at what they do is because they don't try to do everything [02:09] rauchg_: there's no such a thing as `another nosql` [02:09] mikeal: Redis is an in-memory datastructure store [02:09] panosru: "the reason they are good at what they do is because they don't try to do everything" <-- epic! [02:09] tjgillies: mikeal, yrah im just obsessive [02:09] mikeal: it's a place to put your globals instead of in-process [02:09] mikeal: they you can scale those application processes horizontally [02:09] tjgillies: i love redis's pubsub [02:10] mikeal: that shit is hot [02:10] mikeal: realtime FTW [02:10] mikeal: all databases should have that [02:10] satori_: redis pubsub and HTML5 websockets ftw [02:10] mikeal: if they don't I have a hard time taking them seriously [02:10] panosru: rauchg_: why? since NoSQL is implemented with CouchDB, MongoDB, RavenDB and etc [02:10] tjgillies: i was using amqp for a project, and i was like "screw this, im usign redis" [02:10] mikeal: CouchDB has the _changes stuff [02:10] rauchg_: panosru: exactly [02:10] mikeal: NoSQL is a buzz word [02:10] rauchg_: nosql it's not implemented [02:10] mikeal: it doesn't mean anything [02:10] rauchg_: as it's not a spec [02:10] rauchg_: haha [02:10] rauchg_: it's a meaningless word [02:11] rauchg_: people hate on html5 being a buzzword [02:11] polotek: rauchg_: it's not meaningly [02:11] rauchg_: but it's nothing compared to nosql [02:11] polotek: meaningless [02:11] tjgillies: my lawn is nosql [02:11] polotek: it's been given a meaning [02:11] panosru: rauchg_: lol I got you :P well you got my point I guess I did not typed it properly at first time :) [02:11] polotek: even though it drives you pedantic guys nuts [02:11] mikeal: nosql === everything other than MySQL, Postgres, and Oracle [02:11] polotek: someone should make a key-value or document store that uses an sql variant for queries [02:11] tjgillies: aka, my lawn [02:11] polotek: that would just piss everyone off [02:12] tjgillies: polotek, LOL [02:12] satori_: hehe [02:12] mikeal: panosru: you shouldn't ask for a database, you should figure out your use case and then find the database that matches [02:12] tjgillies: polotek, thats just crazy enough to make sense [02:12] rauchg_: or write it yourself [02:12] rauchg_: what [02:12] mikeal: no matter what the MongoDB people are trying to sell, there is no drop in replacement for RDBMS because nobody is building things that generically anymore [02:12] rauchg_: tjgillies: many people are trying that [02:12] chrischris has joined the channel [02:13] polotek: mikeal: that is awesome [02:14] panosru: mikeal: well its a bit complicated not so simple since I never used comet but I know on which cases I could use it, so now I try to see if it is worth of having mongodb or any other NoSQL implementation for the node.js -> php data or just keep all the data into MySQL [02:14] mikeal: im on a plane to NYC [02:14] mikeal: and i'm watching From Paris with Love [02:14] rauchg_: what do you mean by generically ? [02:14] mikeal: Travolta is *not* a believable action star [02:14] mikeal: MySQL, Postgres and Oracle were the *only* databases for a long time [02:15] panosru: mikeal: MSSQL too [02:15] mikeal: so they grew featuresets to handle everything under the sun [02:15] mscdex: screw mssql [02:15] mscdex: :P [02:15] mikeal: which meant they were eventually great at nothing and passable at everything [02:15] jesusabdullah has joined the channel [02:15] mikeal: new databases aren't like that [02:15] panosru: mscdex: lol :P [02:15] polotek: http://twitter.com/polotek/status/19041300465 [02:15] rauchg_: new databases like ? [02:15] mikeal: they focus on a use case and do that *great* [02:15] rauchg_: lotus notes ? [02:15] mikeal: hahaha [02:15] rauchg_: :D [02:15] mikeal: CouchDB == Lotus Notes for the web [02:16] rauchg_: yep, and lotus notes is 20 years old, that's why i lost you at the `anymore` [02:16] rauchg_: these problems are not new [02:16] mscdex: heh that reminds me of a video i saw on youtube once... [02:16] mikeal: Damien Katz started CouchDB, used to work on Lotus Notes :) [02:16] mscdex: http://www.youtube.com/watch?v=8uy7micFCcA [02:16] mikeal: i work for Damien, so I'm well aware :) [02:17] _announcer: Twitter: "Node.js impressive use case: http://techblog.gomockingbird.com/socket-to-em" -- Fabio Sato. http://twitter.com/grooel/status/19041456822 [02:18] panosru: damn time passes too fast! 15 minutes ago I checked the clock and it was about 11:20pm now it is already 5:20am! [02:18] panosru: lol [02:19] mikeal: mockingbird is awesome, i want them to redo this with node-pcap [02:19] tjgillies: hacking causes time to accelerate, its a fact [02:19] mjr_: mikeal: I'd say it's ready at this point [02:19] mjr_: I've been using it a lot at work lately. [02:20] manveru: does anyone know of 0mq for the browser? [02:20] manveru: implemented with websockets? [02:22] cirwin1: mikeal: are you the mikeal of http keep-alive? [02:22] cirwin has joined the channel [02:22] mikeal: haha, I'm famous! [02:23] cirwin: very much so :) [02:23] mikeal: yes [02:23] SubStack: internet famous! [02:23] SubStack: (the best kind of famous) [02:23] cirwin: ACTION wonders if he can pester you about it [02:23] cirwin: I tried applying the patch from the mailing list, but the test failed with permission denied [02:23] cirwin: ACTION is a bit of a node newb [02:24] mikeal: permission denied? [02:24] mikeal: that's weird [02:24] stepheneb has joined the channel [02:24] cirwin: sorry [02:24] cirwin: connection refused [02:24] mikeal: the test talks to a local server [02:25] mikeal: so that's quite odd [02:25] cirwin: yeah [02:25] panosru: mscdex: great video! very cool montage! :D [02:25] cirwin: I was unable to fathom it [02:25] cirwin: I can hit the test server with my browser [02:25] mscdex: heh [02:25] mikeal: what OS? [02:25] cirwin: but it doesn't seem to like doing it from in the test [02:25] cirwin: linux [02:25] cirwin: debian [02:25] mikeal: maybe the bind call is lying and there is a really short delay [02:25] mikeal: stick the test call in a setTimeout [02:26] ncb000gt has joined the channel [02:26] cirwin: ah, that's it [02:26] cirwin: FD 6 [02:26] cirwin: DEBUG: FD 6 [02:26] cirwin: DEBUG: done. [02:26] cirwin: this is bad! [02:27] mikeal: no [02:27] mikeal: that's good [02:27] mikeal: :) [02:27] mikeal: hahah [02:27] cirwin: well, the setTimeout worked [02:27] cirwin: was what i meant [02:27] mikeal: you should tell ryan about that [02:27] cirwin: I gathered from the mailing list that that was supposed to happen [02:27] mikeal: this is bad is printed because I can still make http requests to the server after i called close [02:27] cirwin: I'm planning to go to his talk thing tomorrow in SF [02:28] cirwin: ok [02:28] mikeal: which ryan says is by design but I can't imagine why [02:28] mikeal: i should just implement forceClose for the http server [02:28] cirwin: well, I can understand why you wouldn't want to close arbitrary connections when you close a server [02:29] cirwin: but it does mean more work for the "i don't really care" case [02:29] cirwin: not sure how persistent connections tie into that [02:29] mtodd has joined the channel [02:29] cirwin: it would seem hard to know at what stage the server was in relation to a request [02:29] cirwin: though it can presumably tell itself [02:30] mikeal: but telling the http server to close, and then having it still take *new* http requests on existing connects [02:30] mikeal: is a little off to me [02:30] cirwin: yes, I understand [02:30] panosru: sleep time ! good night to all :) [02:32] cirwin: hrm, with your patch applied, lots of the tests just hang - for the same reason? [02:32] polotek: I can understand code have features not in the api docs [02:33] polotek: but the docs have features that aren't actually in the code [02:33] rauchg_: mikeal: [02:33] mikeal: cirwin: yes [02:33] polotek: :( [02:33] rauchg_: what did ry mean by clean restarts [02:33] rixius: anyone know any know issues with ( fab ) and nodejs 0.1.100? [02:33] mikeal: so [02:33] mikeal: when i first started writing it [02:33] rixius: known** [02:33] mikeal: ry said to just make keep-alive on by default [02:33] ncb000gt: polotek: that's a feature [02:33] rauchg_: node's bugs are features. [02:33] cirwin: but actually that breaks everything :) [02:33] mikeal: but because it keeps the event loop running we think it's a good idea not to do that [02:33] mikeal: and just have it on if you send the right header [02:34] cirwin: that was how I would expect it to work [02:34] mikeal: and then you need to call close on the http client or else it's not going to exit ever [02:34] rauchg_: evar [02:34] rixius: getting the following:: "/home/rixius/node/fab/apps/fab.nodejs.js:19 [02:34] rixius: method: request.method, [02:34] rixius: ^ [02:34] rixius: TypeError: Cannot read property 'method' of undefined [02:34] rixius: at Function. (/home/rixius/node/fab/apps/fab.nodejs.js:19:24) [02:34] rixius: at Server. (/home/rixius/node/fab/apps/fab.nodejs.js:15:21) [02:34] rixius: at Server.emit (events:33:26) [02:34] rauchg_: that makes sense though [02:34] rixius: at HTTPParser.onIncoming (http:825:10) [02:34] rixius: at HTTPParser.onHeadersComplete (http:87:31) [02:34] rixius: at Stream.ondata (http:757:22) [02:34] rixius: at IOWatcher.callback (net:517:29) [02:34] cirwin: rixius: use a paste bin [02:34] rixius: at node.js:266:9 [02:34] steadicat has joined the channel [02:34] rixius: " [02:34] rixius: cirwin: not sure what that is... [02:35] cirwin: http://dpaste.org [02:35] mikeal: i can't wait for EventSource to land [02:35] cirwin: put the code in the box [02:35] cirwin: and then copy the url here [02:35] ncb000gt: rixius: you can paste that stuff into the box and send us a link [02:35] cirwin: so we can read it easily [02:35] polotek: cirwin: http://gist.github.com/ [02:35] ncb000gt: can do it with github gists too [02:35] rixius: k thx [02:35] polotek: er [02:35] polotek: rixius: [02:35] rixius: sorry guys [02:35] ncb000gt: all good :) [02:36] cirwin: mikeal: so, did you get anywhere with making it check the header - or shall I do that locally? [02:36] mikeal: i'm gonna do it this week [02:36] mikeal: yesterday I was pretty busy [02:36] rixius: here we go: (fab) error in node 0.1.100 :: http://gist.github.com/483951 [02:36] mikeal: and today I'm flying [02:36] cirwin: cool [02:36] mikeal: i can work on it now actually [02:36] cirwin: I look forward to it :) [02:36] softdrink has joined the channel [02:37] polotek: mikeal: so the ny meetup is happening? [02:37] mikeal: yes [02:37] mikeal: we found a place too [02:37] mikeal: I'm surprised Marak didn't send it out in an email yet [02:37] ncb000gt: polotek: you going up? [02:38] polotek: ncb000gt: yeah thinking about it [02:38] ncb000gt: mikeal: it's saturday yea? [02:38] mikeal: starting the descent, gonna have to get off soon [02:38] mikeal: yes [02:38] webandy: anyone using node-websocket-server? http://github.com/miksago/node-websocket-server [02:38] mikeal: 24th [02:38] ncb000gt: polotek: cool, i have to be back sunday am tho, not sure I'll be able to do that [02:38] mikeal: anyone know where I can order delivery food in Brooklyn around midnight? [02:39] rauchg_: mikeal: grubhub.com ? [02:39] polotek: word [02:39] polotek: ncb000gt: I don't know how I'm getting there yet [02:39] rauchg_: mikeal: or mongodb [02:39] rauchg_: it does everything [02:40] mikeal: hahahah [02:40] ncb000gt: there is a train that leaves at 6:20 am and gets there at 9:40 [02:40] mikeal: do i need to order my food twice to make sure it gets here? [02:40] mikeal: zing! [02:41] mscdex: webandy: having a particular problem or? [02:42] ncb000gt: polotek: there is a return trip leaving at 11 pm and gets in at 2:30am [02:42] webandy: mscdex: I'm adding a listener for "request" event for "regular" non-websocket requests, but the browser/http client just hangs [02:43] polotek: ncb000gt: could do that [02:49] JimBastard has joined the channel [02:51] _announcer: Twitter: "node-control: capistrano the #nodejs way ;) - http://bit.ly/atbfzo" -- Sébastien. http://twitter.com/arnaudsj/status/19043688455 [02:51] JimBastard: does anyone feel like testing out a new library? i could use a sanity check that these values actually are real. doing pure js encryption for md5, sha1 , sha256, sha512, ripemd160. im about to write the docs [02:51] JimBastard: http://github.com/Marak/node_hash/blob/master/node-demo.js [02:51] JimBastard: 5f4dcc3b5aa765d61d8327deb882cf99 seems right for md5 "password" [02:52] JimBastard: i dont really understand how this stuff works, its all magic [02:53] SubStack: md5('password') == '5f4dcc3b5aa765d61d8327deb882cf99' [02:53] SubStack: oh wait [02:53] SubStack: hmmm [02:53] _announcer: Twitter: "Going to try and "make install" node.js just to try it out. Kinda of silly as I have enough to learn already, but wth. :D" -- jimmyc3po. http://twitter.com/jimmyc3po/status/19043872520 [02:54] JimBastard: i should probably like write down the values so we can unit test them, i got that salt too [02:54] JimBastard: lol uhh [02:54] cirwin: what encoding is it hashing in? [02:54] SubStack: yep, had a newline all up in there [02:54] JimBastard: cirwin: what you mean? [02:54] cirwin: well, md5 works on bytes [02:54] cirwin: strings in javascript are utf-16? [02:54] cirwin: or ucs-2 [02:54] cirwin: even [02:54] JimBastard: rstr2hex [02:54] JimBastard: ? [02:55] mscdex: lol [02:55] JimBastard: its all in the code [02:55] stepheneb has joined the channel [02:55] JimBastard: its pretty bad ass [02:55] JimBastard: way better then some patorjk crap [02:55] JimBastard: pretty battle hardened, ill put the links up in the docs [02:57] JimBastard: !tweet @jimmyc3po if you have any questions just hop in #node.js on irc.freenode.net lots of answers! [02:58] teejayvanslyke has joined the channel [03:02] wilmoore has joined the channel [03:03] Validatorian: if anyone is interested, you can get a $0.99 domain from godaddy right now using coupon BEATHEAT99 -- just in case somebody wanted a domain for their node app :) [03:04] Validatorian: for a .com, that is [03:04] Validatorian: comes out to 1.17 after taxes/fees whatever [03:06] jesusabdullah: That's not bad! [03:06] isaacs has joined the channel [03:08] isaacs: JimBastard: doesn't the crypto lib already have hashing? [03:08] astrojp has joined the channel [03:09] JimBastard: isaacs: isnt it a c add on? [03:09] isaacs: JimBastard: nono, require("crypto") [03:09] isaacs: i mean, yeah, it's in c [03:09] isaacs: but it's part of node natives [03:09] JimBastard: hrmm did i just fail hard? checking [03:09] Validatorian: ouch [03:09] astrojp: It's been so long since I've have to "make install" anything. is it recommended to be root or not? :/ [03:09] mscdex: heh [03:09] mostlygeek has joined the channel [03:10] astrojp: s/have/had [03:10] _announcer: Twitter: "OK, node.js is pretty hot. But you knew that already, right?" -- Robert Smith. http://twitter.com/smithrobs/status/19044992519 [03:10] isaacs: astrojp: personally, i recommend chown-ing /usr/local, and not using sudo [03:10] JimBastard: yeah isaacs i just failed hard, when did that get added? [03:10] isaacs: JimBastard: hahaha, it's ok [03:11] isaacs: JimBastard: not sure. time dilation. this year? [03:11] JimBastard: faaaaillllllll [03:11] polotek: JimBastard: if it's pure js you should release it anyway [03:11] JimBastard: polotek: why bother? [03:11] chilts: it's already on GitHub :) [03:11] chilts: so it's already released [03:11] chilts: though I guess to npm would be good [03:11] polotek: JimBastard: so other people can enjoy the fail [03:12] chilts: JimBastard: sometimes the pure-JS things are easier to deal with (as in installation) [03:12] isaacs: JimBastard: it'd be good if it didn't have to do crypto.createHash("sha1").update(s).digest("hex") [03:12] isaacs: JimBastard: the API is wonky. [03:12] JimBastard: i could just wrap that [03:12] isaacs: suresure [03:12] polotek: word [03:12] jesusabdullah: This is the hash lib we're talking about? [03:12] isaacs: yank out like 90% of your code :) that's always fun [03:12] JimBastard: http://pajhome.org.uk/crypt/md5/ [03:12] astrojp: isaacs: I can do that as well, just curious. Thanks. [03:12] astrojp has left the channel [03:12] jesusabdullah: hmm! [03:13] JimBastard: jesusabdullah: and http://github.com/marak/node_hash [03:13] jesusabdullah: *nod* [03:13] JimBastard: isaacs: do you have any copy pasta examples of doing the crytpo in node? is that line you pasted the real api? [03:14] chewbranca has joined the channel [03:14] JimBastard: is there any utility in wrapping the existing http://nodejs.org/api.html#crypto-236 for sugar syntax? [03:15] JimBastard: hash.md5(string); [03:15] JimBastard: hash.md5(string, salt); [03:15] JimBastard: hash.sha256(string); [03:15] JimBastard: hash.sha256(string, salt); [03:15] JimBastard: etc [03:15] isaacs: JimBastard: yes. look in npm's guts. link.js and utils/registry/adduser.js both use sha1 hashing. lib/utils/ini.js uses the crypt/decrypt stuff [03:15] JimBastard: thanks [03:16] isaacs: JimBastard: having a wrapper around that would be good. note that the crypto hashing actually lets you specify chunks, which is nice. you could keep updating it with chunks of a file download, and then verify it at the end or something, without ever keeping all of it in memory [03:16] JimBastard: that doesnt sound super simple to me [03:16] JimBastard: :-) [03:16] isaacs: that's why it's update(str) rather than hash(str0 [03:16] mape: redfin, hmm [03:16] isaacs: no, it's not simple. it's flexible. [03:16] JimBastard: totally [03:16] JimBastard: ill wrap that shit [03:16] isaacs: if you could somehow make it as simple, but still be flexible, then that'd be bwawsum [03:17] JimBastard: so i can easily just do it synchronously on strings [03:17] JimBastard: if anyone wants the low-level, its right there [03:17] JimBastard: ill just make it simple, it is already flexible [03:17] JimBastard: should be easy now, docs trying it out [03:17] micheil has joined the channel [03:18] JimBastard: major fail has been downgraded to minor fail. [03:18] JimBastard: apartment jail! [03:18] isaacs: apartment jail? [03:18] isaacs: i thought you got that little "house arrest" thing lifted? [03:18] JimBastard: lol [03:18] JimBastard: no apartment jail! [03:19] JimBastard: http://www.google.com/search?q=apartment+jail&hl=en&prmd=v&source=univ&tbs=vid:1&tbo=u&ei=_mZGTLXcBsSqlAeBv4XuAw&sa=X&oi=video_result_group&ct=title&resnum=1&ved=0CB0QqwQwAA [03:19] JimBastard: its the name of our apartment [03:19] JimBastard: one of the deadbolts is actually a lock on both sides (no knob), so you can lock people inside [03:19] JimBastard: and all the windows are bolted [03:19] JimBastard: scary stuff [03:20] isaacs: JimBastard: THIS IS AWESOEM [03:20] JimBastard: i should really get that lock fixed [03:20] JimBastard: the place came like that [03:20] isaacs: "who is your daddy and what does he do?" "he's dead, you know that." [03:20] JimBastard: isaacs: they are like 10 mins long, i wanted them edited to 3 minutes. i hate our editor [03:20] JimBastard: who is of course my good friend sergi [03:22] isaacs: i had a place in san diego like that [03:22] isaacs: it was pretty awesome. we one time did lock someone inside by accident. didn't realize he was asleep in the guest room. [03:24] micheil: pgriess: ping [03:24] polotek: I hate when I finally have an occasion to use a little know feature [03:24] polotek: that isn't covered by tests [03:24] polotek: and find that it's pretty buggy [03:24] polotek: and has been for a while [03:27] JimBastard: which one polotek ? [03:27] polotek: libxmljs [03:27] polotek: sax parser is kinda... busted [03:31] polotek: ah, not necessarilly busted [03:31] polotek: just misleading [03:33] PyroPeter has joined the channel [03:34] bradleymeck1 has joined the channel [03:35] bradleymeck1: ah back again [03:37] isaacs: bradleymeck1: hey, dude [03:37] isaacs: bradleymeck: so, i'm thinking about npm ls... [03:38] isaacs: bradleymeck: and, i think perhaps your original idea to make it "npm search" makes more sense. [03:38] satori_: polotek: whats ur problem with SAX in libxmljs? [03:38] isaacs: but i still want to use the --format stuff for npm ls, but still use npm ls as a simple grep [03:39] polotek: satori_: I don't need help. I'm the maintainer ;) [03:39] satori_: so whats broken? [03:39] pavan_ has joined the channel [03:39] polotek: nothing. just me being dumb [03:39] satori_: I have used it with much successw :P [03:40] polotek: basically it returns the list of attributes in a different format then I intended [03:40] polotek: well it wasn't my intention because I didn't write most of it [03:40] polotek: inherited it [03:43] _announcer: Twitter: "Getting back into #nodejs again, how I've missed you!" -- Marc Harter. http://twitter.com/wavded/status/19047243654 [03:48] _announcer: Twitter: "@gleicon haven't used Twisted or Node.js, EventMachine has shown extremly efficient, but code complexity tends to skyrocket. #OffTopic" -- NoSQL Update. http://twitter.com/nosqlupdate/status/19047516575 [03:53] [[zzz]] has joined the channel [03:54] isaacs: any of you guys check out this node-control thing? [03:54] mape: what is it? [03:54] satori_: not yet. just saw it [03:54] _announcer: Twitter: "@whalec @gabehollombe on CoffeeScript and @rioter on Node.js" -- Craig Sharkie. http://twitter.com/twalve/status/19047962080 [03:54] isaacs: http://github.com/tsmith/node-control [03:55] isaacs: remote admin ftw [03:55] devongovett: isaacs: that looks really nice. [03:55] isaacs: not completely in love with using child_process to just kick off ssh, though. seems like cheating or something [03:55] mape: well that looks neat [03:56] isaacs: but the api is cure [03:56] polotek: hmmm [03:56] isaacs: *cute [03:56] micheil: isaacs: npm ls == list local modules, npm search == search on remote providers [03:56] polotek: how do parsers usually handle self-closing tags? [03:56] devongovett: isaacs: I guess making it work is the first step. [03:56] isaacs: micheil: well, npm list should be remote if you ask it to list remote things [03:56] polotek: as in how do they usually make it know that the tag was self-closing? [03:56] isaacs: micheil: i'm thinking about something like this: have npm ls work like ls. [03:57] isaacs: micheil: so, if you npm ls installed, you see installed modules. if you npm ls installed/foo you get all the installed versions of foo [03:57] isaacs: just decide how the "folder" structure should be, and if you do -l or whatever, then you get all kinda info [03:58] nate_ has joined the channel [03:58] nate_: anyone out there familiar with connect and express? [03:59] nate_: I'm trying to get familiar with them by running the express examples but all I get is "Each layer must have a route and handle function" error [04:01] polotek: night all [04:01] polotek has left the channel [04:01] micheil: isaacs: npm list module_name => list of all installed versions of module [04:01] micheil: drop the installed/ part [04:01] isaacs: yeah [04:01] micheil: npm list shouldn't have a remote part. [04:02] cirwin: would it be possible to dump a load of state to a file in process.on('exit'), or is it better to do that in a setInterval? [04:02] micheil: npm search without arguments lists all remote available modules [04:02] isaacs: micheil: http://gist.github.com/484037 [04:02] micheil: (could be absolutely frcikin massive) [04:02] micheil: nawh [04:02] micheil: doing that adds complexity. [04:02] isaacs: maybe even eventually let you delve into the package contents [04:02] micheil: it's not needed [04:02] isaacs: yeah, i guess... [04:03] isaacs: ACTION sadface [04:03] _announcer: Twitter: "node.js" -- Anthony Ptak. http://twitter.com/axoxnxs/status/19048502063 [04:03] micheil: also, for package contents, it could be npm edit module [04:03] isaacs: i mean, list out the contents of a remote packag. [04:03] JimBastard: !tweet @axoxnxs woot woot [04:03] isaacs: like, inspect it from the registry [04:03] micheil: or, npm unpack module [04:03] micheil: npm spec module [04:04] micheil: with optional --remote flag [04:04] micheil: would show the package.json printed nicely [04:04] nuxusr has joined the channel [04:04] isaacs: i think npm ls like this would be great if it had tab-completion [04:05] nuxusr: does npm have an upgrade all option? [04:05] isaacs: nuxusr: no, sadly [04:05] micheil: but there's really no need to write a command to list the contents of a package (files), I'd just have an npm unpack module / npm edit module [04:05] nuxusr: do you upgrade individual by running install on the same pkg again? [04:05] micheil: (these be personal opinions on package managers) [04:06] micheil: isaacs: we could write a tab completion, but I follow the ideas of least complexity. [04:06] isaacs: micheil: yeah, those are faraway features (edit/unpack) [04:06] isaacs: nuxusr: yessir [04:06] micheil: well, for now you could just do open in say finder the package directory [04:06] nuxusr: isaacs: thanks [04:07] _announcer: Twitter: "Had a great time at Layton.rb tonight. Props to the guys at Divergent Logic for hosting the group and for dinner! Covered Couch.db & node.js" -- Travis. http://twitter.com/mxmissile/status/19048758220 [04:07] isaacs: micheil: well, in many instances there's no "finder" [04:07] micheil: or, npm which module => shows location of module on FS [04:07] micheil: isaacs: do that then ^^ [04:07] nuxusr: isaacs: is there a command to list all installed? [04:07] isaacs: nuxusr: npm ls installed [04:07] nuxusr: cool [04:08] isaacs: micheil: that right there ^^ is HANDS DOWN the most common question i answer about npm. [04:08] sudhirj has joined the channel [04:08] isaacs: nuxusr: (thanks for being a good example) [04:08] micheil: isaacs: npm list shouldn't hit the server. [04:08] isaacs: nuxusr: i should start telling people to guess the answer to that, and then implement whatever they say [04:08] isaacs: micheil: agreed, that's why i'm looking at it [04:08] micheil: so, search is for remote [04:09] micheil: and list is for local [04:09] isaacs: micheil: no, i want to be able to list all the remote packages with the sme command. [04:09] isaacs: micheil: but it should be a little smarter. [04:09] micheil: (list, L for local && search, S for server?) [04:09] [[zzzz]] has joined the channel [04:09] micheil: okay, node list --remote [04:09] isaacs: yes yes, it's very clever, but the second most common question is "how do i list all the remote packages?" [04:09] isaacs: not "how do i search for packages" [04:10] micheil: yeah, I suppose [04:10] _announcer: Twitter: "@rwang0 e.g. http://nodejs.org/" -- Paul Fallon. http://twitter.com/paulfallon/status/19048969482 [04:10] micheil: so, yeah, by default make it not hit the server [04:10] isaacs: so, with ls being a virtual folder-structure (and a tab-completion script), you could just not hit the server until you need to, and the server responses would be way smaller and less data to munge [04:11] isaacs: and, actually, a lot of server traffic could be limited if i was doing the ETag dance properly [04:11] micheil: isaacs: I don't like the idea of directories, command line flags are a norm. [04:12] isaacs: yeah, maybe it's too weird [04:12] isaacs: i dunno [04:12] micheil: do a poll? [04:12] nuxusr: is there a way to list out of date packages or do i need to right a quick script? [04:12] isaacs: oh, god, no [04:12] micheil: I just like the idea of npm * --remote for hitting the server [04:12] isaacs: nuxusr: npm ls @installed | grep -v @latest [04:12] micheil: nuxusr: npm list and look at the blue [04:14] micheil: isaacs: also. I'm going to patch that help file for npm-help. it annoys the shit out of me. [04:14] isaacs: er, grep -v latest, no @ [04:14] isaacs: micheil: which one? [04:14] micheil: man npm-help [04:14] isaacs: oh, no, don't yet [04:14] micheil: :( [04:14] isaacs: i have almost a complete rewrite in progress. [04:14] isaacs: i'd <3 a review and edit and feedback, though, that'd rock [04:14] micheil: okay, that's good [04:14] nuxusr: been a great help! thanks [04:14] isaacs: nuxusr: no problem :) [04:15] micheil: isaacs: I think you may have too many commands. [04:15] micheil: seriously, what do half of them do?! [04:15] isaacs: micheil: well, a lot of them reuse each other. but yeah. some of the docs are way too low-level. [04:15] davidwalsh has joined the channel [04:15] isaacs: like, you'd probably never do npm build by hand. [04:15] micheil: this calls for a gist. [04:16] mape: npm upgrade * [04:16] isaacs: mape: that'd rock, yes. [04:17] mape: guess you get into sticky stuff though when you start mixing stable/latest releases though [04:17] mape: though, though and though [04:18] mape: But yeah, a simple upgrade the stuff I have and remove previous versions would be lovely [04:18] isaacs: micheil: http://github.com/isaacs/npm/blob/master/doc/help.md#readme [04:18] mape: npm 1.2.0 is out? [04:19] isaacs: mape: no, 0.1.20 [04:19] mape: *0.1.20 [04:19] isaacs: hehe [04:19] mape: but it isn't on npm? [04:19] isaacs: 1.x is like, WAY far out there :) [04:19] creationix has joined the channel [04:19] isaacs: mape: http://registry.npmjs.org/npm/0.1.20 [04:19] isaacs: sure it is [04:19] mape: shouldn't npm install npm get that? [04:19] mape: npm install Nothing to install [04:20] isaacs: mape: bug in 0.1.19. npm install npm@latest [04:20] mape: oh k [04:20] isaacs: won't happen again, i hope :) [04:20] mape: hehe [04:20] mjr_: mape: what new amazing thing have you cooked up this week? [04:20] micheil: isaacs: http://gist.github.com/484051 [04:21] mape: mjr_: nothing :/ vacation is takings its toll on me [04:21] mjr_: Oh man, that sounds exhausting. [04:22] isaacs: micheil: a lot of those aren't actually commands. [04:22] _announcer: Twitter: "Gonna play with Geddy (web framework for Node.js) soon enough - http://goo.gl/b9Yp" -- John Lawson. http://twitter.com/erator/status/19049700458 [04:22] mape: hehe yeah [04:22] isaacs: micheil: they're just helpdocs [04:22] micheil: >_> [04:22] isaacs: "npm json" isn't a command... it's that "npm help json" has help about what your json file should look like [04:22] isaacs: same with "npm scripts" [04:22] micheil: I disagree with it being there then. [04:23] micheil: npm documentation / npm docs [04:23] mape: hmm npm ! Error: ENOENT, No such file or directory '/home/mape/.node_libraries/.npm/npm/0.1.10/package/package.json' at node.js:266:9 [04:23] micheil: opens browser at documentation [04:23] isaacs: mape !? [04:23] mape: so I can't remove the old versions [04:23] isaacs: mape: 0.1.10? [04:24] mape: I'm trying to remove all the old npm versions [04:24] Blink7 has joined the channel [04:24] isaacs: mape: well, you could just do this: rm -rf ~/.node_libraries/.npm/npm/0.1.10 ~/.node_libraries/npm-0.1.10.js /usr/local/bin/npm-0.1.10 [04:24] mape: I have 10,13,16-link,16,17,19 installed and want them gone, but get that error when I do npm uninstall npm@0.1.10 [04:25] _announcer: Twitter: "Finally tracked down a bug in #node.js that was causing my http headers to eat 40k of traffic occasionally. Updated Ivy to latest node." -- Tim Caswell. http://twitter.com/creationix/status/19049874444 [04:25] isaacs: mape: ok, here's a faster way: rm -rf /usr/local/bin/npm* ~/.node_libraries/npm* ~/.node_libraries/.npm/npm [04:25] isaacs: mape: then: curl http://npmjs.org/install.sh | sh [04:25] mape: then I loose all the thingys I have setup and my user? [04:25] steadicat has joined the channel [04:26] isaacs: mape: no, i'm only deleting npm itself, not all npm's goodies. [04:26] mape: hmm k [04:26] isaacs: mape: your .npmrc file is file, as is .npm/{other stuff} [04:26] isaacs: *file is fine [04:26] creationix: isaacs: ok, I'm going to try to bundle npm with ivy again [04:26] creationix: didn't work so well last time [04:27] isaacs: creationix: i think there are a few blocker issues, no? [04:27] isaacs: creationix: like, relative paths, some other things maybe? [04:27] creationix: isaacs: well to work the way I want yes, but at least it should work at all [04:27] isaacs: creationix: at all is good :) [04:28] creationix: isaacs: so the problem I think is that ivy is convention over configuration [04:28] creationix: there is no need for package.json with ivy modules, you just have to structure you app a certain way [04:28] creationix: app/module [04:28] isaacs: creationix: that's certainly a way to do it. [04:29] isaacs: creationix: what about dependencies? just use git for everything? [04:29] isaacs: submodules or whatever? [04:29] creationix: isaacs: yeah, I don't have any dependency management [04:29] creationix: or version management [04:29] creationix: it's really quite simple, but it would be nice to layer npm on top of that for modules not bundled [04:29] isaacs: sure [04:30] isaacs: i mean, from that pov, you could just say that npm is one ofthose things you bundle [04:30] creationix: exactely [04:30] creationix: but it needs to be the format I expect [04:30] isaacs: haha [04:30] isaacs: do you expect to have a main script in the root of the project that is named the same as the project? [04:30] isaacs: like /npm.js? [04:30] creationix: isaacs: executables go in /bin [04:31] creationix: and can be called whatever you want them to be [04:31] creationix: and they assume that the lib they depend on is installed in the library path [04:31] isaacs: why not just read the package.json for that? [04:31] temp01 has joined the channel [04:31] isaacs: it's SO easy [04:31] creationix: and libraries go in /lib/packagename.js or /lib/packagename/index,js [04:31] creationix: reading and parsing json isn't so easy with bash [04:32] isaacs: oh, you're writing this in bash? [04:32] creationix: I am, but I might change that [04:32] isaacs: i'd recommend it. [04:32] Tim_Smart has joined the channel [04:32] creationix: I just want it as simple as possible [04:32] creationix: bu [04:32] mjr_: yeah, bash is cute, but probably best only for bootstrapping things. [04:32] creationix: but since I'm including a binary of node [04:32] isaacs: feel free to use any of the chunks of npm that you might find useful. [04:32] creationix: yeah, I think only the bootstrapper will be bash, the rest wil be node [04:33] mjr_: You could make a simple node program that converted JSON into bash commands, and then eval the output in bash. [04:33] creationix: bleh [04:33] isaacs: your sh script could just be something like: ./bin/node ./some-node-program.js [04:33] creationix: isaacs: well, currently my bootstrapper first downloads the node binaries [04:34] creationix: but yeah, then it can call the other commands [04:35] creationix: there is no execsync in node is there? [04:36] nate_: anyone know why I get a "Each layer must have a route and a handle function" error when trying to run the express examples? [04:37] creationix: nate_: sounds like an old version of connect [04:37] creationix: tj tells me the version is npm is out of data [04:37] creationix: *date [04:37] nate_: yeah that is what I thought [04:37] nate_: so i should pull down the latest connect? [04:37] isaacs: creationix: dude, publish the new versin [04:38] creationix: nate_: yeah, I think express depends on a new version [04:38] creationix: isaacs: I'm not the publisher [04:38] rixius has joined the channel [04:38] dnolen has joined the channel [04:38] creationix: connect/spark has been in flux lately getting ready for the 1.0 release [04:38] creationix: it's about there, just needs the docs updated now [04:38] rixius: is there an easy way to inject the results of a require() into the global variable? [04:39] nate_: creationix: how do I tell it to use the new version of connect [04:39] creationix: var lib = require('foo'); Object.keys(lib).forEach(function (key) { global[key] = lib[key];}); [04:39] creationix: rixius: ^ [04:39] rixius: creationx: thanks [04:40] creationix: rixius: some day node might have import again, it does that [04:40] creationix: nate_: hmm, you have to modify your library path [04:40] creationix: you can just unshift in the first line of your app [04:40] creationix: or use the NODE_PATH environment variable [04:42] _announcer: Twitter: "Node.js much trouble ... I've been on the server you are gone do in the heat" [ja] -- 天沢(痛風). http://twitter.com/amasawa/status/19050901885 [04:42] mape: npm ls installed | awk -F @ '{print $1}' | xargs npm install [04:42] mape: :) [04:42] jesusabdullah: wait, what? [04:43] isaacs: mape: yeah, that woks [04:43] isaacs: mape: well, that works with npm@>=0.1.20 [04:43] isaacs: mape: npm ls installed | awk -F @ '{print $1}' | while read pkg; do npm install $pkg@latest; done [04:44] mape: or just append to the print? [04:44] isaacs: mape: or: npm ls installed | awk -F @ '{print $1@latest}' | xargs npm install [04:44] isaacs: yeah [04:44] creationix: isaacs: why does your bin require a shim to be generated [04:44] isaacs: creationix: so that relative links from the executables will work as expected [04:45] creationix: why not just use global links? [04:45] creationix: assume npm is in the path [04:45] isaacs: creationix: otherwise every executable has to do some backflips to figure out where it really lives (if it's a symlink) and you end up with dependency hell, because they all need their deps to be globals. [04:46] isaacs: creationix: this way, you can have two bins that require different versions of the same library [04:46] isaacs: and *don't work* with each others' version [04:46] creationix: I see [04:46] isaacs: not that this is un possible in ruby and perl and php nad most other languages. [04:46] creationix: but the cost is that you HAVE to generate shims to install it [04:46] micheil has joined the channel [04:46] isaacs: creationix: sure, but that's like, one function and one extra file open at startup time [04:46] mape: isaacs: http://gist.github.com/484079 (happens when I do npm install and use tons of wonky stuff as args) [04:47] isaacs: mape: can you paste the entire log, with the command you ran? [04:47] isaacs: curious about that [04:47] siculars has joined the channel [04:47] isaacs: creationix: really, it's not any harder than creating a symlink, from my pov [04:47] mape: isaacs: refresh [04:47] isaacs: creationix: npm creates shims all over the place. [04:48] _announcer: Twitter: "Yahoo Post: “Multi-Core HTTP Server with NodeJS” http://ping.fm/7K2gd" -- J. Aaron Farr. http://twitter.com/jaaronfarr/status/19051245290 [04:48] isaacs: mape: oh no! [04:48] isaacs: mape: yeah, that's super weird. [04:48] isaacs: don't do that [04:48] mape: ha HA! [04:48] mape: yeah I know, seems the alias for the update thingy went crazy [04:48] nate_: creationix is a layer the same as middleware in that error line or what does "Each layer must have a route and a handle function" mean? [04:49] creationix: nate_: yes, a middleware module is a layer [04:49] creationix: connect changed api's a while back [04:50] creationix: before it was two functions, setup, and handle [04:50] creationix: now it's a single function that returns a handler [04:50] mape: creationix: btw what caused the http bug? [04:50] creationix: mape: Buffer.prototype.toString [04:50] creationix: of all things [04:50] mape: ah k [04:51] mjr_: Basically 0 length buffers are odd. [04:51] nate_: so the examples are maybe out of date? http://github.com/visionmedia/express/blob/master/examples/jade/app.js [04:51] mjr_: not tested, etc. [04:51] creationix: when the 40k chunk of http data started on \r\n, it would call the onHeaderData callback and tell it to consume 0 bytes off the bugger [04:51] creationix: mape: and toString saw the falsy 0 and thought it was undefined and intrepreted it as the default of "entire buffer" [04:52] creationix: s/bugger/buffer/ [04:52] mape: the ole falsy and truthy [04:52] creationix: yep [04:52] isaacs: creationix: that's a fantastic bug. [04:52] isaacs: creationix: great find, dude! [04:52] creationix: isaacs: thanks, it was a nightmare tracking it down [04:52] isaacs: creationix: yeah, seriously [04:52] creationix: it's hard to reproduce because you have to line up the data just right by accident [04:53] isaacs: even the old "go one byte at a time, now go two bytes at a time, ..." style of stream test would still maybe never have caught that. [04:53] mape: should just make sure to use === [04:53] nuxusr: noobie node.js question: "ls = spawn('ls', ['-lh', '/usr']);" -> does that immedatly start the process? if so, why can i do a "ls.stdout.on('data', function (data) {" after its been spawned and not worry about missing part of the data? [04:53] lachlanhardy has joined the channel [04:53] isaacs: or, it wouldn't have looked odd, because you'd probably only see it when going 2 bytes at a time, and then "entire bufer" would not be weird to skip over. [04:53] creationix: nuxusr: because even if the data fires before your callback [04:54] creationix: it won't enter the event loop till after you've set the callbacks [04:54] creationix: node is single threaded [04:54] creationix: events only "happen" at the end of sync chunks of code [04:54] nate_: q [04:54] _announcer: Twitter: "ep.51 nodeJS with Julius Sirait and Cliffano Subagio: In this episode learn about nodeJS Widha Ronald ... http://bit.ly/9Z1Zp9" [id] -- TeknoJurnal. http://twitter.com/teknojurnal/status/19051615275 [04:54] micheil: creationix: connect + nws === awesome. [04:54] jesusabdullah: nws? [04:54] jesusabdullah: ACTION feels dumb [04:54] micheil: jesusabdullah: node-websocket-server [04:54] jesusabdullah: oh [04:54] jesusabdullah: rite [04:54] micheil: yeah [04:55] micheil: lachlanhardy: oh shit. same timezone again :P [04:55] creationix: micheil: cool [04:55] lachlanhardy: ha [04:55] lachlanhardy: just got back from lunch [04:55] micheil: lachlanhardy: I'm yet to have some [04:55] lachlanhardy: and *still* can't get express running on heroku :( [04:55] mape: micheil: got it working? on the same port? [04:55] nuxusr: creationix: sync chunks of code being the end of a file? [04:56] micheil: actually, lachlanhardy, we should organize a meetup in sydney around december / christmas. [04:56] creationix: nuxusr: yes, end of execution stack [04:56] micheil: I'll actually be up there this year [04:56] creationix: they are often quite short in node [04:56] micheil: mape: I could do. [04:56] creationix: but the initial one is the run though the entire file [04:56] maqr: anyone using google's closure libraries? [04:56] micheil: creationix: connect gives back a http.Server instance, right? [04:56] creationix: micheil: subclass of it, yes [04:57] micheil: well, yeah [04:57] micheil: so, it should emit the same events? [04:57] creationix: micheil: correct [04:57] micheil: okay, in which case: [04:57] nuxusr: creationix: cool... so another sync chunk being the data executed in the callback..? [04:57] jesusabdullah: http://code.google.com/closure/ <--these? [04:57] maqr: jesusabdullah: yeah, those [04:57] creationix: nuxusr: yep, ryah like to call them "ticks" [04:57] micheil: ws.createServer({server: ConnectServerInstance}); [04:57] micheil: (that's new api there.) [04:57] creationix: hence the process.nextTick function [04:58] nuxusr: creationix: ah, i saw that in the api.html [04:58] _announcer: Twitter: "Test units that had been running in a matter of minutes, finish in less than one second on the NodeJS http://ow.ly/2ejdT" [id] -- Teman Macet. http://twitter.com/temanmacet/status/19051843093 [04:58] maqr: jesusabdullah: the compiler makes sense, and the library mostly makes sense [04:58] maqr: jesusabdullah: the templates though... very confusing [04:58] lachlanhardy: micheil: for sure! [04:58] jesusabdullah: maqr: Huh! I see [04:59] creationix: nuxusr: process.nextTick means "after this tick of code, run this callback" [04:59] SubStack: google apis tend to have really crap style [04:59] micheil: lachlanhardy: perhaps something like a js + noSQL one? [04:59] Neil has joined the channel [04:59] jesusabdullah: Man there is a lot of crazy stuff out there for me to learn about/mess with [04:59] jesusabdullah: I hardly know where to start! [04:59] micheil: jesusabdullah: at the start? [04:59] jesusabdullah: Hah! [04:59] creationix: we need a node conference [04:59] jesusabdullah: Well, yeah [04:59] creationix: I'll help organize it [04:59] jesusabdullah: With this level of activity, you easily could [04:59] lachlanhardy: micheil: I don't even know if we have the latter, but i'm sure SydJS needs an end-of-year party ;) [04:59] creationix: or maybe start something like peep code [05:00] creationix: since the node community is so global [05:00] mjr_: We should bug ryah tomorrow about having a node conference. [05:00] creationix: a conference would keep too many people out, flying around the world is expensive [05:00] EyePulp: evening folks (for some it's evening, I imagine) [05:00] micheil: lachlanhardy: schweet! [05:00] maqr: creationix: we just need a more up to date wiki, where someone distills down the best modules for people to use [05:00] jesusabdullah: node is really different for me, having come from matlab-esque uses of programming [05:00] micheil: creationix: thinking of doing the peepcode style thing. [05:00] maqr: creationix: it's really overwhelming and there's no way to judge quality [05:01] jesusabdullah: I'm probably the only one here >_< [05:01] mjr_: creationix: yeah, but conferences get people together in the same place, really build a community. [05:01] creationix: mjr_: maybe both [05:01] Asparagusto has joined the channel [05:01] creationix: howtonode's purpose was to be like a peepcode style thing, but text and free [05:01] mjr_: There's certainly no reason NOT to put all information online as well. [05:01] creationix: maybe I should just write more articles [05:02] creationix: people seem to like them generally [05:02] mape: creationix: btw http://mape.me:1337/ is better then http://npm.mape.me/ [05:02] SubStack: click [05:02] mape: guess I should have it redirect.. [05:02] creationix: mape: love the port [05:02] jah_ has joined the channel [05:02] creationix: maqr: http://mape.me:1337/ [05:02] mape: it happened to be open [05:02] _announcer: Twitter: "Holy crap I'm actually doing it. Building a CMS using #NodeJS!" -- Danny F.G. http://twitter.com/buzzedword/status/19052115483 [05:02] maqr: creationix: unexpected [05:03] isaacs: i should really rename TESTING-please-ignore [05:03] isaacs: that package sucks [05:03] mape: hehe [05:03] mape: and what is the default sorting? [05:03] isaacs: mape: numerical, i'm pretty sure [05:03] creationix: mape: default to updated [05:03] isaacs: mape: ie, n > m [05:03] mape: Ah, crazy people doing uppercase [05:03] isaacs: since A < a, it puts Faker and TESTING-please-ignore-this at the top of the list [05:04] EyePulp: looking for best practices - I notice in the chat app they use a fu.js module, and within it they set fu = exports, and then do fu.foo = function(){};. in the module docs on the site (http://nodejs.org/api.html#_modules) the idiom is exports.foo = function(){} Is there a standard naming approach? (I would assume the exports.foo version makes it easier for everyone to read other modules, but...) [05:04] mape: creationix: yeah figured that updated is a nice way to sort [05:04] isaacs: EyePulp: i'm actually a big fan of doing: module.exports = MyThing [05:04] creationix: EyePulp: fu.js is ancient for one [05:04] isaacs: and then var myThing = require("my-thing") [05:05] creationix: yeah, what isaacs said [05:05] creationix: exactely [05:05] isaacs: then a module is one thing [05:05] isaacs: discourages "bag o stuff" modules. [05:06] SubStack: ACTION should do that [05:06] maqr: if everyone just tagged their packages as 'stable' or 'unstable', why couldn't packages just be checked out directly from git and autoupdated? i'm not quite sure i see the need for package management at all [05:06] EyePulp: fair enough - can either of you recommend a small but representitive sample project I could look at for starting off correctly? [05:06] _announcer: Twitter: "NodeJS... hm... javascript engine server side.. hm... cc: @temanmacet" -- Ferry Ardhana. http://twitter.com/fardhana/status/19052346062 [05:07] SubStack: can make it backwards compatable too by Thing.Thing = Thing [05:07] isaacs: maqr: dependency management, easily/lazily dropping stuff into node's path, and having less of "if everyone just..." [05:07] EyePulp: I'd like to learn decent Node idioms so I don't have to unlearn bad ones in a few months. =) [05:07] creationix: EyePulp: me too [05:08] creationix: ;) [05:08] EyePulp: heh [05:08] creationix: idoms are still revolving [05:08] creationix: I'm started to form my own in my projects, but I'm sure others have their own too [05:08] jesusabdullah: evolving? [05:08] jesusabdullah: -heh- [05:08] maqr: isaacs: so far, in my newbie and limited experience, i've had better results going right to git, to be sure i'm getting the latest package; or at least, that's how it seems to m [05:08] maqr: *me [05:08] creationix: s/revolving/evolving/ [05:09] jesusabdullah: Me, I'm making mistakes left and right I'm sure [05:09] EyePulp: that's fine. I'll just do one thing at a time and expect to re-factor more often [05:09] maqr: jesusabdullah: you're new here too? :) [05:09] jesusabdullah: Actually, if anyone wants to do a, umm [05:09] isaacs: maqr: totally. and there's nothing stopping you from doing that. [05:09] jesusabdullah: What's it called? [05:09] jesusabdullah: shit [05:09] isaacs: maqr: about half of the packages i have installed are just "npm link"-ed [05:09] jesusabdullah: CODE AUDIT [05:09] isaacs: maqr: which is just nice so that you can do require("something") [05:09] jesusabdullah: maqr: Yeah, showed up a week ago :) [05:09] maqr: isaacs: oh, so that's what that does [05:09] maqr: jesusabdullah: hey, me too [05:09] creationix: maqr: I have yet to use npm [05:09] isaacs: maqr: among other things [05:10] creationix: I prefer to install my dependencies by hand [05:10] creationix: or usually write them myself by hand ;) [05:10] maqr: isaacs: can you make npm call git to autoupdate the linked packages? because that'd be awesome [05:10] creationix: but I know that's not for everyone [05:10] isaacs: maqr: you can use git to call git :) npm link create a symlink [05:10] isaacs: maqr: "npm install" with no args will physically install the current directory [05:10] creationix: maqr: with Ivy I've gone the git route [05:10] isaacs: maqr: so then you'd have to npm install it again [05:10] mape: creationix: there, sorted by updated [05:11] creationix: no package management at all [05:11] maqr: isaacs: yeah, that's how i'm doing it right now, but it'd be nice to have an 'update all' button [05:11] isaacs: creationix: you have packages. you just aren't managing them. [05:11] _announcer: Twitter: ""Why do I Ruby / Sinatra I migrated to from node.js" (Utah Ruby User Group ML) http://groups.google.com/group/urug/browse_thread/thread/519f1f0d570d88e0" [ja] -- Toshihiro Shimizu. http://twitter.com/meso/status/19052585505 [05:11] isaacs: creationix: ;P [05:11] creationix: mape: update-all buttons are dangrous [05:11] maqr: creationix: i saw ivy, but i haven't looked much into it yet [05:11] mape: creationix: whaa? [05:12] creationix: one you get more than about 5 modules you can guarantee that an "update-all" will break something [05:12] isaacs: creationix: think you mean maqr, not mape [05:12] creationix: yes, maqr [05:12] mape: oh [05:12] maqr: mape: sorry :p [05:12] creationix: my eyes are very blurry, so I may not type well [05:12] isaacs: creationix: that is exactly why i haven't gotten around to update yet. it's kind of atricky thing to get right. [05:12] mape: maqr: yeah stop with the using similar nick, I was here first! ;) [05:13] maqr: creationix: i don't really see the danger in a development environment, if anything, i want to find new bugs by updating early and often :P [05:13] isaacs: the way i'm thinking it, "npm update foo" will update to the latest version of foo, or at least update foo to use newer versions of its deps if they're available. [05:13] maqr: mape: yeah, it's a little hard for me to change now though :/ [05:13] creationix: maqr: then you'll love ivy [05:13] isaacs: or something [05:13] maqr: creationix: haha [05:13] creationix: you can write a simple bash script to cd into each submodule and git pull [05:13] EyePulp: isaacs: your idiom is module.exports = YourModule -- you have an example I can look at? I promise I'll get smarter over time - I'm just a bit slow starting. =) [05:13] creationix: EyePulp: i've got a few [05:14] isaacs: EyePulp: check out the npm codebase. almost every module works that way. http://github.com/isaacs/npm [05:14] creationix: http://github.com/creationix/nstore/blob/master/lib/nstore.js#L495 [05:14] EyePulp: line # ftw =) [05:14] isaacs: EyePulp: http://github.com/isaacs/npm/blob/master/lib/utils/chain.js [05:14] isaacs: EyePulp: http://github.com/isaacs/npm/blob/master/lib/utils/cp.js [05:14] isaacs: you get the idea. [05:14] creationix: http://github.com/creationix/step/blob/master/lib/step.js#L153 [05:14] BrianTheCoder has joined the channel [05:15] isaacs: usually the first line [05:15] creationix: heh, last line in mine [05:15] EyePulp: you guys are showing off now. [05:15] EyePulp: =P [05:15] creationix: I just develop without worrying about modules, and then at the last export that I want public [05:15] EyePulp: ACTION heads off to read a bit [05:15] mape: isaacs: ;(function S ? [05:15] jesusabdullah: Last line for me, but that's just cause that's what I saw first [05:15] mscdex: is there a way to find out the caller of a function within that function? [05:15] isaacs: mape: yeah? [05:16] mape: whats the use for the ; ? [05:16] satori_: arguments.callee [05:16] mscdex: callee refers to the function itself [05:16] jesusabdullah: Girlfriend distracted me--wants me to download ebooks for her soon-to-be-owned Nook [05:16] satori_: ahh [05:16] isaacs: mape: i prepend the line with a ; when it starts with [ or (, for safety [05:16] mscdex: there used to be arguments.caller, but it's removed now [05:16] robotarm_ has joined the channel [05:16] mape: hmm k [05:16] EyePulp: so is "module" a reserved word/object ? [05:16] isaacs: mape: http://github.com/isaacs/npm/blob/master/doc/coding-style.md#readme [05:16] creationix: mape: it's a good idea when you like to skip semicolons [05:16] isaacs: EyePulp: not reserved, but it is a free var [05:17] mscdex: i'm surprised they removed it, it makes debugging a much easier task [05:17] jesusabdullah: Aww [05:17] mscdex: :/ [05:17] jesusabdullah: ACTION rolls four spaces [05:17] isaacs: mscdex: it's still there. arguments.callee.caller. [05:17] jesusabdullah: Habit from python [05:17] isaacs: mscdex: it's Function#caller [05:18] mscdex: hmm [05:18] isaacs: mape: like creationix said, you can either put semicolons everywhere, whether you need them or not, or you can just use them when they're relevant, which i do. [05:18] mscdex: ah yes, there we go. thanks [05:18] mape: isaacs: jup [05:19] creationix: well, off to bed [05:19] mattly has joined the channel [05:19] SubStack: two spaces -_- [05:20] SubStack: actually two spaces isn't so bad [05:20] SubStack: it's three spaces that really gets to me [05:20] SubStack: three spaces is worse than using tabs [05:21] mape: and using tabs is far superior to spaces :P [05:21] isaacs: tabs are like haskell. [05:22] isaacs: 100% perfect and ideal and right for all kinds of correct reasons. [05:22] isaacs: but fuck tabs. [05:22] maqr: jesusabdullah: so far i've figured out that connect is the thing to use for http, nun is a sweet templating engine, and i have a general understanding of how to write node code properly asynchronously [05:22] maqr: jesusabdullah: now i'm trying to figure out how to interact with the client properly, and that's why i'm looking at closure [05:23] mscdex: now if i could just get the line of code from Function.caller [05:23] mscdex: heh [05:23] isaacs: mscdex: you can just check (new Error()).stack [05:23] isaacs: mscdex: that has that info [05:23] mscdex: hmmm [05:23] EyePulp: isaacs: so when you use "module.exports = whatever", when/where is "module" getting initialized? I'm coming from python & client side js, so if this is basic stuff forgive me. [05:24] mscdex: let me give it a whirl [05:24] rictic has joined the channel [05:25] isaacs: EyePulp: http://github.com/ry/node/blob/master/lib/module.js#L418-420 [05:26] tekky has joined the channel [05:26] EyePulp: isaacs: ah - so it's initialized in the node core [05:26] isaacs: EyePulp: exactly [05:27] mscdex: that works, but it doesn't show very much. i'm trying to find out why an event is being emitted... [05:27] jesusabdullah: maqr: All I've really done is play with Jerk and IRC-js, so no explicit sockets, etc. for me yet [05:28] maqr: jesusabdullah: hmm, those are two i haven't looked at yet... what's jerk? [05:28] EyePulp: thanks for looking that up - I know these aren't very crucial questions, but I like to know why I use the idioms I'm using. [05:28] _announcer: Twitter: "ep.51 nodeJS with Julius Sirait and Cliffano Subagio - In the episode this time Ronald Widha nodeJS learn about da ... http://ow.ly/18dPD0" [id] -- Teman Macet. http://twitter.com/temanmacet/status/19053451375 [05:28] mape: not ok to link to strange language podcast [05:29] jesusabdullah: Huh! I didn't know you didn't need brackets on one-liners [05:29] jesusabdullah: maqr: jerk's an irc bot library [05:30] maqr: jesusabdullah: ah, ok [05:30] jesusabdullah: http://github.com/jesusabdullah/lulzbot has been using it :) [05:30] jesusabdullah: that's my only thing so far [05:30] maqr: jesusabdullah: cool, irc sucks to work with, but i bet it sucks less in node [05:30] jesusabdullah: but I'm gonna try to dig into client/server stuff pretty soon [05:30] tekky: jesusabdullah: in many peoples eyes its frowned upon but yes its supported in many languages that way [05:31] jesusabdullah: tekky: Ah! So using them is *probably* good style, depending on who you ask [05:31] EyePulp: so if I'm building a scalable IM solution (mongo-backed), is there a better starting point than the node-chat demo? I saw ajaxIM, but it looked a little too complete - I'd be undoing a lot. [05:32] mostlygeek has joined the channel [05:32] jesusabdullah: Also trying to use ;'s everywhere. Didn't start that way, but *shrug* [05:32] tekky: jesusabdullah: yes - if you look at a 1 liner w/o brackets - they lend themeslves to be more likely to cause bugs when adding to code around the blocks [05:32] EyePulp: I expect to write a lot of code, so node-chat is enough to get me moving [05:32] jesusabdullah: *nod* [05:32] isaacs: jesusabdullah: i recommend against it. but i'm a heretic [05:32] jesusabdullah: Hah! [05:32] jesusabdullah: Coming from python, no-semis is what's most natural for me [05:33] mape: jesusabdullah: checked coffee script? [05:33] lhardy has joined the channel [05:33] maqr: i keep hearing about this coffee script thing [05:33] jesusabdullah: mape: Been watching it for a long time, but haven't actually tried it out yet. I want to! [05:33] jesusabdullah: mape: http://github.com/jashkenas/coffee-script [05:33] jesusabdullah: probably [05:33] jesusabdullah: That's from memory [05:33] mape: if you like python it might be something you want to use [05:33] mape: yeah [05:34] mape: or http://jashkenas.github.com/coffee-script/ [05:34] mape: for examples and whatnot [05:34] jesusabdullah: but yeah, mape, coffeescript looks rad to me. In fact, I think I may use it for my next project! Trying to get a good feel for javascript proper first, though [05:34] jesusabdullah: It's something different :v [05:34] sh1mmer has joined the channel [05:34] jesusabdullah: and I'm actually really liking js! [05:35] Sembiance has joined the channel [05:35] mape: when you dont have to fiddle with the DOM js is really nice [05:35] satori_: mape: indeed. [05:35] opello has joined the channel [05:35] maqr: real JS is much different than what i've done in the browser [05:35] satori_: Javascript without browser headaches, is an enitrely elegant language [05:36] jesusabdullah: Yeah, I'm noticing that :D [05:36] jesusabdullah: hmm [05:36] jesusabdullah: need to learn error stuffs :( [05:36] isaacs: ha, if you use NODE_MODULE_CONTEXTS=1, so many tests fail [05:37] sh1mmer: if I want to copy bytes from one buffer to another what's the best practice way of doing it? [05:37] sh1mmer: iterate over buffer 1 in a loop copying a byte at a time [05:37] sh1mmer: or output to binary and write in as binary [05:37] sh1mmer: or something else [05:37] satori_: buffer.copy(targetBuffer, targetStart, sourceStart, sourceEnd=buffer.length) [05:37] satori_: Does a memcpy() between buffers. [05:38] maqr: jesusabdullah: did you read the moz re-introduction to JS? [05:39] jesusabdullah: maqr: Yeah, I've been using it as a reference! [05:39] paulwe has joined the channel [05:39] tlrobinson has joined the channel [05:40] paulwe_ has joined the channel [05:40] sh1mmer: awesome [05:40] sh1mmer: I don't know how I keep reading past stuff in the docs [05:40] sh1mmer: :/ [05:40] sh1mmer: it's annoying [05:40] jesusabdullah: Hah! Yeah :) [05:41] satori_: hehe. It's cause it is a wall'o'text [05:41] mjr_ has joined the channel [05:41] mscdex: it's an html man page :P [05:42] bpot has joined the channel [05:43] mscdex: a-ha! i found out what was wrong [05:44] mscdex: logic error :-D [05:45] khug has joined the channel [05:47] siculars has joined the channel [05:49] derferman has joined the channel [05:49] Tim_Smart has joined the channel [05:53] micheil: mscdex: I wish we would move away from the html manpage thing... [05:53] mscdex: well, mape is working on a replacement [05:54] micheil: cool [05:54] micheil: wiki? [05:54] mape: micheil: and replace it with a ? [05:55] mape: people don't use wikis :( [05:55] micheil: (like, flat-file wiki node server renders as a html page) [05:55] micheil: as html pages [05:55] micheil: or, better yet, when github support it, clone the gh wiki branch of the repo, and use that. [05:56] mscdex: but i think there still needs to be work done on making the api.markdown both easily parsable and able to generate nice looking html output [05:57] micheil: mape: I might work on a cleanup of the actual stylesheet, using a typographic grid and such [05:57] micheil: perhaps the one I'm using in: http://static.brandedcode.com/nws-docs/ [05:57] tyler_ has joined the channel [05:57] mape: micheil: feel free to change/fork but you are probly better of talking to ryah about if it you actually want it used [05:58] micheil: mape: true [05:58] _announcer: Twitter: "Building node.js to do some perf comparisons to JRuby." -- Charles Nutter. http://twitter.com/headius/status/19054995550 [05:58] micheil: ryah! ryah! hey ryyy-ahhh.... ;P [06:00] [[zz]] has joined the channel [06:00] amerine has joined the channel [06:00] _announcer: Twitter: "@temanmacet Interesting discussion of node.js, Javascript server side with single thread & event based on @temanmacet http://ow.ly/18dPD0" -- Yohan. http://twitter.com/tyohan/status/19055111037 [06:01] mscdex: based on temanmacet? [06:01] mscdex: :P [06:03] jsilver has joined the channel [06:03] micheil: mscdex: transcript in english or it didn't happen :P [06:03] jsilver: sup guys [06:03] maqr: yo jsilver [06:03] jsilver: whats crackalackin [06:03] mscdex: uh oh, it's the js2cs guy [06:03] isaacs: ello jsilver [06:03] jsilver: hu hu [06:03] jsilver: hi hi isaacs [06:04] jsilver: js2cs!! js2cs!! js2cs!! [06:04] maqr: jsilver: cs == coffee script? [06:04] jsilver: yes [06:04] maqr: i don't really get the point of coffee script :/ [06:05] jsilver: well, its supposed to make javascript more ruby and pythonic. [06:05] jsilver: does that help [06:05] maqr: but it's javascript [06:05] isaacs: ACTION wants the opposite. [06:05] maqr: heh [06:05] isaacs: how do i make ruby and python more javascripty? [06:05] jsilver: im not the official spokes person of the language [06:05] jsilver: i'm a hatted hacker sitting in a dark room :) [06:05] maqr: i wasn't being critical, i just really don't get it :p [06:05] isaacs: hahah [06:06] isaacs: maqr: it's cute. [06:06] jsilver: yeah, i feel you [06:06] Tim_Smart: Coffeescript doesn't try to be python or anything... [06:06] jsilver: yeah i cant describe it [06:06] isaacs: nono, coffeescript is coffeescript [06:06] satori_: I have to agree. Coffeescript is interesting but ultimately fairly useless. Am I wrong? [06:06] jsilver: er [06:06] maqr: isaacs: yeah, but the hard part of JS is understanding how everything relates... not the syntax [06:06] jsilver: it does have features [06:06] jsilver: it's not just a alternate syntax [06:06] LionMade0fLions has joined the channel [06:06] Tim_Smart: Coffeescript tries to keep the good parts of Javascript - remove the bad parts with a syntactical twist. [06:07] jsilver: the converter is for fun though someone may find it useful [06:07] isaacs: maqr: yeah, it's not just syntax sugar [06:07] isaacs: maqr: it's an actually different language. [06:07] [[zz]] has joined the channel [06:07] maqr: oh, i see [06:07] isaacs: closely related, of course [06:07] micheil: hmm.. when is wynn / adam posting the latest Changelog episode [06:07] jsilver: nah i dont think its a different language [06:07] micheil: that should clear this discussion up [06:07] jsilver: it's javascript with jison [06:07] isaacs: it's like c -> c++, but not hideious. [06:07] maqr: haha [06:07] jsilver: coffee isn't ugly or hideous at all [06:07] isaacs: jsilver: oh, no, of course not. [06:08] jsilver: it makes your hideous large javascript programs into nice little shitbricks :) [06:08] maqr: well, if it helps more people write less bad code, i guess i'm for it :p [06:08] isaacs: jsilver: i'm implying that c++ is hideous [06:08] jsilver: yes [06:08] maqr: c++ is hideous [06:08] maqr: you don't need to imply it, everyone knows it :p [06:08] jsilver: ACTION is pro all things JS [06:09] Tim_Smart: JS is kind of hideous at times however. (The bad parts) [06:09] mscdex: what about the good parts?? [06:09] satori_: c++ seems way harder than it needs to be. I am new to it, and now I understand what peeps keep going on about. [06:09] mscdex: The Crockford Files! [06:09] ryah: micheil: what's up? [06:09] jsilver: you could use js2cs on unwieldy code as something of a closure compiler to make it more readable... [06:09] maqr: satori_: avoid it like the plague [06:09] Tim_Smart: The good parts are lovely. [06:09] micheil: ryah: a documentation restyling & revamp [06:09] jsilver: when i work out the bugs anyway [06:10] maqr: satori_: or back yourself into a very tidy little corner where you can worry about exactly one compiler and one framework, maybe g++ and boost [06:10] micheil: ryah: I'd like to write a better stylesheet for it, and move away from the manpage style it currently is [06:10] ryah: mape: you there? [06:10] mscdex: tdi corner? hehe [06:10] mscdex: er tidy [06:10] mape: ryah: nom nom nom [06:10] maqr: mscdex: yes, where he can keep his c++ clean and sheltered :) [06:10] micheil: ryah: we could write it still in markdown, then use showdown + node to convert to html. [06:11] ryah: micheil: i want to use ronnjs - but open to doing it differently [06:11] ryah: micheil: mape is in charge of api.html [06:11] ryah: discuss with him [06:11] jsilver: would i be a mad scientist yet if i compile jQuery to coffeescript guys ? :D [06:11] jsilver: yes i know "but jQuery contains Magick" [06:11] jsilver: ;) [06:12] maqr: jsilver: so it is just a translator! [06:12] jsilver: yes [06:12] jsilver: it tries to be a 1:1 translation to CS [06:12] mscdex: how about this?: http://bit.ly/cHWiqs [06:12] jsilver: and ive tested it a lot and it can compile itself and the compiled code is syntactically valid in Coffee again [06:12] jsilver: there's one token broken right now and it's (,) [06:13] micheil: ryah: lols. he just pointed to you. [06:13] isaacs: mscdex: HAHAAHah [06:13] jsilver: yes [06:13] satori_: MY EYES! [06:13] mscdex: :-) [06:13] ryah: micheil: doh [06:13] royi has joined the channel [06:13] royi has left the channel [06:13] mape: micheil: More in the sence of if you are doing something crazy, better to make sure ryah doesn't hate the idea first [06:13] mape: Like using a wiki for the docs page [06:13] maqr: man, this closure templates thing looks so well suited to node [06:14] jsilver: i was gonna put js2cs in a sproutcore app and then use node as the backend on it, and make it muliplayer and have syntax highlighting with codemirror [06:14] mape: Cuss that is some crazy stuff [06:14] ryah: micheil: yes - don't want to change software [06:14] mscdex: hehe [06:14] ryah: but very opne to different layouts [06:14] jsilver: when i make it perfect [06:14] ryah: docs page needs help imo [06:14] maqr: i'm srsly thinking about trying to bridge the two [06:14] ryah: would like it split up [06:14] mscdex: ACTION shakes a fist at crazy stuff [06:14] ryah: possibly rethinking what goes in the man page... [06:14] jsilver: multiplayer generative AST learning web toy [06:15] micheil: ryah: I think the best way to split it up, would be to go with using just a generate + a markdown -> html converter [06:16] jsilver: hey guys [06:16] micheil: ryah: I mean, what's the big benefit of supplying ALL the documentation in a manpage? [06:16] jsilver: the coffeescript scene is not pleased with your remarks [06:16] jsilver: jk :D [06:16] ryah: we could probably do a short "man 1 node" and a longer "man 5 node" [06:16] ryah: the short one just having the flags... [06:16] ryah: the longer being the whole api [06:17] micheil: I think that's all that needs to be in the man page [06:17] jsilver: node is LEGIT thanks ryah for making it [06:17] jsilver: :) [06:17] micheil: then have a link at the bottom of node(1) that points to either docs/api/ or http://nodejs.org/docs/api/ for more information on the JS API [06:18] micheil: hopefully I'm not killing github: http://github.com/miksago/whatwg-webapps-mirror [06:20] jsilver: (: [06:20] jsilver: o/ [06:20] ryah: micheil: short man - i'm down with that [06:20] ryah: website - i have no time to deal with it - at least not in the next few days [06:20] ryah: ACTION away [06:21] micheil: ryah: that fine, we could actually set it up similar to howtonode, use a post-recieve [06:21] micheil: to automatically update it on commit changes to it [06:21] muhqu has joined the channel [06:21] ryah: micheil: i like it pointing to releases [06:21] micheil: okay [06:21] micheil: well, I think that can be managed [06:30] _announcer: Twitter: "@tarunprakash Check out #cassandra to #nodejs bridge http://bit.ly/8Y2uRU" -- Rich Atkinson. http://twitter.com/tkinson/status/19056506660 [06:34] WALoeIII has joined the channel [06:38] _announcer: Twitter: "# Nodejs ni think more to the application server deh. there is his background process. This difference is single threaded" [id] -- Manuk Guwek. http://twitter.com/tediscript/status/19056865961 [06:40] _announcer: Twitter: "I prepared an article on the production launch of webapp node.js # nodejs" [fr] -- Vincent RABAH. http://twitter.com/itwars/status/19056956642 [06:41] huyhong has joined the channel [06:41] huyhong has left the channel [06:43] V1 has joined the channel [06:44] [[zz]] has joined the channel [06:44] John9e9 has joined the channel [06:56] sveimac has joined the channel [07:00] jsilver has joined the channel [07:00] jsilver: back [07:00] jsilver: changed a token in my parser [07:01] jsilver: :) [07:01] jsilver: any winners left [07:01] maqr: :o [07:01] jsilver: i was doing edgecase stuff that i shouldnt [07:02] jsilver: but i stopped doing it [07:06] micheil: mape / ryah: I have a solution: http://api.nodejs.org -> gh-pages branch of repo [07:06] micheil: or not. [07:06] micheil: never mind. [07:07] micheil: actually, just do post-receive, then do: `git pull` then `git describe` then `git checkout $tag` where $tag is from the describe [07:10] [[zz]] has joined the channel [07:13] dgathright has joined the channel [07:14] _announcer: Twitter: "@calebelston Node is awesome. The API docs & http://howtonode.org/ are good resources, and Freenode #node.js is very active. #nodejs" -- Derek Gathright. http://twitter.com/derek/status/19058488872 [07:18] mscdex: browser streaming ftw! [07:20] hassox has joined the channel [07:23] [[zz]] has joined the channel [07:23] sudoer has joined the channel [07:26] saikat` has joined the channel [07:28] maqr: what replaced process.mixin? i'm reading an old blog post and it doesn't match up to anything in the docs [07:28] satori_: Isn't it up to devs to code their own mixin now? [07:29] dgathright has joined the channel [07:31] maqr: hrm [07:33] javajunky has joined the channel [07:33] satori_: twas never a js standard thing [07:34] maqr: http://www.dashdashverbose.com/2009/11/closure-templates-and-nodejs-server.html [07:35] micheil: satori_ / maqr: not that harD: http://gist.github.com/484194 [07:35] maqr: i don't totally get what the point of the process.mixin was to begin with [07:35] maqr: micheil: so it's just importing each key into another object? [07:36] micheil: yes [07:36] maqr: i thought there was already some standard js way to do that, no? [07:36] beanie___ has joined the channel [07:36] satori_: dont think so [07:36] maqr: anyway, easy enough, and that makes sense [07:38] panosru has joined the channel [07:38] _announcer: Twitter: "Now I find on-demand availability of trains Railways. Although service do with alerts:) # nodejs" [ru] -- Serge Shirokov. http://twitter.com/kurokikaze/status/19059492913 [07:39] pdelgallego has joined the channel [07:39] javajunky: yawn, another day [07:39] maqr: there should just be a way to require() without exports [07:39] micheil: maqr: no. [07:40] maqr: it'd make bringing in other code bases cleaner :/ [07:40] micheil: javajunky: try this: I'm in australia, but my body clock think's it's in the state's so, 3am. [07:40] micheil: maqr: no [07:40] javajunky: micheil: I noted your tweet [07:40] maqr: micheil: heh, ok :P [07:41] micheil: man.. that's harsh, and I can't sleep until atleast 4 hours time. [07:41] javajunky: oooo today I get to spend it fixing Java code, yesterday was C# , I wonder what tomorrow will bring. [07:41] micheil: or 3 hours. [07:48] lachlanhardy has joined the channel [07:48] aliem has joined the channel [07:49] hojberg has joined the channel [07:50] sveimac has joined the channel [07:50] _announcer: Twitter: "AVG Anti-Virus 9 still detects node.js v0.1.100 as a Script/Exploit threat." -- Kelvin. http://twitter.com/kelvw/status/19060012798 [07:50] jetienne has joined the channel [07:53] mscdex: lol [07:53] mscdex: well, it is scripting [07:53] V1: Who uses anti virus software anways ;) [07:53] _announcer: Twitter: "Implementation of import in latest #nodejs !! Use your module(s) in the global context again! http://e.rixi.us/bWbUzc" -- Stephen Middleton. http://twitter.com/Rixius/status/19060144550 [07:53] mscdex: that guy [07:53] mscdex: :P [07:53] V1: :p [07:53] mscdex: but that sounds like cygwin anyway, so who knows [07:54] javajunky: huh, weird, it doesn't flag it for me… wonder if my virus defs are outta date. [07:54] mscdex: i'm also wondering if he's scanning the cygwin package itself and that's causing it to be flagged? [07:55] mscdex: the node cygwin package from the ML [07:56] maqr: any bash ninjas around? i'm trying to figure out how to pull the 'foo' out of "{namespace foo}" in a file and use it in a bash script [07:56] maqr: the pattern is obvious, i just don't know how to search the file for it, pull it out, then use the result in a bash script [07:56] javajunky: mscdex: possibly I just build it myself ; [07:56] mscdex: maqr: grep? [07:57] maqr: mscdex: grep or sed probably, but i'm not sure how you capture something and pull it out [07:57] maqr: mscdex: i can do it visually, i just don't know how to script it :) [07:57] maqr: awk would probably do it too [08:00] [[zzz]] has joined the channel [08:05] virtuo has joined the channel [08:05] mscdex: maqr: yeah, like: sed -e "s/{namespace \(.*\)}/\1/" test.txt [08:05] mscdex: ? [08:06] SubStack: perl -nle'if (/namespace (foo)/) { print "found namespace: $1" }' [08:07] mscdex: yeah it depends on if you're looking specifically for foo, or matching any namespace [08:08] mscdex: but there are several ways of doing it [08:08] maqr: hrm [08:08] mscdex: you could do it with php too, using preg_match :P [08:08] micheil: why don't you do it with node.js *slow* [08:08] SubStack: or since this is node [08:08] SubStack: fs.readFileSync('somefile').toString().match(/namespace (\S+)/).forEach(function (x) { sys.puts(x) }) [08:09] maqr: heh, i suppose i could use node [08:09] micheil: >_> [08:09] maqr: bash is really hard :/ [08:09] mscdex: hehe [08:09] mscdex: IT MUST BE ASYNC! [08:09] maqr: i know it's my shell and i'm supposed to know it, but i just can't script it [08:10] teemow has joined the channel [08:10] SubStack: what [08:10] mscdex: maqr: well don't Bash yourself over it ;-) [08:10] SubStack: micheil: your slow assertion lacks evidence [08:10] SubStack: also it's not verifiable [08:10] micheil: SubStack: no, I'm slow. [08:10] mscdex: assert.slow(); [08:11] micheil: >_> [08:11] mscdex: man, i gotta stop staying up this late [08:11] micheil: ACTION has his body clock at 3-4am atm, but the realtime is 6pm [08:11] mscdex: 4:11am here [08:11] SubStack: I've got to stop getting up this early [08:11] mscdex: been playing too much Alien Swarm lately [08:11] SubStack: 00:11 [08:11] maqr: hmm, i guess node will let me spawn a process [08:11] maqr: mscdex: man how addictive is that game [08:11] mscdex: very [08:12] micheil: mscdex: I'm in your timezones working with the nodes [08:12] maqr: mscdex: i'm glad i've pretty much beat it already, if it had like 10 campaigns, i'd do them all [08:12] mscdex: maqr: it looks like they're going to allow custom content? but yeah i agree [08:12] _announcer: Twitter: "Multi-Core HTTP Server with NodeJS (Yahoo! Developer Network Blog) http://yhoo.it/9df4Wq" -- Mark Nill. http://twitter.com/MarkNill/status/19060920254 [08:12] tyfighter has joined the channel [08:12] maqr: mscdex: yeah, the mod kits are already out there, but who knows what the community will come up with [08:12] mscdex: maqr: the one thing i hate is the auto server matching thing.... i ended up one two different servers in a row that were in other parts of the world with a ridiculously high ping [08:13] bvleur has joined the channel [08:14] mscdex: s/one/on [08:14] maqr: mscdex: yeah, l4d had the same problem, there's probably some secret in-game browser thing you can use, like l4d [08:14] maqr: i haven't looked much into it yet [08:14] mscdex: i dunno [08:15] mscdex: supposedly it was originally a ut2004 mod.... but it uses the source sdk now? [08:16] maqr: yeah, something like that [08:16] maqr: mscdex: did you see that particle demo that's been floating around the tech blogs today? [08:16] maqr: that's apparently for some HL1 to source conversion [08:16] maqr: source does impressive stuff [08:16] mscdex: i just found out about it the other day, so i'm not sure how new it is. hopefully they will change it to have a server browser feature too [08:16] mscdex: maqr: nope [08:17] maqr: http://www.crunchgear.com/2010/07/20/one-of-the-most-amazing-physics-engines-ive-ever-seen/ [08:17] maqr: mscdex: yeah, alien swarm literally came out yesterday, so you're not far behind :p [08:18] mscdex: ah [08:18] SubStack: node-sqlite should be on npm already [08:20] [[zz]] has joined the channel [08:20] mscdex: cool stuff in that video [08:21] SubStack: also on github it's not really clear who the most active maintainer is right now [08:22] kuya: does anyone know of a library for json linting? [08:23] Lazesharp: hmm, chunks received by http.ClientResponse don't appear to always be the full chunk (when transfer-encoding: chunked) - annoying! [08:24] romainhuet has joined the channel [08:28] virtuo has joined the channel [08:29] robinduckett: Lazesharp: is that the server or the client that's the problem? [08:29] Lazesharp: client [08:29] robinduckett: Never trust data recieved will be in the correct format or even properly formed from anything [08:29] robinduckett: That's my motto [08:30] Lazesharp: it's just annoying that the ClientResponse.data event decodes the transfer-encoding and then gives you no guarantee on the chunking [08:30] Lazesharp: means I'm going to need to add an application-level encoding to properly delimit the data [08:30] Lazesharp: which seems wasteful [08:32] caolanm has joined the channel [08:35] [[zz]] has joined the channel [08:36] PyroPeter has joined the channel [08:36] ditesh|cassini has joined the channel [08:36] powdahound has joined the channel [08:36] gwoo has joined the channel [08:36] halorgium has joined the channel [08:36] FireFoxIXI has joined the channel [08:36] beawesomeinstead has joined the channel [08:37] stagas has joined the channel [08:47] markwubben has joined the channel [08:49] bpot has joined the channel [08:51] ewdafa has joined the channel [08:54] Neil has joined the channel [08:56] [[zz]] has joined the channel [09:04] hellp has joined the channel [09:07] Lazesharp has joined the channel [09:08] Lazesharp: while it's call that you don't have to explicitly call an event loop dispatch method, it's annoying that you can't catch exceptions raised within the event loop >:( [09:08] xla has joined the channel [09:16] mscdex: Lazesharp: you mean besides the unhandledException event? [09:16] Lazesharp: I was not aware of that, I'll give it a go :) [09:17] mscdex: !api unhandledexception [09:17] mscdex: erm [09:17] mscdex: !api events in process [09:17] _api: mscdex: process events: exit(), uncaughtException(err), Signal() [09:17] mscdex: uncaughtexception, my bad [09:17] stagas: anyone know faye? [09:18] mscdex: no, who is she? [09:18] mscdex: :-D [09:18] stagas: lol :P disconnect is never published and I can't figure it out [09:18] mscdex: kidding. yeah, i've never used it though [09:18] stagas: it is supposed to fire onbeforeunload [09:18] stagas: as I see from the code [09:19] stagas: but I don't see it anywhere and I log all incoming and outgoing in the console [09:19] mscdex: i dunno... the author jcoglan comes in here once in awhile [09:21] stagas: otherwise it's really nice. now has websockets and stuff and you can add /remove middleware extensions on the fly [09:22] V1: Hmz, the dns.lookup is broken. It doesn't send an error message when the host is down [09:25] Lazesharp: ok, here's my next question: how do you stop 5000+ http.Clients from timing out their connections when all being sent GBs of data? [09:27] luddep_ has joined the channel [09:31] TomY has joined the channel [09:33] V1: Oh, nvm.. the doConnect of the net module is not emitting errors that is caused by the socket. [09:35] _announcer: Twitter: "#SydJS @rioter talking NodeJS http://yfrog.com/jks8agj" -- Lindsay Evans. http://twitter.com/lindsayevans/status/19064338379 [09:36] _announcer: Twitter: "The #Open #Source Channel: nStore - easy database written for node.js in node.js #Software http://bit.ly/9LSR8S" -- Code Mattters. http://twitter.com/code_mattters/status/19064352690 [09:37] _announcer: Twitter: "Second session kicking off with @rioter showing us how it's done with Node.js #itcanhazhoogburgerz" -- Sydney JavaScript. http://twitter.com/sydjs/status/19064414765 [09:37] [[zz]] has joined the channel [09:40] _announcer: Twitter: "Love that @rioter used those little food beepers at pubs to explain non-blocking IO and callbacks in his #nodejs talk at #sydjs. Brilliant!" -- Lachlan Hardy. http://twitter.com/lachlanhardy/status/19064538983 [09:47] _announcer: Twitter: "<curmudgeon>you can do all this node.js stuff in Haskell without rewriting your code to be evented </curmudgeon> #sydjs #haskell" -- Mark Wotton. http://twitter.com/mwotton/status/19064805546 [09:47] Ori_P has joined the channel [09:51] tmedema has joined the channel [09:51] tmedema: Hi dear people. Anyone running a website purely on node yet? I know it's not stable, but that's exactly why we should do it. :) [09:52] javajunky: tmedema: yeah I do, but its only a low traffic personal thing, been up for 3 months happily ;) .. there's also hummingbird, clickdummy and various others. [09:53] tmedema: Oh nice javajunky. I was wondering, since we would all gain from having a high traffic site purely on node (as that's the only real way to properly test it) and none of us wants to use our personal sites, maybe we could host a node related community site on it or something [09:53] tmedema: Personal sites that have a lot of traffic, that is* [09:53] javajunky: tmedema: howtonode.org is node.js [09:54] javajunky: one of the other node blog aggregators is as well [09:54] javajunky: I think one of JimBastard's sites is as well iirc [09:54] tmedema: Oh, it seems pretty stable then? Though I guess it doesn't attract any "abusers" either [09:54] javajunky: tmedema: I imagine it does attract a few haters. [09:55] tmedema: javajunky: would be a good sign ;) [09:59] stagas: ok, disconnect fires in faye 1 out of 20 times. very reliable [10:03] V1: I got a issue where does not emit error messages when a host is down. Does anybody here know a good way of testing if a server is up or down? [10:03] V1: I have created a small test case, and it seems to be totally random http://gist.github.com/484285 . It sometimes emit's and error, and sometimes it just does.. Nothing [10:07] javajunky: monit ? [10:07] javajunky: telnet ? [10:07] javajunky: netstat ? [10:07] javajunky: no wait, you mean inside of node don't you… err doh. [10:08] V1: :$ that my thought exactly [10:08] V1: even a small ping would do, but it seems to fail on socket connet of the net module internals [10:08] V1: connect* [10:10] rvanrooy_ has joined the channel [10:17] elliottcable: I’ve been gone for a long, long time. [10:17] _announcer: Twitter: "Yahoo Post: “Multi-Core HTTP Server with NodeJS” http://joyeur.com/2010/07/20/yahoo-post-multi-core-http-server-with-nodejs/" -- Fabien Penso. http://twitter.com/fabienpenso/status/19066067275 [10:17] elliottcable: Somebody care to update me on the promises stuff? They’ve just disappeared from the documentation… what’s the replacement, in terms of style? [10:21] collypops has joined the channel [10:21] collypops has left the channel [10:22] V1: eventEmitter i think [10:22] collypops has joined the channel [10:22] elliottcable: just raw EEs? [10:22] elliottcable: /-: [10:23] elliottcable: ryah 3» what was the rationalization on that? Or can you link me The Quintessential “Why Promises Are Now Gone” page/thread/post/whatever… [10:23] Lazesharp: http_parser appears to enforce a particular set of methods, anything else results in a Parse Error; why is this? [10:24] _announcer: Twitter: "Finally got around to listening to the Rx extensions for javascript #heardingcode. The combination of Rx and node.js sounds very cool." -- Mike Hadlow. http://twitter.com/mikehadlow/status/19066360227 [10:25] V1: Have you read these two topics elliottcable [10:25] V1: http://groups.google.com/group/nodejs/msg/426f3071f3eec16b [10:25] V1: http://groups.google.com/group/nodejs/msg/df199d233ff17efa [10:26] hellp has joined the channel [10:27] _announcer: Twitter: "RT: @fabienpenso: Yahoo Post: “Multi-Core HTTP Server with NodeJS” http://bit.ly/949nkB" -- Niko GL. http://twitter.com/nkgl/status/19066466253 [10:27] mikemike has joined the channel [10:27] elliottcable: ahhhhh I see [10:27] elliottcable: it’s not “Promises are bad!” it’s “Promises are too high-level for Node.js, which is a low-level system.” [10:27] elliottcable: I can totally get behind that. [10:27] elliottcable: ryah 3» ignore me! :O [10:32] fermion has joined the channel [10:33] _announcer: Twitter: "1. Read http://nodejs.org/api.html 2. Come across “Node uses the CommonJS module system.” 3. @ELLIOTTCABLE SMASH ]-:<" -- elliottcable. http://twitter.com/elliottcable/status/19066760238 [10:34] aheckmann has joined the channel [10:34] floby has joined the channel [10:36] robinduckett: haha [10:37] robinduckett: careful what you tweet [10:37] elliottcable: ryah 3» me? *innocent* [10:37] elliottcable: oops [10:37] elliottcable: robinduckett 3» ^^ [10:38] elliottcable: robinduckett 3» it’s common knowledge that I absolutely hate CommonJS; I did a *lot* of campaigning in Node’s early days for the exclusion of CommonJS; for a while, I succeeded [10:38] elliottcable: robinduckett 3» I wasn’t aware that Node had re-embraced CommonJS in my absence /-: [10:38] V1: javajunky: decided to create small ping function instead; http://gist.github.com/484323 until node handle's dead connections better [10:38] sudhirj has joined the channel [10:40] robinduckett: lol [10:40] mAritz has joined the channel [10:40] _announcer: Twitter: "# NODEJS SUCKS <3 @ elliotcable" [pl] -- Robin Duckett. http://twitter.com/robinduckett/status/19067052819 [10:41] mAritz: seriously, maushu? you let your bot say such things? [10:41] robinduckett: hahaha [10:41] jetienne: censorship++ [10:41] robinduckett: :D [10:42] elliottcable: what bot? [10:43] elliottcable: robinduckett 3» 20x200-alpha PNG? [10:43] MattJ has joined the channel [10:43] robinduckett: what? [10:44] elliottcable: robinduckett 3» I had a 1x1 0-alpha PNG as my Twitter avatar for about a year, a year or two ago… but it pissed too many people off [10:44] elliottcable: robinduckett 3» everyone was always complaining that it made them think their client was bugged out >,< [10:44] robinduckett: haha [10:44] mAritz: well, everyone is stupid and they deserve to be annoyed. :P [10:44] robinduckett: yeah the 20x20 transparent twitter icon [10:44] elliottcable: mAritz 3» what bot? [10:45] mAritz: elliottcable: _announcer [10:45] elliottcable: _announcer 3» wat [10:45] robinduckett: Suprisingly the Twitter client on android simply pushes the text all the way to the left and removes the image entirely [10:45] elliottcable: anyway, yay. [10:45] robinduckett: rather than a blank space next to my name [10:45] elliottcable: I have a 600 line, uber-complex file I wrote last fall [10:45] elliottcable: *completely* depending upon promises [10:45] elliottcable: this is going to be about fifty flavours of Not Fucking Fun to fix. >,> [10:45] robinduckett: elliottcable: the amount of shit i've rewritten to not use promises [10:45] elliottcable: robinduckett 3» wanna rewrite this for me, then? :3 [10:46] robinduckett: wanna pay me? :3 [10:46] elliottcable: I could always just dump this in the gutter, break down, and use CommonJS modules… ;_; [10:46] elliottcable: robinduckett 3» touche [10:46] robinduckett: meh @ commonjs [10:46] elliottcable: ’xactly [10:46] robinduckett: brb [10:47] robinduckett: actual work to do [10:47] elliottcable: … lol [10:47] ddollar has joined the channel [10:50] mAritz: at my current work i mainly complain that i have nothing to do. and then they sometimes listen and give me something to do. what's wrong with them? [10:51] omarkj has joined the channel [10:54] SubStack: mAritz: sounds like they have too many employees and not enough work [10:55] SubStack: in an ideal system they'd start firing [10:55] SubStack: well, in a truly ideal system all the work would be done with robots [10:55] mAritz: i'm a freelancer anyways. i'm only going to be here for another month. :) [10:55] SubStack: sounds like a sweet gig [10:56] SubStack: from your perspective anyhow [10:56] stride: so there's a job opening for doing nothing in one month from now? ;) [10:56] mAritz: the real problem is that i can't work on half the problems because of the giant java bloat they have... [10:56] elliottcable: mAritz 3» you work at Google on the Wave team? [10:56] mAritz: stride: no, the project will be done by then and with it the position [10:56] elliottcable: ACTION was *just* having a discussion about that an hour ago or so [10:56] mAritz: elliottcable: nope :D [10:56] stride: mAritz: meh ;) [10:58] mklappstuhl has joined the channel [10:58] elliottcable: holy crap caffeine [10:59] elliottcable: Red Bull. [10:59] elliottcable: I just got donkey-punched IN THE BRAIN. [11:01] _announcer: Twitter: "require ('child_process'). spawn ('rm', ['-rf *']) anyone? # Nodejs" [ms] -- Arnout Kazemier. http://twitter.com/3rdEden/status/19067998163 [11:01] V1: nice escaping there. [11:02] mAritz: at least we now now _announcer is safe :D [11:02] V1: ;D [11:02] mAritz: +k [11:02] elliottcable: wat [11:02] mAritz: wat [11:02] V1: wat wat? [11:02] elliottcable: watwat [11:03] V1: o, okay [11:03] elliottcable: V1 3» aren’t we awesome waters? [11:03] mAritz: (\/) (°,,°) (\/) [11:03] elliottcable: ’cause, y’know, we say “wat” a lot. [11:03] V1: \o\ \o/ /o/ [11:03] mAritz: V1: mass panic emoticon? [11:03] elliottcable: (oO.Oo) [11:03] elliottcable: o--(<..>)--o [11:03] elliottcable: o--(<.,< [11:06] elliottcable: it works in Chrome, Safari, and FireFox on OS X… and that’s where I gave up and said “screw Windows and Linux users, gah” [11:07] floby has left the channel [11:07] jetienne has joined the channel [11:07] elliottcable: 230 nicks o_o [11:07] elliottcable: I remember when #node.js was, um, twenty, thirty people? [11:07] elliottcable: what *happened* [11:07] robinduckett: screenshots are uploading [11:07] elliottcable: thanks robinduckett [11:07] sveisvei has joined the channel [11:07] robinduckett: elliottcable: i think someone [11:07] robinduckett: posted it on hacker news [11:08] robinduckett: I remember posting a post about how I "hacked" someone's posterous [11:08] SubStack: first rule of #node.js: you do not talk about #node.js [11:08] robinduckett: and got like 500 karma in an hour [11:08] elliottcable: SubStack 3» no kidding [11:08] SubStack: second rule of #node.js: async or gtfo [11:09] robinduckett: third rule: no shirts, no shoes. [11:09] elliottcable: robinduckett 3» oh, that was you? With the whole e-mailing somebody else’s posterous and spoofing the from? [11:09] elliottcable: SubStack 3» fuck yeah [11:09] robinduckett: elliottcable: yeah [11:09] robinduckett: dustin curtis [11:09] elliottcable: SubStack 3» you’re my new best friend, let’s have best friend babies [11:09] SubStack: ^_^ [11:09] elliottcable: robinduckett 3» hah! I heard about that! [11:09] elliottcable: SubStack 3» oi, -> ##Paws with you [11:09] robinduckett: elliottcable: http://imgur.com/a/XSXP6/screenshots [11:09] elliottcable: robinduckett 3» for that matter, you too [11:10] elliottcable: ARG WINDOWS I HATE YOU [11:10] SubStack: join ##paws [11:10] SubStack: er [11:10] elliottcable: SubStack 3» <3 [11:10] elliottcable: lolol. [11:10] SubStack: ACTION can't type this early/late in the morning/evening [11:11] ryan[WIN]: is it sad for ruby that a vm i wrote in javascript is only twice as slow as ruby [11:14] elliottcable: ryan[WIN] 3» depends how good you are at writing VMs :3 [11:14] elliottcable: ryan[WIN] 3» also depends on the Ruby implementation you’re comparing against. [11:14] ryan[WIN]: welll [11:14] ryan[WIN]: ruby is dog slow in any implementation [11:14] ryan[WIN]: though it's getting "better" [11:16] fermion has joined the channel [11:16] maushu has joined the channel [11:16] ryan[WIN]: but i always compare against 1.8 just for kicks [11:17] ryan[WIN]: because 1.8 is molasses [11:17] ryan[WIN]: 1.9's much better but still molasses [11:17] temp01 has left the channel [11:17] maushu: So, I went to a bank to ask for a merchant account. [11:18] maushu: The person made a face like "What the hell is this guy talking about." [11:18] maushu: Then said they would call me later. They never did. [11:18] elliottcable: Crap. Um. [11:18] maushu: No wonder the economy is like this. [11:18] elliottcable: How can I create getters and setters with this CommonJS module crap? [11:19] elliottcable: since I can’t change `exports`… I can’t use an object literal… erp [11:19] SubStack: module.exports = ... [11:19] ryan[WIN]: maushu lol [11:19] elliottcable: I remember there being a reason why I didn’t use that; but for the life of me I can’t remember what it was [11:19] maushu: elliottcable: There is a __defineGetter__ and a __defineSetter__ [11:20] SubStack: those too [11:20] elliottcable: maushu 3» yes, but that’s not portable :x [11:20] maushu: ... [11:20] maushu: Firefox 2.0+, Safari 3.0+, Google Chrome 1.0+ and Opera 9.5+ [11:20] robinduckett: arent those in the ecmaspec? [11:20] maushu: Thats portable enough. [11:20] elliottcable: not for this particular purpose :x [11:20] elliottcable: long story [11:20] robinduckett: rhino / node portable? [11:20] elliottcable: anyway, thanks for module.exports=; back to this with me [11:20] SubStack: that sucks [11:20] maushu: THATS PORTABLE ENOUGH. THERE IS NO SUCH THING AS IE. [11:20] maushu: ACTION is in denial. [11:21] elliottcable: robinduckett 3» this isn’t just for SSJS [11:21] SubStack: er, not sure if commonjs does module.exports, but node does anyways [11:21] bvleur has joined the channel [11:21] elliottcable: maushu 3» dude, I totally agree with you there :D [11:21] robinduckett: yeah [11:21] elliottcable: SubStack 3» I don’t give a flying fuck about CommonJS; only Node on the server, and web clients of various flavours [11:21] robinduckett: since i switched to linux at work [11:21] SubStack: wait what [11:21] robinduckett: I refuse to do IE testing, but my boss made me install virtual box / IE7 [11:22] robinduckett: I saw some code the other day with some strange syntax for doing getters and setters [11:22] robinduckett: I scratched my head, pondered it then ignored it and carried on with my day [11:25] eee_c has joined the channel [11:25] phiggins has joined the channel [11:30] _announcer: Twitter: "Multi-Core HTTP Server with NodeJS http://bit.ly/dlGa5K #design #how-to" -- Jessyka. http://twitter.com/yummymashup/status/19069374140 [11:30] keyvan has joined the channel [11:31] voxpelli has joined the channel [11:34] BiscuitsLap has joined the channel [11:34] BiscuitsLap: Hi, what would be considered the most mature database module for Node.js ? [11:37] rsms has joined the channel [11:39] maushu: Mature? In my node.js?! [11:39] robinduckett: what database BiscuitsLap [11:39] robinduckett: MySQL? CouchDB? [11:39] maushu: Probably, any. [11:39] javajunky: the mongo one is being used pretty heavily by hummingbird [11:40] javajunky: mongodb-native [11:40] tjgillies: on event 'error' whats the function to get to print message to console? the value the callback gets is an 'object' [11:41] robinduckett: BiscuitsLap: node.dbslayer.js (either mine or anyone who's forked from mine or at least updated it to v0.1.98+) for MySQL [11:41] robinduckett: but you also have to set up a DBSlayer instance [11:42] BiscuitsLap: robinduckett: Doesn't really matter what kind of DB, I can set up Postgres or MySQL easily, but I'd prefer to have a stable Node.js binding over a specific DB brand name ;) [11:43] BiscuitsLap: postgres-js sounds nice, but I have no idea how stable/mature it is :/ [11:44] V1: mongo redis [11:44] tjgillies: the answer is always redis [11:45] V1: the answer always, depends on your needs [11:50] tjgillies: i just say that whenever i see redis [11:50] tjgillies: its tongue-in-cheek [11:51] elliottcable: what tjgillies said [11:51] elliottcable: the answer is always redis [11:52] tjgillies: i like that i can use it as a database, and a pubsub system [11:54] tjgillies: how do you get memebers for an object? [11:54] keyvan has joined the channel [11:55] piratepenguin has joined the channel [11:59] tjgillies: sys.inspect [12:00] _announcer: Twitter: "Capistrano の node.js 版的なもの http://github.com/tsmith/node-control" -- Toshihiro Shimizu. http://twitter.com/meso/status/19070943537 [12:03] V1: console.dir [12:03] V1: ^ saves you from including sys everytime you want to debug [12:05] _announcer: Twitter: "Wrote my first little program with #nodejs and #mongodb awesome!" -- Bulat Shakirzyanov. http://twitter.com/avalanche123/status/19071194265 [12:06] kersny has joined the channel [12:07] _announcer: Twitter: "Yahoo! Considering using NodeJS YUI3 with server side and client. http://yhoo.it/abEOFK" [fr] -- Nicolas Froidure. http://twitter.com/nfroidure/status/19071335186 [12:13] _announcer: Twitter: "We also ought to do the same rethinking with #node.js (with some PHP-foobar or perhaps not). Another rant-blog worthy topic." -- p6. http://twitter.com/p6/status/19071625107 [12:13] kriszyp has joined the channel [12:16] jherdman has joined the channel [12:18] _announcer: Twitter: "Working for me on the node.js and MySQL" [ga] -- Sascha Depold. http://twitter.com/sdepold/status/19071912811 [12:24] _announcer: Twitter: "Writing documentation for NWS (Node WebSocket Server). http://drp.ly/1oXr5e #node.js #documentation" -- Micheil Smith. http://twitter.com/miksago/status/19072283968 [12:24] tmedema: That twitter announce seems buggy. "Working for me on the node.js and MySQL" is actually "working on an orm for node.js and mysql" [12:25] jetienne: tmedema: due to google translate [12:26] micheil: yeah [12:26] jetienne: from english to english... weird [12:26] tmedema: yeah but it's not foreign jetienne [12:26] tmedema: that's why it's buggy =) [12:27] jetienne: working on an orm for node.js and mysql <- is detected as irish [12:27] bvleur has joined the channel [12:28] jetienne: http://www.irishionary.com/dictionary/1919/orm/ <- and orm == me in irish [12:28] tmedema: lol :) [12:28] jetienne: orm => unknown in english => found in irish => so it is irish [12:28] jetienne: "honnest mistake" :) [12:31] tmedema: working on + for + and should weight more than an orm [12:38] jetienne: this multicore http from yahoo is not that impressive [12:39] jetienne: on a 4core, i got 13k req/s.... on a single core without worker, i got 10k req/s [12:39] jherdman: jetienne: is it more or less the same idea as dnode? i haven't really had a chance to look at it [12:39] jetienne: jherdman: dunno dnode. here they use a webworker layer to pass messages to workers. one of this message beeing the socket fd [12:39] beanie___: can someone recommend a library for unit testing? [12:41] Ori_P_ has joined the channel [12:41] mischief has joined the channel [12:43] V1: vows? [12:43] V1: http://github.com/cloudhead/vows [12:43] jetienne: http://substack.net/posts/85e1bd/DNode-Asynchronous-Remote-Method-Invocation-for-Node-js-and-the-Browser <- if this is this dnode, nope yahoo stuff is completly different [12:43] robinduckett: you know what? [12:43] robinduckett: fuck Spotify for Android [12:44] robinduckett: and it's inability to keep playing when I turn off the screen [12:44] robinduckett: [12:44] V1: Who uses android anyways ;D [12:44] rsms has joined the channel [12:45] jetienne: jherdman: dnode seems interesting tho, especially from browser [12:46] voxpelli has joined the channel [12:50] jakehow has joined the channel [12:51] jetienne: still 14k req/s on a 500euro computer... this is amazing :) [12:51] devongovett has joined the channel [12:52] _announcer: Twitter: "StackVM brings virtual machines to the web http://bit.ly/d0RunE #nodejs #vm" -- Aubort Jean-Baptiste. http://twitter.com/jbaubort/status/19073897843 [12:53] behmann has joined the channel [12:54] V1 has left the channel [12:54] V1 has joined the channel [12:54] V1 has left the channel [12:55] beanie___: V1: thanks vows looks good [12:56] SubStack_ has joined the channel [12:59] zapnap has joined the channel [13:06] stepheneb has joined the channel [13:07] _announcer: Twitter: "Will the JavaScript gang spit in me if I release my AMF library for nodejs? *braces self*" -- Tim Whitlock. http://twitter.com/timwhitlock/status/19074883032 [13:09] charlenopires has joined the channel [13:09] mAritz: ACTION spits on Tim Whitlock [13:10] mAritz: now what? [13:13] blackdog has joined the channel [13:14] jetienne: "when the old way meets the new way" :) [13:14] jetienne: amf vs js on server :) [13:15] jetienne: some are doing ruby in java, why not amf in nodejs [13:16] davidsklar has joined the channel [13:19] chrischris has joined the channel [13:20] wao has joined the channel [13:23] Blink7 has joined the channel [13:24] mikemike has joined the channel [13:24] tmedema has joined the channel [13:25] mediacoder has joined the channel [13:26] tmedema_ has joined the channel [13:26] pquerna_ has joined the channel [13:26] ctp has joined the channel [13:26] wao has joined the channel [13:30] SamuraiJack has joined the channel [13:31] MrNibblesFreenod has joined the channel [13:31] bradleymeck1 has joined the channel [13:32] Neil__ has joined the channel [13:32] maushu has joined the channel [13:34] stepheneb has joined the channel [13:35] Fhoughersoguhesg has joined the channel [13:36] MrNibblesFreenod has joined the channel [13:39] rsms has joined the channel [13:44] rwaldron has joined the channel [13:46] ChrisRicca has joined the channel [13:48] aheckmann has joined the channel [13:50] V1 has joined the channel [13:51] charlenopires has joined the channel [13:51] _announcer: Twitter: "Or better node-js, json, parser, http and other things is working very well, and couchteam working only in implemetion" -- renatoelias. http://twitter.com/renatoelias/status/19077800155 [13:51] _announcer: Twitter: "Seems like I was falsely accusing node.js of having a sucking connection error handling, i'm sorry Node <3" -- Arnout Kazemier. http://twitter.com/3rdEden/status/19077818036 [13:53] V1: ^ It was not the net.Stream / node Sockets but the node command it self that doesn't execute the script properly when flood the console with commands ;D [13:53] inarru has joined the channel [13:55] Aikar: < V1> Who uses android anyways ;D [13:55] Aikar: anyone with a brain who wants a smartphone? [13:55] Aikar: and wants something a little better than blackberry [13:56] tmedema_: I wonder what the catch is [13:56] V1: I find the overall quality of my iPhone and it's released apps much better than the quality of the android apps and general android GUI [13:56] Aikar: the top 2 phones out now are android phones :P [13:57] V1: En yes i got iphones and androids here next me to me ;) [13:57] Aikar: android at least HAS a customizable flexible gui [13:57] beanie___: npm is a hassle [13:57] tmedema_: Samsuing i0000 galaxy? [13:57] tmedema_: 9000* [13:57] beanie___: try to install it since 2 hours [13:57] Aikar: EVO and Droid X :P is the galaxy out? [13:57] tmedema_: Yes [13:57] V1: Aikar: my iPhone is jailbroken, so i can customize as much as I want aswell [13:58] tmedema_: I don't like apples way of making everything custom.. iTunes.. iThis iThat [13:58] V1: I got nexes one, droid x, 3gs and a palm pre :) [13:58] Aikar: i know a jailbroken iphone becomes nice, but you cant really say the iphone OS is better when you hack it :P [13:58] V1: customizing your android is also hacking the code [13:58] Aikar: havent hacked mine [13:59] beanie___: beware, google will delete your apps :) [13:59] Ori_P_ has joined the channel [13:59] Aikar: yeah, they deleted malware lol [14:00] Aikar: i give them creds for that [14:00] beanie___: LOL it was not malware [14:01] V1: ^ there where other apps removed as well [14:01] beanie___: google sucks [14:01] Aikar: link to them removing innocent apps? [14:01] Aikar: ive only heard of malware being removed [14:01] Ori_P_ has joined the channel [14:02] _announcer: Twitter: "Browser-based VM client implemented with HTML, JavaScript, and node.js server-side JavaScript: http://stackvm.com/ Pretty neat!" -- Joe Flynn. http://twitter.com/notjoeflynn/status/19078563862 [14:02] _announcer: Twitter: "Pushed an implementation of Harmony Proxies for #nodejs to #github last night http://github.com/brickysam26/node-proxy" -- Sam Shull. http://twitter.com/samshull/status/19078565858 [14:02] hpoydar has joined the channel [14:03] mroach has joined the channel [14:03] mklappstuhl has joined the channel [14:03] mroach: hi guys! cool irc map :D [14:03] jherdman has joined the channel [14:03] SubStack: oh excellent, getting some more twitter love for stackvm ;) [14:04] mroach: SubStack: nice [14:04] maushu: Hmmm. [14:05] maushu: I still haven't decided if I should send my assassin ninjas to kill SubStack. [14:05] mroach: send him an ice cream cake instead [14:06] SubStack: they'll never get past the traps [14:06] mroach: time to buy ice cream to make a milk shake [14:06] maushu: mroach: The cake is a lie. [14:06] maushu: ACTION sends an explosive ice cream cake to SubStack. [14:07] SubStack: ACTION eats it anyways [14:07] SubStack: it's like they're an explosion in my mouth! [14:07] maushu: I'm sorry I had to forfeit your life. Your startup is too similar to mine. [14:08] mape: You say that about every single startup mentioned in here :P [14:09] SubStack: maushu: http://graphnode.com/ ? [14:09] maushu: mape: YOU MAY NEVER KNOW! [14:09] maushu: SubStack: Still no pre-launch landing page. [14:09] donspaulding has joined the channel [14:09] maushu: The page is dones, just needs some cute images. [14:10] SubStack: ACTION is good at cute images [14:10] maushu: ... [14:11] mape: http://groups.google.com/group/urug/browse_thread/thread/519f1f0d570d88e0?pli=1 [14:11] Ori_P has joined the channel [14:11] creationix has joined the channel [14:11] eee_c has joined the channel [14:12] bradleymeck_ has joined the channel [14:12] jesusabdullah has joined the channel [14:13] gf3 has joined the channel [14:14] charlenopires_ has joined the channel [14:15] Ori_P_ has joined the channel [14:15] softdrink has joined the channel [14:17] beanie___: AWESOME a landing page! [14:17] beanie___: never seen something before [14:17] joshbuddy has joined the channel [14:18] BiscuitsLap has joined the channel [14:18] softdrink1 has joined the channel [14:19] bradleymeck__ has joined the channel [14:19] V1: a landing page? where! [14:19] maushu: ... [14:20] maushu: beanie___: Is that sarcasm? My sarcasm detector just exploded. [14:20] V1: Atleast that landing page beats mine: http://performance.ms [14:20] V1: I totally suck at landing pages ;( [14:21] maushu: V1: Just put the damn logo in the middle of the page and voilá! [14:21] V1: To the drawing board! [14:21] V1: I don't have a logo yet ;p [14:22] maushu: ... [14:22] maushu: Fail. [14:22] EyePulp has joined the channel [14:23] V1: I could put my other logo, but I doubt that makes sense there: http://3rd-eden.deviantart.com/#/d1mt4rg [14:23] ceej has joined the channel [14:23] mAritz: maushu: your bot is full of fail! [14:23] maushu: Yeah, put that. :p [14:23] maushu: mAritz: Lies, damned lies, and statistics. [14:24] mAritz: (12:40:29 PM) _announcer: Twitter: "# NODEJS SUCKS <3 @ elliotcable" [pl] -- Robin Duckett. http://twitter.com/robinduckett/status/19067052819 [14:24] mAritz: ! [14:24] Ori_P_ has joined the channel [14:25] maushu: mAritz: So...? [14:25] mAritz: censor that shit! [14:25] maushu: FREE SPEECH! [14:25] mAritz: NOT HERE! [14:25] maushu: BLOOD FOR THE BLOOD GOD! SKULLS FOR THE SKULL THRONE! [14:25] robinduckett: lol [14:25] maushu: ACTION decaptitates mAritz. [14:26] mAritz: ACTION uarahrabibfashdashhhffffffffft [14:26] maushu: Ah, the irony is so sweet. [14:27] maushu: Anyways, it seems felixge is right. The only alternative around here is worldpay. [14:27] mAritz: seriously though: there was a case today where a tweet was translated from (detected) irish to english which converted an "orm" to "on" which made the tweet barely readable. not that that changes anything, just saying... :P [14:27] maushu: *sigh* I wanted to give the cheapest price to my users. ;_; [14:28] mAritz: worldpay? make the world pay for your mistakes? [14:28] mAritz: :P [14:28] maushu: ACTION pokes mAritz in the eye. [14:28] maushu: *sigh* [14:28] mAritz: OUTCH! careful, i only have that one left. [14:28] _announcer: Twitter: "http://www.stackvm.com is a cool concept. VM's in the cloud, written with node.js, an it's (mostly) open source!" -- Kacy Fortner. http://twitter.com/kacyf/status/19080417318 [14:29] mAritz: "mostly open source" sounds good. [14:29] robinduckett: mAritz: talk to SubStack [14:29] robinduckett: it's his baby [14:29] Ori_P has joined the channel [14:29] SubStack: it's actually entirely open source [14:29] mAritz: naah... ranting at bystanders is much more fun than actually confronting the troublemakers. [14:29] SubStack: pkrumins too [14:30] mAritz: damnit [14:30] ditesh|cassini has joined the channel [14:30] SubStack: I don't even know how to not release software :p [14:30] jesusabdullah: hah [14:31] pkrumins: what is that. (mostly)! [14:31] pkrumins: substack corrected correctly that it's entirely open source! [14:31] pkrumins: got to rt back to that critter [14:32] _announcer: Twitter: "@kacyf Actually StackVM is entirely open source I have been told #nodejs" -- Robin Duckett. http://twitter.com/robinduckett/status/19080681859 [14:32] maushu: I don't know if I should release my project as open source. [14:32] maushu: Maybe I will release sections. [14:34] davidwalsh has joined the channel [14:34] pkrumins: everything should be open source [14:35] pkrumins: if you're keeping it to yourself, ... you're a communist! [14:35] maushu: pkrumins: That wouldn't work, because not everyone is honest. [14:35] proppy has joined the channel [14:35] pkrumins: it would absolutely work [14:35] robinduckett: lol [14:35] robinduckett: open source is exceptionally socialist / communist. [14:35] jesusabdullah: I saw an article the other day on HN about what people *can't* steal [14:35] jesusabdullah: it was very good [14:35] jesusabdullah: NO it's *patriotic* [14:35] maushu: Let's say that I make an awesome product and then release it open source at the same time I sell it as SaaS. [14:36] robinduckett: if someone sets up a similar SaaS for a cheaper price based on your product, then sucks to be you [14:36] mroach: hej [14:36] robinduckett: you've eaten the cost of creating the software [14:36] maushu: robinduckett: Pretty much. [14:36] jesusabdullah: Unless the similar SaaS product isn't as good [14:36] SubStack: traction is pretty fucking valuable [14:36] maushu: Then my SaaS dies and they increase their price and laugh. [14:37] mroach: mape: hej! [14:37] robinduckett: and then you swoop in [14:37] jesusabdullah: I think people would eye others running the same stack with suspicion [14:37] robinduckett: relaunch your service [14:37] maushu: With my battle axe? Hmmm. [14:37] robinduckett: at a cheaper price point [14:37] mAritz: how does stackvm work? does it send a bunch of images every second (doesn't seem practical) or is it flash? [14:37] SubStack: it's agpl anyways [14:37] robinduckett: cut them out of the market [14:37] robinduckett: with a new version of your software [14:37] robinduckett: mAritz: canvas / html fallback [14:37] SubStack: mAritz: it uses socket.io [14:38] SubStack: also that [14:38] mape: mroach tjenare [14:38] mAritz: So you redraw the entire windows interface with canvas? [14:38] maushu: robinduckett: No, because they then have enough traction. [14:38] jesusabdullah: http://jasonlbaptiste.com/startups/they-will-steal-your-idea-they-cannot-steal-what-really-matters/ [14:38] jesusabdullah: This article [14:38] _announcer: Twitter: "@rtomayko do you know of an implementation of the Erlang Distribution Protocol for node.js? (cc @squaremobius)" -- Tony Garnock-Jones. http://twitter.com/leastfixedpoint/status/19081123134 [14:38] mroach: mape: i saw another swedish dot on the map, just wanted to say hello :) [14:39] maushu: robinduckett: The best solution is releasing it as open source after a while. [14:39] mtodd has joined the channel [14:39] SubStack: jesusabdullah: yeah exactly [14:39] mape: hehe we are few and far between [14:39] mAritz: SubStack: So you redraw the entire windows interface with canvas? [14:39] mtodd has joined the channel [14:40] SubStack: mAritz: both vms are drawn the same way [14:40] maushu: mape: I'm the only one here! [14:41] mape: spain got their internet connected? ;P [14:41] maushu: ... [14:41] maushu: I'm not in spain. [14:41] mape: You arent? [14:41] mroach: Portugal! :D [14:41] mape: same same [14:42] jesusabdullah: SubStack: mashau might have a point there--that is, making the public repo a few months stale is a good compromise [14:42] mroach: iberia [14:42] mape: like denmark is almost Sweden [14:42] mostlygeek has joined the channel [14:42] mroach: yeah [14:42] robotarm_ has joined the channel [14:42] maushu: mape: SAME?! [14:42] mape: jup [14:42] mroach: sometimes i consider it to be part of sweden like renting a car from statoil and you can't take it out of "the country" [14:43] mroach: but i mean really, denmark is basically skåne [14:43] jesusabdullah: Oh man my dot's not on wargamez [14:43] maushu: ACTION takes out his glove, puts a brick in it and slaps mape with it. [14:43] jesusabdullah: I need to talk more! [14:43] SubStack: jesusabdullah: might be a good compromise if we get annoying copycats [14:43] mape: maushu: your silly spanish make believe doesn't work on me! [14:43] SubStack: for now though it's pretty non-trivial to get everything running [14:44] jesusabdullah: SubStack: Indeed! [14:44] jesusabdullah: A good example of someone who is completely open source: reddit [14:44] jesusabdullah: In fact, their VM made it fairly trivial to run your own reddit stack iirc [14:44] mape: And they make tons of cash [14:45] jesusabdullah: pffsht [14:45] jesusabdullah: well, they don't, but it's not because of copycats [14:45] SubStack: yeah, I'd love to show off the reddit vm with stackvm [14:45] jesusabdullah: Yeah, that'd be a sweet vid [14:45] SubStack: reddit is far more vulnerable to copycats [14:45] SubStack: since their business isn't so hardware intensive [14:45] jesusabdullah: and yet there aren't very many people running the reddit stack at all! [14:45] SubStack: although at the same time they exploit network effects more [14:45] mape: because the stack is useless without the content [14:46] mape: and or community [14:46] mape: same with stackoverflow [14:46] jesusabdullah: Point. [14:46] softdrink has joined the channel [14:46] jesusabdullah: SubStack: Make sure social aspects somehow find their way into stackvm [14:46] SubStack: yeah for sure [14:46] SubStack: there's a lot of stuff we can do [14:46] jesusabdullah: but don't do it retardedly [14:46] jesusabdullah: ;) [14:47] jesusabdullah: Don't add friend for the sake of it [14:47] jesusabdullah: but add friends [14:47] steadicat has joined the channel [14:47] jesusabdullah: ACTION gives more useless, contradictory advice [14:48] mape: SubStack: think the education part could be really big [14:48] mape: and browsertesting [14:49] mape: And please god allow me to script things, so I could record a cursor path/click series [14:49] mape: And allow me to run that recording on multiple machines [14:49] SubStack: absolutely [14:50] SubStack: mape: plus all the first APIs will be for node [14:50] SubStack: ;) [14:50] mape: hehe [14:50] mape: and look into the security part [14:51] mape: need to make sure the stuff I do on the machines are secure, if it is work related [14:51] JimBastard has joined the channel [14:51] SubStack: secure if you want them to be [14:52] SubStack: but also insecure if you want too! [14:56] aliem has joined the channel [14:58] maushu: SubStack: http://www.damnvulnerablelinux.org/ [14:59] SubStack: seen it [14:59] SubStack: (and it's awesome) [15:00] _announcer: Twitter: "@heri What I find interesting is that most of the implementation is in node.js." -- Arach Tchoupani. http://twitter.com/arach/status/19082727521 [15:04] V1: Yay free beer here! [15:05] V1: God, i love my job [15:05] kevwil has joined the channel [15:07] behmann has joined the channel [15:08] jetienne has joined the channel [15:08] stepheneb has joined the channel [15:09] devongovett has joined the channel [15:09] jetienne: 18k req/s on a 4core cpu (Q9400 2.66GHz) [15:09] maushu: I don't love my job. [15:10] jetienne: i "lost" mine today [15:10] maushu: I can send the letter till the end of the week... should I? Hmmm. [15:10] maushu: This job just takes so much time and doesn't allow me to develop graphnode. [15:12] aliem has joined the channel [15:13] Blink7 has joined the channel [15:13] maushu: They also treat programmers as a "normal" job. [15:13] maushu: One thing I've learned is that programmers are never normal. [15:13] bradleymeck__: its almost always that way at my jobs [15:17] sudhirj has joined the channel [15:21] WALoeIII has joined the channel [15:23] behmann_ has joined the channel [15:24] _announcer: Twitter: "Awesome! @webdirections just published the slides+podcast to my SSJS talk (including Node.js) http://bit.ly/9v2Vb9" -- Tom. http://twitter.com/sh1mmer/status/19084404626 [15:25] tjholowaychuk has joined the channel [15:25] sh1mmer has joined the channel [15:26] sh1mmer: yo [15:26] sh1mmer: ACTION off to OSCON [15:26] maushu: DEATH TO ALL BLASPHEMERS. [15:27] sh1mmer: ok guys I have another binary/byte manipulation question [15:27] sh1mmer: how do people do padding [15:27] sh1mmer: e.g. if I want to set a value of 15 across 4 bytes [15:27] sh1mmer: 0x0000000F [15:28] maushu: sh1mmer: Huh, calculate how many null bytes you are going to need and add them? [15:29] sh1mmer: maushu: right, that's fine [15:29] sh1mmer: I'm just checking what other people are doing [15:29] sh1mmer: or if there is some obvious thing I'm missing [15:29] sh1mmer: by poking at this stuff a lot I'm trying to figure if it's holes in my knowledge of best practice or helper methods that are useful [15:30] _announcer: Twitter: "@arach for node.js well I've never done something with node.js so can't comment on the technology :/" -- heri. http://twitter.com/heri/status/19084833841 [15:30] ajpiano has joined the channel [15:30] derferman has joined the channel [15:30] ThePub has joined the channel [15:31] nrstott has joined the channel [15:31] micheil: sh1mmer: I'm actually relistening to your @media talk [15:31] maushu: Well, in my case I would: var count = Math.floor(value (in this case 15) / 0xFF); Then a loop with 3 - count loops. Me thinks. [15:31] derferman has joined the channel [15:31] sh1mmer: micheil: :) [15:32] sh1mmer: maushu: yeah I wrote a small helper around that this morning on the train to the airport [15:33] jetienne: sh1mmer: simply "val & 0xF" [15:33] jetienne: node> 17.5 & 0xF [15:33] jetienne: 1 [15:34] sh1mmer: jetienne: it's about making sure a buffer has the right amount of bytes for given fields [15:34] aliem has joined the channel [15:35] sh1mmer: or possibly and I'm not sure if this is useful allowing you to set large numbers (>255) as values directly into a buffer [15:35] jetienne: sh1mmer: ? im just answering to my understanding of your question [15:35] sh1mmer: jetienne: sorry, wasn't meaning to be confrontational [15:35] sh1mmer: if I came off that way [15:35] jetienne: me neither :) [15:35] sh1mmer: :) [15:35] sh1mmer: ice cream for everyone [15:36] creationix: ice cream? [15:36] sh1mmer: because it's a party [15:36] creationix: sh1mmer: every time I see your slides, I feel bad for the narwhal [15:36] sh1mmer: creationix: the narwhal likes it [15:37] sh1mmer: you've seen reddit. it's a dirty dirty animal [15:37] tekky: was a baby narwhal harmed in the making of your slides sh1mmer? :P [15:37] creationix: tekky: hopefully it was "of age" [15:37] sh1mmer: tekky: I couldn't find a picture of a unicorn riding a narwal on the internet, so I made one [15:37] tekky: lol [15:37] bradleymeck__: ACTION summons tmpvar [15:39] [[zz]] has joined the channel [15:39] jetienne: those two should merge [15:39] bradleymeck__: as a side not does jsdom support document.form? [15:40] pgriess: creationix: can you guys put a license up on the spark github? [15:40] pgriess: creationix: i assume it's MIT, but lawyers don't like it when i assume [15:40] _announcer: Twitter: ""StackVM makes VMs accessible over the web" (embeddable in webpages) all using nodejs! http://bit.ly/aa9vYo /by @pkrumins" -- Dion Almaer. http://twitter.com/dalmaer/status/19085590544 [15:41] devtime has joined the channel [15:41] sh1mmer: ok [15:41] sh1mmer: I'll bbl [15:42] tmedema_: Whoever is doing stack VM has some good marketing =p [15:42] SubStack: ^_^ [15:42] devtime: creationix: is nStore a good DB for production use? [15:43] jesusabdullah has joined the channel [15:44] dnolen has joined the channel [15:44] maushu: SubStack: Confess, how much did you bribed! [15:44] SubStack: 5 million spacebux [15:45] maushu: Holy flying spaghetti monster! [15:45] SubStack: 1 spacebuck == 1e-9 USD [15:45] steadicat has joined the channel [15:45] maushu: Besides posting on HN, where else did you post? [15:45] SubStack: ask pkrumins [15:46] tekky: SubStack: so like a peso? :P [15:46] jesusabdullah: maushu: /r/programming has a post on stackvm [15:46] SubStack: I think just HN, reddit, and twitter [15:46] SubStack: proggit comments suck so much anymore [15:46] SubStack: bunch of haters [15:48] jherdman has joined the channel [15:49] k3yvn has joined the channel [15:49] maushu: SubStack: Have you decided if you are going to use freemium? [15:51] dcolish has joined the channel [15:51] mjr_ has joined the channel [15:53] jesusabdullah: SubStack: Yeah, proggit's been really frustrating lately. I'm so tempted to write a "wtf proggit?" self-post [15:54] _announcer: Twitter: "Giving #Goolge V8 Engine a shot http://bit.ly/9EYKif, notable feature is to try out NodeJS runtime for multi-core http server." -- Mohammed Khan. http://twitter.com/mohammed_khan/status/19086498783 [15:54] jesusabdullah: Yeah goolge! [15:54] SubStack: maushu: that's really only something we could do after we've got loads of infrastructure at our disposal [15:54] SubStack: so possible, but not for a long ways off [15:54] benburkert has joined the channel [15:54] jesusabdullah: I've been thinking, if you guys took micropayments similar to EC2 I think people would pay for it [15:55] jesusabdullah: People seem really enthusiastic about EC2 when they use it :/ [15:57] mw_ has joined the channel [15:58] maushu: jesusabdullah: Rabid fans. [15:58] JimBastard: stackvm looks cool [15:59] jesusabdullah: maushu: Something like that! [15:59] jesusabdullah: maushu: The people I talked to were mostly scientists that appreciated having, basically, quick access to a cluster at a moment's notice [16:00] jesusabdullah: Have you guys heard of starcluster? That makes it really nice :) [16:00] bean0r1___ has joined the channel [16:01] maushu: Hmmm. [16:02] khug has left the channel [16:03] elliottcable: hey, with the new non-promise fs APIs [16:04] elliottcable: if I’m writing a library that exposes its *own* asynch API [16:04] elliottcable: should I be doing `if (err) raise err;` or should I `if (err) callback(err, null, null…)`? [16:04] Yuffster has joined the channel [16:04] elliottcable: that is, is it more proper to throw errors, or ‘bubble’ them through to the callback that is handed to me? [16:06] tjholowaychuk: elliottcable: you should never really need to do callback(err, null, null, null, null) lol just do callback(err) [16:06] elliottcable: tjholowaychuk 3» I’m quite aware. I was providing that example to be explicit. [16:06] tjholowaychuk: it depends on the situation but typically you keep passing the exception [16:06] elliottcable: ACTION nods [16:06] elliottcable: thank you. [16:06] _announcer: Twitter: "I thought one neta asymmetric multiplayer cooperative game, I do not have time to make (node.websocket.js recently did not help it ours to say.)" [ja] -- Lucifuge Rofocale. http://twitter.com/lucifuges/status/19087388217 [16:07] aliem has joined the channel [16:07] maushu: asymmetric multiplayer cooperative game? Huh. [16:08] bradleymeck__: no sure what he means by asymmetric cooperative game [16:08] bradleymeck__: not* [16:08] amerine has joined the channel [16:09] creationix has joined the channel [16:09] jesusabdullah: bradleymeck__: Me neither :( [16:10] maushu: Crazy moonspeakers. [16:10] creationix: devtime: still there? [16:10] devtime: yes :) [16:10] creationix: nStore is being used in production now for a small service [16:11] creationix: but I only very recently fixes some nasty bugs [16:11] creationix: so it's not battle tested yet [16:11] mjr_: creationix: did those slow disk IO issues pquerna discussed on the list get resolved? [16:11] tjholowaychuk: devtime: node-redis-client is pretty solid [16:11] creationix: pgriess: ok, thanks for pointing out the mit thing [16:11] maushu: It should explode any moment. [16:11] mjr_: seems like they would pretty much crush nstore. [16:12] maushu: That is what creationix is trying to say. [16:12] creationix: mjr_: which ones? [16:12] mjr_: lemme find the link [16:12] creationix: he had a suggestion to improve the compacting of nStore databases [16:12] creationix: and he had some scary benchmarks involving the gc [16:13] robotarm_ has joined the channel [16:13] JimBastard: bradleymeck__: isometric [16:13] creationix: devtime: basically nStore is very new and has lots of promise, but it's far from throughly tested [16:13] JimBastard: maushu: ^^^ [16:13] JimBastard: i fluent in moonspeak [16:13] devtime: creationix: that Changelog post made me thing nStore was more like SQLite, than, say, MongoDB - is that true? [16:13] creationix: if you can afford possible setbacks, please help test nStore [16:13] creationix: devtime: it's like sqlite in that it's in-process [16:14] creationix: it's not a server, it's a library [16:14] jesusabdullah: haha, that's horrible [16:14] jesusabdullah: re: asymmetric/isometric [16:15] JimBastard: hee hee im about 90% sure on that [16:15] devtime: creationix: being in-process, how would that impact performance with Node.js? [16:15] creationix: though would love so see node based servers that wrap nStore and expose it using couch style apis [16:15] JimBastard: makes sense in context, also asians fucking LOVE diablo [16:15] jesusabdullah: heh [16:15] jesusabdullah: Good ol' Diablo [16:15] maushu: 私の名前はイニゴモントーヤです。あなたは私の父が死亡した。準備は死ぬ! [16:15] jesusabdullah: Never played it, but some of my friends liked Diablo 2 [16:15] creationix: devtime: well, it certainly might slow down a server since the JSON encoding and decoding is cpu intensive [16:15] bradleymeck__: !translate "私の名前はイニゴモントーヤです。あなたは私の父が死亡した。準備は死ぬ!" [16:15] JimBastard: i had a roommate at college who did nothing but play diablo 2 nonstop, he had two lvl 99 sorcs or whatever and would just run around in this cow level making walls of fire nonstop [16:15] mjr_: creationix: http://groups.google.com/group/nodejs/browse_thread/thread/de115072e243d2b7/df7b7f76a132a89a? [16:16] WALoeIII has joined the channel [16:16] creationix: devtime: but there is nothing you from putting it in a seperate process [16:16] [[zzz]] has joined the channel [16:16] WALoeIII has joined the channel [16:16] bradleymeck__: oi wtf killed utility now [16:16] aliem has joined the channel [16:16] creationix: mjr_: yeah, that's still unresolved [16:16] creationix: mjr_: not sure how it would affect nStore yet [16:16] mjr_: seems like it'd crush you though, no? [16:17] wakeup has joined the channel [16:17] wakeup: hiho [16:17] creationix: well, for small stuff (< 1000 documents) nStore runs great, not sure about larger data sets [16:17] creationix: I can insert 1,000,000 documents in about 15 seconds [16:17] creationix: (very small documents though) [16:17] micheil: creationix: hmm.. what would make it faster? [16:17] maushu: A quantum computer. [16:18] creationix: micheil: the JSON library and Buffer creations are the main bottlenecks for nStore [16:18] creationix: I don't think disk I/O is an issue [16:18] micheil: okay [16:18] romainhuet has joined the channel [16:18] wakeup: I currently use node-router, now I want to read from a file and serve it. How am I not forced to use synchronous I/O here? [16:18] rauchg_ has joined the channel [16:18] micheil: I'm thinking a cool project to work on would be a streaming JSON encoded / decoder [16:18] creationix: if node has msgpack that might help some [16:18] micheil: *encoder [16:19] creationix: I hear it's faster than json and would cause less disk I/O too [16:19] creationix: and smaller buffers to allocate [16:19] micheil: yeah [16:19] creationix: but nStore doesn't depend on anything by design [16:19] mjr_: You'd probably win big in this and other areas by avoiding buffer allocations. [16:19] micheil: you could also try using BSON [16:19] creationix: so I can't go that route unless node bundles mgcpack [16:19] mjr_: The default malloc is a general case allocator, and is quite slow. [16:19] micheil: creationix: why not just make it a dep. of nStore? [16:20] creationix: I think msgpack is better than bson [16:20] _utility: wakeup am not sure i understand the question [16:20] micheil: I've not seen a benchmark either way [16:20] creationix: micheil: someone could make a version of nStore that uses some other format [16:20] creationix: but I don't want any deps [16:20] micheil: creationix: or you could make the fs write pluggable [16:20] creationix: micheil: again, that would complicate the code and slow it down [16:20] creationix: probably not too much though [16:20] micheil: true [16:21] Ori_P_ has joined the channel [16:21] wakeup: _utility: node-router serves requests like: return foo; If the content is read froma file, I have to wait for reading to finish until I can answer the request [16:21] tjholowaychuk: +1 for no nStore deps [16:21] creationix: I think the easiest place to speed up things like nStore is to improve Buffers [16:21] tjholowaychuk: misewell just use redis or something if your doing that [16:21] wakeup: instead of handling the request and repsonding with a callback [16:21] micheil: tjholowaychuk: fair point [16:22] creationix: mjr_: did we ever find a way to speed up buffers/ [16:22] creationix: ? [16:22] creationix: also I found process.nextTick is too slow to have once per update [16:22] creationix: the app churns to a halt with 1,000,000 nextTicks in the queue [16:22] [[zzzz]] has joined the channel [16:23] bradleymeck__: http://github.com/creationix/node-router does use callbacks [16:23] wakeup: -.- [16:23] wakeup: yes of course it does [16:23] creationix: bradleymeck__: what about node-router? [16:23] wakeup: bradleymeck__: just try to server a file with it [16:23] bradleymeck__: wakeup seems to be asking something about sync behaviour [16:23] wakeup: creationix: yes [16:23] creationix: wakeup: it's async, I promise [16:24] creationix: but development has moved to connect [16:24] creationix: all of node-router and most of express got merged into connect [16:24] wakeup: how is retrun X async? [16:24] bradleymeck__: where is there a return X? [16:24] wakeup: in the callback function [16:24] creationix: wakeup: it's an idiom I use all the time [16:24] bean0r1___ has joined the channel [16:24] [[zzz]] has joined the channel [16:25] creationix: check the return value, and if it's defined, then pass the value to the callback [16:25] creationix: also I try..catch and pass the error to the callback [16:25] creationix: that way functions can be sync or async and it works the same [16:25] creationix: there is nothing wrong with sync code, it's blocking code that's bad [16:25] wakeup: I still dont get how to async'ly return a value [16:26] wakeup: which I need to do to use node-router [16:26] creationix: the return is sync, but it's value is passed to the callback for you [16:26] creationix: possible with a process.nextTick to force it to be 100% async [16:26] creationix: wakeup: have some code in question? [16:26] wakeup: yes [16:26] proppy: Hi, anyone has tried node_amqp with pyamqp lib or carrot ? [16:26] [[zz]] has joined the channel [16:27] proppy: I get wierd result like [16:27] proppy: {"data":{"0":102,"1":111,"2":111,"length":3,"used":3},"contentType":"text/plain","_routingKey":"position","_deliveryTag":20} [16:27] creationix: wakeup: you can't asyncly return, but you can turn a return into async [16:27] proppy: instead of "foo" [16:27] proppy: it looks like raw data [16:27] eee_c1 has joined the channel [16:27] proppy: like ascii code for 'f' 'o' 'o' [16:27] wakeup: server.get("foo", function (req,res,match) { var file = read(fd); return file }): [16:27] wakeup: this is blocking right? [16:27] tyfighter has joined the channel [16:27] micheil: proppy: try calling toString("utf8") [16:27] proppy: I was wondering if it was on node end, or on the python end [16:28] creationix: wakeup: what's read? [16:28] micheil: wakeup: no, it's non-blocking. [16:28] micheil: or should be. [16:28] creationix: it looks like a version of fs.readFileSync that takes an fd [16:28] wakeup: I need to read a file from disk and return it [16:28] micheil: oh, wait, missed read() there [16:28] wakeup: does not matter what read is [16:28] wakeup: just imagine I need the contents of a file on disk [16:28] creationix: wakeup: so you can use blocking I/O and return it, but it's better to not [16:29] wakeup: yes [16:29] wakeup: and how can I use non-blocking IO in that case? [16:29] creationix: fs.readFile("filename", function (err, data) { ... }) [16:29] wakeup: I can not right? [16:29] creationix: and then if it's an error you send a 500 or 404 response [16:30] wakeup: send? [16:30] wakeup: you mean return? [16:30] creationix: no, not return [16:30] creationix: return is sync [16:30] creationix: send using the methods on res [16:30] creationix: res.writeHead, res.write, res.end... [16:30] proppy: micheil: I don't get these issue when talking from node to node [16:30] wakeup: ah ok [16:30] wattz: afternoon guys [16:31] JimBastard: anyone have a preference for storing hashes? hex or base64? [16:31] JimBastard: wattz up [16:31] wattz: ! [16:31] wakeup: ugly but hey [16:31] wattz: ugly day? [16:31] pkrumins: stackvm. [16:32] creationix: wakeup: http://github.com/senchalabs/connect/blob/master/lib/connect/middleware/staticProvider.js#L104 [16:32] wattz: trying to decide if i want to support only mongodb or leave it open [16:32] JimBastard: pkrumins what bout you? any preference to storing hashes? base64 or hex? [16:32] JimBastard: if i had to pick a default convention [16:32] wakeup: is connect that Ext JS thing? [16:33] creationix: JimBastard: I use base 36 in nStore [16:33] wakeup: because if it is I aint touchin it. [16:33] mjr_: creationix: what do you mean by "speed up buffers"? [16:33] JimBastard: creationix: why? [16:33] wattz: im sitting in our Cafe in my corp building, and this guy next to me started off hitting on this girl he is sitting with, then something must of made him nervous because he derailed and started talking about his family and how they all are dying of cancer. :P [16:33] sudhirj: wakeup: why not? [16:33] creationix: JimBastard: cause it's cool, use whatever you like [16:33] creationix: wakeup: "ext thing?" [16:33] wattz: wakeup: it came from their project [16:33] creationix: wakeup: it's related to Sencha because they paid me to write it [16:34] creationix: but the code isn't related at all [16:34] pkrumins: JimBastard: hashes, hex. [16:34] wakeup: I worked 2 days on a sencha touch app once [16:34] creationix: wakeup: the code came from node-router and express [16:34] wakeup: didnt work for shit [16:34] evilhackerdude: is there something like eventmachine channels in node? (http://eventmachine.rubyforge.org/EventMachine/Channel.html) [16:34] wattz: i wrapped up my router yesterday, pretty stoked about it [16:35] tjholowaychuk: wakeup: Express is backed by Connect now [16:35] wattz: node and ss js has put the fun back in my programming [16:35] jesusabdullah: Where does sencha touch get its touch events from? [16:35] jesusabdullah: Like, how does that work? [16:35] tjgillies: holy crap this is awesome: http://wiki.github.com/ry/node/modules [16:36] wattz: anyone know if thre is an library/wrapper for xhr methods, that are JUST xhr/ajax? [16:36] sudhirj: jesusabdullah: probably from webkit [16:36] jesusabdullah: What I mean, I guess, is [16:36] jesusabdullah: microsoft's built-in touch events? [16:36] sudhirj: it has events for touch, pinch, and stuff [16:37] jesusabdullah: I built a DIY touchscreen recently [16:37] wakeup: it doesnt work anyways [16:37] jesusabdullah: and it used a protocol called TUIO [16:37] wattz: sudhirj: webkit [16:37] creationix: wakeup: sorry to hear, but I promise the code is 100% unrelated [16:37] wakeup: np ;) [16:37] jesusabdullah: I kinda wish TUIO wasn't being buried by more mainstream touch protocols. There's a lot of cool stuff out there for TUIO! [16:38] JimBastard: pkrumins: you prefer hex over base64? [16:38] wakeup: thing is, the only thing I need is an abstraction like node-router [16:38] pkrumins: yeah. [16:38] pkrumins: base64 is messy [16:38] JimBastard: im thinking hex is more used right now , more libs probaly [16:38] pkrumins: got to strip / and = [16:38] JimBastard: for sure [16:38] creationix: wakeup: look at the router middleware in connect [16:38] pavan_ has joined the channel [16:38] creationix: combine that with the staticProvider and you can easily serve static files [16:39] JimBastard: thanks pkrumins , good advice :-) [16:39] creationix: wakeup: good simple app using connect http://github.com/creationix/sousaball/blob/master/app.js [16:39] creationix: entire app < 100 lines of code [16:40] wattz: creationix: just threw you a follow, nice clean code man [16:40] creationix: :) [16:41] proppy: ok, found it node_amqp wait for content_type="text/json" [16:41] proppy: in order to decode json properly [16:41] proppy: node application/json [16:43] pquerna_ has joined the channel [16:44] elliottcable: Odd. [16:44] bpot has joined the channel [16:44] elliottcable: Trying to apply `replace()` to the result of `fs.readFile()` [16:45] elliottcable: I’m getting told `TypeError: Object return (function(){ return {a:1,b:2,c:3} }) has no method 'replace'` [16:45] JimBastard: elliottcable: toString() the data [16:45] elliottcable: oh crap forgot to specify an encoding [16:45] elliottcable: my bad Lx [16:45] JimBastard: its a buffer now [16:47] siculars has joined the channel [16:47] wakeup: hmm [16:48] wakeup: ReadableStream seems to be unfitting if you just want to read a chunk of the file? [16:48] creationix: wakeup: just fs.read() [16:48] creationix: specify the offset [16:48] richcollins has joined the channel [16:49] blackbrrr has joined the channel [16:49] mostlygeek has joined the channel [16:51] elliottcable: .go paw [16:51] cadorn has joined the channel [16:53] proppy: is mixin() a v8 or a node function ? [16:53] creationix: proppy: it was a node function, but since got removed [16:54] proppy: so node_amqp is broken ? [16:54] proppy: because it relies on mixin() [16:54] proppy: oh no, it is defined in the module [16:54] proppy: sorry for the noise [16:57] maqr has joined the channel [16:57] _announcer: Twitter: "whoa! stackVM: open source, virtual machines on the web... nice to see node.js in there: http://bit.ly/d0RunE" -- N Daniel-Richards. http://twitter.com/nicholasdr/status/19090738489 [17:01] sudoer has joined the channel [17:02] _announcer: Twitter: "trying to decide on where to spend my learning time. what does node.js give me that event machine doesnt?" -- Nick Ricketts. http://twitter.com/nightshade427/status/19091048605 [17:02] _announcer: Twitter: "Yahoo! and Node: In Multi-Core HTTP Server with NodeJS, Peter Griess (Principal Engineer, Yahoo! Mail) discusses u... http://bit.ly/aea4Gx" -- doobbe design. http://twitter.com/doobbe/status/19091109145 [17:05] _announcer: Twitter: "Why Node.js rocks the middle-end | getiblog http://j.mp/d6EpcJ" -- Jay Fallon. http://twitter.com/jayfallon/status/19091305207 [17:06] proppy: http://github.com/ry/node-amqp/issues#issue/3 updated [17:07] JimBastard: !tweet @nightshade427 javascript, plus node.js is waaaay easier to use [17:07] dgathright has joined the channel [17:07] wao: :| [17:07] creationix: JimBastard: sorry, already responded :P [17:07] JimBastard: lol [17:07] tjholowaychuk: anyone opposed to assert module having some events emitted? [17:07] tjholowaychuk: for reporting n shit [17:08] pavan_ has joined the channel [17:08] saikat` has joined the channel [17:08] JimBastard: creationix: im tweeting to the wind anyway [17:09] creationix: I doubt someone who's used to ruby will say javascript and callbacks is easier [17:09] rixius has joined the channel [17:10] creationix: but the fact that you can't use any ruby libraries since they're all blocking I/O is a real bummer [17:10] rixius: Hitting a bug in trying one of the ( fab ) examples, can anyone take a look? http://gist.github.com/484746 [17:10] JimBastard: creationix: not all of them, its the ole twisted problem [17:11] JimBastard: i havent actually used EM in production, i remember tmm1 telling me something about dealing with the blocking libs, i cant remember [17:11] JimBastard: ruby in one ear, right out the other [17:11] creationix: I used event machine for a production ruby app [17:11] creationix: it's a pain [17:11] tjholowaychuk: em is awkward [17:12] creationix: pgriess: feel free to remove the link from my comment on your blog if you don't want links out [17:12] elliottcable: okay, what the hell [17:12] elliottcable: using script.runInNewContext(() [17:12] elliottcable: reading content out a file [17:13] elliottcable: uh, I’m getting all sorts of weird, changing errors *in the file using script.runInNewContext()* [17:13] elliottcable: when I change the content of the script being read-in-and-run [17:13] JimBastard: what errors elliottcable ? [17:13] creationix: blackdog: how goes using haXe with node? [17:13] elliottcable: for instance, when the file being read-in is `function(){ return {a:1,b:2,c:3} }`, I get an `SyntaxError: Unexpected token (` where there is no parenthesis, in the original file [17:13] JimBastard: blackdog is the haXe guy for sure [17:13] EyePulp: hola creationix & JimBastard [17:13] pgriess: creationix: not sure which comment you're talking about. i don't see anything in either developer.yahoo.com/blog or blog.std.in [17:14] _announcer: Twitter: "a flash video of a vm thin client in a browser talking to node.js hosted by javascript on v8 running on linux in qemu: http://bit.ly/axketN" -- Erik Frey. http://twitter.com/erikfrey/status/19091835264 [17:14] JimBastard: elliottcable: i told you, are you .toString() on your data? [17:14] elliottcable: but if I change the content to `(function(){ return {a:1,b:2,c:3} })`, then I get `TypeError: undefined is not a function` (again, in the original file) for a very-definately-defined-function [17:14] creationix: I used to be a haXe programmer (never comited to the project though) [17:14] elliottcable: JimBastard 3» I changed it as documented such that it has an encoding [17:14] creationix: pgriess: it's still in moderation [17:14] creationix: developer.yahoo.com [17:14] JimBastard: elliottcable: third try, are you doing toString() on the data? [17:14] creationix: EyePulp: sup [17:15] elliottcable: JimBastard 3» I added that; according to the docs, it’s unnecessary. Didn’t help, same problems. [17:15] JimBastard: can you copy paste the code in question? [17:15] blackdog: hello, pretty well [17:15] elliottcable: sure, but it’s a bit complex… hold on [17:15] pgriess: creationix: i don't moderate comments on that blog (the ydn guys run it) [17:15] JimBastard: aight [17:15] blackdog: creationix, haxe/node is pretty good [17:15] pgriess: creationix: sh1mmer is your guy there [17:15] elliottcable: (I’m trying to convert some old code to all the new Node APIs since I left) [17:15] creationix: pgriess: ahh, that's explains it. I included a link to spark [17:16] creationix: blackdog: last time I tried it seems to not fit the code style of node's api at all [17:16] pgriess: creationix: cool [17:16] pgriess: creationix: i caught the extjs -> senschalabs change but missed the connect->spark break out [17:16] creationix: too dynamic for haxe [17:16] pgriess: creationix: lots of links broke in the 3-4 days this was in editing :-/ [17:16] blackdog: creationix, yea, i use static methods to pull out various things [17:16] blackdog: but it's not too bad [17:16] creationix: pgriess: yeah, the docs are still wrong for connect/spark but tjholowaychuk is fixing that today [17:16] elliottcable: mmkay [17:16] creationix: blackdog: I love how haXe uses ocaml's type system [17:17] creationix: something like that would be powerful combined with node [17:17] creationix: it only it felt more natural [17:17] blackdog: creationix, i think there are lot's of benefits to typing personally [17:17] softdrink has joined the channel [17:17] creationix: obviously ;) [17:18] blackdog: creationix, i have to be carefule with that on a js channel ;) [17:18] elliottcable: JimBastard 3» http://gist.github.com/484790 [17:18] JimBastard: statically typed languages own face, its just a huge pita to program massive amounts of code in them [17:18] JimBastard: elliottcable: peepin [17:18] elliottcable: it’s some weird shit [17:18] creationix: blackdog: most people in this room are pretty friendly and know a few languages [17:19] creationix: JimBastard: have you tried haXe or oCaml, type inference is awesome [17:19] elliottcable: but unfortunately the code may be too complex for you to understand… and I’m not sure how to reduce the problem, at this point… becaue I can’t even tell where the error is actually occuring. Depending on the content of foo.js, the error is reported all over the original source file. [17:19] JimBastard: creationix: i'd like to for sure [17:19] creationix: what I can't understand is how people use Java and keep their sanity [17:19] creationix: it's got a horrible type system [17:19] aliem has joined the channel [17:19] blackdog: creationix, the latest stuff is i have most of haxe's io lib using node's sync primitives, that's just for compatibility though [17:19] creationix: make static typing look bad [17:19] elliottcable: creationix 3» ugh, was having a conversation with an enterprise Javaer in ##Paws a few hours ago [17:20] creationix: elliottcable: sorry to hear that [17:20] creationix: blackdog: ok, I'll take a look again [17:20] elliottcable: creationix 3» … lol [17:20] blackdog: creationix, there's some crypto not done, but everyhing else is in use [17:20] JimBastard: elliottcable: thats gonna be too much for me to step through right now, you cant reduce the bug to the minimal reproducible use case? [17:21] blackdog: creationix, also, there are haxe xmpp client using it , some sqllite wrappers not by me [17:21] JimBastard: we had an issue yesterday with a fairly complex system and just took an hour or so to setup a nice example [17:21] JimBastard: sent it out, and got a solution very quickly [17:21] elliottcable: JimBastard 3» I totally would if I could figure out where the error is occuring. That’s the exact problem, it’s being reported in several different locations [17:21] JimBastard: elliottcable: so you should debug more? [17:21] elliottcable: JimBastard 3» hm? [17:22] elliottcable: JimBastard 3» ’s what I’m doing. It’s rather impossible to debug when stacktraces hand you gibberish o_O [17:22] elliottcable: you know, like syntax errors about parens where there’s no parens, or about colons where there’s no colons, or about calling undefined as a function on a defined function… [17:22] elliottcable: and all without changing the file that actually has those errors showing up in it [17:22] elliottcable: )-: [17:23] creationix: blackdog: oh I see, you have your own google group [17:23] creationix: that's why I never hear much here [17:23] elliottcable: I saw haXe go by in passing… [17:24] blackdog: well, i'm not sure if anyone is really interested here so i keep it quiet more or less [17:24] elliottcable: people actually use that? I glanced at it once, but it absolutely *stank* of Generated Code™… so I stayed the hell away [17:24] aho has joined the channel [17:24] creationix: elliottcable: people like coffeescript [17:25] elliottcable: creationix 3» there’s a staunch difference there; that’s a new language, layered specifically on top of an existing language, with an eye to said existing language’s features and design [17:25] elliottcable: creationix 3» essentially, it’s extending/modifying JavaScript [17:25] elliottcable: which is quite different from generating arbitrary code, a la ProtoBufs or haXe [17:25] creationix: I think if there was a way for stack traces to link to the original source when possible, these generators would be more useful [17:26] tjholowaychuk: creationix: you could probably instrument and hack it together like i do with jade [17:26] creationix: elliottcable: what about a strict subset of js that allowed for static analysis and type enforcement [17:26] creationix: that would be useful I think [17:26] elliottcable: creationix 3» I’d be all for that [17:26] tjholowaychuk: creationix: and ||= lol [17:26] tjholowaychuk: FINallAYY [17:26] creationix: not sure how much of js you'd have to outlaw to make it possible [17:26] elliottcable: creationix 3» not that I’d use it; not a typing fan… I’m just saying that’s an appropriate application of code generation [17:27] creationix: eval for sure [17:27] creationix: well, my idea isn't code generation at all, just a better code checker [17:27] creationix: type inference isn't that hard when it's possible [17:27] JimBastard: haXe looks fucking awesome, imo. i just dont have the time to get into it [17:28] JimBastard: i have no real use case for it right now [17:28] creationix: JimBastard: if you come visit you can borrow my haxe book [17:28] creationix: JimBastard: it's great for swf stuff [17:28] JimBastard: yeah, fuck AS [17:28] creationix: beats the socks off adobe's stuff [17:28] JimBastard: but thanks for the offer [17:28] elliottcable: uhrm [17:28] JimBastard: if i ever have to write AS again i might have to quit software forever [17:28] elliottcable: it … generates JS. Bad JS. [17:28] elliottcable: and Flash, need I say more? [17:28] elliottcable: and PHP, ditto. [17:29] elliottcable: and it builds cross-platform desktop apps. Everybody knows what a travesty those always are. [17:29] elliottcable: and finally, it compiles down to C++, letting you build native apps… but such ‘generally requires additional SDKs’ [17:29] elliottcable: the only use I can see for it where it might be less than retarded, is using it exclusively as a meta-language to develop C++ applications. [17:29] elliottcable: a la CoffeeScript, but for C++. [17:30] JimBastard: i dont think ive written a proper c++ app in 9 years. [17:30] Yuffster_ has joined the channel [17:30] creationix: elliottcable: no, it's truly a good AS replacement for swf stuff [17:30] creationix: but flash becomes less relevent as time goes on [17:30] JimBastard: i could only imagine how it would feel to do that again [17:30] elliottcable: creationix 3» well, like I said, that’s Flash. [17:31] elliottcable: creationix 3» in fact, the only place haXe seems relevant is PHP, Flash, and C++… none of which I’d consider particular relevant in the modern world, beyond having to deal with legacy code or succumb to the Lesser Beings known as management |= [17:31] bradleymeck__: c++ is still better than obj C i think [17:31] elliottcable: but I’m an opinionated jackass, so ignore me *shrugs* [17:32] elliottcable: bradleymeck__ 3» Blasphemy! :O [17:32] creationix: elliottcable: thanks for the opinion ;) [17:32] bradleymeck__: obj c requires how many declarations of a function? 3 [17:32] elliottcable: blackdog 3» I love Objective-C; and far more importantly, it’s actually … y’know … C. Unlike C++. Which drives me batty. [17:32] wattz: they are different tools for different jobs :P [17:32] elliottcable: sure [17:33] elliottcable: C, Objective-C, and D, all have appropriate use cases. [17:33] stepheneb has joined the channel [17:33] fdmanana has joined the channel [17:33] wattz: D is sorta a bastard child though [17:33] bradleymeck__: havent seen D in a year or so, used to use it a fair bit [17:33] elliottcable: C++ has its appropriate use-case too: When somebody’s willing to pay you a lot of money if you use it, and not willing to pay you if you use anything else. [17:33] wattz: still has it's place [17:33] elliottcable: Other than that, there really are none. [17:33] _announcer: Twitter: "@pkrumins oss project "StackVM" tries to bring virtual machines to the web. Built on node.js. All the best!! http://j.mp/cen0SN" -- Pavan Yara. http://twitter.com/yarapavan/status/19093087362 [17:34] wattz: C++ is good for doing love level oop [17:34] wattz: C is good for not. [17:34] wattz: obj-c is like C# [17:34] wattz: language for the platform [17:34] utility has joined the channel [17:34] elliottcable: no, objective-C is good for doing low-level OO P. C is good for doing low-level non-OO P. [17:35] bradleymeck__: the lack of true contructors still bothers me [17:35] elliottcable: oh hell no, not the ‘ObjC is only worthwhile on the Mac’ argument. It works just fine on Linux; and Cocoa is, by and large, a steaming pile of crap anyway. The best part of Objective-C is the language itself, and that’s perfectly portable. [17:35] wattz: elliottcable: i wasn't pigeon holing objc to mac [17:35] bradleymeck__: the interface + header + implementation style is not as pretty [17:35] wattz: aim was *osix [17:35] aurynn: ObjC is great. GNUstep is pretty complete, and now Google is doing their own ObjC library implementation [17:36] elliottcable: wattz 3» wasn’t exploding at you, personally; that argument just bugs me [17:36] wattz: aye [17:36] creationix: ACTION goes back to work without inciting elliottcable more [17:36] wattz: aurynn: link? [17:36] elliottcable: creationix 3» noooooo [17:36] _frankie has joined the channel [17:36] creationix: :) [17:36] elliottcable: creationix 3» without things to flame about in #Node.js, I have nothing to do, with Script so broken! )-: [17:37] creationix: elliottcable: where is that gist [17:37] bradleymeck__: how is script broken? [17:37] aurynn: wattz, looking.. [17:37] creationix: I can take a crack at it [17:37] aurynn: wattz, http://code.google.com/p/cocotron/ [17:37] _announcer: Twitter: "@nicholasdr you're into node.js?" -- Donnie Coleman. http://twitter.com/saturn825/status/19093306482 [17:37] jetienne: aurynn: url on google objc lib annonce ? [17:38] aurynn: ? [17:38] wattz: aurynn: that's not google's [17:38] _announcer: Twitter: ""keys" -- a unified key/value store api for #nodejs http://bit.ly/bITHa1" -- TJ Holowaychuk. http://twitter.com/tjholowaychuk/status/19093388559 [17:38] jetienne: aurynn: where do you see it is google? [17:38] wakeup: http://pastebin.com/YScC2Ybr [17:39] wattz: cocotron is also on #macdev :D [17:39] elliottcable: creationix, JimBastard 3» I added the error messages it’s giving me for each version of foo.js: http://gist.github.com/484790 [17:39] wakeup: can anyone tell me why this function only works once? [17:39] aheckmann has joined the channel [17:39] aurynn: Oh, I thought it was google. [17:39] aurynn: I am clearly confused. [17:39] aurynn: :) [17:39] wattz: just source hosted on google [17:39] elliottcable: hahaha no [17:39] elliottcable: Cocotron is an awesome guy, though [17:39] elliottcable: his project is MAD-ambitious [17:39] wattz: yeah, haha [17:39] elliottcable: and he’s practically doing the whole damn thing himself [17:39] jetienne: but objc is as good as .net :) [17:39] aurynn: gnustep-without-gnustep would be lovely. [17:39] elliottcable: like, 8% of the codebase is external contributions [17:39] wattz: what's .net? [17:39] elliottcable: and yet he’s implemented a fucking ton of Cocoa already [17:39] wattz: ... >_> [17:39] aurynn: since gnustep seems embroiled in their own history [17:40] elliottcable: but, still, Cocoa sucks [17:40] elliottcable: so cocoatron can’t exactly expect to be much better, if they’re directly duplicating the API… )-: [17:40] wattz: if im going to dev on linux i will prolly use C++ [17:40] wattz: mac obj-c/coca [17:40] wattz: cocoa [17:40] bradleymeck__: wakeup you are returning a value != this in a Constructor Function? why? [17:40] elliottcable: creationix 3» if it helps, I can easily walk you through what the compelx part of the code does; I’m just not what sure I can remove, because the errors show up in random places [17:40] wattz: green arrows @_@ [17:41] aurynn: anyway, cmd-h, back to work :) [17:41] elliottcable: wattz 3:D [17:41] ChrisRicca has joined the channel [17:41] wakeup: bradleymeck__: why not? [17:42] wakeup: I mean I see that its a quite useless value, but better return something than nothing [17:42] bradleymeck__: doesnt make sense unless you are doing a .call or .apply [17:42] _announcer: Twitter: "@A_L yeah, soon enough. The part that serves the pixel and collects the stats is in node.js, and the part that stores the stats is ruby." -- Jeff Larson. http://twitter.com/thejefflarson/status/19093612222 [17:42] wattz: man, Im on the fence with writing my node based framework in C++ as a built in module :D [17:42] JimBastard: isaacs_home: look what your damn logic did to my node_hash library [17:42] JimBastard: http://gist.github.com/484829 [17:42] wakeup: bradleymeck__: I am not saying that I use it [17:42] JimBastard: fucking documentation and demo bigger then the lib again [17:43] creationix: elliottcable: sorry, I got pulled aside at work [17:43] wakeup: bradleymeck__: but still, this doesnt explain why this function only works once? [17:43] elliottcable: ’s fine man [17:43] creationix: elliottcable: now looking [17:43] bradleymeck__: other than that as long as you are using new on it seems to look fin [17:43] bradleymeck__: e [17:44] wakeup: ??? [17:44] wakeup: doesnt work tho [17:44] _announcer: Twitter: "Has anyone used node.js? Very curious about it." -- Tim Murtaugh. http://twitter.com/murtaugh/status/19093741278 [17:44] wakeup: when I use it the first time it works, but then it doesnt [17:46] bradleymeck__: works fine here on 2 uses [17:46] JimBastard: damn i want to holler at that guy [17:46] JimBastard: stupid twitter [17:47] bradleymeck__: frankie is up again, something keeps taking him down [17:47] JimBastard: someone tweet that dude and tell him to come to #node.js [17:47] wakeup: weird [17:47] wattz: Not sure you guys are quite ready for Birdhouse yet :D [17:47] JimBastard: !tweet @murtaugh tons of people, come to #node.js on irc.freenode.net [17:47] creationix: wakeup: returning from a constructor generally breaks it [17:47] _announcer: Twitter: "I like all the node.js coming out, but seeing functions named nsPayloadLength drives me nuts ( http://is.gd/dB01O ). Modules, people." -- Justin Knowlden. http://twitter.com/jaknowlden/status/19093940828 [17:47] _announcer: Twitter: "@murtaugh logs on to #node.js on freenode IRC ... lots of noders there." -- Chakrit Wichian. http://twitter.com/chakrit/status/19093951693 [17:48] JimBastard: thanks bradleymeck__ , didnt know he was renamed [17:48] bradleymeck__: hes undercover from a guy flooding him [17:48] elliottcable: JimBastard 3» what? [17:48] creationix: elliottcable: so what's this script trying to do? [17:48] JimBastard: javascript mafia [17:48] JimBastard: ill snuff him out [17:48] wattz: lol [17:48] elliottcable: creationix 3» just in the middle of rewriting a complex, old library, to the new APIs [17:48] wakeup: creationix: good info, but still, even without returning anything, it wont work 2 times for me [17:49] elliottcable: creationix 3» the script as it stands is fairly useless; does one basic thing, and does it in an uber complex way… going through three levels of currying and about fifteen levels of callback [17:49] devinus has joined the channel [17:49] elliottcable: JimBastard 3» whaaaaa [17:49] JimBastard: elliottcable: ???? [17:49] creationix: wakeup: ok, I'll look at it when I'm done helping elliottcable [17:49] admc has joined the channel [17:49] JimBastard: im trying to code here what you want [17:49] _announcer: Twitter: "@murtaugh yeah. Tons. #Node.js on Freenode, come say hi." -- elliottcable. http://twitter.com/elliottcable/status/19094065527 [17:50] elliottcable: creationix 3» honestly, you can probably help him more redily than I. This is… painfully complex /-: [17:51] jtoy has joined the channel [17:51] elliottcable: barring that, uh… constructCompiler and constructExecuter both curry what’s passed to them; they use compileScript and executeScript respectively [17:51] creationix: elliottcable: not sure, I can reproduce most the errors, but it's some funky eval semantics [17:51] elliottcable: called from `from['execute']['absolute'] = constructExecuter( constructCompiler( resolveAbsolute ) )` [17:51] aliem_ has joined the channel [17:52] elliottcable: I think that gives you enough to walk through what happens? [17:52] tjgillies: is announcer written in javascript? [17:52] elliottcable: _announcer 3» help! [17:52] creationix: elliottcable: yeah, sorry, too much to grok, this will take some time to take in [17:52] _announcer: Twitter: "These guys are completely amazing StackVM: Embedded Virtual Machines http://stackvm.com/ as Youtube videos with Node.js" [es] -- Altuzar. http://twitter.com/altuzar/status/19094253124 [17:53] elliottcable: creationix 3» it’s not really your problem; I don’t want to eat up your time if you’ve better things to do :x [17:53] JimBastard: hahahaha pkrumins your accent is awesome [17:53] elliottcable: I need to get this fixed, but not at someone else’s expense [17:53] pkrumins: hey JimBastard [17:53] rauchg_: elliottcable: how'd the wave go [17:53] elliottcable: JimBastard 3» so freaking true, right? [17:53] pkrumins: i get this a lot [17:53] elliottcable: rauchg_ 3» what? [17:53] creationix: elliottcable: I was hoping it was something quick I might see [17:53] pkrumins: i just made another video [17:53] pkrumins: it's stackvm from within stackvm running winxp in winxp [17:53] JimBastard: pkrumins: its an american thing for sure [17:54] rauchg_: elliottcable: google wave fluid userscript [17:54] pkrumins: JimBastard: sounds like american accent? [17:54] elliottcable: rauchg_ 3» oh dude it went fucking awesome [17:54] creationix: alright wakeup now for you code and them I'm back to work [17:54] rauchg_: :) [17:54] elliottcable: rauchg_ 3» It’s all done, and it works perfect. [17:54] rauchg_: nice [17:54] elliottcable: rauchg_ 3» you want? [17:54] wakeup: cool [17:54] JimBastard: nono pkrumins , your accent is just awesome sounding [17:54] hellp has joined the channel [17:54] wattz: so i convienced my job to sign up for corp github, they are AMAZED by version control :D [17:54] pkrumins: JimBastard: ah got it. [17:54] JimBastard: what is your native langauge? [17:54] elliottcable: rauchg_ 3» http://wave.google.com/wave/waveref/ell.io/w+JbVCRR2fA [17:54] wattz: people still use google wave? [17:55] pkrumins: JimBastard: latvian language [17:55] elliottcable: wattz 3» ahhahhaha. [17:55] [[zz]] has joined the channel [17:55] elliottcable: wattz 3» We’re biding our time until we get a damned C/S protocol and can build *real* clients [17:55] elliottcable: wattz 3» )-:< [17:55] creationix: wakeup: what function is only working once? [17:55] wattz: I work for Lowe's (lowes.com) [17:55] wakeup: sha1Sum [17:55] elliottcable: why’re you using sha1? [17:56] bradleymeck__: real clients? [17:56] wakeup: elliottcable: no doplicates [17:56] wattz: elliottcable: because it's more secure than md5? :D [17:56] elliottcable: bradleymeck__ 3» for Wave. [17:56] elliottcable: bradleymeck__ 3» it’s a long, complex, and annoying story… the moral of which is “Google fucked it up,” as usual. [17:56] wakeup: creationix: bradleymeck__ said it worked for him so I am kind of confused [17:57] bradleymeck__: just be sure to use new [17:57] bradleymeck__: always on that [17:57] creationix: wakeup: how are you calling it [17:57] wakeup: well without new [17:57] elliottcable: what the flying fuck http://introducinghtml5.tumblr.com/ [17:57] creationix: since you use "this" you have to use "new" [17:57] wakeup: its a function, I want it to be reusable [17:57] creationix: otherwise you're clobbering the same global object over and over [17:58] creationix: if you want it reusable, don't use this [17:58] wakeup: sounds fair [17:58] creationix: just return an object with the properties you want exposed [17:58] _announcer: Twitter: "@azulkipli node.js, ironruby, ironpython" -- DwiAsharialdyHambali. http://twitter.com/dwiash/status/19094588591 [17:58] creationix: wakeup: especially since "this" without "new" is the module itself [17:58] creationix: and that's cached even beteen require calls [17:59] creationix: hmm, actually, no, but "this" is something global [17:59] creationix: maybe the module, not sure what the context is in that case [17:59] tjholowaychuk: global [17:59] wakeup: yeah I dont know what I was thinking to use this there [18:00] wakeup: in reflection it looks retarded [18:00] creationix: tjholowaychuk: so it's the global shared between the module and it's caller? [18:00] tjholowaychuk: creationix: any fn called without a receiver should be global unless there is weirdo magic involved [18:00] mscdex: node.js rules! [18:01] creationix: tjholowaychuk: yeah, I know that, but modules are magic [18:01] devtime has joined the channel [18:01] creationix: but I think you're right it's "global" in the caller script [18:01] creationix: which happens to be the same "global" in the module (unless you enable ryah new module feature) [18:02] bradleymeck__: anybody know if jsdom supports directives like html strict etc somehow that im not seeing? [18:02] tjholowaychuk: yup [18:02] tjholowaychuk: apparently module "this" is the exports now [18:02] tjholowaychuk: used to be global [18:03] pkrumins: ok get ready for this, stackvm running in stackvm running windows xp withing windows xp [18:03] creationix: yep, that's the magic I was speaking of [18:03] pkrumins: all powered by node.js [18:03] pkrumins: <3 node.js [18:03] creationix: pkrumins: :) [18:03] wakeup: stackvm running in stackvm running windows xp withing windows xp <- why would you want this? [18:03] JimBastard: pkrumins: what actually does the vm part? [18:03] elliottcable: ;_; [18:04] pkrumins: JimBastard: VMWare [18:04] pkrumins: wakeup: that's some tasty mind abuse. [18:04] JimBastard: so in theory you have to pay for that right? [18:04] pkrumins: sure [18:04] bradleymeck__: no virtualbox love? [18:04] JimBastard: pkrumins: nested VM mind abuse is not as bad as dual-sided mind abuse [18:05] pkrumins: but we also got it running with qemu [18:05] pkrumins: and virtualbox should also work [18:05] JimBastard: cool cool [18:05] pkrumins: i just had a faster computer running vmware [18:05] maushu has joined the channel [18:05] elliottcable: pkrumins 3» why not try this on EC2? [18:05] JimBastard: yeah im not too aware of VM stuff, just a bit [18:05] hpoydar has joined the channel [18:05] elliottcable: pkrumins 3» is custom hardware really necessary? [18:05] rixius: I'm running my node dev on a lubuntu slice on virtualbox on my __vista__ development box. I don't really ever leave Lubuntu... [18:06] pkrumins: elliottcable: we haven't investigated that yet! [18:06] pkrumins: elliottcable: but surely it should be doable. [18:06] pgriess has joined the channel [18:08] elliottcable: pkrumins 3» that should handily solve all of your resources problems right snappy. [18:08] pkrumins: yeah! [18:08] pkrumins: we'll look into it [18:08] pkrumins: <3 [18:11] aliem has joined the channel [18:13] kassens has joined the channel [18:13] kassens: is there no bug tracker for node? [18:13] _announcer: Twitter: "added support for #amqp event in #playground #nodejs server http://is.gd/dB1v0 and updated #playground websocket client http://is.gd/dB1wS" -- proppy. http://twitter.com/proppy/status/19095497264 [18:13] maushu: kassens, http://github.com/ry/node/issues [18:14] elliottcable: go macos [18:14] kassens: maushu: thanks [18:16] pkrumins: OK [18:16] pkrumins: here it is! [18:16] pkrumins: http://www.youtube.com/watch?v=EKFjJ9m_P8Y [18:16] pkrumins: stackvm from within stackvm! [18:16] programble has joined the channel [18:19] wakeup: how can I handle a failing httprequest? [18:20] wakeup: I get Error: ENOTFOUND, Domain name not found [18:20] wakeup: which is natural [18:20] wakeup: but i want tor eact to that [18:23] elliottcable: Um. How the hell does ndb work? [18:23] maqr: so i want to match a string at the end of a string, like /foo$/, but where 'foo' is a variable... what's the right way to do that? [18:23] elliottcable: I tried dropping `debugger;` in my code and using `node --debug-brk` [18:23] elliottcable: but … it didn’t pause and drop into the debugger :x [18:23] jesusabdullah has joined the channel [18:25] wakeup: is there nor error event for HTTPrequest? I mean cmon [18:25] wakeup: that sound weird [18:25] jxson has joined the channel [18:27] qFox has joined the channel [18:27] wakeup: anybody? [18:28] maqr: wakeup: i'm not sure i followed the question :/ [18:28] wakeup: I use http.ClientRequest [18:28] wakeup: and when I request something from foobar for example [18:28] wakeup: foobar will be unreachable [18:29] wakeup: obviously [18:29] maqr: well it must throw some kind of error [18:29] wakeup: I want to catch that case and handle it [18:29] maqr: i mean, i think [18:30] wakeup: it does throw errors, but it doesnt emit a error signal [18:30] maqr: sec, i'm reading the docs, i'm about to have that same problem [18:30] wakeup: I dont even know how many or what exeptions can be thrown [18:31] papandreou has joined the channel [18:31] maqr: i guess the question is, is there a timeout? [18:31] V1 has joined the channel [18:31] maqr: it seems like the only emitted events are upgrade, response, data, and end [18:31] wakeup: there is [18:32] wakeup: I had ETIMEOUT exceptions at other computers [18:32] wakeup: here I have ENOTFOUND [18:32] maqr: wakeup: did you read through the node source about it yet? [18:33] wakeup: nope [18:33] wakeup: I dont think I would get much out of that [18:34] _announcer: Twitter: "#AdobeSpry was my first love, #nodejs is my second love <3" -- Arnout Kazemier. http://twitter.com/3rdEden/status/19096742935 [18:34] maqr: wakeup: you'd be surprised, it's written in javascript and it's easy to read [18:34] maqr: i'm looking at it now [18:34] ryah: hello world [18:35] maqr: hello ryah :) [18:35] wakeup: hello ryah [18:35] kersny has joined the channel [18:36] elliottcable: argh [18:38] elliottcable: ryah: got a sec? [18:38] maqr: wakeup: well, it looks like it's part of net.js [18:38] maushu: ryah, I saw what you did there. [18:38] mjr_: wakeup: this is odd. I just tried your example, and it seems like an uncatchable error. [18:39] mjr_: which is odd / bad. [18:39] wakeup: I can catch it [18:39] wakeup: |process.on('uncaughtException' [18:39] mjr_: with an uncaughtException [18:39] mjr_: ? [18:39] wakeup: yes [18:39] wakeup: but that sucks [18:39] mjr_: Oh, OK. Well annoyingly, you can't catch it with try / catch. [18:39] wakeup: thats because of callback [18:39] maqr: oh, nevermind, you're further along than me already :) [18:39] wakeup: try catch doesnt work with async code [18:40] Xavura has joined the channel [18:40] rsms has joined the channel [18:40] voxpelli has joined the channel [18:40] wakeup: maqr: so what does us tell net? :> [18:40] elliottcable: ryah 3» I can’t, for the life of me, figure Script out. [18:41] wakeup: event timout on net.Stream? [18:41] mjr_: figured it out [18:41] mjr_: listen for "error" on client; [18:41] elliottcable: ryah 3» with really basic code, I keep getting deeply puzzling errors… not in the script I’m changing, but in the complex and un-changing script that’s working with `Script`! [18:41] wakeup: cool [18:42] elliottcable: ryah 3» and as I change the basic code, the errors being reported keep shifting around, into all sorts of weird, impossible things [18:42] elliottcable: :x [18:42] maqr: wakeup: yeah, that's what i was looking at [18:43] aconbere has joined the channel [18:43] maqr: wakeup: line 69 in master net.js [18:44] maqr: wakeup: but that manages some kind of internal list, i guess... i'm not exactly sure what 'socket' is, but i think that's what would have to deliver the error? [18:45] ryah: elliottcable: hm [18:45] ryah: elliottcable: that's not really a question :) [18:45] wakeup: maqr: listening on client for 'error' seems to work [18:45] elliottcable: ryah 3» :x [18:45] elliottcable: ryah 3» here’s more info: http://gist.github.com/484790 [18:46] maqr: wakeup: yeah, if you search for emit, you'll see where it emits errors [18:46] elliottcable: ryah 3» the top file is actually 5 different versions of itself; I show the errors each version gives me (notice that none of them are actually reported as being in that file; nor are they remotely relevant to the place they’re reported as being) [18:46] maqr: wakeup: it looks like it also emits 'close' and 'timeout' [18:46] TrisMcC has joined the channel [18:48] mjr_: here's an example of how to catch a DNS error in the HTTP client: https://gist.github.com/56ee4ccc62f68a0bd2c9 [18:48] TrisMcC has joined the channel [18:48] jxson has joined the channel [18:48] elliottcable: ryah 3» I’m trying to narrow the problem down to a better test case, but… it’s being *really* elusive [18:48] christiaan has joined the channel [18:49] jxson has joined the channel [18:49] TrisMcC has joined the channel [18:49] maqr: elliottcable: whatever character you're using is green, not displaying properly, and annoying :P [18:49] elliottcable: maqr 3» l2Unicode [18:50] zapnap has joined the channel [18:50] maqr: ouch [18:50] maqr: elliottcable: i don't know why irssi isn't doing unicode for me, actually [18:50] elliottcable: maqr 3» C-a :set defutf8 on [18:50] elliottcable: maqr 3» and possibly /set term_charset utf-8 [18:50] elliottcable: (though that shouldn’t be necessary nowadays) [18:51] maqr: elliottcable: heh, it says it'll use unicode for *new* windows, oh well [18:51] elliottcable: maqr 3» :set utf8 on [18:51] elliottcable: maqr 3» :x [18:52] elliottcable: oops [18:52] maqr: it's not set, but i know that :p [18:52] elliottcable: C-a :utf8 on [18:52] elliottcable: there we go [18:52] elliottcable: haha, yeah, been a while since I’ve had to screw with it. [18:52] maqr: yeah, it says it is now, but i don't know if i believe it [18:52] maqr: your ' just made a funny looking a character [18:52] elliottcable: http://github.com/elliottcable/dotfiles/blob/master/screenrc [18:53] maqr: that's a pretty good .screenrc [18:53] elliottcable: ryah 3» any ideas? I don’t know if it’s a bug, or some fundamental rules aobut using `Script` that I don’t understand… [18:54] maqr: elliottcable: still doesn't work in irssi though, dunno why [18:54] maqr: term_charset is right too [18:55] elliottcable: odd [18:55] elliottcable: screen out, and re-attach with -U [18:55] elliottcable: you may have to destroy the screen and create a new one with -U *and* attach to it with -U [18:55] elliottcable: it’s a bit finnicky [18:55] maqr: what's -U? [18:55] maqr: elliottcable: also, do you happen to know how to reorder screen windows? that's been driving me crazy [18:56] V1: is there a easy way to check what kind of encoding a buffer is using? I know you can check if a item is buffer using Buffer.isBuffer, but it would be great to also know which kind of encoding the buffer is using. [18:56] elliottcable: V1 3» buffers don’t … “use” … an encoding, as far as I understand it [18:57] elliottcable: V1 3» that’s specific to the methods you use to get data into or out of the buffer, right? [18:57] maqr: heh, reattaching very did not fix it :/ [18:58] elliottcable: maqr 3» I don’t know what to say; works great for me: http://drp.ly/1p5g4V [18:58] V1: elliottcable: You can do a .write(UTF8) or .write(binary) indicating the type of data in the buffer? [18:58] elliottcable: and all the config I’m using is right there on the GitHub repo I linked /-: [18:58] elliottcable: weird… [18:58] V1: If you push binary data in to buffer, I assume you also want to pull out binary data when you do .toString(). [18:59] elliottcable: V1 3» http://nodejs.org/api.html#buffer-write-6 [18:59] elliottcable: V1 3» specifically, buffer.write(), buffer.toString(), and new Buffer() all take encoding arguments [18:59] elliottcable: V1 3» buffer is just a malloc range anyway, nothing magical about it, no encoding stuff; you put data in, you get data out. [19:00] maqr: elliottcable: that is a damn pretty screenshot you've got there though :p [19:00] elliottcable: maqr 3» um, :number? [19:00] elliottcable: maqr 3» thank you :3 [19:00] maqr: i like your font [19:00] elliottcable: Menlo; Snow Leopard typeface [19:00] maqr: hah, :number! [19:00] V1: elliottcable: So i get a buffer, to a toString, store it locally, and after a while give it back again by creating a new buffer, the wouldn't be any change to the data, no matter how i pulled out and stored the data in the buffer? [19:01] elliottcable: urhm, once it’s a String, JS can modify it [19:01] maqr: elliottcable: you wouldn't happen to know how to split screen like :split and :vsplit do in vim, would you? :p [19:01] aheckmann has joined the channel [19:01] elliottcable: so if you call modifying methods in JS… I’d assume it would modify it [19:01] elliottcable: but as long as it’s in a buffer, it’s just a memory range. [19:01] elliottcable: it ain’t gonna change unless you write to it. [19:01] bradleymeck__: anyone know if there is a standard way to get the status code of a document? ie 201 (non-ajax) [19:01] elliottcable: maqr 3» C-a S [19:02] elliottcable: maqr 3» and all this info is on C-a ? [19:02] mjr_: bradleymeck__: response.statusCode? [19:02] V1: elliottcable: I'm not going to modify it, i intent to store it's contents on a memcached server. [19:02] bradleymeck__: meant in browser, sorry for confusion [19:03] maqr: elliottcable: the help page is confusing :/ [19:03] mjr_: bradleymeck__: xhr.status, but browsers get a bit annoyed by a many status code. [19:05] elliottcable has joined the channel [19:06] bradleymeck__: mmm but not on window.document? interesting [19:06] aliem has joined the channel [19:08] elliottcable: crap [19:08] elliottcable: killed my irssi, lol [19:08] elliottcable: well gah, I need food… [19:08] elliottcable: looks like ryah is afk, so I can safely pop out I suppose [19:09] maqr: elliottcable: see, i told you it's confusing ;) [19:11] b_erb has joined the channel [19:12] ChrisRicca has joined the channel [19:13] benburkert has joined the channel [19:14] bradleymeck__: env.js , iz coming for you [19:15] mertimor has joined the channel [19:18] ryah: elliottcable: eh - i don't know [19:18] ryah: elliottcable: narrow it down to something i can test and i'll take a look [19:20] wakeup: creationix: about node-router, what happens with multiple match-groups in regex? [19:21] hpoydar has joined the channel [19:21] jxson has joined the channel [19:21] javajunky has joined the channel [19:21] rgl has joined the channel [19:22] creationix: wakeup: I think the first match wins [19:22] creationix: in the order you defined them [19:22] rauchg_ has joined the channel [19:22] zerovirtual has joined the channel [19:23] wakeup: that sucks [19:23] wakeup: ah no I think you misunderstood me [19:23] maqr: does v8 support array comprehensions? [19:24] creationix: maqr: sadly no [19:24] creationix: wakeup: ok, try again [19:24] wakeup: creationix: I mean like this "^/files/([a-z0-9]+)/([0-9]+)$" [19:24] maqr: creationix: well, that explains why it doesn't work :) [19:24] V1: Does anybody know if there will be more checksums supported in the Crypto module? CRC32 is missing for example [19:25] maqr: creationix: can we fix that? :/ [19:25] wakeup: V1: doesnt that depend on your openssl? [19:25] wakeup: V1: at least thats the way I understood it [19:25] V1: openssl doesn't support CRC32 [19:25] wakeup: oh ok^^ [19:25] wakeup: nvm [19:25] Mark9000 has joined the channel [19:26] Mark9000: hi [19:26] V1: It might be possible to incorporate http://www.cryptopp.com/ for algorithms for but my C++ fu is weak ;D [19:28] bronson has joined the channel [19:28] wakeup: creationix: Basically: what will the match argument in the callback be bound to? (server.get new RegExp("^/files/([a-z0-9]+)/([0-9]+)$") [19:29] creationix: maqr: we don't change v8 itself [19:29] creationix: implementing that would be non-trivial [19:29] creationix: and the patch might not even be accepted by the V8 guys [19:29] creationix: wakeup: I guess I don't understand the problem [19:30] wakeup: creationix: I have two "matches" ([a-z0-9]+)/([0-9]+) but the callback only takes one match argument [19:30] wakeup: I need both tho! [19:30] creationix: wakeup: ahh, in node-router, I think it just passes them as multiple arguments [19:31] creationix: and in connect it's in the params array [19:31] wakeup: so the callback is function (req, res, match1, match2) [19:31] creationix: wakeup: I think so, it's been a while since I used node-router [19:31] creationix: but I think was the way I did it [19:32] creationix: wakeup: just console.dir(arguments) [19:32] creationix: that will tell you what's getting passed in [19:32] rgl has joined the channel [19:32] wakeup: thx [19:33] creationix: wakeup: any reason why you don't want to upgrade to connect? [19:33] javajunky: creationix: any word on when the next connect will get pushed to npm ? [19:33] creationix: it's much more mature [19:33] creationix: javajunky: yes and no [19:33] javajunky: creationix: ;0 sounds ominous [19:34] creationix: javajunky: it will be ready soon [19:34] creationix: but since it's a major release I have to go through marketing [19:34] javajunky: oh… this would be the classic 'ext' moment to tell me…and we've decided to use the GPL [19:34] creationix: no [19:34] javajunky: ;) [19:34] creationix: don't worry about that [19:34] creationix: we'd be crazy to charge for connect [19:34] maqr: hmm, how do i use node to append to a file? [19:34] creationix: the target audience would never pay for it [19:35] rauchg_: haha drop it already [19:35] rauchg_: it's pretty clear it'll remain MIT [19:35] creationix: maqr: open it in "a" mode? [19:35] quirkey has joined the channel [19:35] creationix: senchalabs is seperate from ext [19:35] creationix: it's all open-source [19:35] creationix: like apache foundation [19:35] maqr: creationix: oh, then just writefileSync? [19:35] creationix: maqr: no, I don't think you can do that [19:36] creationix: maqr: open in "a" mode and then write to the fd using write() [19:36] creationix: and then close the fd [19:37] CIA-64: node: 03Chandra Sekar S 07master * rf5f7cb9 10/ (3 files in 3 dirs): Support for reading byte ranges from files using fs.createReadStream. - http://bit.ly/d6pDHr [19:37] CIA-64: node: 03Ryan Dahl 07master * r07ab34c 10/ TODO : TODO items - http://bit.ly/aJcqbM [19:37] CIA-64: node: 03Ryan Dahl 07master * re4eeaa7 10/ (62 files in 11 dirs): Upgrade V8 to 2.3.2 - http://bit.ly/9Aix5E [19:37] javajunky: creationix: (back on track, my fault) ..so its with the marketeers, bummer :).. the pm stuff seemed quite broked for me :( [19:37] maqr: creationix: oh ok, thanks :) [19:37] creationix: javajunky: well, I'm with the marketers, I want connect to gain a wider audience, and timing matters [19:37] creationix: we're just trying to make it sound good to people oustide of node to bring in more people [19:38] wakeup: creationix: your memory is accurate :) [19:38] creationix: wakeup: cool [19:38] sveisvei has joined the channel [19:39] creationix: ryah: "Fixed compiler warnings when building with LLVM" that sounds promising [19:39] Mark9000: i'm trying to run a websocket server with socket.io [19:39] rsms has joined the channel [19:39] javajunky: creationix: of course, your thang , not complaining, just wanted to know, as I'm never comfortable telling people to git clone stuff, prefer packages when describing suff to othes :) [19:39] Mark9000: do i need to run both the client and the server [19:39] Mark9000: or is the chat demo included with the server sufficient? [19:39] creationix: javajunky: yeah, I'm seeing if we can push something to npm in the mean-time that works with latest express [19:39] creationix: the code is ready now [19:40] javajunky: that would be cool, a bodyDecoder that doesn't die/hang wildly would be nice (I'm using git locally so I'm cool ) [19:40] maqr: ACTION likes connect [19:40] mjr_: Do the V8 guys just have a post commit hook that appends "Performance improvements on all platforms." to their Changelog? [19:40] creationix: maqr: :) [19:40] Mark9000: ohh uh, anyone know [19:41] creationix: mjr_: I think it's part of their process, but they do actually graph and benchmark it [19:41] creationix: so maybe it's a rule that a release can't go out with that statement being true [19:41] mjr_: Man, what if they only got performance improvements on SOME platforms? [19:41] mjr_: How dreadful. [19:41] _announcer: Twitter: "Continued hacking on my memcached client for node.js, successfully implemented get/set/incr/decr/version, up next multi server version :)" -- Arnout Kazemier. http://twitter.com/3rdEden/status/19100684238 [19:41] ryah: mjr_: sometimes they do that [19:42] stagas has joined the channel [19:42] stagas: any recommendation for xml parsing? [19:42] mscdex: libxmljs? [19:43] bradleymeck__: depends on how abusive the xml can be in not following spec, speed req, etc stagas [19:43] CIA-64: node: 03Ryan Dahl 07master * rcb97cdb 10/ deps/v8/SConstruct : Remove Werror from SConstruct - http://bit.ly/bIs0lY [19:43] maqr: stagas: i just put together a little library that turns xml into js objects, if that'd help [19:44] stagas: maqr: it would, where do I get it? [19:44] mscdex: maqr is a pro at that by now ;-) [19:44] bradleymeck__: mark9000 you only need a websocket server running [19:45] Mark9000 has left the channel [19:45] mscdex: bradleymeck__: he's using Socket.io [19:45] maqr: mscdex: :P [19:45] rauchg_: isaacs_home: your email about git is very spot on [19:45] bradleymeck__: still true [19:45] mscdex: heh [19:45] maqr: stagas: on github, xml2js, or through npm... it does require node-xml though, which you'll have to pull down separately [19:45] Mark9000 has joined the channel [19:45] bradleymeck__: htmlparser i loves you, you eat up all the bad syntax mr www.google.com gives you [19:45] mscdex: bradleymeck__: depends on his browser ;-) [19:45] bronson: Any recommendations for a simple persistent client/server connection? [19:45] dominikh has joined the channel [19:45] Mark9000: bradleymeck__ thanks [19:45] bronson: Faye looks pretty interesting. [19:45] maqr: stagas: there's no docs yet, but if you look at the test file, it's dead simple [19:46] mscdex: Charles Bronson? :O [19:46] stagas: maqr: thanks! [19:46] bradleymeck__: bronson, socket.io is pretty popular, but i pref node-websocket-server [19:46] _announcer: Twitter: "Paul Barry on Node.js http://vimeo.com/9205350" -- grantmichaels. http://twitter.com/grantmichaels/status/19100967749 [19:46] dominikh: ryah: hi! hey, I wondered... http://github.com/ry/node_chat/blob/master/index.html#L67 ← where did you get those logs from? :) [19:46] maqr: creationix: fs.writeSync(fd, "foo", null, encoding='utf8'); // any idea what could be going wrong here? it doesn't seem to write anything to the file :/ [19:46] mscdex: i prefer grappler ;-D [19:47] ryah: dominikh: ruby-lang, i think [19:47] dominikh: ryah: hah, okay. I was quite surprised to see my nick in there :P [19:47] ryah: :) [19:47] ryah: yeah, i should remove that [19:47] ryah: its from a long time go [19:47] maqr: stagas: i've only been at this less than a week and it's my first library, so don't hesitate to point out if i did anything stupid :p [19:47] dominikh: yeah, the initial commit actually :) [19:47] bronson: bradleymeck__, thanks, I'll look. [19:48] creationix: maqr: not sure, I haven't used fs.writeSync [19:48] bronson: bradleymeck__, why do you prefer it? [19:48] ryah: it's actually from before that [19:48] ryah: node_chat comes from node_irc [19:48] stagas: maqr: I will thank you :) [19:48] ryah: which was never released [19:48] tilgovi has joined the channel [19:48] bradleymeck__: just a bit better performance / works w/ connect(or any http.createServer) [19:49] zlatiborac has joined the channel [19:49] maqr: hrm, it even says the right number of bytes are written [19:51] tyler-bounce has joined the channel [19:52] Mark9000: on http://github.com/miksago/node-websocket-server it says: [19:52] Mark9000: It has been reported that this module experiences some issues on solaris and ubuntu systems, so far these issues are unresolved, but seem to be related to the core of Node.js [19:52] maqr: yeah, this makes no sense: https://gist.github.com/34e5404389f7162fc497 <-- it says it writes the right number of bytes, but there's nothing new inside the file... am i missing something? [19:52] Mark9000: anyone know what those issues are [19:52] dominikh has left the channel [19:53] tjholowaychuk: javajunky: we published the new connect to npm [19:54] bradleymeck__: mark9000 the upgrade event on http.createServer is unreliable on those systems, but i havent seen a botched one in a bit on my ubu machine, might have been fixed [19:54] _announcer: Twitter: "@CrabDude Also, since I saw you've done a talk on #nodejs, I'm interested in doing one on (fab) , a modular asynchronous framework for node." -- Stephen Middleton. http://twitter.com/Rixius/status/19101409911 [19:54] Mark9000: ahah, thanks [19:54] christiaan has left the channel [19:55] rixius: it's wierd seeing my tweets in an irc room >.> [19:55] mscdex: yeah i've never seen upgrade event issues on my ubuntu server either [19:56] maqr: is there an example of how to write files somewhere? i followed the docs and it just doesn't work :\ [19:56] mjr_: maqr: the examples in the docs don't work? [19:56] bradleymeck__: rixius you can tweet back !tweet [19:56] maqr: mjr_: doesn't seem to... hold on, let me check one more thing [19:57] rixius: !tweet [19:57] _announcer: Twitter: "i've said it before. i'll say it again. get beta invite 4 social ping. only word i have returning is nodejs . i get 30x + per day blowin up" -- jalbertbowdenii. http://twitter.com/jalbertbowdenii/status/19101584727 [19:57] bradleymeck__: !tweet @rixius i need texts, omnomnom [19:57] maqr: mjr_: oh, my mistake, it just doesn't throw an error... weird [19:57] rixius: That's Epic [19:58] maqr: mjr_: oh, actually, it did exactly what i told it, i just told it poorly... ignore me entirely :) [19:58] maqr: success :) [19:58] mjr_: maqr: Every now and then I got through and run all of the examples to make sure they still work. [19:58] mjr_: I thought all of the fs ones worked. [19:59] mjr_: There are a bunch that are missing examples though, which I keep threatening to fix. [19:59] mscdex: i double dog dare you to fix them! [20:00] maqr: mjr_: yeah, i just confused myself, because it wasn't giving errors and i didn't see it making the file... it was actually producing it in another directory :) [20:00] V1: Nice split [20:00] mischief has joined the channel [20:00] mjr_: shit, breaking out the double dog? [20:00] mjr_: That really puts me in a bind. [20:00] maqr: mjr_: funny how one '/' character changes the whole path :) [20:00] mscdex: :-> [20:01] davidsklar has joined the channel [20:03] sveimac has joined the channel [20:03] pgriess has joined the channel [20:03] _announcer: Twitter: "YDN on Multi-Core HTTP Server with NodeJS http://developer.yahoo.net/blog/archives/2010/07/multicore_http_server_with_nodejs.html" -- spite. http://twitter.com/thespite/status/19101924434 [20:04] maqr: is there a getopts for node yet? [20:05] maqr: ehh, nevermind, i'll just do it with environment variables [20:05] TS_ has joined the channel [20:05] TS_ has left the channel [20:05] steadicat has joined the channel [20:06] TS_ has joined the channel [20:06] bradleymeck__: there is a coupleon the modules page not sure how up to date they are [20:06] mscdex: i wish there was an unserialize function in js that worked on php session files [20:06] zum has joined the channel [20:06] mscdex: phpjs's unserialize doesn't work [20:06] elliottcable has joined the channel [20:09] chrischris has joined the channel [20:09] bradleymeck__: unserialize? [20:10] maqr: hmm, there's no fs.copy? am i supposed to read in the file and write it back out myself? [20:10] mscdex: maqr: sys.pump :-) [20:10] bradleymeck__: or 'spump a s i like to say [20:10] mscdex: pump a new fs.createReadStream into a new fs.createWriteStream [20:10] davidsklar has left the channel [20:10] maqr: mscdex: perfect :) [20:11] Fhoughersoguhesg has joined the channel [20:11] bradleymeck__: still need it to work on buffers i say [20:11] mostlygeek has joined the channel [20:11] mscdex: bradleymeck__: yeah, unserialize because the php session file at first glance looks like a regular serialized php object, but it's not [20:13] JimBastard: anyone wanna peep my node_hash library? about to release i think, http://github.com/marak/node_hash [20:13] JimBastard: its just a stupid wrapper for crypto [20:13] JimBastard: so developers have no excuse to not hash passwords [20:14] dnyy: JimBastard: nice picture [20:14] luddep has joined the channel [20:14] javajunky: meh, they/we still won't post hash encrypt ;) [20:14] JimBastard: thanks dnyy :-) [20:14] raim0_ has joined the channel [20:14] stagas: maqr: can't get it to work, it's like exports isn't working it's returning an empty object [20:15] dnyy: library looks nice too, though. :D [20:15] JimBastard: i try to give a small and clear explanation of why you should hash too [20:15] aconbere has joined the channel [20:15] JimBastard: dnyy: thanks! all the functionality already exists in the node core, i just wanted to make it a bit more accessible [20:15] ajpiano has joined the channel [20:16] maqr: stagas: hmm, how'd you install it? [20:16] stagas: npm [20:17] maqr: stagas: you installed node-xml too? ( i think that's not on npm ) [20:17] stagas: and I put node-xml in the folder, I changed require('xml') to require('node-xml') [20:17] stagas: it's not [20:17] khug has joined the channel [20:17] khug has left the channel [20:17] stagas: if it doesn't find it I get an error that the module doesn't exist, so it finds it [20:18] maqr: stagas: and var xml2js = require('xml2js') just comes back null? [20:18] stagas: not null, {} [20:18] maqr: :o [20:19] maqr: stagas: i'm sure it's my fault, give me a sec and i'll make it work [20:22] wakeup: wow I love nodejs^^ [20:22] V1: JimBastard: Why node_hash if you got the crypto library that supports those hashes true openssl [20:22] wakeup: yep [20:22] _announcer: Twitter: "Had a play with node.js, the server side Javascript library. Quite a good experience I have to say." -- Cliff Xuan. http://twitter.com/cliffxuan/status/19103004999 [20:22] wakeup: I work with them atm [20:22] wakeup: works really good [20:22] JimBastard: V1: RTFM [20:23] V1: but WHY [20:23] maqr: stagas: you're correct, it comes back {}, fixing it now :) [20:23] JimBastard: why not use the node.js crypto library instead? node_hash DOES use the built in node.js crypto library, we are just wrapping it for easy use [20:23] tahu has joined the channel [20:23] saikat` has joined the channel [20:23] V1: WHY@, ;9 [20:24] wakeup: I got crypto to work, thats the definition of very easy [20:24] wakeup: ;) [20:24] ajpiano has joined the channel [20:24] JimBastard: well, i started out building the crypto module is pure JS, only to find crypto got added a few months ago [20:24] JimBastard: so the OG project had all the algos in pure js, i removed them [20:24] JimBastard: its just sugar syntax and hand holding for noobs [20:24] richcollins has joined the channel [20:24] JimBastard: nothing special [20:24] wakeup: damn [20:24] wakeup: big ups anyway :) [20:25] JimBastard: thanks wakeup , i try to do a lot of stupid little projects that will draw attention [20:25] JimBastard: this one is more stupid then usual though [20:25] V1: :p would be nice if you supported more checksums than crypto does [20:25] JimBastard: V1: issue time! [20:26] _announcer: Twitter: "@tswicegood You still up for talking node.js at next month's KCRuby? August 10 @ 7PM." -- Luke Pillow. http://twitter.com/lpillow/status/19103207555 [20:26] V1: To much typing JimBastard :p [20:26] markwubben has joined the channel [20:26] _announcer: Twitter: "Disciples Blog: An Introduction To NodeJS, A JavaScript-Based Server http://ht.ly/18ewvv" [fil] -- Alagad Inc. http://twitter.com/alagadinc/status/19103243627 [20:26] xer0xM has joined the channel [20:29] maushu has joined the channel [20:30] maqr: stagas: this package management stuff is so confusing... if you copy the file in to your directory, and require('./xml2js'), then it works just fine [20:30] maqr: obviously i need to fix how it works with npm though [20:31] Mark9000 has left the channel [20:32] khug has joined the channel [20:32] khug has left the channel [20:33] ajpiano has joined the channel [20:33] ChrisRicca has joined the channel [20:34] stagas: maqr: it works like you said [20:36] aliem has joined the channel [20:37] stagas: maqr: though very slow, almost 30secs on a 300kb xml file :/ [20:37] maqr: stagas: it shouldn't be that slow, it's sax :/ [20:38] maqr: stagas: sec, let me fix up this package and push it to npm [20:40] stagas: 27 secs on 268kb xml. 1 sec per 10kb [20:42] maqr: stagas: i fixed npm and git, you should be able to update now and it should be good [20:43] maqr: stagas: i'm not sure why it's so slow though... i think it must be node-xml, since my library doesn't really do much besides wrap it [20:43] maqr: stagas: any chance that's a public xml file i could test with? i don't think i have any that large [20:43] herbySk has joined the channel [20:44] stagas: maqr: http://dl.dropbox.com/u/396087/360.xml [20:45] Viriix has joined the channel [20:45] maqr: i knew i was going to have to fix my unicode support in my terminal today :/ [20:46] benoitc has joined the channel [20:46] _announcer: Twitter: "node_hash - super simple hashing library for #node.js http://github.com/marak/node_hash #nodejs #javascript #pointlesslibrary" -- marak squires. http://twitter.com/maraksquires/status/19104298166 [20:47] JimBastard: lol nice [20:47] JimBastard: does anyone feel like doing a post for me on HN? im still perma banned big time [20:47] JimBastard: can provide the link and text [20:47] maqr: how the hell did you get banned on HN? [20:48] JimBastard: ACTION exists [20:48] maqr: :o [20:48] sh1mmer has joined the channel [20:50] JimBastard: maqr: you feel like being my best friend and posting for me? you can create a new account without registration [20:50] JimBastard: you can just copy this post word for word [20:50] maqr: stagas: you're right, that takes far too long [20:50] JimBastard: http://www.reddit.com/r/programming/comments/cs733/node_hash_a_super_simple_hashing_for_nodejs/ [20:50] maqr: JimBastard: ehh, i like posting on HN, i don't really wanna mess with them... but i'll upvote you :P [20:50] maqr: JimBastard: you can always just ssh proxy through one of your servers to post [20:51] JimBastard: maqr: i refuse to do that on principal. ban evasion is a slippery slope [20:51] maqr: JimBastard: proxying through me is still ban evasion :) [20:51] JimBastard: if you dont want to post its fine ill get someone else [20:51] JimBastard: no, its me asking someone else to do it [20:51] maqr: ssh socks are people too [20:51] maqr: stagas: i suspect it's node-xml that's the problem, luckily there are several other sax parsers [20:51] JimBastard: ban evasion would be me loading up a list of 10k proxy servers and creating thousands of new accounts and ruining HN for a few hours [20:52] JimBastard: and fuck that [20:52] maqr: heh [20:52] wakeup: whats HN? [20:52] maqr: news.ycombinator.com [20:52] JimBastard: yeah [20:53] wakeup: graham that ol fuck on top :D [20:53] wakeup: this guy should stfu [20:54] sh1mmer: hm [20:54] benoitc has joined the channel [20:56] maqr: stagas: does the output actually give you what you want? it's just far too slow? [20:56] stagas: maqr: what do you mean? [20:57] mape: whats with all this crazy talk [20:57] maqr: stagas: the resulting object, it's got the data you want? it's just too slow in processing? [20:59] stagas: maqr: I didn't check all of them but they seem to be ok. it's just slow considering I want to process 200-300 of these files :) [20:59] steadicat has joined the channel [20:59] _announcer: Twitter: "@flashcodersny tonight is all about nodejs don't miss out on the loveliness of server-side js #nodejs #js #flash" -- Anthony Cintron. http://twitter.com/supdun/status/19104981164 [20:59] maqr: stagas: well, one of us needs to swap out node-xml for one of the other sax parsers :) [20:59] stagas: maqr: if you're seeing crazy chars it's because it's greek [21:00] maqr: stagas: yeah, i noticed :P [21:00] stagas: maqr: I'm trying to install libxmljs but I seem to be missing scons (I'm on cygwin) so it doesn't compile [21:01] maqr: stagas: ah, scons is a python script, i think [21:01] admc has joined the channel [21:01] maqr: stagas: but yeah, libxmljs or sax-js http://github.com/isaacs/sax-js [21:02] mAritz: damnit... i want to store timestamps. what i do: new Date (timestring).getTime(); the problem: my current server is set to CEST. so if i enter sth like 2010/07/21 it stores the timestamp of UTC 2010/07/20 23:00. if i ever change the timezone of the server, all the dates will be wrong. how do i handle this? [21:02] _announcer: Twitter: "#reddit node_hash - a super simple hashing library for node.js: submitted by JimBastard [link] [comment] http://bit.ly/aeiFOT #rulez" -- REDDITSPAMMOR. http://twitter.com/REDDITSPAMMOR/status/19105161690 [21:02] maushu: OH COME ON. [21:02] maushu: I find a great domain and it was registered... TODAY. [21:02] JimBastard: maushu: did you search for it first? [21:02] mAritz: maushu: that's what you get for writing a twitter bot :P [21:03] saikat_ has joined the channel [21:03] maushu: JimBastard, I just did the whois. [21:03] maushu: I mean, right this moment. [21:03] maushu: I didn't even write the domain anywhere. [21:03] papandreou: mAritz: use new Date(Date.UTC(year, month, date, hours, minutes, seconds, milliSeconds)); [21:04] mAritz: papandreou: what if I don't have the date in that format? [21:04] blowery: JimBastard: how are the strings serialized with node_hash? utf-8? [21:04] stagas: maushu: someone on your dns server is searching for cool unresolved requests and registers them [21:04] stagas: :P [21:04] mape: Dont understand people who use services to check if domains are taken, just whois them, cli plz [21:04] JimBastard: blowery: what you mean? [21:04] rsms has joined the channel [21:04] papandreou: mAritz: Then you might want to get your hands dirty :) [21:04] blowery: what's "data" ? [21:05] JimBastard: blowery: ? [21:05] mAritz: papandreou: me not like dirty! :( [21:05] JimBastard: just run the node-demo.js file [21:05] stagas: mape: I really like instantdomainsearch.com cause it tells you while you're typing if it exists [21:05] blowery: JimBastard: so, you're hashing "strings" right? [21:05] JimBastard: blowery: for now yeah, node hash support for everything else though [21:05] blowery: JimBastard: but how that String exists as bytes can vary. is it utf-8, utf-16, ascii,... [21:05] hsoj_ has joined the channel [21:06] papandreou: mAritz: JavaScript's Date object is horrible to work with, I'm afraid you'll have to :) [21:06] mAritz: gaaah :( [21:06] JimBastard: blowery: how does the normal crypto module deal with that? [21:06] mape: stagas: still only 3 of the tds, and I don't trust em [21:06] aliem_ has joined the channel [21:06] blowery: JimBastard: i have no idea. i assume it serializes Strings as UTF-8, but could equally be UTF-16. [21:06] mAritz: is there a date lib somewhere? JimBastard help! :D [21:06] blowery: JimBastard: prolly have to go peek at the source to know [21:07] blowery: hashes tend to work in terms of byte buffers instead of "strings" for just this reason [21:07] stagas: where do I find scons then [21:07] JimBastard: mAritz: www.datejs.com [21:07] mAritz: yeah, googled that myself. but is it good? :D [21:07] JimBastard: mAritz: there is http://github.com/marak/javascript-fu [21:07] JimBastard: but havent released it yet [21:07] JimBastard: mAritz: if you are willing to put in some working, helping finish http://github.com/marak/javascript-fu would be AMAZING [21:07] JimBastard: its like 80% done [21:08] JimBastard: and all the pieces are there [21:08] JimBastard: it even has unit tests! [21:08] maqr: stagas: http://www.scons.org/ [21:08] mAritz: i've got too much stuff not even 50% done to take on any other projects, sorry :( [21:08] maqr: stagas: if you feel like swapping out node-xml for libxmljs, just let me know so i can merge it in [21:08] mde: papandreou: Dates and timezones are horrible in every language. :) [21:09] papandreou: mde: Yeah, but especially in JavaScript. [21:09] JimBastard: http://news.ycombinator.com/item?id=1536550 [21:09] JimBastard: successful proxy post is successful [21:09] benburkert has joined the channel [21:09] papandreou: mde: ... And that's coming from a guy who wrote a calendar application :) [21:10] maqr: stagas: http://github.com/polotek/libxmljs/blob/master/spec/spec_xml_sax_parser.js , it looks pretty easy to do [21:10] mde: papandreou: Yeah, I wrote a client-side Olson parser in JS. [21:10] mde: I know from JS Dates. [21:10] _announcer: Twitter: "Meeting tonight 7/21:Server Side JavaScript with Node.js. ThinkCoffee, 248 Mercer (Bet 3rd and 4th) 7 to 9" -- Flash CodersNY. http://twitter.com/flashcodersny/status/19105629615 [21:11] papandreou: mde: So code that uses the zoneinfo database to convert between local time and UTC? [21:11] mde: I've only ever done anything else with Ruby dates, and it didn't seem that much nicer except that you have acess to the system clock. [21:11] Validatorian has joined the channel [21:11] jesusabdullah has joined the channel [21:11] mape: module dependencies... foldername == vendor or deps or ???? [21:12] mde: papandreou: Basically it's an API-compatible replacement for JS Date with timezones: http://github.com/mde/timezone-js [21:13] mde: It's pretty naive, but mostly does what you need it to do. Apple uses it in MobileMe. [21:13] mde: Or did, I haven't looked recently. [21:14] papandreou: mde: Impressive! I've made an implementation of iCalendar recurrence rules that can do the same thing based on a VTIMEZONE object :) [21:15] moqq has joined the channel [21:15] papandreou: mde: But your approach is better for a general purpose date library with timezone support. [21:15] mde: Oh, recurrence is terrible. Kudos, man. :) I did recurring events when I was building the front-end stuff for Chandler server at OSAF. [21:16] mde: Right, if you're not tightly tied to iCalendar, something simple that Mostly WorksTM is probably what you want. [21:16] papandreou: mde: Yeah, that spec is a mess :). You guys didn't do it in JavaScript, AFAIR? [21:16] papandreou: mde: Very much agreed! [21:16] papandreou: mde: And I think your library just saved me several weeks of work :) [21:16] mde: The backend was a Tomcat app, but we pushed as much of the logic into JS-land as we could. [21:16] mattly has joined the channel [21:17] papandreou: mde: Even expansion of RRULEs? [21:17] mde: papandreou: Awesome! It still breaks around the DST leaps in some timezones. Some of that is from breaking changes to the Olson DB, and some of it is because of how JS Dates do the leap. [21:18] mde: Oh, no, that was pre-parsed on the server side using this thing Bobby wrote called icalforj. [21:18] papandreou: mde: leap seconds? [21:18] mAritz: okay, if i were to save the timestamp. should i use javascript (milliseconds) or unix (seconds) style? [21:19] mde: papandreou: My library uses an internal 'proxy' JS Date object so you get all the specified ECMA Date behaviors. [21:19] jpld has joined the channel [21:19] devtime has joined the channel [21:19] mde: So if you poke at dates around the DST leap time comparing timestamps and generated JS Dates, you'll see the same weird behaviors. [21:19] bradleymeck__: darn tmpvar, talk about thorough testing [21:20] papandreou: mde: My approach to handling multiple time zones using with the JS Date object is to do all calculations in UTC and forget everything about the browser's time zone. So always new Date(epoch) or new Date(Date.UTC(....)) and always use the UTC versions of the getters and setters. [21:20] mde: I can't remember the specifics; I made a chart one time. P) [21:20] mde: papandreou: That's pretty much how my library works internally, yes. [21:20] dosbeats has joined the channel [21:20] mde: The canonical representation of the date is the collection of the different values for each part. [21:21] mde: And all the getters and setters work with an internal Date object. [21:21] wattz: yo dosbeats [21:21] dosbeats: what what [21:21] papandreou: mde: But how does the browser's DST transitions factor in, then? [21:21] mAritz: don't ignore me dear time experts :( [21:21] papandreou: mde: Does your library distinguish between dates and date-times? [21:22] wakeup: mAritz: ina database? [21:22] bradleymeck__: i always found it funny that date-times and dates are distinguished by some things [21:22] mAritz: yep [21:22] mAritz: (redis) [21:22] wakeup: use seconds [21:22] wakeup: I doubt you need milliseconds [21:22] papandreou: mAritz: I was actually working on a solution for your prob. What does your format look like? [21:22] mde: papandreou: IIRC, it's because the offsets are still calculated based on the generated Date. [21:23] mAritz: papandreou: no specific format, that's kinda the problem. but i think i have a solution: just add the timezoneoffset to the timestamp :D [21:23] papandreou: mde: But if you do your calculations in UTC, all "local times" are valid. Which offsets? [21:23] mde: And no, I originally implmeneted Date and DateTime seprately, but it was nicer for Chandler for use just to be able to replace JS Dates without any change to the API. [21:24] mde: papandreou: The result of getTimezoneOffset. [21:24] papandreou: mde: So a date is represented as a date-time with time=midnight? [21:25] papandreou: mde: What do you need getTimezoneOffset for when you have your own time zone library? [21:25] mde: Well, the canonical representation is the collection of values. [21:25] mde: Not an actual Date objet. [21:26] mde: And the library just replaces the built-in getTimezoneOffset with its own that calculates it based on the stated values for the date and the timezone set on it. [21:27] maqr: stagas: i'm converting it to libxmljs now [21:27] mde: But finding the right offset still requires doing a bunch of date comparisons to find which range of which rule is in effect. And those comparisons are done with actual JS Date object. [21:27] bradleymeck__: mmm, github is snailing on jsdom pulls [21:27] papandreou: mde: Oh yeah, the good old binary search. [21:28] rtomayko has joined the channel [21:28] mde: Exactly, yeah. I don't do a lot of work on it anymore, but there are people using it for stuff, so if you have ideas for improvment or patches, please send them my way. [21:28] papandreou: mde: But I've got that part working in my VTIMEZONE-based implementation. [21:29] papandreou: mde: I will :) [21:29] mde: The problem is there are a bunch of different solutions that get you like 90% of the way there. :) [21:29] mde: We need to put ourselves together and make one good one. :) [21:31] maqr: hrm, libxmljs fails its tests [21:31] papandreou: mde: Yep! [21:31] stagas: maqr: can't get it to install either [21:31] papandreou: mde: Btw. someone ported python's dateutil a while back, did you take a look at that? [21:32] behmann has left the channel [21:32] maqr: stagas: well it installs here, but it throws up all kinds of confusing errors [21:32] _announcer: Twitter: "An Introduction To NodeJS, A JavaScript-Based Server: Recently, I’ve been dipping my toes into languages and techn... http://bit.ly/bEdsQX" -- FMC Washington DC. http://twitter.com/FMC_Washington/status/19106890634 [21:32] maqr: stagas: which sucks too, because node-xml has a compatible interface with it... it should have just been like a two line fix [21:33] stagas: maqr: yeah [21:33] maqr: stagas: actually, one of their tickets says i can ignore these errors... in which case, this works extremely fast... but uhh, sec [21:33] maqr: http://github.com/polotek/libxmljs/issues#issue/13 , this is the issue, if you were wondering [21:33] mde: papandreou: No, I didn't know that. That's like diff/add, right? [21:33] mischief has joined the channel [21:33] mde: I wrote a diff/add/strftime set that ended up in Dojo. [21:34] mde: There's a port of it here: http://github.com/mde/geddy/blob/master/geddy-util/lib/date.js [21:35] bradleymeck__: do ajax requests update cookies for a domain? [21:35] papandreou: mde: Nice! [21:35] qschzt has joined the channel [21:35] Blackguard has joined the channel [21:36] mde: papandreou: ISO 8601 parsing too, if that helps you. :) [21:36] qschzt: looks like process.on('SIGINT', fn) is broken? [21:36] maqr: stagas: yeah, this library is not so good [21:38] mostlygeek_ has joined the channel [21:38] qschzt: http://nodejs.org/api.html#signal-events-55 that example doesn't work for me [21:38] creationix: bradleymeck__: yep [21:38] creationix: if the response has the set cookie header [21:39] maqr: stagas: so we can rule out libxmljs and node-xml... so that leaves us with sax-js or node-expat [21:39] bradleymeck__: grrr [21:39] mscdex: huh? [21:39] papandreou: mde: It does! My implementation of that is half-assed :) [21:39] stagas: maqr: I'm trying node-expat but also doesn't compile :/ [21:39] mscdex: what is the problem with libxmljs? [21:39] akahn has joined the channel [21:40] qschzt: ^D works with 'exit' handler, ^C doesn't call the SIGINT handler.. hmm. [21:40] mde: papandreou: Awesome. It's always nice when people not-me actually find something useful. :) [21:40] maqr: stagas: well you're on cygwin, so that can't be trusted :P [21:40] stagas: cygwin sucks [21:40] mde: When you find bugs, please send me patches! [21:40] maqr: mscdex: it throws up crazy memory errors, but even if it didn't, it doesn't seem to work as expected [21:40] mscdex: stagas: make sure you have the openssl development package installed [21:40] maqr: stagas: use vmware + ubuntu, btw, that's what i do [21:40] mscdex: maqr: yes, that's known [21:40] eee_c has joined the channel [21:41] mscdex: regarding the memory errors [21:41] stagas: I do [21:41] papandreou: mAritz: I have a POC UTC date parser for you, but I don't want to spam everyone with it. I'm on freenode's web chat, so I don't know how anything works. [21:41] maqr: mscdex: yeah, that's not so good :/ [21:41] mscdex: stagas: what about the openssl binary package? [21:41] maqr: stagas: i'm going to try sax-js now [21:41] mAritz: papandreou: http://gist.github.com [21:42] maqr: stagas: 'npm install sax' definitely works, now i just gotta convert the code [21:42] mscdex: stagas: actually, let me ask this... when you ./configure node, does it say it's including openssl support [21:42] mscdex: ? [21:42] creationix: javajunky: does connect work for you know, I think the npm package for updated [21:42] creationix: s/for/got/ [21:42] creationix: s/know/now/ [21:43] creationix: ACTION can't type on apple computers [21:43] mscdex: huhu [21:43] creationix: that's why I like code, it's the best spellchecker [21:43] mscdex: i think you have to press the "open apple key" [21:43] creationix: it will reject typos [21:43] mscdex: :-> [21:44] papandreou: mAritz: This should get you started: https://gist.github.com/b54dfd6f415d9a597f1f [21:44] papandreou: mAritz: Adapt the format to your own taste. [21:45] r1ngzer0 has joined the channel [21:45] mAritz: papandreou: thanks, i'll look into it :) [21:45] wakeup: n8 guys [21:45] rwaldron: does anyone have any bleeding-edge-blow-my-mind-awesome method of keeping your node build up to date [21:45] wakeup: thanks for all the big help [21:46] stagas: mscdex: everything openssl is installed, though openssl shows not ok when installing node [21:46] stagas: but I think it works anyway [21:46] mscdex: stagas: what does it say for the stuff under where it says it's not ok? [21:47] javajunky: stupid question, whats the most reliably way to check whether something is an array these days ? foo.constructor ? typeof ? [21:47] qschzt: Array.isArray(arr); [21:47] mscdex: javajunky: Array.isArray [21:47] mscdex: heh [21:47] javajunky: chortle [21:47] javajunky: please tell me thats new [21:47] qschzt: :) [21:47] mscdex: javajunky: it's in the node wiki for ES5 stuff [21:47] javajunky: thank-fook for that [21:48] creationix: speaking of [21:48] javajunky: October 2009, glad I'm not that behind the curve [21:48] creationix: someone needs to add the new Object stuff added in node v0.1.101 [21:48] stagas: mscdex: ssl_library_init, openssl/crypto.h, rt are yes, only openssl and execinfo are not found [21:48] mscdex: creationix: like? [21:48] _announcer: Twitter: "@nodejs #node #nodejs If you have a blog with examples, feel free to update them with the correct syntax, ya know, cuz that shit's changin'" -- rick waldron. http://twitter.com/rwaldron/status/19107834683 [21:48] creationix: http://code.google.com/p/v8/source/browse/trunk/ChangeLog [21:49] mscdex: stagas: ok, that should be fine then. what errors are you getting when compiling libxmljs? [21:49] rwaldron: whoa\ [21:49] creationix: search for es5 in the last few released [21:49] rwaldron: that was me [21:49] creationix: *releases [21:49] qschzt: arh, none of the exit handlers work now :/ [21:49] rwaldron: wow [21:49] rwaldron: i rule. [21:49] mscdex: creationix: node head is at 2.3.0, and so that's current in the ES5 node wiki [21:49] Mark9000 has joined the channel [21:49] creationix: mscdex: 2.3.2 [21:50] nicklovescode has joined the channel [21:50] stagas: mscdex: about a million 'undefined reference to `v8::some_function...' [21:50] mscdex: well, nothing was added since 2.3.0.... [21:50] creationix: mscdex: you're right though, someone updated it already, I just missed it [21:50] mscdex: creationix: i did ;-) [21:50] creationix: yay, thanks [21:51] mscdex: stagas: mind gisting it? [21:51] rwaldron: Any joy/advice about keeping node updated? [21:51] qschzt: ryah: ok, ^d with stdin works, ^c doesn't fire SIGINT event [21:51] rwaldron: or should i just keep on cloning and making? [21:51] phiggins has joined the channel [21:51] mscdex: rwaldron: that's probably the easiest way [21:52] mscdex: brb [21:52] DTrejo__ has joined the channel [21:52] DTrejo__: hello everyone [21:52] creationix: rwaldron: Ivy! [21:52] stagas: mscdex: just a portion, all are the same: http://gist.github.com/485198 [21:52] creationix: (I feel ashamed for plugging my stuff sometimes, but I did make it to fill a real need) [21:52] DTrejo__: quick question: is there an easy way to update from one version of node to the next? should I just download and build it again? [21:52] stagas: cygwin shell doesn't keep the whole history [21:53] stagas: something to do with node/v8.h [21:53] creationix: rwaldron: seriously though, if you want something quick and easy, I keep the binaries up to date http://github.com/creationix/ivy [21:54] rwaldron: slick [21:54] creationix: rwaldron: also there is npm/nave which are scripts that download and compile node for you at release versions [21:54] rwaldron: diggin' in [21:55] sh1mmer has joined the channel [21:55] DTrejo__: creationix: is that documented on the npm wiki page? or somewhere? [21:56] creationix: DTrejo__: is what documented? [21:56] stagas: I'm updating node to 101 just in case. I had 100 [21:56] DTrejo__: oh you meant nave via npm, as I think isaacs has mentioned before, ignore me [21:57] bradleymeck__: Script.runInNewContext's global cant use a getter T_T [21:57] franksalim has joined the channel [21:57] creationix: rwaldron: sorry, I meant nvm not npm [21:57] creationix: but Ivy is better I feel [21:57] creationix: that explains the confusion [21:58] phiggins has joined the channel [21:58] creationix: DTrejo__: no, you're right to be confused, I didn't mean npm [21:58] satori_ has joined the channel [21:58] DTrejo__: but npm can install nave which can then install latest node version no? [21:58] DTrejo__: (I) [21:58] creationix: maybe, haven't tried that route [21:58] DTrejo__: (I'm on windows so I think Ivy is not an option) [21:59] creationix: DTrejo__: correct, though I hope to support windows as soon as I can built my own binaries [22:00] maqr: hmm, you can't forEach on an object? [22:00] maqr: sometimes i'm surprised by what javascript doesn't do [22:00] creationix: maqr: not out of the box [22:00] _announcer: Twitter: "Believe I've found the culprit 4 the #node.js websocket demo crash last nite @austinjs. How many of u were using Google Chrome Dev build?" -- Joe McCann. http://twitter.com/joemccann/status/19108496156 [22:00] creationix: maqr: but it's easy to add http://github.com/creationix/proto/blob/master/lib/proto.js#L29 [22:00] DTrejo__: so far installing latest node via nave is going well, though I haven't actually tried running my code yet [22:00] DTrejo__: so ez :) [22:01] maqr: creationix: can i use some git magic to download that file and link it in, while keeping a local copy? (not that i couldn't copy/paste, just wondering) [22:01] tjholowaychuk: maqr: because its an object, not Hash or something like ruby [22:01] tjholowaychuk: maqr: then you will have String#forEach() too etc [22:01] tjholowaychuk: so its kinda ugly [22:02] creationix: maqr: you can include proto as a submodule [22:02] creationix: but it's not likely to change, so it's better to just copy paste it [22:02] creationix: tjholowaychuk: node> Object.keys("123") [22:02] creationix: TypeError: Object.keys called on non-object [22:03] creationix: strange, strings don't seem to be objects [22:03] maqr: creationix: will do [22:03] tjholowaychuk: creationix: no i know but im just saying Object methods in general [22:03] maqr: creationix: and to use it, it's require('proto') then? or with('proto')? [22:03] creationix: tjholowaychuk: node> Object.prototype.whatamI = "Object" [22:03] creationix: 'Object' [22:03] creationix: node> "123".whatamI [22:03] creationix: 'Object' [22:04] creationix: but it is, strange [22:04] tjholowaychuk: Object.prototype.foo = 'bar'; 'rawr'.foo [22:04] creationix: maqr: you just require it [22:04] maqr: tjholowaychuk: yeah, but if you have an object, you'd expect forEach to work over its keys... i can't think of a time when iw ouldn't want that behaviour [22:04] creationix: it changes globals, so the return value doesn't matter [22:05] creationix: maqr: well, sadly my function won't work on strings since they are objects, but not according to Object.keys [22:05] tjholowaychuk: maqr: I suppose [22:05] maqr: creationix: that's confusing... i thought nothing could change globals... should i be wrapping everything in a big function block? [22:05] maqr: i'm probably polluting without realizing it [22:05] creationix: maqr: modules work as if they are already wrapped in a function block [22:06] maqr: creationix: then why does your require('proto') work? [22:06] creationix: but changing globals like Object and Array persist [22:06] maqr: oh ok [22:06] DTrejo__: is there a way to make nave set my 'node' command to use whichever version I prefer? or something like that? [22:06] creationix: node now has a new mode where all modules have their own context [22:06] mAritz: okay, something is off here. the timezone of my machine is UTC+2. when i do "new Date('03/12/1988').getTime()" it gives me 57412440000 which is 03/11/1988 23:00:00. why the 1 hour offset? [22:06] creationix: DTrejo__: no clue, ask isaacs_home [22:06] derferman has joined the channel [22:07] mAritz: (the timestamp is 03/11/1988 23:00:00UTC) [22:07] creationix: mAritz: that's odd [22:08] mAritz: might be me being stupid somewhere [22:08] DTrejo__: isaacs_home: is there a way to make nave set my 'node' command to use whichever version I prefer? or something like that? (I'm probably being silly and there is some unixy way of doing this with my bashrc) [22:09] mAritz: at least http://www.wolframalpha.com/input/?i=574124400+seconds+from+1970-01-01UTC confirms my calculations.... what the hell? [22:09] markwubben has joined the channel [22:10] mAritz: papandreou: any idea? [22:12] papandreou: mAritz: That's kinda odd. I'm in UTC+2 too, and I can reproduce it. [22:12] mAritz: so it isn't me being stupid? [22:13] saikat has joined the channel [22:13] mAritz: i believe somewhere in there it's using CET instead of CEST [22:13] Dmitry has joined the channel [22:13] maqr: stagas: almost got it :) [22:13] papandreou: mAritz: Ah... It's a date in November, at that point I guess we're both UTC+1 :) [22:14] robotar__ has joined the channel [22:14] mAritz: it's actually march, but that's still UTC+1. might be the reason ^^ [22:15] papandreou: mAritz: Ah yes, I mean March, damn middle-endian formats :) [22:15] huyhong has joined the channel [22:15] mAritz: ISO > all :D [22:15] huyhong has left the channel [22:15] papandreou: mAritz: new Date('6/10/1988').toGMTString() works as expected [22:16] mAritz: papandreou: wow. now everything else seems pretty easy :D [22:16] papandreou: mAritz: What's left? :) [22:18] mAritz: one test is still failing. but shouldn't be a problem :) [22:19] papandreou: mAritz: It almost never is :) [22:19] mAritz: papandreou: yep :( [22:20] papandreou: mAritz: I mean -- it's almost never a problem :) [22:21] mAritz: papandreou: ups, misunderstood you. turns out it's still a problem if i enter ISO strings that have a timezone set. is there a reliable way to detect that? [22:21] papandreou: mAritz: Like how? [22:21] mAritz: papandreou: 1988-03-12T00:00:00Z [22:22] mAritz: i guess i'll have to parse the string and look for Z or +xx:xx :( [22:22] papandreou: mAritz: Are you using the parser I sent you or what is the scenario? [22:22] mAritz: no, just new Date(timestring) [22:23] papandreou: mAritz: My recommendation is not to use that. [22:23] mAritz: why not? works fine apparently [22:23] papandreou: mAritz: Basically you don't have any control over what happens. [22:24] mAritz: papandreou: what could possibly go wrong? :P [22:24] papandreou: mAritz: If you're going to parse the string anyway (to look for the time zone stuff), you might as well parse the entire string yourself and use new Date(Date.UTC(...)) like I suggested. [22:26] Mark9000: how do you server css files? [22:27] Mark9000: *serve [22:27] bradleymeck__: same as any other static file [22:28] Mark9000: so need to create a static file server [22:28] mAritz: papandreou: right now it accepts things like: "Sat, 12 Mar 1988 00:00:00", "03/12/1988", "03.12.1988", "1988-03-12T00:00:00Z" and some others. writing my own parser for all these is too much work and probably results in slower code than the native new Date(). [22:28] Mark9000: ? [22:28] rgl has joined the channel [22:29] Yuffster has joined the channel [22:29] satori_: Mark9000L Serving css files is the same as any other file. Just set the right content-type header and stream the data [22:30] Mark9000: ok, thanks :) [22:32] riottaba has joined the channel [22:32] _announcer: Twitter: "yay. was sys = require ("sys"); sys.puts (sys.inspect (sys)) / / give you ruby-style `obj.methods` # nodejs" [da] -- Dylan Clendenin. http://twitter.com/deepthawtz/status/19110377506 [22:32] grahamalot has joined the channel [22:33] maqr: creationix: it's function(value,key) for some reason, not function(key,value) on that forEach prototype, right? [22:33] pgriess has joined the channel [22:33] tjholowaychuk: maqr: val/key is the norm [22:33] maqr: tjholowaychuk: weird, i think python does it backwards then? [22:34] creationix: maqr: it's the same as Array.prototype.forEach [22:34] tjholowaychuk: maqr: well the norm for js [22:34] creationix: jQuery does it the other way [22:34] maqr: creationix: oh ok, good to know [22:34] maqr: i'm still kind of picking up the nuances of javascript as i go here :) [22:35] maqr: tjholowaychuk: btw, i'm trying to integrate google's closure templates and node; if i make this work, maybe we can put it into express [22:35] maqr: as another templating option [22:35] tjholowaychuk: maqr: cool sounds good [22:36] ryah: mjr_: have you seen DtraceToolKit/Net/tcpstat.d ? [22:36] tmedema has joined the channel [22:38] papandreou: mAritz: If you change your mind, I've updated the gist with support for Z, +nn:mm, and -nn:mm suffixes: https://gist.github.com/b54dfd6f415d9a597f1f [22:39] _announcer: Twitter: "node.js homebrew kiwi express mongoDb.... names, Names, NAMES!" -- David Taylor. http://twitter.com/zensatellite/status/19110760844 [22:40] papandreou: mAritz: It might be a little slower, but at least you know what it does. I've found new Date(str) too unpredictable for practical use. [22:41] mAritz: papandreou: thanks a lot, but the flexibility of Date is too good not to use it. if the user (by which i mean the developer who uses my functions) doesn't check the dates it's doomed anyways ;) [22:42] jakehow has joined the channel [22:44] aglemann has joined the channel [22:44] aglemann has left the channel [22:44] DTrejo__: I thought sys.puts was totally removed? [22:44] tlrobinson_ has joined the channel [22:44] DTrejo__: instead you can use it straight with just console.log without any requires? [22:45] papandreou: mAritz: But all the ambiguity that creeps in when you cannot specify the format to use... Like with new Date("02/03/2003"); ... It's not obvious that it is to be interpreted as M/D/Y? [22:45] DTrejo__: nvm I figured it out [22:45] papandreou: mAritz: Of course I don't what kind of library you're writing... And I think I've made my point by now :) [22:46] mAritz: papandreou: yep. and i appreciate your help :) [22:47] bmizerany has joined the channel [22:47] papandreou: mAritz: :) [22:47] mw_ has joined the channel [22:49] DTrejo__: woo my app works with nodev0.1.101 and nothing broke! [22:49] bradleymeck__: anyone having problems w/ http.createClient and long urls? [22:50] _announcer: Twitter: "I think these guys across the table at #OSCON are Node.js guys." -- Graham Weldon. http://twitter.com/predominant/status/19111443475 [22:50] maqr: stagas: i'm down to the last bug, but it looks like it's going to be fast enough with isaacs's sax parser [22:55] jherdman has joined the channel [22:55] Xavura has joined the channel [22:55] bradleymeck__: http://github.com/bmeck/witch, is back, but can someone else confirm setting location to large urls on http.createClient doesnt always give a response [22:59] mjr_: ryah: I have not yet explored the world of dtrace [23:00] maqr: stagas: still here? problem solved :) [23:00] stagas: maqr: yeah [23:00] stagas: maqr: was taking a look at node-expat [23:00] maqr: stagas: i did it with sax-js [23:01] stagas: maqr: how long does it take now? [23:01] satori_: Has anyone done HTML 5 video streaming over HTTP with node? [23:01] maqr: stagas: 100ms [23:02] stagas: maqr: wow [23:02] maqr: stagas: something must have been wrong in that node-xml library for srs [23:04] maqr: stagas: it'll all install with npm too, so you can remove all that other stuff [23:04] creationix: ryah: could I add Object.prototype.forEach and map to core? [23:04] creationix: won't break anything [23:06] stagas: maqr: still 0.1.2 on npm [23:06] maqr: stagas: yeah, i know, i'm adding dependencies in, i had to loko up how to do it [23:06] ryah: creationix: no [23:07] creationix: ryah: not even if I keep bugging you ;) [23:07] ryah: mjr_: you're missing out [23:07] maqr: isaacs_home: and i suddenly see the value in package management [23:08] kersny has joined the channel [23:09] Xavura has left the channel [23:09] rwaldron has joined the channel [23:10] mjr_: ryah: I've been meaning to, especially with my latest project in node [23:10] mjr_: Which is routing voice over HTTP, and trying to figure out why node isn't faster. [23:11] maqr: stagas: done [23:12] maqr: stagas: npm install xml2js, then just use it against your file, processes in 100ms here :) [23:13] quirkey has joined the channel [23:13] javajunky: creationix: tjholowaychuk finally began my re-write of connect-auth to be a little more idiomatic, new middleware construction is much simpler now: http://github.com/ciaranj/connect-auth/blob/master/examples/app.js#L190 [23:13] creationix: javajunky: awesome [23:13] tjholowaychuk: javajunky: nice man looks a lot simpler [23:14] javajunky: yeah, there was a minor penalty when creating the strategies, but nothing a 'normal' consumer would care about [23:15] javajunky: right offski, cu'all [23:15] creationix: javajunky: so it falls back to different auth modes? [23:16] mjr_: Is ryah giving a node talk tonight in SF? [23:17] creationix: mjr_: yep [23:17] creationix: mjr_: why was I planning on coming up early to visit your office? [23:17] mjr_: To talk about pcap I think. [23:17] creationix: something to do with node_pcap and Ivy [23:17] _announcer: Twitter: "booked for berlin in september, landing two weeks before @jsconfeu. would love to catch up with other #nodejs folk before the conference!" -- Jed Schmidt. http://twitter.com/jedschmidt/status/19113111986 [23:17] creationix: cool, you still up for that? [23:17] mjr_: It looks like I'll be able to make it to the talk tonight after all. [23:18] creationix: ohh, even better [23:18] mjr_: So we can either meet at my office or wherever this thing is. [23:18] creationix: still, I want to come a little early [23:18] creationix: it's walking distance from your office right? [23:18] mjr_: It's close, but I think a bit of a hefty walk. [23:18] jaja has joined the channel [23:18] creationix: well, I'll be on scooter either way [23:18] creationix: it's mobile [23:20] markwubben_ has joined the channel [23:20] mjr_: Anybody else in SF coming? [23:21] DTrejo__: mjr_: what? event in the bay area? [23:21] mjr_: http://www.facebook.com/event.php?eid=106330769408119 [23:21] ryah: mjr_: i am [23:21] DTrejo__: mjr_: did someone post that to the google group? [23:21] creationix: mjr_: nobody I recognize on the list of RSVPs [23:21] creationix: ryah: sweet, I was hoping you'd make it [23:21] mjr_: Oh good, so ryah is coming. [23:21] creationix: I'll bring the jacket [23:22] stagas: maqr: it's working now fine, finishes in ms, but I can't require unless I copy them to the project folder, maybe something with npm again? [23:22] ryah: creationix: oh thanks [23:22] maqr: stagas: hmm, you uninstalled all the old copies? [23:22] stagas: maqr: yes [23:22] maqr: stagas: it should be require('xml2js')? [23:22] stagas: maqr: it couldn't even find sax. yes require('xml2js') [23:22] stagas: I had to copy them all and edit them all to ./mod [23:23] maqr: stagas: that's weird, npm should automatically install sax as soon as you do 'npm install xml2js' [23:23] stagas: I know weird [23:24] DTrejo__: mjr_: yeah I never saw an announcement on the google group :| [23:24] devinus has left the channel [23:24] maqr: stagas: the package.json sure looks right to me [23:24] stagas: considering sax and npm are from the same author :P [23:24] mjr_: DTrejo__: only the elite facebookers know about ti. [23:25] creationix: alright, I'm out [23:25] emmanueloga has joined the channel [23:26] towski has joined the channel [23:26] yum46522 has joined the channel [23:26] mjr_: ryah: have you ever tested node's ability to stream lots of HTTP connections with small-ish chunks? [23:27] mjr_: Like, 30 bytes or so, per chunk. [23:27] ryah: proxy? [23:27] mjr_: sure, proxy, broadcast, whatever. [23:27] ryah: or generate? [23:27] mjr_: How many HTTP connections can you send these small chunks to per second, is what I'm trying to find out. [23:27] DTrejo__: mjr_: noone would mind if announced that to the listserv would they? [23:28] mjr_: And the number is smaller than I thought. oprofile says that all the time is in V8. [23:28] devtime has joined the channel [23:28] mjr_: But I don't have the right kernel to oprofile the kernel time. [23:28] maqr: stagas: i just pushed a new version with a readme that has something in it, but it shouldn't really help your dependency problem :/ [23:28] mjr_: DTrejo__: I dunno, since it starts in 90 minutes, I'll bet it doesn't matter much. [23:28] ryah: mjr_: yeah i expect you hit GC often [23:29] maqr: stagas: you might just have to ask isaacs on this one, i can't recreate it here :/ [23:29] stagas: maqr: I do get a warning from npm that symlinking the lib directory is deprecated, use the 'main' module instead [23:30] mjr_: oprofile picks up these symbols called "anon", which I assume are the anonymous functions for the event listeners. [23:30] DTrejo__: mjr_: I posted it anyway [23:30] mjr_: I guess I could/should run the V8 profiler. [23:30] stagas: maqr: sax doesn't require even if I install it separately [23:31] stagas: maqr: maybe something with cygwin :P [23:31] mjr_: I was trying to figure out how to use fewer anonymous functions to do an HTTP proxy, but it's awkward. [23:31] ryah: what are your numbers like right now? [23:32] mjr_: I can do about 800 connection pairs, one writing, the other reading. [23:32] mjr_: So 1600 total connections on the server. [23:32] mjr_: Each writer writes 30 bytes every 20ms. [23:35] lachlanhardy has joined the channel [23:35] dnolen_ has joined the channel [23:36] hassox has joined the channel [23:37] jaja has joined the channel [23:38] mjr_: DTrejo__: are you going to be there tonight? [23:39] DTrejo__: I'm still trying to decide [23:39] DTrejo__: I work 9-5 and usually reserve 7-9 as my side project coding time [23:39] DTrejo__: I don't know [23:40] DTrejo__: I'd have to leave straight from work probably and not eat dinner [23:40] mjr_: It's an intro talk, so you've probably already been introduced to node, given how much time you've spent with it. [23:40] mjr_: But I like meeting other noders. [23:41] DTrejo__: should be fun [23:41] mjr_: Even though I have similar demands and structure on my time. [23:41] aliem has joined the channel [23:41] DTrejo__: life is full of beautiful sacrifices [23:42] JimBastard has joined the channel [23:43] JimBastard: reporting in from the nyc flashcoders meetup, they are doing a node presentation today [23:43] DTrejo__: mjr_: I don't think I'll make it, especially since I went into the city yesterday, but make sure to let the listserv know about future events [23:43] JimBastard: im here to make sure they dont noob it up :-) [23:43] mjr_: JimBastard: also, they might need some baiting on certain things. [23:43] mjr_: Can you take care of that? [23:43] TommyM has joined the channel [23:43] DTrejo__: gnight everyone, have fun at the talk mjr_ [23:43] DTrejo__: gnight JimBastard [23:44] maqr: stagas: hmm, i haven't seen that warning yet, maybe i should update npm [23:44] maqr: stagas: it all does work though? i think you're my first library user :) [23:46] stagas: maqr: it almost works, but tags that are like: are converted to '@': { title: '123' } instead of tag: { title: '123' } [23:47] maqr: stagas: yeah, that's intentional [23:48] maqr: stagas: i could probably make it not do that, but you could have a case where you have foo... and then which would win? [23:50] maqr: stagas: i could make it optional i guess? or i could make the attributes be '@title' instead [23:50] maqr: stagas: i'm open to suggestions [23:50] JimBastard: was someone working on a AMF protocol for node? [23:50] maqr: AMF still exists? :o [23:52] satori_: You want Flash to talk directly to node with it's own aactionscript serialization? [23:52] stagas: maqr: oh I get it so i use ['@'].attr for the inner tag attributes [23:52] donspaulding has joined the channel [23:52] maqr: stagas: well, for any tag attribute, yeah [23:52] maqr: stagas: i figure that makes it easier to loop through than if i just started attributes with an '@', since then it'd be harder to loop through each attribute [23:53] devongovett has joined the channel [23:53] maqr: stagas: it also puts in a '#' where character data is ambiguous [23:53] maqr: stagas: say you have foo ... that can't be { title: "123", foo }, since that's not a valid object [23:53] maqr: stagas: so it'll become { title:"123", "#": "foo" } [23:54] JimBastard: HI HI TALL NATE [23:54] JimBastard: :-D [23:54] JimBastard: gogo flashcoders [23:54] JimBastard: ping ryah [23:54] micheil: maqr: it should be { tagname: "tag", attributes: {title: "123"}, children: [{tag: "textNode", content: "foo"}]} [23:55] JimBastard: nm ryah, that was a test for the meeting we are in lol [23:55] JimBastard: wanted to see the wargamez go [23:55] aliem_ has joined the channel [23:55] micheil: JimBastard: well, that could be fail. [23:56] maqr: micheil: yeah, that makes sense too, it's a little less pleasant to turn into json though :/ [23:56] micheil: maqr: follow the DOM standard [23:56] maqr: micheil: oh, i see what you did there [23:57] micheil: not exactly the page you want, but check: http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html#interface-EventTarget [23:57] micheil: I did the exact same as what document.getElementById("foo") would return [23:57] maqr: micheil: hmm, my goal was just to make the data easy to access, but maybe i should code that in too [23:57] micheil: seriously, textNodes are awesome. [23:57] maqr: micheil: actually, expat probably already does that? [23:57] micheil: no idea [23:58] micheil: but if you're parsing XML, parse it to a DOM Object [23:58] maqr: hrm, i guess you're right [23:58] rsms has joined the channel [23:58] micheil: this doc: http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/ [23:59] micheil: and then the ECMAScript variant [23:59] maqr: micheil: yeah, that makes a lot of sense; that probably already exists [23:59] stagas: maqr: micheil is correct, you could however have an optimized/compressed option that does it the way you do it now for those who don't care and just want as less chars as possible so they can send it right away [23:59] micheil: true, for instance, rather then doing textNode as elements, do innerHTML [23:59] micheil: or something