[00:00] ckknight: but I plan on keeping the data generally pretty small [00:00] isaacs: redis is extremely fast, and good for fast-changing stuff. [00:00] Hello71 has joined the channel [00:00] Hello71 has joined the channel [00:00] isaacs: send your questions about using node with redis and couchdb to mjr_ [00:00] isaacs: ckknight: he's got more experience with that than anybody, probably. [00:01] mjr_: not having a great day with couchdb today [00:01] johnnywengluu: is it recommended to use databases targeted at specific needs or just a general database that can handle all cases [00:01] isaacs: or, hell, i mean, just use mysql and put memcached in front of it. [00:01] johnnywengluu: if i have to learn a lot of differenet dbs it would take a lot of time [00:01] prettyrobots: johnnywengluu: Specific needs. [00:01] johnnywengluu: can't couchdb handle a lot of things? [00:01] isaacs: ckknight: it's great for a lot of things, and you probably know how to make it not suck if you've been using it forever as you say. [00:02] mjr_: I still like CouchDB, but if you want to get really large, you have to understand what the tradeoffs are. [00:02] mjr_: Redis thus far in my journey continues to delight. [00:02] johnnywengluu: mjr_: what are the tradeoffs with couchdb? [00:02] ckknight: isaacs: hmm? I haven't used any NoSQL thing before [00:03] mjr_: CouchDB's incremental map/reduce is very clever, and for some applications, it is completely brilliant. [00:03] isaacs: mjr_: couch rider!! https://skitch.com/isaacschlueter/ramc7/voxxer-redis-couch-node-google-search [00:03] dyer_ has joined the channel [00:03] tfe__ has joined the channel [00:04] tfe_ has joined the channel [00:04] mjr_: But if you frequently read the results of a reduce view, it can be really slow [00:04] isaacs: incremental mr is as wonderful as lambda calculus, which is as wonderful as lambda calculus. [00:04] prettyrobots: isaacs: What was that link? What am I looking at? [00:04] prettyrobots: I don't see anything. [00:04] Sean_Colombo has left the channel [00:04] isaacs: prettyrobots: https://img.skitch.com/20110330-q5itn5d1cifxchttbrwpyewppu.png [00:04] isaacs: screenshot of google [00:05] prettyrobots: isaacs: Thank you. [00:05] mjr_: I guess we need to quickly register voxxxer.com [00:05] mjr_: For the porn version [00:05] prettyrobots: I didn't see it in the context of the page. I think I'm getting tired. [00:05] isaacs: mjr_: YES. [00:06] isaacs: btw, does voxxer work on the verizon iphone? [00:06] losing has joined the channel [00:09] mjr__ has joined the channel [00:09] Sorens3n: err, has anyone used browserify/dnode? cannot for the life of me get it working [00:10] Sorens3n: events.js:23 [00:10] Sorens3n: throw arguments[1]; // Unhandled 'error' event [00:10] Sorens3n: ^ [00:10] Sorens3n: TypeError: Function.prototype.apply: Arguments list has wrong type [00:10] dominictarr has joined the channel [00:12] mcantelon has left the channel [00:16] mike_miller has joined the channel [00:19] WRAz has left the channel [00:20] WRAz has joined the channel [00:20] sveisvei has joined the channel [00:21] TheIronWolf_ has joined the channel [00:22] DTrejo has joined the channel [00:22] DTrejo: jesusabdullah: http://githubissues.heroku.com/#joyent/node/228 [00:23] ohtogo has joined the channel [00:23] DTrejo: I wonder about github issues: it seems like node has a lot of issues, but a TON are from a long time ago [00:23] DTrejo: and I would like to think they've been resolved? [00:24] ckknight_ has joined the channel [00:25] ckknight_ has joined the channel [00:26] jesusabdullah: DTrejo: What did you use for all that UI stuff? sencha? [00:26] DTrejo: oh, that's not mine [00:26] DTrejo: it's capuccino though [00:26] dominictarr has joined the channel [00:26] DTrejo: I don't like github's issue viewer, hard to scroll through it [00:27] bbttxu has joined the channel [00:27] jesusabdullah: Ah [00:27] TheIronWolf has joined the channel [00:28] dominictarr has joined the channel [00:28] zenwolf has joined the channel [00:28] zenwolf has left the channel [00:28] bart has joined the channel [00:28] jesusabdullah: objective-J? Why do people do these things? >_< [00:29] jesusabdullah: Sometimes, I just don't understand why people make up new languages just for some project [00:29] DTrejo: jesusabdullah: agree [00:29] tjholowaychuk: jesusabdullah: haha i dont know, i loved the look of it until i saw objective-j [00:30] mjr_: jesusabdullah: I don't generally understand either, but a neat aspect of objective-j is that it lets you use the OSX Interface Builder [00:30] DTrejo: jesusabdullah: it's a pretty UI, but why not JS :\ [00:30] DTrejo: although.... http://ukijs.org/examples/ [00:31] jesusabdullah: tjholowaychuk: Exactly. It looks pretty, but they had to make up some new language that people have to learn JUST to use the product [00:31] DTrejo: specifically: http://ukijs.org/examples/core-examples/wave/ [00:31] jesusabdullah: Yessch [00:31] jesusabdullah: The UI builder's kind of a cool idea---maybe that was their goal [00:32] jesusabdullah: but then again I don't really like stuff centric to a particular OS, either [00:32] jonaslund: errr [00:32] jesusabdullah: I mean, it happens! It HAS to [00:32] jonaslund: why would "objective-J" fit interface builder more than some thin JS wrapper ? [00:32] jesusabdullah: but it's not something that should necessarily be encouraged, I guess is my thinking [00:33] tjholowaychuk: they probably have nice abstractions thanks tothe new lang [00:33] tjholowaychuk: but [00:33] tjholowaychuk: is it really worth turning away potentially thousands of devs [00:33] jesusabdullah: Shoulda used coffeescript! ;) [00:33] tjholowaychuk: just like coffeescript :) [00:33] tjholowaychuk: haha [00:33] jesusabdullah: haha [00:33] Jamool has joined the channel [00:33] tjholowaychuk: cant stand when I get pull requests for something coffee specific [00:33] jesusabdullah: coffee is kinda cool, in that a lot of times you can mix and match [00:33] dgathright has joined the channel [00:34] jesusabdullah: Yeah, I get mixed feelings about that [00:34] DTrejo: I wanna try out ukijs.org sometime [00:34] tjholowaychuk: it's exactly why we DONT need two languages in the same community [00:34] DTrejo: ACTION agrees [00:34] jesusabdullah: I think it's cool when it's adding stuff that makes coffee automagically work, and you didn't have to do it [00:34] jesusabdullah: Like, automatically javascriptifying coffeescript for browserify [00:35] dominictarr has joined the channel [00:35] jesusabdullah: but it's a little lame when coffeescript's behavior "breaks" a library and you have to "fix" the library so that CS users can use it [00:35] jesusabdullah: well [00:35] jesusabdullah: "have to" [00:35] jesusabdullah: You could tell them to piss off, I guess [00:35] tjholowaychuk: i like when write dynamic languages in their original state lol [00:35] jesusabdullah: but, yeah [00:35] DTrejo: tjgillies: do you know why there are so many open and old issues on the node repo? [00:36] tjholowaychuk: css etc are different stories [00:36] DTrejo: *tjholowaychuk ^ oops, autocomplete typo [00:36] tjholowaychuk: but js is fine [00:36] tjholowaychuk: no clue [00:36] jimt has joined the channel [00:39] WRAz: is there a better mongodb client than mongoose? [00:40] bingomanatee: No - that being said Mongoose uses Native as its gateway to MongoDB so you can send lower level commands to MongoDB via Native quite well. [00:40] WRAz: cool, some things are driving me insane [00:40] bingomanatee: http://www.wonderlandlabs.com/wll_drupal/os/node/mongodb.html [00:41] bingomanatee: Also, though its far less tested than Mongo (and in contradiction to my "No" above) check out https://github.com/marcello3d/node-mongolian which is a much closer mirror to the actual scripting syntax of Mongo than native. [00:42] tjholowaychuk: they both use mongodb-native or w/e [00:42] bingomanatee: Let me know how you find Beefcake if you use it: [00:42] sprout has joined the channel [00:42] WRAz: so sexy [00:43] bingomanatee: so yes, I guess there is an alternative - that being said - forewarned - even marcello3D admits beefcake has not went through a very thorough vetting. [00:43] bingomanatee: Later all! maybe see some of you at Yahoo tonight. [00:43] templaedhel has joined the channel [00:44] templaedhel: When trying to use https I get an error 107 ssl error. Any bug hunting tips? [00:44] WRAz: I got mongoose doing what I want right now but mongolian looks pretty sexy [00:44] templaedhel: ACTION uses mongous  [00:44] bgilbert has joined the channel [00:45] tjholowaychuk: WRAz: the main issue is you usually want some kind of abstraction layer to enforce validations etc [00:45] tjholowaychuk: which is where mongoose comes in of course [00:45] tjholowaychuk: but i understand the need for "rawness" [00:45] WRAz: ofc, the virtual/setter/getters are awesome [00:45] timmywil has joined the channel [00:46] WRAz: and plugins/etc [00:46] WRAz: sometimes I would like to just get shit done, like I'm hashing out a day project and really not going to use any/most of that [00:46] tjholowaychuk: haha yeah [00:46] WRAz: even for day projects tho, Unit Tests ;) [00:47] templaedhel: Anyone here have a server with https working? [00:47] dgathright has joined the channel [00:48] mjr_: templaedhel: I'm using https with some success [00:48] dominictarr has joined the channel [00:48] mjr_: There's unfortunately a memory leak in there somewhere. [00:48] mjr_: But other than that, it is working pretty well. [00:48] templaedhel: mjr_: Do you reverse proxy with nginx or anything? [00:48] Horofox has joined the channel [00:49] mjr_: straight node [00:49] templaedhel: Hm. I still get an ssl error connecting straight to my node port [00:50] templaedhel: mjr_: http://pastebin.com/8ZjTdZAt Does your code look much different then this? [00:50] mjr_: you can point your client at one of my servers and see if it can validate: https://test1-nr1.voxer.com/ping [00:51] mjr_: templaedhel: you should use the new API [00:51] templaedhel: There is another new one? [00:51] DTrejo: templaedhel: 8 months ago is a long time! be a bit wary of clutch [00:52] templaedhel: I will try without clutch, but I like it [00:52] mjr_: http://nodejs.org/docs/v0.4.4/api/https.html [00:52] templaedhel: mjr_: Is that not what I am using? [00:52] mjr_: nope [00:52] johnnywengluu: how do you generate online guides/tutorials documentation based on markdown? [00:52] mjr_: you are doing crypto.createCredentials [00:52] DTrejo: templaedhel: https://github.com/joyent/node/wiki/modules look through there and see which one is recent and one that you like [00:53] DTrejo: lotsa people use express [00:53] templaedhel: mjr_: Oh, legacy from the last method I tried! Thanks for the catch [00:53] kmiyashiro: who here prefers bbcode to markdown in forums? [00:53] wbailey has joined the channel [00:54] templaedhel: works, thanks for the catch [00:55] tjholowaychuk: kmiyashiro: markdown ftw [00:55] kmiyashiro: that's what I thought [00:56] DTrejo: ^ ditto [00:57] kmiyashiro: Thinking about creating a markdown syntax for gist embedding [00:57] kmiyashiro: unless... just checking for the gist domain name and pattern would be easier... but I assume that would be more expensive [00:58] DTrejo: kmiyashiro: you mean it automatically pulls in gisted links? [00:58] kmiyashiro: yeah [00:58] kmiyashiro: the user would put in the gist URL [00:58] cbare has joined the channel [00:58] kmiyashiro: and the processor would have to wrap it in script tags [00:58] kmiyashiro: in the output [00:59] willwhite has joined the channel [00:59] kmiyashiro: I mean, use i for the src [00:59] dominictarr has joined the channel [00:59] beawesomeinstead has joined the channel [00:59] beawesomeinstead has joined the channel [00:59] cbare: Hi Noders! [00:59] dominictarr has joined the channel [00:59] samcday: Hail! [01:00] DTrejo: ohai cbare [01:00] cbare: mind if I ask a clueless noob question? [01:00] cbare: just installing and got this from 'make test' [01:00] cbare: assert.js:81 throw new assert.AssertionError({ ^ AssertionError: -1 == 0 at EventEmitter. (/Users/cbare/Documents/projects/nodejs/node-v0.4.4/test/simple/test-tls-ext-key-usage.js:171:10) at EventEmitter.emit (events.js:81:20) at EventEmitter.exit (node.js:199:15) at Object._onTimeout (/Users/cbare/Documents/projects/nodejs/node-v0.4.4/test/simple/test-tls-ext-key-usage.js:98:11) at Timer.call [01:01] eventi has joined the channel [01:01] hadashikick has joined the channel [01:01] cbare: and another similar error from: test/simple/test-tls-securepair-client.js:166:10) [01:01] DTrejo: cbare: what system are you using? [01:01] dominictarr has joined the channel [01:01] cbare: OS X [01:01] kmiyashiro: just use macports [01:02] DTrejo: macports is at 0.2.6 [01:02] DTrejo: :| [01:02] kmiyashiro: not for me, I'm on 0.4.3 [01:02] softdrink has joined the channel [01:02] DTrejo: oh, i need to port selfupdate [01:02] cbare: macports appears to be at nodejs 0.4.3 [01:02] DTrejo: nvm [01:04] edude03 has joined the channel [01:06] jimt has joined the channel [01:06] vckt has joined the channel [01:08] mscdex: node.js rules! [01:08] dominictarr has joined the channel [01:08] konobi: 1) you do not talk about nodejs [01:09] rchavik has joined the channel [01:09] hij1nx has joined the channel [01:09] jesusabdullah: Nonono [01:09] jherdman has joined the channel [01:09] jesusabdullah: 1) You do NOT talk about ringojs. [01:10] jesusabdullah: ;) [01:11] zentoooo has joined the channel [01:11] DTrejo: 3) you do talk about claypooljs ! http://www.claypooljs.com/ [01:12] zorzar has joined the channel [01:13] jherdman has joined the channel [01:15] k1ttty has joined the channel [01:16] [[zz]] has joined the channel [01:16] chester has joined the channel [01:18] samcday: DTrejo, haha is that project for serious :P [01:19] dguttman_ has joined the channel [01:21] DTrejo: samcday: why? it's old, so yeah.. [01:21] samcday: I dunno, it just kinda looked like a joke at first. [01:21] pyrony has joined the channel [01:22] unlink has joined the channel [01:22] unlink has joined the channel [01:23] dgathright has joined the channel [01:23] cbare: another dumb question to try your patience: I installed by macports, looked good. Is it possible to run that same test suite on the version that came from macports? [01:24] DTrejo: hmm [01:24] DTrejo: try and figure out where it put the files? [01:24] DTrejo: then you can `make test` [01:24] bentruyman has joined the channel [01:24] bitmonk has joined the channel [01:25] Yuffster has joined the channel [01:29] GriffenJBS: wtf?! I have a local server, and script and I'm still getting origin not allowed by Access-Control-Allow-Origin [01:29] WRAz: is mongodb the DB of choice for node.js ? [01:30] GriffenJBS: WRAz: which tool depends on which job [01:30] WRAz: looking for a fast document store [01:30] WRAz: or object database [01:31] konobi: mongodb is a choice? I thought it was the webscale equivalent of /dev/null? [01:31] GriffenJBS: which is more important speed, recovery, etc? [01:31] BillyBreen has joined the channel [01:31] WRAz: ease of use ;) [01:31] sugardave has joined the channel [01:32] jdub has joined the channel [01:32] wbailey_ has joined the channel [01:33] scrogson: Hey guys...I'm new to Node...I've got node, npm and express installed...I just used express to generate a new application...when I run `node app.js` I get an error saying that 'express' cannot be found. What am I missing? [01:33] matschaffer has joined the channel [01:33] WRAz: are you requiring express? [01:33] matyr has joined the channel [01:33] scrogson: yes [01:33] tytsim has joined the channel [01:33] scrogson: var express = require('express'); [01:34] scrogson: that's the first line of code [01:34] DTrejo: npm install express ? [01:34] DTrejo: (yes that's a sily thing to do, but..) [01:34] DTrejo: maybe it will work [01:34] DTrejo: (especially considering that you already installed the command line tool) [01:35] samcday: Anyone know of a good module to do some filesystem stuff quicker? [01:35] scrogson: when I run `npm ls installed` I get: express@2.1.0 active installed [01:35] scrogson: I'll run it again [01:35] samcday: Like copying a directory recursively for example [01:35] samcday: I found "wrench-js" but it's kinda sucky - copies files as utf8, which ruins binary files I'm trying to copy :P [01:36] DTrejo: samcday: npm has something, I think [01:36] konobi: samcday: shell out to command line? [01:36] scrogson: should I have to run sudo to use npm? [01:36] DTrejo: samcday: you looked through these already I'm guessing https://github.com/joyent/node/wiki/modules#other [01:37] samcday: konobi, didn't really wnana have to resort to that, bad for portability for starters. DTrejo yeah I looked there [01:37] scrogson: I couldn't get it to install without sudo and now I have to use sudo to install all packages [01:37] losing has joined the channel [01:37] DTrejo: scrogson: I recommend https://gist.github.com/579814#file_take_ownership.sh [01:38] EyePulp has joined the channel [01:39] johans_ has joined the channel [01:39] scrogson: DTrejo: could this be why node can't seem to find express? [01:40] DTrejo: scrogson: I'm really not sure, but I'm inclined to say that it should not matter [01:40] scrogson: yeah, I didn't think it would matter [01:40] DTrejo: hmm [01:41] DTrejo: try installing another package and seeing if it works? [01:41] DTrejo: npm install underscore [01:41] scrogson: DTrejo: so the error that I'm getting is coming from node.js:134 throw e; // process.nextTick error, or 'error' event on first tick [01:41] DTrejo: yeah, that's a really common one, means something bad happened previously, but the stack trace is gone, so not very helpful in figuring out what happened [01:42] cbare: Thanks Dtrejo and kmiyashiro... and whoever built the mac port for node.js. I'm up and noding. No tests, but wtf, it looks like it's working. Thanks! [01:43] DTrejo: try npm install underscore && node -e "var _ = require('underscore'); console.log(_.compact([false, '', "I'm alone!"]))" [01:43] dominictarr has joined the channel [01:43] DTrejo: glad I could help cbare [01:44] scrogson: DTrejo: http://pastie.org/1733510 [01:44] perezd: anyone working with expresso? [01:44] scrogson: same error with mongoose [01:46] DTrejo: scrogson: I have no idea :| could it be a node install problem? [01:47] scrogson: not sure..I just upgraded to 0.4.4 using Homebrew [01:47] chrisdickinson: scrogson: try "node -e console.log(require.paths)" to see where it's looking? [01:48] actonapp has joined the channel [01:48] vckt has joined the channel [01:48] chrisdickinson: (maybe put the console log call in quotes, whoops) [01:48] johans_: scrogson: looks like install path - try $ express --help which will display express options [01:48] johans_: if installed correctly [01:49] scrogson: johans_: I can access express with no problem (from the cli) [01:50] dominictarr has joined the channel [01:50] sugardav1 has joined the channel [01:51] scrogson: ah...so it looks like node is looking for modules in ~/.node_modules, ~/.node_libraries & /usr/local/Cellar/node/0.4.4/lib/node [01:52] actonapp has left the channel [01:52] Vertice: when profiling node, wtf is "_LI_ils_create" [01:54] scrogson: anyone now how to change the require paths for node? [01:54] actonapp has joined the channel [01:54] jtsnow has joined the channel [01:55] johans_: scrogson: http://nodejs.org/docs/v0.4.3/api/globals.html#require [01:56] wookiehangover has joined the channel [01:56] actonapp has left the channel [01:57] actonapp has joined the channel [02:02] yinkei has joined the channel [02:05] muk_mb has joined the channel [02:06] AAA_awright: scrogson: Also ./node_modules [02:07] AAA_awright: Yeah it's in the documentation >:( [02:08] kmiyashiro has joined the channel [02:09] jimt has joined the channel [02:10] dgathright has joined the channel [02:15] WRAz: baaah [02:15] WRAz: freaking hate mongoose [02:15] dguttman has joined the channel [02:17] evanmeagher has joined the channel [02:17] templaedhel: mongous is good [02:18] Draggor has joined the channel [02:18] yhahn has joined the channel [02:20] isaacs has joined the channel [02:21] isaacs: scrogson: depends [02:21] isaacs: scrogson: (re: sudo npm) [02:21] isaacs: scrogson: if you've got npm set up to install someplace which requires root write perms, then yes [02:22] meso has joined the channel [02:22] tmzt_: DTrejo: have you worked with soap clients in node? [02:22] DTrejo: tmm1: I haven't, sorry [02:22] DTrejo: arg [02:22] DTrejo: * tmzt_ [02:23] tmzt_: oh, there was something I remember reading from you on a forum from last year [02:23] tmzt_: guess it was something else [02:23] DTrejo: hmm [02:24] prettyrobots: Which do you prefer: MySQL or PostgreSQL? [02:24] prettyrobots: (As a Node.js developer.) [02:25] DTrejo: (no idea, but go for the one with better module support after reading through the modules list, that'd be my approach) [02:26] bbttxu has joined the channel [02:26] konobi: postgres [02:26] davidascher has joined the channel [02:26] mjr_: I think the driver breakdown is this: Felix's mysql driver is neat because it is pure JS, but not as fast as a native driver. There is an actively maintained native driver for pgsql from brianc. [02:26] mjr_: I think brianc, right? [02:26] mjr_: Somebody who is in here a lot. [02:26] konobi: ryah has one... not sure if it's ative though [02:27] prettyrobots: konobi: You use PostgreSQL with Node.js? [02:27] zzak: https://github.com/brianc/node-postgres [02:27] mjr_: that's the one [02:27] terite: Has anyone here successfully used Socket.IO with cluster, both by learnboost? [02:27] prettyrobots: Also, is there a lot of middleware support for one over the other? [02:27] konobi: prettyrobots: yup [02:28] tmzt_: there's an orm for mysql, don't know about postgres [02:28] konobi: orm-- [02:28] v8bot: konobi has taken a beer from orm. orm now has -1 beers. [02:28] konobi: woot! [02:28] prettyrobots: konobi: Is that a dirty acronym around here? [02:29] Me1000 has joined the channel [02:29] siculars has joined the channel [02:29] pauls has joined the channel [02:29] konobi: is for me at least [02:30] DTrejo: beer-- [02:30] v8bot: DTrejo has taken a beer from beer. beer now has -1 beers. [02:30] DTrejo: beer++ [02:30] v8bot: beer is getting too many beers. Don't let beer get drunk! [02:30] templaedhel: Anyone here use any validation modules? [02:30] prettyrobots: konobi: I think someone needs to point out to the framework mavens that SQL is a DSL, that usually gets them hot and bothered, DSL. [02:31] DTrejo: templaedhel: saw a good one, but haven't used it [02:31] konobi: prettyrobots: treat a database as a database and not as a stupid retarded object storage mechanism... may as well just store JSON in files with IDs [02:31] hij1nx has joined the channel [02:31] konobi: prettyrobots: however... dbix-class is much close to being nice [02:31] templaedhel: DTrejo: Link? [02:32] konobi: actually treats the db as a db... while providing sugar [02:32] templaedhel: this is the only one I know https://github.com/chriso/node-validator [02:32] DTrejo: yeah I think that was the one I was thinking of [02:32] prettyrobots: konobi: So, yeah, this is why I don't really know which is more popular. I'm not aware of how they are being used except directly via the drivers. [02:33] konobi: prettyrobots: skip the ORMs for now [02:33] templaedhel: The try catch error handling is obtuse for something were a simple true false would be nice imo [02:33] prettyrobots: konobi: I wouldn't use it myself, but I'm wondering what's more generally supported. [02:34] prettyrobots: MySQL or PostgreSQL. [02:34] konobi: postgres [02:34] prettyrobots: Or the the community has a strong preference. [02:34] konobi: mainly because it actually has a native async interface [02:34] konobi:  [02:35] zylo has joined the channel [02:36] Hello71 has joined the channel [02:36] Hello71 has joined the channel [02:37] reid has joined the channel [02:37] aconran has joined the channel [02:38] terite: terite++ [02:38] v8bot: terite: Don't cheat! You can't give a beer to yourself. [02:39] terite: :( [02:39] DTrejo: v8bot++ [02:39] v8bot: DTrejo has given a beer to v8bot. v8bot now has 20 beers. [02:39] terite: v8bot-- [02:39] v8bot: v8bot is getting too many beers. Don't let v8bot get drunk! [02:40] DTrejo: v8bot-- [02:40] v8bot: v8bot is getting too many beers. Don't let v8bot get drunk! [02:40] DTrejo: it has a timer it seems [02:40] sourcode has joined the channel [02:42] draginx1 has joined the channel [02:42] draginx1: Is there a POP3 thing for nodejs? [02:43] jesusabdullah: If not, I know there's an imap thing [02:43] jesusabdullah: https://github.com/mscdex/node-imap [02:44] mostlygeek has joined the channel [02:45] perlmonkey2 has joined the channel [02:45] hammerdr has joined the channel [02:45] hammerdr: Anyone know how I would attach socket.io to an express app? [02:47] DTrejo: hammerdr: yep, just pretend the express app is a regular http server [02:48] DTrejo: socketio.listen (app) or somethign like that [02:48] terite: hammerdr: There's an example at http://socket.io/ [02:48] draginx1: jesusabdullah: i can only send with imap though a? [02:48] draginx1: ya* [02:49] hammerdr: ah. Yeah. I thought it did but my coffeescripts weren't compiling [02:49] hammerdr: Thanks guys [02:51] willf4 has joined the channel [02:51] ChrisRulesNodes has joined the channel [02:51] jesusabdullah: draginx1: Yeah, afaik that particular thing is for imap only. There might be a pop3 dealio, but I just happened to remember the imap one. [02:52] jesusabdullah: draginx1: Will that work for you, or do you need pop3 in particular? [02:52] draginx1: i just need to be able to read emails [02:52] draginx1: on gmail ;) [02:53] dominictarr has joined the channel [02:55] willf4: i'm struggling with callbacks! i'm trying to assign a locals variable in a res.render to a function, e.g. locals: {results: searchResults() } and i have a function searchResults(callback) {Doc.find( {find criteria}, function (err,results) { callback(results) }); } - can anyone suyggest what i'm doing wrong or point me to some mongoose snippets - i've searched high and low. [02:56] DTrejo: willf4: show a gist.github.com of your code? [02:56] mbrochh has joined the channel [02:56] dominictarr has joined the channel [02:57] willf4: https://gist.github.com/893777 [02:58] Aaron_ has joined the channel [02:58] vckt has joined the channel [02:59] techwraith: willf4: I'd just return docs; instead of calling a callback there. [02:59] techwraith: That should do what you want [03:00] jimt has joined the channel [03:00] mscdex: draginx1: node-imap will work fine for reading emails [03:01] mscdex: :) [03:01] mscdex: draginx1: if you need any help or run into any problems, let me know [03:02] techwraith: willf4: or, if you want to do it the way I've always seen it done, just wrap the res.render() in the searchResults function [03:02] willf4: techwraith: thats what i did originally but feed is showing as undefined [03:03] draginx1: thanks! :D [03:03] willf4: i wanted to abstract the db call away into a function so i could expand it [03:04] techwraith: willf4: are you sure that you're getting stuff back from the DB for that query? [03:05] techwraith: But yeah, a callback is not what you want there. [03:06] willf4: yeah, if i do a console.log(docs) before return(docs) it shows the data, but anywhere else a console.log(searchResults()); is undefined. [03:06] willf4: so the assignation doesn't seem to work or... haha, i've been working at this for a ridiculous amount of time :) [03:06] jimt_ has joined the channel [03:06] bentruyman has joined the channel [03:07] willf4: should be so simple, i'm obviously doing something stupid but what?! [03:07] techwraith: try var searchResults = function(){}; instead of just searchResults(){} [03:07] techwraith: and definitely replace the callback with return; [03:08] willf4: i replaced the callback [03:08] willf4: try var SearchResults within the local scope? [03:08] willf4: locals [03:08] DTrejo: willf4: https://gist.github.com/893787 [03:08] DTrejo: try that [03:08] DTrejo: you want the async thing on the outside, and then when it's done, put docs in there [03:09] techwraith: DTrejo, yeah that's the best way to do it [03:09] zentoooo has joined the channel [03:09] techwraith: I thought he had a reason not to do it that way :) [03:09] tbranyen: asynchronous behavior is trippy [03:09] tbranyen: man [03:09] DTrejo: :) [03:09] DTrejo: I should answer some stackoverflow questions [03:09] jesusabdullah: Has anyone here used google charts? I swore I saw someone mention google charts and now I'm going nuts [03:09] tbranyen: jesusabdullah: yea [03:10] jesusabdullah: It's RESTful, right? [03:10] DTrejo: jesusabdullah: what are you looking to make with them? [03:10] jesusabdullah: Oh, nothing [03:10] DTrejo: I have some links to a buncha nice charting libs, if you want em [03:10] jesusabdullah: but I lurve charts [03:10] jesusabdullah: Oh yeaH? I'd love that actually [03:10] tbranyen: jesusabdullah: restful in the sense that there is an api that works over http [03:10] tbranyen: doesn't use all the verbs n shit tho [03:11] jesusabdullah: I meant in the sense where you're all like chart.com?x=y&z=w and shit [03:11] tbranyen: yeah an http accessible api [03:11] jacobolus has joined the channel [03:11] DTrejo: jesusabdullah: https://github.com/alexyoung/ico [03:11] DTrejo: jesusabdullah: http://g.raphaeljs.com/ [03:11] tbranyen: graphael sucks [03:11] tbranyen: stay far away [03:11] tbranyen: it could have been great [03:12] tbranyen: but its far too incomplete [03:12] jesusabdullah: Yeah, unfortunately graphael is not so good. It's a good idea but the guy hasn't worked on it at ALL and there's no docs [03:12] DTrejo: I have another [03:12] jesusabdullah: Yeah, basically [03:12] DTrejo: 1 sec [03:12] jesusabdullah: DTrejo: Have you heard of graphael? [03:12] DTrejo: http://dejavis.org/ [03:12] techwraith: willf4: let me know if that worked :) [03:12] jesusabdullah: er [03:12] jesusabdullah: not graphael [03:12] jesusabdullah: HERP [03:12] jesusabdullah: graphico [03:12] jesusabdullah: It's ico but more stuff [03:12] DTrejo: I saw it in my google search for ico [03:13] jesusabdullah: hmm [03:13] jesusabdullah: There's a plotting lib for R that I want to try [03:13] DTrejo: jesusabdullah: this one? http://kilianvalkhof.com/2010/design/grafico-javascript-charting-library/ [03:13] jesusabdullah: Oh, this looks sweet! [03:13] jesusabdullah: Yeah, that one DTrejo [03:13] jesusabdullah: I like this dejavis thingy [03:13] DTrejo: :) [03:13] DTrejo: that guy makes some awesome stuff [03:13] jesusabdullah: there's also this cool exploratory graphing thing someone did in node [03:14] jesusabdullah: graph.tk I think [03:14] DTrejo: but it all goes into his startup, and he doesn't hang around in here [03:14] jesusabdullah: and CanvasXpress is okay, except its api sucks [03:14] jesusabdullah: Way too bulky [03:14] tbranyen: oh wait never heard of this [03:14] tbranyen: grafico looks pretty cool [03:14] willf4: DTrejo, techwraith - that did work. Thank you both :) I think I had it in my head I wanted to do it in that particular way because thats how I would do it in Perl or whatever! But looking at it I can see how this will work well! Thanks again :) [03:14] tbranyen: too bad its prototype [03:14] jesusabdullah: It's because the guys using canvasXpress are using it for uber-metadata'd biology stuff [03:14] tbranyen: and raphael [03:14] jesusabdullah: tbranyen: Not a raphael fan? [03:14] jesusabdullah: Prefer canvas? [03:14] tbranyen: not a prototype fan [03:14] jesusabdullah: I like raphasel itself [03:15] jesusabdullah: Ah [03:15] wilmoore has joined the channel [03:15] noahcampbell has joined the channel [03:15] tbranyen: raphael is alright [03:15] jesusabdullah: Yeah, I looked at proto, wasn't really diggin' it [03:15] jesusabdullah: What I REALLY want is this: [03:15] jesusabdullah: plot(x,y, options) [03:15] jesusabdullah: Actually, what would be AWESOME is a chaining interface [03:15] DTrejo: oo build it ;) [03:15] jesusabdullah: plot(x,y).xlabel('time').ylabel('number of cooldudes') [03:16] techwraith: willf4: Gotta change the way you think ;) [03:16] jesusabdullah: DTrejo: I just might! [03:16] tbranyen: yeah i implement chaining in all my apis [03:16] willf4: techwraith: thats not as easy as it sounds! [03:16] tbranyen: its inherent to the way i modularize my code [03:16] jesusabdullah: Also, matplotlib for python: Best there is for python, but annoying [03:16] jesusabdullah: ggplot [03:16] techwraith: willf4: Nope , it isn't :P [03:16] jesusabdullah: That's what it's called [03:16] jesusabdullah: ggplot for R [03:16] jesusabdullah: I want to give THAT a shot [03:16] jesusabdullah: Need to learn me some R though [03:16] ChrisRulesNodes: Hi there I need some help using http.request [03:17] ChrisRulesNodes: Expecially when there is a HTTP error ex: 400, 500 401 etc [03:17] jesusabdullah: I actually have a LOT of shit I want to build for node when I have time [03:17] jesusabdullah: mostly data crunching and plotting stuff [03:18] jesusabdullah: GSL bindings, a subset of underscore with data juggling as its primary goal, and a nice plotting tool [03:18] ChrisRulesNodes: If you are busy, can you redirect me at least to some good example? [03:18] ChrisRulesNodes: s [03:19] mike_miller: on the same lines of plotting, what library would you guys recommend for plotting a gausian curve with a vertical line at the median? [03:19] jesusabdullah: ChrisRulesNodes: I'd help you, but tbh I don't usually use the http guy directly [03:19] mike_miller: I'd use canvas on the client, but I want to support rasterizing to .png/,jpg for clients that don't have canvas support. [03:19] ChrisRulesNodes: How can you get content from the web (i.e. graph API on Facebook) without it ? [03:19] jesusabdullah: mike_miller: I saw something that might do it for you, hold on [03:19] tfe_ has joined the channel [03:21] dominictarr has joined the channel [03:21] jimt has joined the channel [03:21] AAA_awright: jesusabdullah: Take some library like flot and use a server-side Canvas render? [03:21] evanmeagher: would anyone from the seattle area be interested in having a node hacknight at some point? [03:22] jesusabdullah: AAA_awright: flot sucks too. You can't do y-axis labels proper. [03:22] jesusabdullah: mike_miller: http://www.jstat.org/ [03:22] jesusabdullah: mike_miller: Nevermind what I just said about flot. ;) [03:22] AAA_awright: jesusabdullah: You use a callback function [03:22] mike_miller: :) [03:22] jesusabdullah: AAA_awright: What do you mean? [03:23] AAA_awright: It's like two lines of code to use a log scale [03:23] mike_miller: "The jStat API documentation is still being compiled." :( [03:23] jesusabdullah: Oh, anyone I was talking plottage to: http://jesusabdullah.github.com/2011/02/26/plolt.html and http://jesusabdullah.github.com/2010/09/08/chernoff-ffffuuuuuu.html [03:23] hammerdr has joined the channel [03:24] jesusabdullah: mike_miller: Yeah, it's relatively new. But, the code is clean. Basically, it's some functions for getting (x,y) action for some typical distributions plus some plotting sugar [03:24] mike_miller: jesusabdullah: Given that there's no API documentation, do you know if there's an easy way to annotate plots, and do things like add vertical lines? [03:25] mike_miller: I basically want to show the user a plot of the pdf, and a vertical line at the median, labeled "median". [03:25] AAA_awright: you define ticks: function(axis){ return [labels] } [03:25] zzak: JESUS [03:25] ChrisRulesNodes: Mmmhhh. I have been looking online... it looks like for https you need to do require('https') instead than require('http') [03:25] jesusabdullah: mike_miller: If I were you, I would use its std. normal curve function to get (x,y) data, and then plot x=[0,0], y=[-10,10] or something of this sort [03:25] mike_miller: jesusabdullah: plot how, exactly? [03:26] mike_miller: i.e. using what library? [03:26] jesusabdullah: AAA_awright: My issue is that you can't put a LABEL on the y axis because flot is based on css action, and it's a Hard Problem to make a label 90 degrees without resorting to the canvas [03:26] jesusabdullah: mike_miller: flot [03:26] mike_miller: jesusabdullah: contradicting yourself yet again! :) [03:26] AAA_awright: jesusabdullah: What do you mean 90 degrees? [03:26] jesusabdullah: AAA_awright: Sideways [03:27] AAA_awright: Why would you want vertically printed text on the y-axis? [03:27] AAA_awright: In any event it's a UI no-no [03:27] jesusabdullah: Because you ALWAYS want vertically printed text on your y axis! [03:27] jesusabdullah: You have to label it! [03:27] jesusabdullah: What? This is about science, not interfaces! [03:27] DTrejo: I'm answering http://stackoverflow.com/questions/5357654/node-js-socket-server-and-connection-on-same-server-slow-down --> is it common practice to use streams to communicate accross processes? Much better to use sockets no? [03:28] AAA_awright: jesusabdullah: You mean labeling the y-axis? [03:28] jesusabdullah: Yes, I maen labeling the y-axis. That's what I said! [03:28] WRAz: gaaah, I think I'm done with mongoose *sigh* [03:29] AAA_awright: Ugh whatever... CSS does do that btw, and that's the whole point of rendering it server-side anyways, for when it doesn't [03:29] jesusabdullah: Anyway, mike_miller, check out http://code.google.com/p/flot/ and see if you can get it, in concert with code from jstat, to do what you want. [03:29] jesusabdullah: Who said anything about rendering server-side? [03:29] AAA_awright: I did [03:29] yhahn has joined the channel [03:29] jesusabdullah: I thought we were talking about why I thought flot sucks [03:29] AAA_awright: jesusabdullah: Take some library like flot and use a server-side Canvas render? [03:30] briznad has joined the channel [03:30] jesusabdullah: hmm [03:30] beawesomeinstead has joined the channel [03:30] beawesomeinstead has joined the channel [03:31] GriffenJBS has joined the channel [03:32] jesusabdullah: fwiw I would probably use canvas rendering if I were to do it myself [03:32] jesusabdullah: actually, no, svg [03:32] jesusabdullah: because, while people usually want raster, vector graphics are technically superior and you can always rasterize a vector graphic but not so much the other way around [03:32] malkomalko has joined the channel [03:33] guybrush: you can always transform [03:33] jesusabdullah: Or, maybe a tikz interface [03:33] guybrush: after getting the output [03:33] jesusabdullah: Yeah, exactly [03:33] jesusabdullah: For a second I thought we were talking about coordinate transforms [03:33] jesusabdullah: which I think are an important component of all this [03:34] dominictarr has joined the channel [03:34] jesusabdullah: It'd be nice to be able to specify coordinates using pixelspace, plotspace or both [03:34] jesusabdullah: y'know, use which is appropriate [03:35] skm has joined the channel [03:36] skm has joined the channel [03:37] Spion_ has joined the channel [03:37] nonnikcam has joined the channel [03:38] AAA_awright: jesusabdullah: I'm interested in more of the data-manipulation end, can I take two time series and divide them? [03:38] AAA_awright: etc [03:38] jesusabdullah: What do you mean? [03:38] jesusabdullah: Like, _.map(function(a,b) { return a/b; }, ta, tb) ? [03:39] AAA_awright: jesusabdullah: Like... Manipulating and operating on data [03:39] jakehow has joined the channel [03:39] jesusabdullah: Yeah, I need that too [03:39] WRAz: whats the best/most popular redis node.js client/ORM? [03:39] jesusabdullah: I find underscore is really helpful for some of that stuff [03:39] jesusabdullah: gotta use your maps! [03:39] jesusabdullah: Also, reduce has its place. SubStack helped me refactor some code the other day to use reduce, and it came out real nice [03:40] jesusabdullah: I think I have it gisted somewhere [03:40] losing has joined the channel [03:40] bentruyman has joined the channel [03:40] AAA_awright: jesusabdullah: Except something with respect to the domain, and interpolates where necessary. Maybe I have one time series of weekly data and one with daily data [03:40] jesusabdullah: Hmm [03:40] jesusabdullah: Yeah, I see what you mean [03:40] jesusabdullah: Usually you have to find a fit for them by-hand and get new points that are on the same grid [03:40] AAA_awright: That's really just the beginning... Something that can also look at the units each time-series uses and figures out the resulting units [03:41] jesusabdullah: Sure [03:41] jesusabdullah: Python's scientific community actually has tools for SOME of that [03:41] jesusabdullah: Like, not as sophisticated as we're talking here, but [03:42] AAA_awright: Plus python really isn't an option [03:42] jesusabdullah: http://pytseries.sourceforge.net/ You may find this useful, though I admit I haven't done much [03:42] AAA_awright: Actually I try and run as python-free as possible. [03:42] jesusabdullah: Oh? client-side only, or just don't like python, or a ruby shop, or what? [03:42] jesusabdullah: Hmm [03:42] draginx1: Why pthon free AAA_awright? [03:43] jesusabdullah: I have to admit, I'm not liking python so much these days, but I do find the scientific stuff useful still [03:43] AAA_awright: It's a preditory language. [03:43] jesusabdullah: Oh, there's also a pretty decent units lib I used once or twice [03:43] DTrejo: predatory, why do you say that? [03:43] AAA_awright: And it violates the #1 rule of programming languages, white space is meaningless [03:43] AAA_awright: And just too many hacks for my liking [03:44] jesusabdullah: ah, The Whitespace Thing: It's a love/hate kinda deal [03:44] AAA_awright: It can't decide where it wants to be an OO language or regular functions [03:44] draginx1: Ruby? :D [03:44] jesusabdullah: I kinda like TWT, but it only really works because of how python limits itself [03:44] AAA_awright: Ruby isn't bad but right away Javascript is better [03:44] jesusabdullah: That is, one-line lambdas [03:45] draginx1: AAA_awright: Why is JS better iyo? :D [03:45] jesusabdullah: python is alright if you want a procedural, class-oriented language [03:45] jesusabdullah: imo [03:45] draginx1: And yeah ive been finding myself ditching ruby more and more for js :S [03:45] jamescarr: learn scala :-P [03:45] AAA_awright: Prototypes, closures that make more sense [03:45] jesusabdullah: If you want something outside that, it's not so hot [03:45] jesusabdullah: I agree, AAA_awright [03:46] draginx1: AAA_awright: isnt prototyping just like …. extending/adding more functions in a class in ruby? o-o [03:46] AAA_awright: Though there's less "wtf" moments with Ruby [03:46] steph021 has joined the channel [03:46] beawesomeinstead has joined the channel [03:47] jesusabdullah: http://www.flickr.com/photos/jesusabdullah/5045956694/ is how I feel about python [03:48] jesusabdullah: It has potential, but the guys In Charge mistake "easy" with "how it's always been" [03:49] jesusabdullah: What I *really* want is dnode-python [03:49] draginx1: can nodejs be used to make applications for macosx/*nix? [03:49] jesusabdullah: so I can write some functions in python and just call them from another process written in node [03:49] jesusabdullah: draginx1: Yeah, for command line stuff anyway. That's honestly how I usually use it XD [03:49] Me1000 has joined the channel [03:50] AAA_awright: jesusabdullah: I forget if I've asked, how much do you know about RDf [03:50] jesusabdullah: draginx1: If you're looking to do command line action, check out optimist for options parsing. Can't get much easier imo. [03:50] jesusabdullah: RDF... the acronym rings a bell [03:50] AAA_awright: It makes statements about resources [03:50] jesusabdullah: hmm [03:51] jesusabdullah: I don't know much about semantic web stuff [03:51] jesusabdullah: Honestly not sure what to make of it [03:51] jesusabdullah: the semantic web in general, I mean [03:51] AAA_awright: So I could have a resource that is a time series, for instance... And I could create a new resource which is the time-series division of two other time series resources [03:51] draginx1: jesusabdullah: meant liek GTK, etc. :P [03:51] AAA_awright: And graph that new resource maybe, which has all the correct units attached to it [03:52] boaz has joined the channel [03:52] jesusabdullah: Hmm [03:52] McMAGIC-- has joined the channel [03:52] jesusabdullah: I'll read about rdf mebbs [03:52] AAA_awright: jesusabdullah: http://magnode.org/ is my project, it builds HTML webpage representations of data (specifically, dereferenced RDF resources) [03:52] AAA_awright: Or at least, it will. [03:52] AAA_awright: jesusabdullah: One of the goals is to generate graphs and such [03:52] mikegerwitz: draginx1: https://github.com/Tim-Smart/node-gtk I can't say how far along it is, though. Never used it. [03:52] jesusabdullah: Oh yeah, I remember that guy! [03:53] jesusabdullah: Cool [03:53] jesusabdullah: Now I remember where I last heard about rdf ;) [03:53] AAA_awright: Okay good ^_^ [03:53] mikegerwitz: draginx1: From the todo, looks like there's lots to do ;) [03:53] jesusabdullah: The time AFTER the AGU conference [03:53] draginx1: lol aye [03:53] jesusabdullah: There are quite a few semantic web guys in the world of geophysics [03:53] AAA_awright: jesusabdullah: Yeah if you like data take a look at using RDF to describe it [03:53] jesusabdullah: Lots of truckloads of data to try to organize [03:53] draginx1: holy crap AAA_awright i didnt know u were in the btc community too [03:54] jesusabdullah: AAA_awright: Have you heard of openDAP? It's used in the geophysics community to serve up netCDFs and such, iirc [03:54] jesusabdullah: btc? [03:54] AAA_awright: draginx1: That I am [03:54] AAA_awright: draginx1: I've talked to you over there I thought [03:54] draginx1: jesusabdullah: bitcoins [03:54] DTrejo: is it acceptable to direct stackoverflow questions to be asked in an IRC channel? [03:54] draginx1: About btc?? Mostly just echelon :S [03:54] jesusabdullah: Ah [03:54] robotarmy has joined the channel [03:54] AAA_awright: draginx1: Or at least I've seen you I'm not as active as I am here [03:54] jesusabdullah: There's a guy on reddit that wants to do a cross-country trip entirely funded by bitcoins [03:54] jesusabdullah: I think he's nuts [03:55] jesusabdullah: but good luck to him! XD [03:55] draginx1: lol yer [03:55] AAA_awright: draginx1: But building a better Bitcoin block explorere is another goal of that project [03:55] AAA_awright: Or use case, rather [03:55] draginx1: magnode looks complicated @_@ [03:55] AAA_awright: jesusabdullah: OpenDAP no [03:55] jesusabdullah: Hmm [03:55] AAA_awright: draginx1: An ongoing problem... But the basic concept is it generates HTML representations of data [03:55] jesusabdullah: It looked like it would be cool if it served up metadata in json or xml instead of its own bullshit representation [03:56] AAA_awright: *any* data [03:56] jesusabdullah: but whatevs [03:56] AAA_awright: jesusabdullah: The idea is it can do Content-type negotiation so you can ask for raw RDF instead of HTML like web browsers do by defauly [03:56] AAA_awright: So even to say "HTML representations" is misleading because it does more than that [03:57] jesusabdullah: Oh, since we were talking about units and shit: http://www.simcop2387.info/docs/language/farnsworth/ is kinda cool. I use it for quick google-ish calcs usually, but I think it has potential as a DSL for certain types of calculations [03:57] jesusabdullah: hmm [03:57] AAA_awright: But to simply say "It generates various representations of data" just sounds WAY too generic [03:58] SubStack: Sorens3n: you probably have old versions of dnode and browserify. Upgrade them both to the latest. [03:59] jesusabdullah: Hmm [03:59] jesusabdullah: I think RDF looks handy, but I wish the standard representation was less xml-esque [03:59] ryanfitz has joined the channel [03:59] jesusabdullah: I have a hard time reading xml for some reason [03:59] draginx1: nice [03:59] draginx1: whoops wrong chat [03:59] unlink has joined the channel [03:59] unlink has joined the channel [04:00] jesusabdullah: Heh [04:01] AAA_awright: jesusabdullah: RDF has nothing to do with XML [04:01] AAA_awright: There is an XML format for encoding RDF data but no one has used that since the standard was published [04:02] sugardave has joined the channel [04:03] jimt has joined the channel [04:04] F1LT3R has joined the channel [04:06] zakabird has joined the channel [04:07] admc has joined the channel [04:10] reid has joined the channel [04:10] beawesomeinstead has joined the channel [04:10] AAA_awright: draginx1: Does this help at all? http://magnode.org/ [04:11] jimt has joined the channel [04:11] draginx1: What did u change? O-o [04:11] AAA_awright: Wait maybe it's cached from Nginx >_> [04:11] AAA_awright: draginx1: Yeah see the "Representations of data" header [04:11] AAA_awright: That doesn't help does i [04:11] draginx1: yeah [04:11] AAA_awright: That doesn't help does it [04:12] draginx1: that should be like.. [04:12] draginx1: at the top [04:12] draginx1: or the very first point other than cms 3.0 [04:12] matyr_ has joined the channel [04:12] AAA_awright: I need a cachier header if it's going to be up there [04:12] draginx1: ur other points don't sell me anything — i mean i know what they mean but the common folk don't (unless that's not ur target? I always thought CMS was for the commons heh) [04:13] AAA_awright: This is true, I should just assume people know a CMS should do authentication :p [04:13] draginx1: u can pull an apple, "Your date, now in HTML" etc. [04:13] AAA_awright: Hahah [04:13] draginx1: data* [04:13] draginx1: make sure u ;) [04:14] AAA_awright: I think I liked "date" better [04:14] DTrejo: is my answer accurate? http://stackoverflow.com/questions/5481675/node-js-and-mutexes/5481788#5481788 [04:14] draginx1: looks like a neat concept though :) [04:15] draginx1: DTrejo: "Nope, events are not interrupted. For example, if you put a while(true){} into your code, it would stop everything else from happening, because that it is being run." [04:15] AAA_awright: DTrejo: Events are handled the moment there's no other code to run [04:15] draginx1: Are u saying it does interrupt or doesnt? :P [04:15] DTrejo: I'm saying it doesn't [04:15] AAA_awright: DTrejo: i.e. When the particular iteration it's doing ends [04:15] draginx1: so why r u saying "it would stop everything frm happening"? :P [04:15] DTrejo: wait [04:16] DTrejo: let's say I have a function that runs some code [04:16] DTrejo: I call that function [04:16] draginx1: nodejs is *not* block-level right? [04:16] DTrejo: it runs all the way through, and when it finishes, then another request can be processed [04:16] AAA_awright: Yes [04:16] DTrejo: yeah, that it innacurate [04:16] DTrejo: hmm, let me revise my answer [04:17] draginx1: So then it would call that function and call other functions O-o correct me if im wrong asyncronous is not my forte still :| I come from 6 years of PHP :'( [04:17] AAA_awright: DTrejo: As a side-effect of being single-threaded, long computations will block all other events [04:17] AAA_awright: Until the computation is done [04:17] DTrejo: AAA_awright: mind if I quote you a lot? ;) [04:17] AAA_awright: Which is why it should be broken up with process.nextTick() [04:17] draginx1: AAA_awright: even fi u event it? [04:17] dominictarr has joined the channel [04:17] draginx1: ok :p [04:18] AAA_awright: DTrejo: Not at all, but your own words would probably be clearer anyways [04:19] malkomalko has joined the channel [04:19] gozala has joined the channel [04:19] matyr has joined the channel [04:19] DTrejo: thanks AAA_awright [04:20] hij1nx has joined the channel [04:22] DTrejo: AAA_awright: will a long running computation made using process.nextTick be run all at once in a row? [04:23] mike5w3c has joined the channel [04:23] skm has joined the channel [04:23] AAA_awright: DTrejo: At the very least it will clear out the function stack so it doesn't overflow, I think it also lets other events be handled though I'm not sure, now that I think about it the name NEXTtick implies no [04:23] skm has joined the channel [04:23] mellowsoon has joined the channel [04:24] skm has joined the channel [04:24] evanmeagher has joined the channel [04:24] DTrejo: AAA_awright: ok, adding that in there [04:24] skm has joined the channel [04:24] AAA_awright: idk if there's an easy way I can test that [04:25] ParadoxQuine has joined the channel [04:25] mellowsoon: DTrejo: Thanks for the answer on SO regarding mutexes. Accepted and up-voted [04:25] DTrejo: AAA_awright: a wihle loop that triggers process.nextTick() on a function that increments a global variable [04:25] Astro has joined the channel [04:25] m3nt0r^aw has joined the channel [04:25] jimt has joined the channel [04:26] themiddleman has joined the channel [04:27] whatcodecraves has joined the channel [04:27] DTrejo: testing [04:27] mbrochh]2 has joined the channel [04:27] davidascher has joined the channel [04:28] DTrejo: I want a jsfiddle for node [04:28] DTrejo: jsapp.us is a bit sandboxed [04:28] DTrejo: no process.nexttick I don't think [04:28] techwraith: What's wrong with just writing a quick js file and running it? [04:29] robotarmy has joined the channel [04:29] robotarmy has joined the channel [04:29] skm has joined the channel [04:30] DTrejo: I just did [04:30] skm has joined the channel [04:31] WRAz: weird [04:31] WRAz: do {} not have forEach? [04:31] dominictarr has joined the channel [04:32] eyesUnclouded has joined the channel [04:32] DTrejo: for i in {} [04:32] DTrejo: _.each [04:32] GriffenJBS: WRAz: Object.keys(obj).forEach [04:32] DTrejo: I like for i in b/c it is short and dangerous ;) [04:32] WRAz: it performs pretty terribly tho DT [04:33] tilgovi has joined the channel [04:33] WRAz: so I just need the values out of the object [04:33] WRAz: would .values work? [04:33] mellowsoon has joined the channel [04:33] tim_smart: http://www.phantomjs.org/ <- Web crawling anyone? [04:33] jesusabdullah: God I hate flash SO much [04:34] jesusabdullah: The html5/js revolution can't come soon enough [04:34] DTrejo: what is juggernaught? why would someone use it rather than socket.io? [04:34] jesusabdullah: It ate *all* my cpu [04:34] DTrejo: (https://github.com/maccman/juggernaut) [04:36] tbranyen: DTrejo: socket.io is strictly for communication [04:36] tbranyen: pretty sweet looking project there [04:36] tbranyen: tho* [04:37] jesusabdullah: Wait, so what can juggernaut do that socket.io can't? [04:37] jesusabdullah: I'm legitimately confused [04:37] DTrejo: tbranyen: so is juggernaught, no? [04:37] DTrejo: *naught [04:37] mscdex: heh [04:37] mscdex: don't forget grappler! [04:37] mscdex: lol [04:38] jesusabdullah: Yeah, I guess that's my thought too DTrejo? [04:38] jesusabdullah: I'm actually happy to see multiple solutions to the same (or almost the same) problem(s) [04:38] SubStack: WRAz: you can do Hash(obj).values with http://github.com/substack/node-hashish [04:38] jesusabdullah: I mean, if that's what juggernaut is [04:38] tbranyen: you can build what juggernaught does in socket.io [04:38] dgathright has joined the channel [04:38] WRAz: @SubStack: stop making useful stuff. [04:38] jesusabdullah: lol [04:38] DTrejo: jesusabdullah: wait so what???? juggernaught is backed by redis and talks to other languages or something? [04:39] Sorens3n: hey, if your going to use juggernaut [04:39] jesusabdullah: I don't know, DTrejo! I'm on the same boat as you dudesky [04:39] Sorens3n: wait, nevermind, depends what your using with it [04:39] DTrejo: oh, oops [04:39] DTrejo: Sorens3n: enlighten us? [04:39] Sorens3n: i've re-wrote the juggernaut library for backbone [04:39] Sorens3n: to work with node [04:39] jesusabdullah: It looks like it's got some ruby server-side action [04:39] Sorens3n: instead of ruby [04:39] jesusabdullah: yeah [04:40] tytsim has left the channel [04:40] tbranyen: Sorens3n: is backbone in node O_O [04:40] Sorens3n: the backbone still happens on the client side, but i've overriden the backbone.sync method to use juggernaut and redis [04:40] kmiyashiro has joined the channel [04:40] tbranyen: ah right on [04:40] techwraith: I've been working on getting backbone models to sync over socket.io actually, it's not that hard. [04:40] Sorens3n: https://github.com/sorensen/backbone-redis [04:40] DTrejo: ~mind scrambled~ [04:40] DTrejo: ok [04:41] Sorens3n: but, at the very least it has condensed juggernaut methods, using underscore instead of superclass or JUTILS [04:41] tbranyen: Sorens3n: what does that give you that couldn't write yourself [04:42] mhooker has joined the channel [04:42] Sorens3n: i just used it as a base [04:42] techwraith: tbranyen: pubsub for backbone models :) [04:42] Sorens3n: and then made it a backbone plugin [04:42] harth has joined the channel [04:42] tbranyen: techwraith: didn't realize underscore had pubsub [04:43] ralphholzmann: underscore has it all. [04:43] Sorens3n: tbranyen: the juggernaut library i had used superclass and jutils, i replaced those with underscore [04:43] techwraith: no, underscore doesn't, but I was talking about multi-user pubsub [04:43] tbranyen: oh [04:43] Sorens3n: i then used that to replace backbone.sync() [04:43] tbranyen: yeah i hadn't heard of pubsub in it [04:44] techwraith: redis backed model pubsub for multiple users is pretty sweet though [04:44] tbranyen: underscore looks awesome for client side normalization and helpers, but in node you get all the ecmascript hotness [04:44] Sorens3n: model id's are stored in redis-sets based on collection [04:44] tbranyen: latest ecmascript* [04:45] DTrejo: would be cool if someone answered this: http://stackoverflow.com/questions/3725928/node-js-ajax-file-uploader, it's a good question [04:46] ralphholzmann: tbranyen: yeah, but theres still some methods i use in underscore that are helpful [04:46] ralphholzmann: like array flatten, reduce etc [04:46] Sorens3n: https://github.com/felixge/node-formidable/blob/master/example/upload.js [04:46] jesusabdullah: AAA_awright: You know of any good reads on RDF? Wikipedia's a bit dry. [04:47] AAA_awright: jesusabdullah: As always go straight to the specs, the RDF Primer http://www.w3.org/TR/rdf-primer/ [04:47] beawesomeinstead has joined the channel [04:47] tbranyen: ralphholzmann: i must be writing weird stuff, i never find myself needing those kinds of methods [04:48] jesusabdullah: Oh wow, this looks surprisingly reasonable [04:48] ralphholzmann: tbranyen: perhaps, althrough its more likely that I'm writing weird stuff [04:48] ralphholzmann: I'm a heavy recursion user [04:48] ralphholzmann: which makes array flatten my friend [04:49] tbranyen: I don't see how that gets you nested array structures [04:49] tbranyen: If I wanted a flat array i'd maintain one to begin with [04:49] tbranyen: i don't know how i'd end up with something that needed to be flattened [04:50] yozgrahame has joined the channel [04:52] seanbeausoleil has joined the channel [04:54] ryanfitz has joined the channel [04:56] beawesomeinstead has joined the channel [04:56] DTrejo: tbranyen: laziness :) [04:56] boaz has joined the channel [04:56] DTrejo: on my part that is [04:58] mbrochh has joined the channel [04:58] AAA_awright: jesusabdullah: You just have to get used to some of the paradigms like open world assumption, which means using linked lists if you want a particular set of items, but it's pretty flexible [04:59] indutny has joined the channel [04:59] felixge has joined the channel [04:59] felixge has joined the channel [05:01] ryankirkman has joined the channel [05:02] ryankirkman: Does anyone here have experience with the async library? [05:03] DTrejo: ryankirkman: I have a bit [05:03] DTrejo: ryankirkman: what's going on? [05:03] paul__ has joined the channel [05:03] dgathright has joined the channel [05:04] seanbeausoleil has left the channel [05:04] ryankirkman: DTrejo: I'm using async for control flow. In this case, I'm trying to short circuit a waterfall at an arbitrary point in any of the functions, rather than having to callback all the way through them. [05:05] ryankirkman: DTrejo: One way I can think of doing this is just not running callback( ... ), but does this have any negative side-effects? [05:06] DTrejo: hmm [05:06] Charuru has joined the channel [05:06] jimt has joined the channel [05:06] liquidproof has joined the channel [05:08] marcosvm has joined the channel [05:09] jesusabdullah: ryankirkman: Why did you choose async, ooc? [05:09] yozgrahame has joined the channel [05:09] ryankirkman: jesusabdullah: Follows the node.js callback style [05:10] ryankirkman: jesusabdullah: Was recommended to me here to avoid nesting nightmare, and lastly has heaps of watchers on github :D [05:10] jesusabdullah: Link? [05:10] ryankirkman: https://github.com/caolan/async [05:11] jesusabdullah: I just ask cause I haven't heard much about it [05:11] beawesomeinstead has joined the channel [05:11] jesusabdullah: except that the author of seq didn't like it very much [05:11] mellowsoon: 3,1question: Is nodeunit the "offical" unit testing framework? [05:11] jesusabdullah: -heh- [05:11] jesusabdullah: mellowsoon: a) Holy crap colors. Are you using pidgin perchance? b) Not really, it's just one of about 3 popular-ish ones. [05:11] mellowsoon: Sorry, just turned it off [05:11] jesusabdullah: mellowsoon: Also worth checking out are vows and expresso [05:12] ryankirkman: jesusabdullah: Would you have a link to the seq author's objections? [05:12] jesusabdullah: Oh, it's fine mellowsoon, I'm not too pissy about it ;) [05:12] mellowsoon: I was like.. Woh.. that just stuck out hhaha [05:12] jesusabdullah: ryankirkman: No link, I'm just a friend of his is all. [05:12] WRAz: heya, decent template middleware for connect? [05:12] ryankirkman: jesusabdullah: Ahh, would you be able to summarise his objections? [05:13] mikl has joined the channel [05:13] jesusabdullah: Yeah, I think so? I think it's just that it doesn't have a unified interface. It feels "scattered" to him [05:13] jesusabdullah: imo, whatever floats your boat. Seq is powerful, but takes a while to wrap your head around. [05:13] langworthy has joined the channel [05:13] jesusabdullah: I think there are a few other flow control libs out now, too [05:13] jesusabdullah: step used to be the cool one like 6 months ago [05:14] jesusabdullah: iirc it's very simple, though [05:14] dgathright has joined the channel [05:14] ryankirkman: jesusabdullah: Haha, RE: step - http://thechangelog.com/post/516202796/step-control-flow-the-node-js-way [05:15] dominictarr has joined the channel [05:15] ryankirkman: Quote: "After making the highly popular “Do” library for making node.JS easier to wrangle, Tim Caswell (aka creationix), gave in and learned to do async code the proper node way." [05:15] jesusabdullah: ryankirkman: I was mostly just wondering about the pros to async, since SubStack is pretty opinionated when it comes to software. [05:15] jesusabdullah: ryankirkman: lol, yeah XP [05:15] jesusabdullah: Oftentimes, you don't need flow control libs [05:16] ryankirkman: jesusabdullah: As far as I can tell they look roughly equivalent [05:16] jesusabdullah: step and async, you mean? They may very well be. [05:16] ryankirkman: jesusabdullah: Hmm, I have found it simplifies my code significantly, at the expense of a few more lines [05:16] ryankirkman: jesusabdullah: async and substack [05:16] jesusabdullah: Ah [05:16] ryankirkman: seq* [05:16] jesusabdullah: They do the same thing, just different styles. SubStizzy really likes method chaining type stuff [05:17] andrewfff has joined the channel [05:17] jesusabdullah: Usually, if I start entering callback hell, I start factoring out code [05:17] jesusabdullah: That's what I found to be effective in many cases [05:17] jesusabdullah: BUT there are definitely times when it's nice to do flow control [05:17] mikl_ has joined the channel [05:17] jesusabdullah: The "ugly" stuff is hidden in the module, so to speak [05:17] ryankirkman: jesusabdullah: E.g. func1 -> func2 -> func3 -> ... etc? [05:18] jesusabdullah: Yeah, or maybe I can take a few functions and make that a lumped deal [05:18] jesusabdullah: like, function1(cb) = fa -> fb -> fc -> cb [05:19] JimBastard has joined the channel [05:19] ryankirkman: I guess that makes sense [05:19] johnnywengluu: isaacs: can't npm automatically create a package.json file with all options for me to fill in? [05:19] ryankirkman: Probably makes things much easier to test that way too [05:19] jesusabdullah: https://gist.github.com/882647 is the only time I needed/wanted flow control [05:19] SubStack: johnnywengluu: npm init [05:20] jesusabdullah: SubStack: I'm not putting words in your mouth, am I? [05:20] jesusabdullah: We were talking about that async lab [05:20] jesusabdullah: er [05:20] jesusabdullah: not lab [05:20] jesusabdullah: module [05:20] jesusabdullah: gahh, too much TAing this semester [05:20] SubStack: sounds like something I would say [05:21] johnnywengluu: SubStack: thanks [05:21] DTrejo has joined the channel [05:21] ryankirkman: SubStack: Would you recommend node-seq over async or just a tool-for-the-job type thing? [05:21] JimBastard: if i write one more unit test im gonna lose it [05:21] JimBastard: :-D [05:21] JimBastard: its all cloudhead's fault [05:22] SubStack: ryankirkman: well I wrote seq so I am hrdly impartial [05:22] gerad has joined the channel [05:22] ryankirkman: SubStack: Well aware, but I'm sure you'd have a keen understanding of the issues that may drive someone to a control-flow module [05:23] no-gooder has joined the channel [05:23] jesusabdullah: JimBastard: Don't test anything >:D [05:23] JimBastard: jesusabdullah: indexzero won't allow it [05:23] jesusabdullah: JimBastard: How's life by the way, you busy beaver you? [05:23] sub_pop has joined the channel [05:24] JimBastard: working on nodejitsu nonstop [05:24] JimBastard: hiring paid interns [05:24] JimBastard: ads should go up this week [05:24] SubStack: ryankirkman: one thing that I find frustrating about async is that in order to mix and match async and parallel options you need to nest calls since everything is mounted at the `async` object handle [05:24] jesusabdullah: Holy cow [05:24] johnnywengluu: i so love npm [05:24] jesusabdullah: Crazy-nuts, JimBastard [05:25] ryankirkman: SubStack: Funny you should say that. I'm running into that right now [05:25] SubStack: but nesting is what async flow control libs are supposed to help cut down on! [05:25] JimBastard: jesusabdullah: you got a summer job yet? [05:25] jesusabdullah: Are you guys still focusing on hosting and consulting? [05:25] SubStack: JimBastard: he's mine! [05:25] jesusabdullah: JimBastard: Probably. ;) [05:25] JimBastard: yeah, and the marketplace [05:25] johnnywengluu: JimBastard: when will it be final? [05:25] jesusabdullah: Marketplace? I'm not familiar with that [05:25] SubStack: :p [05:25] JimBastard: johnnywengluu: "soon" :-D [05:25] jesusabdullah: Oh, I see [05:26] jesusabdullah: Interesting idea, this marketplace! [05:26] JimBastard: its coming along [05:26] jesusabdullah: Actually, that's a cool idea [05:26] jesusabdullah: potentially, anyway [05:26] JimBastard: jesusabdullah: gotta get the oss developers some of that internet money [05:26] DTrejo: I am going to flood this channel with all my stackoverflow links to ask questions ;) [05:26] jesusabdullah: Any literature with the marketplace? [05:26] ryankirkman: SubStack: My strategy up to now has been to abstract nested stuff out into its own function, because by that stage it's probably too complex. But as jesusabdullah said, if you can do that well enough, you may not even need an flow control library [05:26] jesusabdullah: DTrejo: :D [05:26] JimBastard: jesusabdullah: coming soon [05:26] jesusabdullah: Awesome [05:27] jesusabdullah: I'll upboat when I see it ;) [05:28] SubStack: ryankirkman: some operations like managing pending operation counters and error parameter propagation really do seem best left to modules [05:28] SubStack: since otherwise you write the same code over and over again [05:28] ryankirkman: SubStack: So you're saying that control-flow modules are good for once-offs? [05:29] fenngle has joined the channel [05:30] SubStack: I'm more saying that as soon as you start seeing patterns in your code those bits are best left to modules [05:30] SubStack: like flow control [05:31] jesusabdullah: Note that SubStack writes a shit-ton of modules [05:31] Viriix has joined the channel [05:32] ryankirkman: Just checked GitHub. So many lol [05:32] jesusabdullah: Yeah [05:32] mattikus has joined the channel [05:32] jesusabdullah: THOUGH, I'll point out that he's not even top five according to his own blog article! OHOHOHO [05:33] jesusabdullah: I'm so mean [05:34] dominictarr has joined the channel [05:35] ryankirkman: SubStack: Besides allowing you to chain sequential and parallel stuff, does node-seq do anything else significantly differently to async? [05:35] stagas has joined the channel [05:35] SubStack: jesusabdullah: well actually if you run the program today I'm at #2 now with 31 modules [05:36] SubStack: ryankirkman: the module catches error parameters so you don't have to care about them as much [05:36] neutralthoughts has joined the channel [05:37] jesusabdullah: SubStack: Oh yeah? Crazy [05:38] JimBastard: SubStack: damn you substack [05:38] techwraith: tj is in the lead, right? [05:38] JimBastard: i might have to rage out of a few weeks and drop 20 more projects [05:38] jesusabdullah: haha :P [05:38] JimBastard: if i learned me a little more C i could do it :-D [05:39] JimBastard: mostly waf and shit [05:39] SubStack: tj has 40! [05:39] mscdex: most modules is the winner! [05:39] techwraith: How many people are on the list? [05:39] techwraith: That's an interesting statistic :) [05:39] mscdex: not enough! write some more modules! [05:39] mjr_: more of anything is certainly better, right? [05:39] Draggor: v8 can be a little crazy I've come to find, but highly rewarding to write it [05:40] mape: SubStack: you should have it count watchers instead :) [05:40] techwraith: I'm working on a few, I just wanted to know how many people are there :) [05:40] mscdex: heh [05:40] SubStack: mape: 2.no.de already does all that [05:40] fangel has joined the channel [05:40] jesusabdullah: Just wait, I'm totally gonna write that poopstream app, and then you'll all be sorry! [05:40] mscdex: mjr_: more modules, more cowbell -- more is always better! [05:41] jesusabdullah: Speaking of [05:41] mape: SubStack: ah yeah, but per author, accumulativ [05:41] jesusabdullah: JimBastard: Did JSONloops have a cowbell? [05:41] JimBastard: jesusabdullah: HELL YEAH [05:41] JimBastard: IT DOES [05:41] mscdex: thought so [05:41] jesusabdullah: Word. [05:41] jesusabdullah: You guys figure out that 32/64 stuff? What's up with that? [05:41] JimBastard: in an alternate reality im already an internet millionaire and work on JSONloops fulltime [05:41] SubStack: mape: http://caolan.github.com/ghstats/ [05:41] jesusabdullah: That's the only thing that's stopped me from installing it tbh [05:41] JimBastard: node-sfml should work [05:42] JimBastard: i added instructions to compile as 32 bit as well [05:42] JimBastard: someone just needs to setup node-sfml instead of irrKlang [05:42] JimBastard: i dont have the time to learn how to do that [05:42] JimBastard: ( on my own ) [05:43] some1else has joined the channel [05:44] jesusabdullah: SubStack: npm install npmtop is acting funky [05:44] jesusabdullah: SubStack: But looking at your code, it doesn't look like the same code npm installed [05:44] Chunk has joined the channel [05:45] Chunk: anyone know how to set http headers like content-type with https.request() ? [05:45] jesusabdullah: SubStack: nvm, I'm fixing it [05:45] scrogson: isaacs: you around? [05:46] konobi: Chunk: same as http [05:46] codivan has joined the channel [05:47] scrogson: any one else having trouble installing NPM? [05:47] isaacs: scrogson: hey [05:47] isaacs: broke some stuff on the github repo, if you're doing `make install` of the code [05:47] techwraith: isaacs: Holy crap, you're always around. I'm impressed. [05:48] isaacs: :) [05:48] scrogson: I've tried the curl command and it's failing too [05:48] isaacs: orly.. [05:48] JimBastard: is it possible to delete couchdb documents from within a view? [05:48] isaacs: scrogson: try now [05:48] gaschamber has joined the channel [05:49] isaacs: scrogson: with `curl | npm_install=rc sh`? [05:49] scrogson: yes [05:49] sivy has joined the channel [05:49] scrogson: I'll paste the error [05:49] skohorn has joined the channel [05:49] isaacs: nah, i'm off. email or github issues if it's still not working [05:50] johnnywengluu: where is issacs? [05:50] scrogson: he bailed [05:50] johnnywengluu: anyone is using this one? https://github.com/isaacs/nopt.git [05:50] johnnywengluu: kick ass parser .. i wonder why there is only 2 watchers though (me and him) =) [05:51] ekryski has joined the channel [05:51] jesusabdullah: BAM pull request [05:51] ekryski: is anyone else having a problem with mongoose sorting? It just hangs when I try it [05:52] jesusabdullah: Good question, johnnywengluu [05:52] jesusabdullah: johnnywengluu: I think it's because he factored it out of npm relatively late in the game, and most people don't need too many bells and whistles for their node cli action (like isaacs does) [05:53] twodollarz has joined the channel [05:53] jesusabdullah: johnnywengluu: I think a lot of people ended up using optimist for their cli needs. It's not the most heavy-duty options parser out there, but it's dead simple [05:54] jesusabdullah: johnnywengluu: Thanks for bringing nopt to my attention. It looks really good. [05:54] johnnywengluu: yeah someone should market it more [05:54] dominictarr has joined the channel [05:54] bingomanatee: Evening all [05:55] johnnywengluu: it has potential [05:55] johnnywengluu: since npm is already using it it should be fully featured already [05:55] jesusabdullah: Yeah, def [05:55] blkcat has joined the channel [05:55] bingomanatee: Spoke to Doug Crockford after his preso at Yahoo tonight. We're going to try and get him up to talk at a meetup this summer. [05:55] jesusabdullah: Holy cow, this options parser is HEAVY DUTY [05:56] ekryski: Anyone weighing in? I basically run a sort like this: TLF.find().sort([['date', 'descending']]).all(function(tlfs) { [05:56] ekryski: loadCallback(tlfs); [05:56] ekryski: }); [05:56] ekryski: and then it just hangs [05:56] jesusabdullah: Oh, what's this about ekryski? [05:56] ekryski: mongoose [05:56] jesusabdullah: oh [05:57] jesusabdullah: Sorry dudesky, I've never used mongoose [05:57] ekryski: hmm. anyone else in here? It should work. [05:59] DTrejo: hey guys, check out all my answers to node.js questions: http://stackoverflow.com/users/90149/dtrejo#qpage_1-anpage_1-qsort_votes-ansort_votes I went on a spree :) [06:01] DTrejo: almost all of them link back to this chatroom :) [06:01] johnnywengluu: this one seems powerful too https://github.com/chriso/cli [06:01] ryah has joined the channel [06:01] jesusabdullah: johnnywengluu: Have you looked at optimist? [06:02] jesusabdullah: It's very nice for simple cli apps [06:02] johnnywengluu: yeah .. both of them seem great and up to date [06:02] jesusabdullah: alright, just makin' sure ;) [06:02] johnnywengluu: watching them both [06:02] jesusabdullah: Hmm! [06:03] flippyhead_ has joined the channel [06:03] mytrile has joined the channel [06:03] jesusabdullah: Man, gj DTrejo [06:03] johnnywengluu: https://github.com/isaacs/node-supervisor [06:03] johnnywengluu: i like node shopping :) [06:04] jesusabdullah: Hah, me too [06:04] jesusabdullah: Oh, also check out indexzero/forever [06:04] DTrejo: ty jesusabdullah [06:04] DTrejo: I use forever for my own server [06:04] DTrejo: wtf is all this crazy unix stuff, node everywhere lol [06:04] DTrejo: *not unix [06:04] DTrejo: monit etc [06:05] jesusabdullah: You just wait, in 2 years node's gonna be for cli apps [06:05] jesusabdullah: and all those webapps are gonna be collecting 400 dusts [06:06] DTrejo: heh [06:07] sh1mmer has joined the channel [06:07] zylo has joined the channel [06:07] jesusabdullah: I actually thought about writing an ncurses app, but I realized that it would be easier to write a server that's meant to be viewed via elinks [06:07] jesusabdullah: or, rather, a webapp [06:08] jesusabdullah: Oh hey, so, does anybody know what creationix is up to these days? [06:08] jesusabdullah: He kinda disappeared on us, didn't he? [06:09] ivan has joined the channel [06:09] ivan has joined the channel [06:10] jesusabdullah: wow, he's still prolific as fuck, check out his github [06:10] jesusabdullah: https://github.com/creationix [06:10] DTrejo: jesusabdullah: he disappeared into HP [06:10] DTrejo: and palm [06:10] DTrejo: jesusabdullah: sencha was paying him to do OS work, and build stuff and teach people [06:11] DTrejo: you should email him though and ask him what's going on [06:11] Bogh has joined the channel [06:12] admc has joined the channel [06:12] jesusabdullah: Really? HP ate him? [06:13] DTrejo: well, not totally [06:13] jesusabdullah: lol [06:13] DTrejo: but I think that's where he works now [06:13] jesusabdullah: Still a chance it'll spit him out? XD [06:13] DTrejo: probably [06:13] jimt has joined the channel [06:13] DTrejo: he likely has 0 trouble getting jobs [06:13] jesusabdullah: Yeah, possible [06:13] sh1mmer: Tim is busy doing product [06:14] sh1mmer: he's still responsive though [06:14] sam0t has joined the channel [06:14] Jamool has joined the channel [06:14] jesusabdullah: Oh yeah? [06:14] jesusabdullah: Tell him I said to drop by on weekends. >:P [06:14] mikeal has joined the channel [06:15] johnnywengluu: "Optimist is a node.js library for option parsing for people who hate option parsing. More specifically, this module is for people who like all the --bells and -whistlz of program usage but think optstrings are a waste of time." [06:15] johnnywengluu: what does he mean with optstrings are a waste of time [06:16] mscdex: hey now, ncurses isn't that bad :) [06:16] ryankirkman has joined the channel [06:17] rfay_afk has joined the channel [06:17] jesusabdullah: johnnywengluu: I think he just means that it's a lot of effort to get the --bells and --whistlz, if you don't need very complex behavior [06:17] SubStack: johnnywengluu: lots of option parsers follow getopt off a cliff and make you figure out the types of all the options ahead of time [06:17] jesusabdullah: optimist gives you flags for very cheap [06:18] jesusabdullah: SubStack: Did you see isaacs's nopt? It's in a sense the yin to optimists's yang...or is it the other way? Anyway, it looks as though it parses options like a boss [06:19] Murugaratham has joined the channel [06:19] jesusabdullah: Has anybody done audio in html5? Just ooc [06:19] jimt has joined the channel [06:19] jesusabdullah: I've had an idea for making an internet radio aggregator for a while, was thinking maybe node/the browser would be a good approach [06:19] jesusabdullah: but i don't want to do it that way if audio in the browser sucks [06:20] jesusabdullah: sans flash, anyway, which, well [06:20] jesusabdullah: still sucks [06:20] johnnywengluu: SubStack: i dont get your boolean example [06:21] SubStack: johnnywengluu: -sp is shorthand for -s -p [06:22] johnnywengluu: what does that have to do with booleans? [06:23] DTrejo: jesusabdullah: use jplayer [06:23] DTrejo: jesusabdullah: mixest.com [06:24] DTrejo: html5 w/ flash fallback [06:24] jesusabdullah: johnnywengluu: If you have the flag, it's a yes. If you don't have the flag, it's a no [06:24] malkomalko has joined the channel [06:24] johnnywengluu: okay [06:24] jesusabdullah: DTrejo: Thx dawg [06:24] DTrejo: np [06:25] DTrejo: jesusabdullah: and https://github.com/hij1nx/SugarSkull for routing so you don't reload and mess up the music :) [06:25] jesusabdullah: Ah [06:25] DTrejo: doesn't support !# yet though I don't think [06:25] beawesomeinstead has joined the channel [06:25] jesusabdullah: !# ? [06:26] DTrejo: google indexable links [06:26] DTrejo: oops [06:26] DTrejo: #! [06:26] jesusabdullah: Ah [06:26] jesusabdullah: Time to follow some bitches [06:26] jesusabdullah: lol that sounds so stalkery [06:26] jesusabdullah: Good thing github is probably 90% male in demographic! [06:26] jesusabdullah: (unfortunate. It COULD be the geekiest dating site in the world) [06:27] jesusabdullah: Ah, in a world where "Hey, I like your code" is a valid pickup line... ;) [06:28] jesusabdullah: Man, first dubset, now mixest? [06:28] jesusabdullah: See, what I think would be cool is to make an app that can aggregate these sources at different times, along with podcasts and listen.pls's [06:28] DTrejo: mixest is really old, but anyway [06:29] jesusabdullah: Huh! [06:29] DTrejo: I didn't make dubset, though I did help make mixest [06:29] SamuraiJack has joined the channel [06:29] jesusabdullah: I wonder why I didn't know about either of thesE? [06:29] jimt has joined the channel [06:29] jesusabdullah: I never used pandora until my ex made an account for me [06:29] jesusabdullah: and then she moved on to grooveshark [06:29] jesusabdullah: and I never tried IT either! [06:29] sh1mmer has joined the channel [06:29] johnnywengluu: oh [06:30] WRAz: decent node proxy? [06:30] dominictarr has joined the channel [06:30] johnnywengluu: now i know why noone knows about nopt ... he just committed that one out 3 hours ago : https://github.com/isaacs/nopt hahaha [06:30] WRAz: found it [06:30] WRAz: never mind [06:30] slickplaid: what's everyone's favorite way of detecting if an optional callback function is included? [06:31] johnnywengluu: if ? [06:31] Viriix: arguments.length or (typeof argumentName != 'undefined') [06:31] jesusabdullah: Yeah, one of those [06:31] Viriix: all depends [06:32] Viriix: either one of those usually work out though [06:32] slickplaid: Okay :) just checking... thought there might be a slicker way of doing it. [06:32] jesusabdullah: what would happen if you did your callback in a try? [06:32] jesusabdullah: Sounds kinda dumb to me, but *shrug* [06:32] beawesomeinstead has joined the channel [06:32] johnnywengluu: why not just if (typeof callback === "function") [06:32] slickplaid: var cb = (callback) ? callback() : function(){}; [06:33] jesusabdullah: That looks like a reasonable approach [06:33] jesusabdullah: from here [06:33] tfe_ has joined the channel [06:33] tfe_ has joined the channel [06:33] jesusabdullah: but I don't eat and breathe javascript...YET [06:33] jesusabdullah: Been doing too much LaTeX and python lately >_< [06:33] DTrejo: slickplaid: or callback && callback() [06:33] DTrejo: but that is more dangerous [06:34] muhqu has joined the channel [06:35] dominictarr has joined the channel [06:38] mellowsoon has left the channel [06:38] atiti has joined the channel [06:40] WRAz: npm running slow for you guys ? [06:41] JimBastard: wtf [06:41] pquerna: yes [06:42] pquerna: now its fine [06:42] pquerna: enoclue. [06:43] harth has joined the channel [06:44] JimBastard: i feel like im going crazy here. if i have an array of objects, why can't i do this? signups.forEach(function(v,i){ signups[i].fuck = "asd"; }); [06:44] JimBastard: it seems to ignore the assignment if signups is a function argument? [06:44] JimBastard: maybe i should go to sleep [06:45] SubStack: v8: var xs = [ {}, {}, {} ]; xs.forEach(function (x,i) { xs[i].i = i }); xs [06:45] v8bot: SubStack: [{i:0},{i:1},{i:2}] [06:47] JimBastard: SubStack: that works for me too, its when the array is passed in from the callback scope, something is wonky [06:47] jetienne has joined the channel [06:47] JimBastard: its refusing to set the property [06:47] dominictarr has joined the channel [06:47] reid has joined the channel [06:47] SubStack: v8: (function (xs) { xs.forEach(function (x,i) { xs[i].i = i }); return xs })([{},{},{}]) [06:47] v8bot: SubStack: [{i:0},{i:1},{i:2}] [06:47] SubStack: :/ [06:48] springify has joined the channel [06:49] beawesomeinstead has joined the channel [06:49] JimBastard: v8: (function (xs) { xs.forEach(function (x,i) { xs[i].i = i }); return xs })([{foo:'a'},{foo:'b'},{foo:'c'}]) [06:49] v8bot: JimBastard: [{foo:"a",i:0},{foo:"b",i:1},{foo:"c",i:2}] [06:49] ckknight_: in Javascript, I really like that I can so easily do makeSomeCallback("blah") and have it produce a completely workable function for me. It's like getting Aspect-Oriented Programming for free. [06:49] prettyrobots has joined the channel [06:49] Twelve-60 has joined the channel [06:50] jaxdahl has joined the channel [06:52] JimBastard: v8: (function (xs) { xs.forEach(function (x,i) { xs[i].i = true }); return xs })([{foo:'a'},{foo:'b'},{foo:'c'}]) [06:52] v8bot: JimBastard: [{foo:"a",i:true},{foo:"b",i:true},{foo:"c",i:true}] [06:53] JimBastard: !!!!!!!!! [06:53] JimBastard: i swear its not working here [06:53] pquerna: debugger; [06:54] SubStack: ckknight_: yep! javascript's heavy use of closures is pretty great [06:55] groom has joined the channel [06:56] DTrejo: closures can do crazy things [06:56] ckknight_: SubStack: mostly the closures-making-closures is something that it nice. My dayjob is in C# and far from as fluid as this node.js stuff [06:56] DTrejo: like screw you up [06:56] ckknight_: that is nice* [06:56] JimBastard: i gave up and just made a new array [06:56] JimBastard: im too deep in the matrix to deal with this [06:56] JimBastard: >.< [06:56] DTrejo: :) [06:57] Murugaratham: anywhere i can find a pubsub socket.io sample? [06:57] JimBastard: i have a feeling it will fix itself after sleep [06:58] TomY_ has joined the channel [06:58] rfay_afk has joined the channel [07:01] beawesomeinstead has joined the channel [07:01] ivanfi has joined the channel [07:01] bitmonk has joined the channel [07:03] fangel has joined the channel [07:04] unlink has joined the channel [07:04] unlink has joined the channel [07:05] herbySk has joined the channel [07:07] nyholt has joined the channel [07:08] DTrejo: Murugaratham: nowjs.com [07:08] DTrejo: gnight everyone! [07:08] DTrejo: gnight jesusabdullah! [07:09] seivan has joined the channel [07:09] raphdg has joined the channel [07:09] muk_mb has joined the channel [07:09] mraleph has joined the channel [07:10] jesusabdullah: Whoo, got a special mention! [07:10] jesusabdullah: That's right [07:10] jesusabdullah: *whew* [07:11] SvenDowideit has joined the channel [07:12] nivoc has joined the channel [07:12] johnnywengluu: jesusabdullah: have you tried cli` [07:13] johnnywengluu: the --help is so cool .. dont have to print out a custom help message anymore [07:14] felixge: [ann]: My little node.js guide is ready: http://nodeguide.com/ [07:14] jesusabdullah: johnnywengluu: I haven't. I've mostly just used optimist and been happy with it. Link? [07:15] johnnywengluu: jesusabdullah: https://github.com/chriso/cli [07:15] johnnywengluu: you'll have a second thought about it after using --help =) [07:15] jesusabdullah: johnnywengluu: optimist also has a pretty nice tool for "you screwed up" output [07:15] jesusabdullah: idk if it does --help or not, but, yeah [07:15] ekryski: Phew… got it! That was a struggle and totally not obvious. [07:15] logii has joined the channel [07:16] mAritz has joined the channel [07:16] jesusabdullah: Oh hey, that's cool! With the --help and all [07:16] johnnywengluu: jesusabdullah: i just dont want to reinvent the wheel all the time [07:16] jesusabdullah: Yeah, sure [07:16] jesusabdullah: wheel reinvention sucks [07:16] jesusabdullah: Just make sure not to put up with a square wheel ;) [07:16] jimt has joined the channel [07:16] jesusabdullah: Making your road ribbed is worse! [07:16] ekryski: ha ha. It's ok. I'm sure there will be something in the future you might need to help me with ;) [07:17] jesusabdullah: ekryski: What was wrong with it? [07:17] jesusabdullah: ekryski: Mongoose, right? [07:17] ekryski: yep [07:17] ekryski: First it was that now I guess mongoose didn't like the double square brackets [07:18] nils_r has joined the channel [07:18] ekryski: then I couldn't use all I needed to use each and then build an array with all the returned documents [07:18] logii: I'm trying to get node.js to work on OSX 10.6, using express/socket.io . Got stucked at: Error: Error: ECONNREFUSED, Could not contact DNS servers at IOWatcher.callback (dns.js:74:15) [07:18] logii: any ideas? [07:19] ekryski: sorry I haven't played with that yet. It's on my list. [07:21] zakabird: : gonna start following the style guide, good stuff [07:21] felixge: zakabird: cool : ) [07:22] troessner has joined the channel [07:23] f1lt3r_bocoup has joined the channel [07:23] ckknight_: felixge: not sure why you're against using Object.freeze and the like [07:23] ajnasz has joined the channel [07:23] felixge: ckknight_: because I don't need it [07:23] mikeal has joined the channel [07:23] felixge: :) [07:23] WRAz: hey guys, finished my side project [07:23] ckknight_: if you have an immutable object, declaring it as such seems like good practice [07:23] WRAz: http://criticmeta.com/ [07:24] WRAz: going to theme it this week [07:24] felixge: ckknight_: anything that potentially gets in my way to unit test something is evil [07:24] felixge: and object freezing certainly does [07:24] Knio has joined the channel [07:24] ckknight_: hmm [07:24] ckknight_: I see it as a security issue [07:24] ckknight_: :P [07:24] felixge: ckknight_: I don't let people I don't trust write code [07:24] no-gooder has joined the channel [07:24] felixge: that is the most secure approach I can think of [07:24] jesusabdullah: WRAz: Nice. You should list top and bottom ten [07:24] felixge: beats Object.freeze for sure [07:24] felixge: ;) [07:25] jesusabdullah: So you can both see who to avoid AND who to trust [07:25] jesusabdullah: Oh wait, there are <> buttons [07:25] jesusabdullah: NEVER MIND [07:25] jesusabdullah: WRAz: NYT rates games?? [07:26] ckknight_: felixge: I don't trust who I am 3 months in the past and 3 months in the future. What if I forget some invariant and end up breaking something accidentally? [07:26] ckknight_: :P [07:26] ckknight_: I'd rather have proper immutability with an invariant forcing its immutability [07:27] dominictarr has joined the channel [07:27] felixge: ckknight_: Maybe I should write a new guide called: "Top 10 signs that you'd be happier with a statically typed language" [07:27] felixge: ;) [07:27] ckknight_: optionally having immutability in a dynamic language is good and shouldn't be discarded. [07:28] fly-away has joined the channel [07:28] felixge: ckknight_: can you give me an actual use case? [07:30] kal-EL_ has joined the channel [07:30] patrick__ has joined the channel [07:30] ckknight_: felixge: all the primitive types in JS are immutable as-is. [07:31] ckknight_: With immutability, you can add interning very easily, which can be a performance gain [07:33] ckknight_: you could have a constants object, freeze that, and be guaranteed that its values won't actually change [07:33] felixge: ckknight_: why would I have constant objects? [07:33] ckknight_: but if you have children that are mutable in it, they can change arbitrarily without guarantee. Freezing those to make immutable objects will guarantee true constancy [07:34] ckknight_: it's about guaranteeing that things are what they should be [07:34] felixge: * would I want to have [07:34] ekryski: g'night all [07:34] ekryski has left the channel [07:34] felixge: I write unit tests for that [07:34] felixge: :) [07:34] felixge: and my objects are manipulated via their methods [07:34] felixge: OOP-style [07:34] felixge: so I don't need to worry about somebody messing with their properties in weird ways [07:36] ckknight_: immutable objects are a pretty fundamental design of traditional functional programming languages, if you write javascript functionally (which is generally a good idea), then you wouldn't want some potential setTimeout or other callback altering your objects which you believe are immutable [07:37] hwinkel has joined the channel [07:39] zomgbie has joined the channel [07:39] k1ttty has joined the channel [07:39] FireFly has joined the channel [07:40] ckknight_: another example: let's say you have a Point class, so you set a new Point(1, 1) onto a whole bunch of different objects. If one happens to change its Point by altering its inner properties, then it would change it for all of them (likely erroneously). If Point were immutable, that case could never occur. [07:41] V1 has joined the channel [07:41] [AD]Turbo has joined the channel [07:42] jesusabdullah: Wait, but [07:42] matyr_ has joined the channel [07:42] jesusabdullah: you'd have to change the prototype right? [07:42] jesusabdullah: because js doesn't have true classes [07:42] [AD]Turbo: hi there [07:42] framlin: chknight_: so you might x and y private set by constructor and having no getter/setter .... [07:42] WRAz: @Jesusabdullah apperently ;) [07:43] SubStack: ckknight_: you've need to mess with pt.__proto__ [07:43] WRAz: I updated it btw, larger sample size and I report how many users voted on the games they reviewed [07:43] SubStack: and that's only for prototypes [07:43] WRAz: http://criticmeta.com/ sort by # of reviews [07:43] WRAz: its really itneresting that worth playing got below a 2 with 25 reviews [07:43] jesusabdullah: Huh? [07:43] jesusabdullah: Oh [07:44] ckknight_: jesusabdullah: I'm basically referring to a Point factory that generates objects. [07:44] WRAz: they're probably pretty trustworthy [07:44] msucan has joined the channel [07:44] jesusabdullah: ckknight_: you mean a constructor, right? But once you generate your Point objects they're on their own [07:44] ckknight_: whether or not its prototype is Object.prototype or something else is arbitrary [07:44] ckknight_: jesusabdullah: I know. [07:44] jesusabdullah: Okay [07:44] jesusabdullah: Sorry, I'm tired [07:45] ckknight_: and it's irrelevant whether it's a class constructor or a function [07:45] jesusabdullah: so I'm probably missing what you're saying entirely. I'm in no condition. :) [07:45] ckknight_: I'm referring to having a point object, e.g. {x:1, y:1} [07:45] ckknight_: and passing that around [07:45] ckknight_: and how it'd be better to have it be immutable in certain cases [07:45] zomgbie has joined the channel [07:46] rapapa has joined the channel [07:46] SubStack: your design can have implicit immutability with getters and set functions that return a new object [07:46] ckknight_: oh yeah, absolutely [07:46] ckknight_: and that's fine [07:46] mraleph: I hate the idea of silent failure immutability (in non-strict mode) [07:46] ckknight_: I have no issue with that [07:47] ckknight_: mraleph: so use strict mode. [07:47] rapapa: make room? [07:47] jesusabdullah: Oh, I see what you mean ckknight_ [07:47] jesusabdullah: For some reason I thought you were talking about fucking with the prototype without fucking with the prototype, and I got REALLY confused [07:47] mraleph: I would rather use normal language. without kludges like Object.freeze :-) [07:47] mraleph: or strict mode [07:47] jesusabdullah: >_< [07:47] ckknight_: jesusabdullah: god no [07:47] jesusabdullah: CARRY ON [07:47] jesusabdullah: lol [07:48] jesusabdullah: ^5 [07:48] ckknight_: mraleph: how is that a kludge? it's essentially a builder pattern. [07:48] tbassetto has joined the channel [07:48] tschundeee has joined the channel [07:48] SubStack: well you probably don't need to freeze members at all [07:48] SubStack: let people shoot their feet off, it's less frustrating than having to go into an interface to disable freezing when you want to do something hackish [07:49] mhausenblas has joined the channel [07:49] mraleph: first we say — oh here is your nice mutable language, your objects are nice dictionaries harharhar you can alter everything. [07:49] BigWookie: xD [07:49] ckknight_: SubStack: don't do hackish things, architect properly. [07:49] mhausenblas_ has joined the channel [07:49] SubStack: "properly" [07:49] SubStack: whatever that means! [07:49] framlin: SubStack: but if you are coding within a team and you are coding large applications and som of the team-members are not as carefully as others, it may be cool to have "const" .. [07:50] SubStack: I do hackish stuff all the time for the greater good [07:50] SubStack: by which I mean usable interfaces [07:50] mraleph: then we say: oh, people are abusing mutability, nomnomnom, let's pile features on top of features and give user access to property decscriptors and give him freeze [07:50] ckknight_: it's not always about being carefully, framlin, sometimes it's about lack of documentation or lack of reading documentation [07:50] SubStack: framlin: large applications are bad no matter what you do [07:50] SubStack: don't do large applications [07:50] mraleph: this approach does not scale. [07:51] SubStack: oh yes it does! [07:51] ckknight_: doesn't sound like it [07:51] SubStack: split everything up into reusable modules! [07:51] SubStack: much nicer way to manage your hackish magical bits [07:51] framlin: if you have large company, that have decided to have javascript-business-applications (intrawebApps), you have to have large applications ... [07:51] BigWookie: When you design the software right you can program modular, when you program modular you just have interfaces to connect [07:51] mraleph: SubStack: I meant language design approach. not your suggestion :-) [07:52] k1ttty has joined the channel [07:52] SubStack: I don't see how applications must necessarily become large and complicated [07:52] BigWookie: and everybode how abuses interfaces should be fired instantly :D [07:52] SubStack: it might be more work to make stuff smaller but it's worth it [07:53] jesusabdullah: What do you mean by interfaces? [07:53] zakabird: AAA game as modules? how would that work? [07:53] jesusabdullah: I think I read about them once but I didn't get into it [07:53] jesusabdullah: I don't know my CS jargon guys :( [07:53] adambeynon has joined the channel [07:53] BigWookie: I come from c++, and i mean class interfaces so you can use objects as black boxes [07:53] framlin: SubStack: the company I work for develop their business-apps since 20 years and thei are accustomed to large apps, becaus thei mirror their workflows ... in that situation their is no chance to have small-apps ... [07:54] ckknight_: jesusabdullah: interfaces are essentially an expected set of methods or properties that an object implements. Depending on how deep you go, it can also dictate the arguments of the methods or the invariants of the objects themselves. [07:54] SubStack: framlin: an argument from adherence to existing business practices does not carry over into the necessity for these practices in the first place [07:54] matjas has joined the channel [07:54] jesusabdullah: Oh, I see [07:55] jesusabdullah: Makes me think of the other half of a framework [07:55] jesusabdullah: Y'know? [07:55] ckknight_: no? [07:55] SubStack: I'm not saying it's easy to split stuff up into reusable components, just that it's a good idea [07:55] jesusabdullah: Like, given a framework that eats an object, it may expect the object to have certain methods [07:56] jesusabdullah: it may expect a particular interface [07:56] SubStack: and that part of doing reuse properly is taking the code ouf of the project hierarchy altogether and throwing it up on github [07:56] zakabird: people seem to interated big apps like word processors and ide's vs the unix command line. perhaps im missing the point [07:56] ckknight_: oh yeah, and you could say that it expects a specific interface [07:56] ckknight_: yeah, exactly [07:56] jesusabdullah: Like how connect expects middleware to be functions of (req, res) [07:57] ckknight_: yep. [07:57] jesusabdullah: Cool [07:57] ckknight_: big apps can provide integration a lot easier, joining smaller apps together can be hard to do. [07:57] jimt has joined the channel [07:57] ckknight_: jesusabdullah: and it doesn't matter if req is actually inherits from the Request class (or what have you), as long as it has the methods you expect, that's what matters. [07:58] stonebranch has joined the channel [07:58] jesusabdullah: Sure [07:58] SubStack: small apps can be just as big when you consider the mountains of software they rest upon to do their tiny function [07:59] framlin: SubStack: I agree with you! The first things I have done here are to pull business-logicout of the view-parts into separate bl-helper-classes and to busines-logic-objects that could be used from a lot of views. But Javascript-coders are rare and most of them are just able to color som menues within web-pages, so they do not always know what they do and sometimes I wished to have consts cause of that ;) [07:59] Samot: lol [07:59] insin has joined the channel [08:00] BigWookie: As long as you work with proper enclosuring and create easy to use blackboxes for functionality it dosn't matter how big an app gehts [08:00] zakabird: substack: are you talking about a different result for the end user or just a 'small components are better' development philosophy? [08:00] SubStack: it's super annoying to get reuse working in browser-side javascript due to the lack of a builtin module system [08:00] SubStack: but now you can use browserify for that! [08:00] skm has joined the channel [08:01] SubStack: zakabird: I'm advocating lots of tiny components in favor of few large components is all [08:01] skm has joined the channel [08:01] zakabird: ah ok nm then [08:01] skm has joined the channel [08:02] skm has joined the channel [08:02] meso_ has joined the channel [08:02] skm has joined the channel [08:03] Samot: i tried reading about browserify this morning, got confused and stopped. [08:03] Samot: will try again later [08:04] SubStack: it lets you write code the node.js way for the browser [08:04] SubStack: including bundling of npm packages [08:05] MikhX has joined the channel [08:05] zakabird: I kinda have always wanted some kind of end user experience that was gui's but with some kind of unix small program shell style composability [08:06] SubStack: I think extjs tries to do that [08:06] zakabird: doesnt every body agree small components are better? but harder to do. I always end up creating a too ambitious, do everything mess [08:06] BigWookie: I use ExtJS + NodeJS [08:07] BigWookie: + all the nice small components of the community :) [08:07] SubStack: zakabird: well if you try to do everything then it's not very small! [08:07] no-gooder has joined the channel [08:08] zakabird: lol. yeah. [08:08] BigWookie: zakabird: if you use Developement patterns like MVC and build Functional objects with loose coupling you can achieve your goal [08:08] framlin: zakabird: its like everything else: too small is as worse as too big ;) [08:08] nils_r has joined the channel [08:08] bluekite2000 has joined the channel [08:08] aklt has joined the channel [08:09] SubStack: if there is a lower bound on smallness of useful npm modules then I haven't encountered it yet [08:09] framlin: .. as bad as ... sorry, Im no native-speaker ... [08:10] BigWookie: I don't doubt that :) [08:11] SubStack: hell even a module require('sum')([1,2,3,4,5,6,7,8,9]) == 45 wouldn't be so bad [08:11] emattias has joined the channel [08:11] SubStack: v8: [1,2,3,4,5,6,7,8,9].reduce(function (sum, n) { return sum + n }, 0) [08:11] v8bot: SubStack: 45 [08:11] sveisvei has joined the channel [08:11] BigWookie: I used Nodejs, irc, nowjs( sorry SubStack but in the beginngng its just easyer than dnode ), and extjs to create a irc client in about 3 hours, what more can you wish [08:12] framlin: SubStack: I think its no good Idea to have 100000 modules ech 2 lines of code and 100 of them sharing "busniess-domain" [08:12] sh1mmer has joined the channel [08:12] stagas has joined the channel [08:13] framlin: SubStack: at least the last 100 should be bound together in one module [08:13] BigWookie: :/ Only thing i'm missing would be a gui designer, I hate gui [08:13] jimt has joined the channel [08:13] dominictarr has joined the channel [08:13] SubStack: framlin: you might be able to factor out a lot of the shared functionality into some kind of business engine though [08:14] SubStack: but I don't have access to your particular codebase [08:20] nivoc has joined the channel [08:20] piscisaureus: mraleph: do the v8 tests test the profiling sampler? [08:20] mraleph: they should [08:21] losing has joined the channel [08:21] jaxdahl has joined the channel [08:22] rfay_afk has joined the channel [08:22] eirikurn has joined the channel [08:23] JimBastard: yeah you will all pass tests [08:23] JimBastard: boom [08:24] piscisaureus: eh ? [08:24] no-gooder has joined the channel [08:25] JimBastard: im talking to my test suite, it appears to be passing [08:25] SubStack: JimBastard: hey mine too! [08:25] SubStack: but I had to make it fail first [08:25] framlin: SubStack: I have done that by introducing a business-helper-object-layer. The biggest business-part of the system is implemented in COBOL and JS does AJAX calls to that BL-tier. I try to push to that layer that I can, but COBOL-dev-resources are as rare as JavaScript-dev-resources ;) [08:25] JimBastard: clean up, document, and merge time [08:26] SubStack: ACTION adds dnode-cobol into his queue [08:26] JimBastard: cobol...lol [08:26] piscisaureus: JimBastard: oh, sad. I was hoping you were about to show off your "artful use of profanity" as felixge puts it [08:26] SubStack: that would be super lulzy to write [08:26] JimBastard: piscisaureus: lolwut? [08:26] piscisaureus: http://nodeguide.com/community.html#marak-squires [08:26] framlin: SubStack: so because the COBOLds have a lot of work, I have to implement a lot of BL-stuff within my JavaScript-BL-helper-layer ... [08:26] JimBastard: Did you just put the words in my mouth and appear to make me wear the dick helmet? Not cool. [08:27] piscisaureus: Ah, it's coming. [08:27] prettyrobots: We're about 24 hours away from the IronNode.js.net announcement. [08:27] piscisaureus: ACTION takes a beer [08:28] framlin: JimBastard: whats wrong about COBOL? [08:28] JimBastard: 246 honored ∙ 6 broken (45.045s) fuuuuu [08:28] JimBastard: framlin: I don't think I'm qualified to answer that. [08:28] prettyrobots: framlin: So many words! [08:29] prettyrobots: http://www.csis.ul.ie/cobol/examples/Accept/Shortest.htm [08:29] piscisaureus: I feel like trolling while waiting for the v8 test suite to finish [08:30] matyr has joined the channel [08:30] framlin: prettyrobots: thats right and its about very indynamic .... an error we have once a month is a kind og array-overflow, cause you have to declare how long an array will be and if your data grow, your result-arrays grow, until ... bang ... you have toi redeclare it ;) [08:31] prettyrobots: framlin: You work in COBOL? [08:32] prettyrobots: !?! [08:32] jakeskik has joined the channel [08:32] shift__ has joined the channel [08:34] framlin: prettyrobots: no, I am the fronted-coder. I build intranet-business-apps with XUL/JavaScript and "talk" to the COBOL-tier to get business-decissons. So I have learned to read COBOL to understand the business-logic behind [08:34] prettyrobots: framlin: That is some really mystical stuff. [08:35] jimt has joined the channel [08:35] framlin: as I started here I thought they are crazy to try to build such apps with JAvaScript, but I learned: its not only possible, its cooool ;) [08:35] rfay_afk has joined the channel [08:36] framlin: cause of the lack of COBOL-coders they migrate the business-tier to PHP now [08:36] Charuru: what's ironjs [08:36] Charuru: ironnodejs? [08:37] MikhX has joined the channel [08:37] stillnzfish has joined the channel [08:39] m00p has joined the channel [08:39] kuya: im getting an error like this with a noce script *** glibc detected *** /home/dunk/local/node/bin/node: munmap_chunk(): invalid pointer: 0x0838fd80 *** [08:39] kuya: how does one go about debugging such a thing? [08:39] piscisaureus: mraleph: I got 2 tests failing, mjsunit/test-pow (expeded Infinity, got -Inifinity) <- have seen that failing before [08:39] piscisaureus: But what worries me more is that cctest test-alloc-CoreRage crashes. [08:39] piscisaureus: Would that mean that there's something wrong with the cygwin code? [08:39] kuya: imm useing node-canvas which is where i suspect the errror is [08:40] luke` has joined the channel [08:40] piscisaureus: *CodeRange, not CoreRage :-( [08:42] dgathright has joined the channel [08:42] Gruni has joined the channel [08:42] framlin: if there is someone livin near munich/gemany and is realy familiar with JavaScript, the company I work for is looking for you ;) [08:43] BigWookie: you used cobol in combination with your company ^^ [08:44] BigWookie: not that that would scare anyone [08:45] framlin: oh in a view years there is only PHP left ;) [08:45] framlin: few years [08:45] beawesomeinstead has joined the channel [08:46] mikl has joined the channel [08:46] framlin: and I advertise for nodejs, where I can ;) [08:46] BigWookie: :D [08:49] snearch has joined the channel [08:51] bzinger has joined the channel [08:51] losing has joined the channel [08:51] dominictarr has joined the channel [08:56] xla has joined the channel [08:57] dcelix has joined the channel [08:57] markwubben has joined the channel [09:01] confoocious has joined the channel [09:01] tokumine has joined the channel [09:02] eventi has joined the channel [09:06] pomodoro has joined the channel [09:07] piscisaureus: mraleph: okay, the test fails due to out of memory [09:08] Lorentz has joined the channel [09:10] hellp has joined the channel [09:11] pdelgallego has joined the channel [09:14] pietern has joined the channel [09:19] mc_greeny has joined the channel [09:19] MikhX has joined the channel [09:20] jimt_ has joined the channel [09:21] Ori_P has joined the channel [09:24] astropirate has joined the channel [09:25] incon has joined the channel [09:25] pastak has joined the channel [09:28] markwubben has joined the channel [09:31] jimt has joined the channel [09:31] fenngle has left the channel [09:31] fermion has joined the channel [09:33] nyholt_ has joined the channel [09:35] no-gooder has joined the channel [09:38] skm has joined the channel [09:38] seivan has joined the channel [09:39] skm has joined the channel [09:40] skm has joined the channel [09:40] k1ttty has joined the channel [09:41] derferman has joined the channel [09:41] skm has joined the channel [09:41] nzfish has joined the channel [09:42] markc_ has joined the channel [09:42] skm has joined the channel [09:42] robhawkes has joined the channel [09:43] skm has joined the channel [09:43] skm has joined the channel [09:44] skm has joined the channel [09:45] piscisaureus: Ok. nvm. Found the issue, it was indeed a problem with platform-cygwin. [09:45] skm has joined the channel [09:46] skm has joined the channel [09:47] skm has joined the channel [09:48] barodeur has joined the channel [09:49] MrTopf has joined the channel [09:50] lukus has joined the channel [09:51] skm has joined the channel [09:52] skm has joined the channel [09:53] skm has joined the channel [09:53] asabil has joined the channel [09:53] skm has joined the channel [09:54] skm has joined the channel [09:55] skm has joined the channel [09:56] skm has joined the channel [09:57] skm has joined the channel [09:57] meandi has joined the channel [09:58] skm has joined the channel [09:58] skm has joined the channel [10:00] matyr_ has joined the channel [10:03] christophsturm has joined the channel [10:03] JY__ has joined the channel [10:03] seivan has joined the channel [10:04] unlink has joined the channel [10:04] skm has joined the channel [10:05] davidcoallier: markc_: I've pulled/pushed [10:05] davidcoallier: Thanks [10:06] markc_: davidcoallier: cool, any ideas about POST? [10:06] Murugaratham has joined the channel [10:08] Shrink has joined the channel [10:08] Shrink has joined the channel [10:10] mike5w3c has joined the channel [10:10] jeremyselier has joined the channel [10:11] jeremyselier: hi there [10:12] jeremyselier: does someone know if it's possible to prevent fetching the body of a request while using http.get [10:12] jeremyselier: I just want to fetch the headers [10:12] dominictarr has joined the channel [10:12] SamuraiJack_ has joined the channel [10:13] romainhuet has joined the channel [10:13] hellp has joined the channel [10:16] d0k has joined the channel [10:17] teemow has joined the channel [10:19] davidcoallier: markc_: yeah I saw how to do this, looking into it [10:19] davidcoallier: markc_: If you google for node.js handling post data it gives some ideas [10:19] matyr has joined the channel [10:20] johnnywengluu: we need something like Thor for ruby on node.js [10:20] markc_: jeremyselier: perhaps look for req.method == 'HEAD' and just return a response.writehead() and response.end() [10:21] k1ttty has joined the channel [10:21] markc_: writeHead() [10:22] jeremyselier: Just to give a bit more info: I'm basically trying to do a resolver of short urls, if there is an ISO behind the short URL, right now, I'm downloading the whole thing [10:22] jeremyselier: the thing is, some server does not support HEAD [10:22] davidcoallier: jeremyselier: which servers don't support HEAD? This isn't 1990 [10:25] jeremyselier: yep you have a point [10:26] markc_: davidcoallier: var b=''; req.on('data', function(c) {b += c}); req.on('end', function() { qs.parse(b); ... } [10:26] davidcoallier: markc_: ouch, we need to find a way to use it and pass it to fcgi then ;-) [10:26] davidcoallier: This is where we start breaking node even more. [10:26] markc_: davidcoallier: to prepare the posted vars but I'm not sure how to present ... to fastcgi [10:26] davidcoallier: Give me a sec, I'll open up the specs [10:28] Shrink has joined the channel [10:28] jeremyselier: anyway, even if I don't use it, you can kill your request before it downloads the body with response.connection.destroy() [10:30] davidcoallier: markc_: I think I can just pass a post body via STDIN, nothing fancy. [10:30] davidcoallier: Might be REQUEST_BODY but I'm looking at the php-fpm code for passing posts now. [10:31] davidcoallier: markc_: if you make a variable available to me I think I can use it and pass it to the fcgi handler. [10:32] shiawuen has joined the channel [10:32] vckt has joined the channel [10:36] jimt has joined the channel [10:37] johnnywengluu: how do i set some colors on node.js? [10:37] johnnywengluu: on the terminal [10:38] stagas: johnnywengluu: npm install colors [10:38] stagas: johnnywengluu: console.log('foo'.yellow) [10:38] dominictarr has joined the channel [10:39] johnnywengluu: thanks [10:39] johnnywengluu: why isnt it listed on node modules?! [10:39] saikat_ has joined the channel [10:42] MattJ has joined the channel [10:43] johnnywengluu: stagas: it says undefined [10:43] johnnywengluu: sys.puts("green".green) [10:43] johnnywengluu: undefined [10:43] Sor3nsen has joined the channel [10:46] stagas: johnnywengluu: doesn't work in repl for some reason. make a script [10:46] mraleph has joined the channel [10:47] johnnywengluu: stagas: cool [10:48] gnagno has joined the channel [10:48] gnagno: hello all [10:48] christophsturm has joined the channel [10:49] broofa has joined the channel [10:49] xla has joined the channel [10:50] gnagno: how can I differ a new connection from a user that just refreshed the page using socket.io ? [10:53] eee_c has joined the channel [10:55] stagas: gnagno: make the client send some kind of uid onopen ? [10:56] gnagno: stagas, do you know where I can find some documentation on socket.io ? the official webpage is a bit "minimal" [10:57] V1 has joined the channel [10:58] monokrome: gnagno: What's wrong with minimal? :D [10:58] gnagno: monokrome, nothing wrong with minimal, but you know... some more documentation or example wouldn't be bad :) [10:59] fly-away: Hi! [10:59] HerrTopf has joined the channel [10:59] monokrome: gnagno: Did you see the example files? [10:59] monokrome: https://github.com/LearnBoost/Socket.IO-node/tree/0.6.3/example [10:59] fly-away: "the tasks will be done tomorrow" - its ok english phrase? [10:59] fly-away: or "Those tasks are to be finished for tomorrow." better? [10:59] monokrome: yep [10:59] fly-away: sorry for offtop [10:59] monokrome: First is better [10:59] gnagno: thank you monokrome [11:00] monokrome: No problem [11:00] monokrome: The tasks will be finished tomorrow [11:00] monokrome: would also worked, if you liked the word finished [11:00] monokrome: s/worked/work/ [11:00] V1: gnagno: I completely documented the Socket.IO client using JSDoc https://github.com/LearnBoost/Socket.IO/pull/111 so you can generate additional documentation from that ;) [11:01] voodootikigod has joined the channel [11:01] gnagno: V1, thank you :) [11:02] gnagno: I am looking for something that will allow me to send a message only to a specific subset of connected users, is this possible ? [11:02] monokrome: ACTION wonders if there are any python backends for socket.io [11:02] V1: You have tornadio monokrome [11:02] monokrome: yeah [11:03] gnagno: monokrome, there's a link in the "minimalistic" homepage concerning a python backend :P [11:03] monokrome: I was considering tornado [11:03] V1: which is Socket.IO on tornado [11:03] monokrome: Oh, cool. [11:03] monokrome: Nice [11:03] V1: gnagno: You can build that functionality your self by extending the Listener of Socket.IO [11:03] voodootikigod has joined the channel [11:04] monokrome: ACTION thought that "tornadio" was a typo... but it's a project! :D [11:04] gnagno: V1, you mean I have to broadcast the message and each user will choose to accept or refuse it ? [11:04] V1: I'll upload a gist with an example [11:05] monokrome: Does the client degrade nicely to browsers without HTML5 sockets? [11:06] mlncn has joined the channel [11:07] markc_: davidcoallier: been away, so just pass on the incoming body to stdin of fastcgi... looking at this again with fresh eyes [11:07] V1: gnagno: https://gist.github.com/894207 [11:07] gnagno: V1, thank you so much I will study it now [11:08] jelveh has joined the channel [11:08] V1: The code assumes that connected "client" has a an array with "rooms" attached to it. [11:08] davidcoallier: markc_: I think so, alongside the content-length [11:08] gnagno: V1, oh this is server side great!!! I thought the only solution would be client side [11:10] eee_c has joined the channel [11:10] V1: Yups gnagno, implementing it client side would be a waste of bandwidth [11:12] gnagno: V1, yes, it was what I worried about [11:12] markc_: davidcoallier: ah, in connection.addListener() there is a body = parts[1]; and response.end(body); methinks some tinkering therabouts [11:12] gnagno: anyway I think node.js and socket.io are really great.... but they are lacking a bit of good documentation, specially the second one [11:13] fly-away: Trac vs. Redmine vs. JIRA vs. something - what can you advise for small projects and command up to 15 programmers? [11:14] gnagno: fly-away, I love redmine [11:14] markc_: davidcoallier: or is that what is coming back from fastcgi and it's the connection.end() in sendRequest() [11:14] fly-away: gnagno, and do you ever tryed track or jira? [11:15] gnagno: fly-away I was using trac for years, after you're used to trac redmine is like a breath of fresh air, it's a lot more modern and elegant, and moreover it's more functional [11:15] gnagno: I never used jira [11:15] V1: gnagno: what kind of documentation is missing? API ? Or more examples? [11:16] __tosh has joined the channel [11:17] gnagno: V1, for node.js the api is really complete and exaustive, but some more examples to help people starting would help.... you know I am the kind of person who prefears to study programming reading examples [11:17] gnagno: V1, for socket.io both exaustive api and examples are really something I miss [11:17] V1: gnagno: did you check out the Wiki on github for node.js? [11:19] gnagno: V1, I am reading it now, thanks [11:19] dnolen has joined the channel [11:19] seivan has joined the channel [11:19] V1: gnagno: As for Socket.IO a better API documentation is being worked on, I already documented the client and the server will be done soon as well. As for examples, these are some what harder to find indeed. We might need to add wiki page for that :p [11:19] logii: Any maintainer of Node.js Integration module on IRC? =) [11:20] gnagno: V1, I would like to help, but I am still studying it :) [11:20] gnagno: I've found this open source book on node.js but they stopped the development: http://visionmedia.github.com/masteringnode/ [11:20] dnolen has joined the channel [11:21] Charuru: V1 is there a timeline for channels in socket.io? [11:21] Charuru: i implemented my own, dunno if its any good :P [11:22] framlin: fly-away: we use JIRA (after mantis) and its very usable. But I we are about 30 Coders and 5 Product-Managers, so I do not know, if its good for 15 peaople, too [11:23] V1: Charuru: It's planned for 0.7, but there will probably be 0.6 final first. But both rauchg and me are working on it, so I can't say any "fixed" timelines for it.. But don't expect it to be done within a week ;) [11:23] MattJ has joined the channel [11:24] Charuru: ok :) thanks [11:24] Charuru: btw what are the plans for scalability? [11:25] piscisaureus: mraleph: for a cygwin build fix, should I add you again as a reviewer or is it better to pick another victim this time ;-) [11:25] mraleph: you can add me again :-) [11:26] chester has joined the channel [11:26] V1: Charuru: support for multiple socket.io processes is something that we planned in 0.7 [11:27] V1: This probably would include cluster.js support [11:27] astropirate: Getting this freaky error while making node: IOError: [Errno 13] Permission denied: '/home/user/Desktop/node-v0.4.4/build/debug/macros.py'. Anyone know whats going on? [11:27] Charuru: sounds great :) [11:28] V1: Multi server scaling will probably be done using ZemoMQ as additional dependency Charuru. But we are still discussing different ideas on tackling those issues [11:28] piscisaureus_ has joined the channel [11:30] Charuru: it's great that you guys are on top of it, hopefully by the time i need multiple server support it's in there, :) [11:30] okuryu has joined the channel [11:31] charlenopires has joined the channel [11:31] btipling has joined the channel [11:31] jacobolus has joined the channel [11:33] broofa has joined the channel [11:33] charlenopires_ has joined the channel [11:34] Kinbote has joined the channel [11:34] HerrTopf has joined the channel [11:34] troessner has joined the channel [11:34] muhqu has joined the channel [11:34] zorzar has joined the channel [11:34] rudebwoy has joined the channel [11:34] skm has joined the channel [11:36] fairwinds has joined the channel [11:38] liquidproof has joined the channel [11:40] MrTopf has joined the channel [11:41] heavysixer has joined the channel [11:44] StevenBlack has joined the channel [11:45] muhqu has joined the channel [11:45] StevenBlack has left the channel [11:46] zorzar has joined the channel [11:46] troessner has joined the channel [11:48] malkomalko has joined the channel [11:48] tiagoa has joined the channel [11:48] seivan has joined the channel [11:49] jasong_at_apache has joined the channel [11:50] micheil: are there any constructors in node's code base that take arguments? [11:50] micheil: hmm, yes. [11:51] skm has joined the channel [11:51] skm has joined the channel [11:52] SvenDowideit has joined the channel [11:52] masylum has joined the channel [11:52] skm has joined the channel [11:52] unomi has joined the channel [11:53] johnnywengluu: how do i get the path of current executable? [11:54] meandi2 has joined the channel [11:54] samcday: johnnywengluu, http://nodejs.org/docs/v0.4.4/api/process.html#process.execPath [11:55] johnnywengluu: samcday: that gives me node [11:56] samcday: Correct. That's the executable. [11:56] johnnywengluu: but im actually running an executable [11:56] johnnywengluu: how do i get my script path? [11:56] samcday: __dirname [11:56] johnnywengluu: yeah [11:56] johnnywengluu: thx [11:56] johnnywengluu: confusing [11:56] samcday: np [11:57] johnnywengluu: why not process.dirname() to keep it consistent =) [11:57] hwinkel has joined the channel [11:57] indutny has joined the channel [11:58] xandrews has joined the channel [11:59] tiemonster has joined the channel [12:00] shaunau has joined the channel [12:01] xandrews has joined the channel [12:01] k1ttty has joined the channel [12:01] romainhuet has joined the channel [12:01] whatcodecraves has joined the channel [12:02] xandrews has joined the channel [12:03] boaz has joined the channel [12:04] johnnywengluu: someone knows how i parse jsdoc comments? [12:04] johnnywengluu: never done parsing before [12:05] johnnywengluu: would be glad if someone could give me some hints [12:05] masylum: https://github.com/visionmedia/dox [12:05] masylum: I use this [12:05] masylum: to generate documentation out of jsdoc [12:06] matyr_ has joined the channel [12:06] johnnywengluu: actually that was not what i meant [12:06] johnnywengluu: hmm [12:07] cjavapro has joined the channel [12:07] johnnywengluu: i want to parse the jsdoc tags to extract @param {String} name Your name [12:08] johnnywengluu: so i can generate command line arguments eg: --name | -n Your name [12:08] cjavapro: Does anybody know how to Increase TCP's Initial Congestion Window to 10 segments in Node.JS on Solaris? This is practiced by Google and they have published a paper with their research: http://www.google.com/research/pubs/pub36640.html [12:09] muhqu_ has joined the channel [12:09] gaYak: Is node.js even taking care of that part, or the Solaris' TCP stack? [12:09] johnnywengluu: one way of doing it in my mind is to read the file .. then just search regexp. but is there a better way [12:10] cjavapro: @gaYak: I don't know. It seems like it would not, but Iain on ServerFault suggested it might be the application level which would suggest node.JS would be where to look. I am checking both routes. Here is my StackOverflow questioon on doing it in the application level. I have not received an answer but a suggestion to check here. http://stackoverflow.com/questions/5248559/node-js-on-solaris-increase-tcps-initial-congestion-window- [12:10] masylum: https://github.com/visionmedia/dox/blob/master/lib/dox/index.js#L242 [12:11] dominictarr has joined the channel [12:11] masylum: this is how dox parses the jsdoc [12:12] johnnywengluu: masylum: thanks ill look into it [12:20] malkomal_ has joined the channel [12:21] cjavapro: I guess nobody knows. If you know, please post on my StackOverflow Question. http://stackoverflow.com/questions/5248559 [12:22] matschaffer has joined the channel [12:22] wtt has joined the channel [12:23] wtt: yo! [12:23] shim`work: yo! [12:24] wtt: anyone got pointers for good examples of testing socket.io connections? im thinking similar to the way that assert.response from expresso works [12:24] V1: run the testcase? [12:25] V1: test suite* [12:26] hellp has joined the channel [12:26] perlmonkey2 has joined the channel [12:26] vckt has joined the channel [12:29] sinisa has joined the channel [12:29] sinisa: hi all [12:29] wtt: nice [12:29] micheil: fuck yeah! new doctool here we come! https://gist.github.com/1a293ef46d65ca10d373 [12:29] micheil: (just got it working after hacking on and off on it for 2-3 months) [12:30] micheil: johnnywengluu: dude, out of code docs ftw. (see link just above) [12:30] sinisa: ppl.. is it possible this: connect via socket to another node.js, get js code from it, eval it and start it..? [12:31] robhawkes has joined the channel [12:31] johnnywengluu: micheil: what is that? [12:31] micheil: johnnywengluu: so, the node.js documentation, I wrote my own format for it [12:32] johnnywengluu: how does it work? [12:32] wtt: V1: so you're thinking my app.js should not do io.listen(httpServer) [12:32] micheil: essentially something suited to node.js [12:32] micheil: it uses a line by line parser / tokenizer, plus a fancy tree looping mechanism. [12:32] wtt: but how would i go about attaching listeners [12:32] micheil: need to still test performance of the tool. [12:32] jroes: sinisa: I think dnode may be what you're looking for [12:32] sinisa: dnode? [12:33] jroes: sinisa: https://github.com/substack/dnode [12:33] micheil: hmm.. node sample/run-sample.js 0.09s user 0.02s system 86% cpu 0.129 total [12:33] dominictarr has joined the channel [12:33] micheil: too many while loops for now.. [12:33] sinisa: jroes: i have clients and want to serve all them code for executing it... [12:33] lukegalea has joined the channel [12:34] micheil: it's blazing fast, but it does hurt the CPU. [12:35] sinisa: jroes... dnode looks like calling functions remotely.. i want to send to client functions :) [12:35] johnnywengluu: micheil: its based on jsdoc tags? [12:36] micheil: johnnywengluu: some what [12:36] sinisa: they are empty on a startup, just socket to connect, get code from main server and start it [12:36] micheil: johnnywengluu: asides from the Event and Property types [12:36] tyler_boyd has joined the channel [12:37] micheil: (it's good to be able to make that distiction, between a property, event, method and constructor [12:38] MaxguN has joined the channel [12:39] SubStack: sinisa: dnode works both ways [12:39] SubStack: it's bidirectional and symmetric [12:39] piscisaureus has joined the channel [12:39] perlmonkey2: Google really needs to add node support to GAE. [12:40] micheil: johnnywengluu: this is the actual tool: https://github.com/miksago/node-doctool/tree/new [12:40] wtt: my issue is that i need to call var socket = io.listen(app) to be able to add functionality (e.g. socket.on('connection', fun.. )) within my app - so how do i go about testing my socket-listeners ? [12:40] sinisa: have to study it a little :) [12:42] SubStack: oh you want to send the functionas in Function.prototype.toString? [12:42] SubStack: why would you want to do that? [12:43] misterncw has joined the channel [12:44] jscheel has joined the channel [12:44] jscheel has joined the channel [12:44] fumanchu182 has joined the channel [12:45] eventi has joined the channel [12:46] johnnywengluu: micheil: you have a good algorithm of how to parse the comment blocks? /* */ [12:46] skm has joined the channel [12:47] micheil: I don't parse comment blocks. [12:47] micheil: Code is unreliable. [12:47] johnnywengluu: what do you parse then? [12:47] skm has joined the channel [12:48] sinisa: substack.. was that question for me? [12:48] lupomontero has joined the channel [12:49] micheil: johnnywengluu: these plain text files. [12:49] micheil: example: https://github.com/miksago/node-doctool/blob/new/sample/fs.nd [12:49] mattmcmanus has joined the channel [12:50] micheil: ryah: I have a solution to your problem with the format not displaying correctly on github: use an alternative file extension, I've been using .nd which displays as plain text. [12:50] eb4890 has joined the channel [12:50] jetienne: micheil: is there a way to export the doc in json ? [12:50] micheil: jetienne: yes, there will be [12:50] jtsnow has joined the channel [12:51] jetienne: micheil: rought eta ? [12:51] micheil: it generates to a JS object tree first, then it'll export to JSON [12:51] jetienne: micheil: oh so it is just a JSON.stringify() to add somewhere ? [12:51] micheil: jetienne: here's what you get: https://gist.github.com/1a293ef46d65ca10d373#file_gistfile1.js [12:51] micheil: yeah [12:51] jetienne: micheil: ok cool thanks [12:52] micheil: it's one of those holy-shit-this-can-be-awesome tools [12:52] jimt_ has joined the channel [12:52] micheil: here we say hello to rich documentation with advanced search features for node.js [12:52] jetienne: micheil: yep navigation is key [12:52] micheil: yep. [12:53] micheil: that's part of the reason I told people to hold off on adding tocs and sidebars and redesigning the documentation [12:53] SubStack: sinisa: yep! you want to *send* client functions? [12:53] SubStack: as in, their sources? [12:54] dominictarr has joined the channel [12:54] micheil: jetienne: only drawback to the tool is that for 16 thousand lines it's 4.61 seconds of machine time and 98% cpu usage. [12:54] micheil: (large amount of object creation and shit) [12:55] jetienne: micheil: not that important, generating doc isnt a frequent event [12:55] micheil: :D [12:55] micheil: for our entire documentation it'd probably still take < 10 seconds. [12:55] micheil: but the entire documentation isn't in the new format yet. [12:57] micheil: jetienne: I should probably add some statistics into the tool, just because stats are awesome. [12:57] bradleymeck: can anyone think of a situation where url.parse(req.url) would have a hostname for http? [12:57] micheil: also, don't paste 16,000 lines or more into textmate, it's just utter fail. [12:58] shaunau has joined the channel [13:00] jetienne: micheil: good idea. url from the doc to the code ? like this function is defined here. dunno if it is possible... [13:00] micheil: url from doc to code, as in? [13:01] bx2 has joined the channel [13:01] micheil: tip, in Module: File System (fs), the part in brackets in the module require-name [13:03] norviller has joined the channel [13:03] kriszyp has joined the channel [13:04] jetienne: micheil: as in the doc explain fs.readSync and give an https://github.com/joyent/node/blob/master/lib/fs.js#L246 [13:04] Horofox has joined the channel [13:04] davidsklar has joined the channel [13:04] tylergillies has joined the channel [13:04] micheil: hmm, so direct referencing of line numbers? [13:05] jetienne: micheil: yep reference to the actual implementation. [13:05] micheil: to manually do it would be a tonne of work to maintain [13:05] jetienne: micheil: yep. so it need to be automatic. not sure how you currently extract doc [13:05] micheil: to automatically do it would be more then likely impractical without some for of code analysis tool [13:05] jetienne: micheil: ok so not for now [13:05] micheil: documentation is currently written in separate files [13:06] micheil: reason? you could easily in your code have a regex like /*\n/ [13:06] jetienne: micheil: what about adding comment ? like poeple can comment on the doc. and doc writer use this to improve doc... and doc users use other comments to understand [13:06] eyesUnclouded has joined the channel [13:06] micheil: that'd get picked up by a dumb parser as a block comment [13:06] jetienne: php doc got comments [13:06] micheil: jetienne: nothing stops people building tools on top of this format. [13:07] jetienne: micheil: ok [13:07] jetienne: just suggesting [13:07] jetienne: going back to arenajs 'where javascript coders fight' :) [13:07] micheil: the idea is purely to be for converting from plaintext to a JS Object, from there it can go to N number of formats. [13:09] jetienne: clean hackable. good [13:09] micheil: that's the biggest thing that annoyed me about the markdown implementation. [13:09] micheil: it wasn't hackable at all. [13:11] micheil: jetienne: should lists be native to the documentation format? [13:11] micheil: as with headings? [13:13] jlecker has joined the channel [13:13] jetienne: micheil: list ? which list [13:14] micheil: lists, as in - foo\n- bar [13:14] micheil: https://github.com/miksago/node-doctool/blob/new/sample/fs.nd#L465-473 [13:14] micheil: currently that's treated as just paragraph [13:15] luke` has joined the channel [13:15] heythisisdave has joined the channel [13:16] luke`_ has joined the channel [13:16] jetienne: micheil: explicit list will be more hackable i think. like if i want to do a toc with link on all the "subfunction". [13:17] astropirate: What unit testing framework are people using now-a-days? [13:18] framlin: printf ;) [13:18] astropirate: :O [13:18] micheil: jetienne: I'll add it in later then. [13:18] micheil: (anything that's a line-by-line type thing is fairly easier to do. [13:20] samcday: Man, C threading can suck me ... [13:20] SubStack: indeed [13:20] SubStack: I hate threads. [13:21] samcday: Well yeah me too, but it's even worse when you don't have nice abstractions layered over them. [13:21] samcday: Sitting here working with mutexes makes me want to /wrist [13:21] SubStack: so many annoying edge cases you've got to keep in the back of your mind all the time while hacking [13:21] samcday: Yeah [13:21] samcday: Especially so when I'm supporting both async and sync in these bindings I'm writing [13:21] samcday: Double the trouble for potential sticky edge cases :D [13:22] samcday: It helps to just sit there and do a brain dump in notepad, think through all the stuff. But it still sucks. :P [13:22] bzinger has joined the channel [13:22] micheil: jetienne: can has some warnings for deprecations now.. [13:24] jetienne: micheil: super, it would help keep the code running when node bumps api [13:24] micheil: by deprecations, I mean tool deprecations [13:25] micheil: like Class: -> Constructor: [13:25] boaz has joined the channel [13:26] micheil: example: { line: 15982, [13:26] micheil: message: 'Usage of identify `Class:` is now deprecated, please use `Constructor:` instead.' } [13:27] skohorn has joined the channel [13:28] edude03 has joined the channel [13:30] vckt has joined the channel [13:31] bradleymeck: whats the best configuration and role modules do you guys think? [13:31] bitmonk has joined the channel [13:31] mbrochh has joined the channel [13:31] mbrochh has joined the channel [13:32] marlun: I'm having some problems with https://gist.github.com/894372 the second console.log shows the same name from the last iteration. I figure because of the async name has allready changed to the value it got in the last iteration when the readFile callback is run but how would I solve it? I also know the nestling doesn't look good but I want this to work before I look into libraries which can help me with that. [13:35] mikegerwitz: marlun: ( function( name ) { /* fs code here */ } )( name ) ..preferably rename the argument to something else to avoid confusion [13:35] mikegerwitz: marlun: I'm not sure if that's what you're looking for. A little confused by your question. That will ensure that name is the same as the file that was read. [13:35] bradleymeck: closures, the bane of for loops everywhere [13:36] amacleod has joined the channel [13:36] baudehlo has joined the channel [13:37] dominictarr has joined the channel [13:37] Poetro has joined the channel [13:38] luke` has joined the channel [13:39] Venom_X has joined the channel [13:41] marlun: mikegerwitz: I use the name on line 36 and right now name has the same value in the second console.log but different in the first. [13:41] marlun: mikegerwitz: will try what you said in a while, thanks :) [13:43] nonnikcam has joined the channel [13:43] pdelgallego has joined the channel [13:43] vckt has joined the channel [13:47] neshaug has joined the channel [13:47] Yuffster has joined the channel [13:48] fmarceau has joined the channel [13:49] Sorens3n has joined the channel [13:49] samcday: Lol, my first pointer to a pointer to a pointer [13:49] muk_mb has joined the channel [13:50] samcday: Triple indirection, setting an array of pointers via a pointer -_- [13:50] bradleymeck: that makes me a sad panda to have more than 2 levels of indirection :( [13:50] willwhite has joined the channel [13:51] jtsnow has joined the channel [13:51] samcday: Actually, I think I might be able to avoid it after all. thank god lol [13:51] Remoun has joined the channel [13:52] jy0ung has joined the channel [13:52] xandrews has joined the channel [13:54] flasomm has joined the channel [13:54] eaton has joined the channel [13:54] flasomm: hello all [13:55] flasomm: I've got a strange error after a node app.js : TypeError: Object [object Function] has no method 'conditionalGet' Any suggestions ? [13:55] strmpnk has joined the channel [13:55] flasomm: I think it's related to connect [13:56] yhahn has joined the channel [13:57] dahankzter has joined the channel [13:58] SubStack: samcday: doing that sort of thing would be awesome in javascript but horrible in c++ [13:58] samcday: SubStack, threading you mean? [13:58] SubStack: pretty sure I've done graph traversals of function-object attributes before [13:58] bradleymeck: flasomm conditionalGet middleware was removed in recent express [13:58] SubStack: I mean pointer/reference trickery [13:58] samcday: Ah yeah [13:58] samcday: Pointers in javascript .... *shudder* [13:59] bradleymeck: you mean ... arrays? bwahahaha [13:59] samcday: No I mean actual pointers :P And heap allocations [13:59] timmywil has joined the channel [13:59] samcday: Who needs memory management anyway! [13:59] flasomm: bradleymeck: ok, so I have to réinstall it ? [13:59] bradleymeck: if you want it [13:59] flasomm: ok thx [14:00] marsha has joined the channel [14:01] timcosgrove has joined the channel [14:03] jimt has joined the channel [14:05] timcosgrove has left the channel [14:05] demolithion has joined the channel [14:06] aheckmann has joined the channel [14:06] Clooth has joined the channel [14:07] ivanfi has left the channel [14:07] icebox has joined the channel [14:08] dominictarr has joined the channel [14:08] Vladimir1 has joined the channel [14:09] dominictarr has joined the channel [14:09] k1ttty has joined the channel [14:10] sivy has joined the channel [14:11] sivy has joined the channel [14:12] sirkitree has joined the channel [14:15] akahn has joined the channel [14:19] saschagehlich has joined the channel [14:19] davidvanleeuwen has joined the channel [14:20] akahn has left the channel [14:20] javaanse_jongens has joined the channel [14:20] EyePulp has joined the channel [14:23] rolando__ has joined the channel [14:24] muk_mb has joined the channel [14:24] muhqu has joined the channel [14:25] Chunk has left the channel [14:28] kuya: can anyone recommend an option parsing lib thats not going to piss me off in the next 5 mins? [14:28] kuya: :) [14:29] kuya: js-opts and optparse have both just failed that requirement [14:29] yhahn: node-optimist? [14:30] kuya: are you willing to accept my wrath if i dont like it? ;D [14:30] yhahn: no [14:30] kuya: ;) [14:31] konobi: https://github.com/isaacs/nopt ? [14:35] SubStack: kuya: do you hate optstrings? [14:36] kuya: nopt looks nice! [14:36] noocx has joined the channel [14:36] noocx: re [14:37] robotarmy has joined the channel [14:37] Samot: baby hit me with an encoreee [14:39] shiawuen has joined the channel [14:39] baudehlo has joined the channel [14:39] kuya: konobi: take a prize [14:40] marsha: hello, does anyone know a feed(rss|atom) client/parser lib? [14:40] SubStack: require('optimist').argv, receieve options [14:41] SubStack: enjoy options [14:43] DanoManion has joined the channel [14:43] konobi: throw("HA... take that... serves you right for being an optimist") [14:43] lessthanzero has joined the channel [14:44] baudehlo: how do I catch EADDRINUSE on http.createServer().listen(port, hostname, callback)? Do I need to use try/catch? [14:45] baudehlo: seems nonpossible :-/ [14:45] tiagoa has joined the channel [14:46] BillyBreen has joined the channel [14:46] jimt_ has joined the channel [14:47] devdazed: hi all, im having issues install node 0.4.4 via nvm on a CentOS machine. [14:47] devdazed: node 0.4.3 installed fine on this machine, this was just a simple upgrade [14:47] devdazed: it's failing on libv8.a [14:47] SubStack: baudehlo: server.on('error', fn) [14:47] devdazed: Build failed: -> task failed (err #2): [14:47] devdazed: {task: libv8.a SConstruct -> libv8.a} [14:47] devdazed: the full trace can be found here: http://pastie.org/1735358 [14:47] hij1nx has joined the channel [14:48] baudehlo: SubStack: ah, so this is just EBADDOCUMENTATION then :) [14:48] mattrobenolt has joined the channel [14:48] eyesUnclouded has joined the channel [14:48] jonaslund: devdazed: did you do ./configure | make _ [14:48] jonaslund: ? [14:48] devdazed: no, i did nvm install v0.4.4 [14:48] devdazed: i use nvm to manage my nodes [14:49] bitmonk has joined the channel [14:49] BigWookie has left the channel [14:49] JianMeng has joined the channel [14:49] jonaslund: ok no experience with that [14:49] devdazed: did any of the base requirements change from 0.4.3 to 0.4.4? [14:50] [AD]Turbo has joined the channel [14:50] jonaslund: btw.. what does people use when hosting multiple domains and node? nginx ? [14:50] devdazed: i use nginx [14:50] mattrobenolt: +1 for nginx [14:50] saschagehlich: +1 for nginx [14:50] saschagehlich: ;) [14:50] jonaslund: i still use apache [14:50] ph^ has joined the channel [14:50] devdazed: for multiple domains and so i can have multiple node processes running on different ports and nginx load balances them [14:51] halfhalo: +1 for special nginx confg [14:51] jonaslund: and i think i'd continue using it for https since i run svn [14:51] mattrobenolt: @jonaslund aren't you defeating a lot of the benefits of Node by running it behind Apache? ;) [14:51] c4milo has joined the channel [14:51] devdazed: is ryah in ? [14:51] jonaslund: mattrobenolt: well i've not put any node stuff into production yet so [14:52] losing has joined the channel [14:52] jonaslund: mattrobenolt: right now my most important service is some old web pages and my subverison repos [14:52] HerrTopf has joined the channel [14:52] konobi: pound is a decent option [14:53] mattrobenolt: @jonaslund Fair enough. You just won't want to use that for anything that is expecting a fair amount of traffic. [14:53] mattrobenolt: You'd be better off using Nodester or something for free anyways. :) [14:53] miccolis has joined the channel [14:54] jonaslund: well apache is way dead in the water for me anyhow since the stuff i'm developing does async stuff [14:55] konobi: putting node behind nginx, you lose long-polling [14:56] konobi: (since nginx only does HTTP 1.0 to backend servers, so no keep-alive) [14:56] slickplaid has joined the channel [14:57] trotter has joined the channel [14:57] halfhalo: ACTION has it setup so that when he adds a node app to his sever its automatically assigned two port numbers, one for nginx and one for any websocket/longpolling stuff [14:57] mattrobenolt: @konobi I haven't seen that in my case, and we use it for long polling. [14:57] MikhX has joined the channel [14:58] mattrobenolt: nginx 0.8.x [14:58] sourcode has joined the channel [14:58] nivoc has joined the channel [14:59] jakehow has joined the channel [14:59] konobi: mattrobenolt: hhhmmm... perhaps... has been a while since I played with it [14:59] jonaslund: halfhalo: hmh.. how does that work with firewalls and stuff ? [14:59] Poetro has joined the channel [14:59] halfhalo: ACTION just has to finish his gitosis admin web app and then he can start working on containering his apps [15:00] mattrobenolt: @konobi I could be mistaken, but why would keep-alive be essential for long polling? Keep-Alive is something different. [15:00] Me1000 has joined the channel [15:01] dominictarr has joined the channel [15:01] halfhalo: jonaslund: depends. its usually a port in the 4000 range, and I have only had an app use it once [15:01] mattrobenolt: Keep-Alive, at least in Apache terms, was needed so that connections weren't reinitiated for tons of small requests across static files, subsequent requests, etc because Apache was so heavy. [15:01] jonaslund: keep-alive as an idea is good [15:02] mattrobenolt: It would keep each connection alive behind the scenes for X amount of seconds incase the user requested another page, it'd use the same connection. Not the same thing for long polling. [15:02] dominictarr has joined the channel [15:02] jonaslund: not just in terms of process reinitialization [15:02] mattrobenolt: For long polling, you just don't send output for a while and let the server hang. There's nothing in Nginx that would kill that automatically, except a max connection length. [15:02] syskk has joined the channel [15:02] halfhalo: I really do wish there was something like heroku for php... [15:02] konobi: mattrobenolt: depends on what you mean by long-polling... it's a somewhat overloaded term now [15:03] fermion has joined the channel [15:03] gozala has joined the channel [15:03] mattrobenolt: Long polling… in terms of like, a real time chat or something of that sort. Where you use AJAX to do a makeshift websocket. [15:03] dustym has joined the channel [15:03] mattrobenolt: @konobi Do people use it to mean other things now? haha, I was unaware. [15:04] yozgrahame has joined the channel [15:04] mikl has joined the channel [15:04] syskk: I'm reading V8's embedder guide and would likee to build a Node.js extension. I cannot however find the way to set properties on an object in my constructor function [15:04] alex_b has joined the channel [15:05] syskk: from V8's doc: point_templ.SetAccessor(String::New("x"), GetPointX, SetPointX); [15:05] syskk: I'm not sure what is point_templ in node's ObjectWrap [15:05] konobi: mattrobenolt: all the backend transports that socket.io has... people commonly refer to any of those as long poll [15:05] codivan has joined the channel [15:05] TheFuzzball has joined the channel [15:05] mattrobenolt: Oh, like websockets and the iframe technique, etc? [15:06] mattrobenolt: (I'm not very familiar with socket.io) [15:06] tbranyen: konobi: they do? [15:06] tbranyen: long polling is a specific form of COMET [15:06] tbranyen: which is the term you were probably thinking of [15:06] charlenopires has joined the channel [15:06] k1ttty has joined the channel [15:07] mattrobenolt: tbassetto: Yes. Comet is the same deal. :) [15:07] konobi: tbranyen: tell that to everyone [15:07] onre has joined the channel [15:08] charlenopires has joined the channel [15:08] ceej has joined the channel [15:08] V1 has left the channel [15:08] brianm has joined the channel [15:08] brianm has joined the channel [15:08] konobi: "Does nodejs support long polling"... "You mean websockets... yes" [15:08] mattrobenolt: I used to use this for nginx before Node: http://pushmodule.slact.net/ [15:08] mattrobenolt: Sketchy as fuck. :( [15:08] sub_pop has joined the channel [15:09] baudehlo: is there an equivalent in JS/Node to #line? [15:10] mattrobenolt: baudehlo: Link for #line? I've never heard of that. [15:10] jetienne: baudehlo: to get the current line of the script as a string ? [15:10] stagas has joined the channel [15:11] jetienne: baudehlo: no. i miss it too [15:11] baudehlo: mostly to set it. [15:11] baudehlo: as I'm doing runInNewContext() to compile a plugin... but putting some boilerplate at the top. [15:12] baudehlo: so when I get errors I get the wrong line number. [15:12] konobi: arguments.callee.caller.line ? [15:12] mattrobenolt: Wow. I was way off, hahaha [15:12] jetienne: baudehlo: a trick is to make the plugin as a single line [15:12] Aikar: baudehlo: check node source [15:12] jetienne: baudehlo: and to put the first instruction of your file on the same line [15:12] Aikar: baudehlo: node also injects code on top of your module, so it has to auto correct line #s [15:13] baudehlo: Aikar: yeah I suspect it does that in C++ though. [15:13] davidascher has joined the channel [15:13] Aikar: nope [15:13] jetienne: Aikar: any keyword to get more info on this [15:13] Aikar: check lib/module.js [15:13] eirikurn has joined the channel [15:14] mattrobenolt: Anyone have any good resources for beginning to write plugins for V8? [15:14] Aikar: actually the line # stuff isnt in module.js [15:14] Aikar: src/node.js i think [15:14] dominictarr has joined the channel [15:15] Aikar: hmm doesnt appear to be i nthere either. i know i saw it somewhere [15:15] dgathright has joined the channel [15:15] baudehlo: lol [15:15] devinus has joined the channel [15:15] jetienne: Aikar: ok when you find it again, tell me :) [15:15] isaacs has joined the channel [15:16] unflores has joined the channel [15:16] wilmoore has joined the channel [15:16] mikegerwitz: Aikar: Are you referring to node's wrapping of CommonJS modules? It just prepends a closure without a newline [15:17] baudehlo: yeah I guess I could prepend without a newline. [15:17] Aikar: mikegerwitz: i know i saw code somewhere about adjusting line # [15:17] jetienne: this is what i do with brequire and dropinrequire [15:17] tk has joined the channel [15:18] kuhrt has joined the channel [15:18] river_t has joined the channel [15:18] jetienne: it is simple and the likelyhood to get an error on the first line isnt too big [15:19] tanepiper: ha ha ha ha http://blog.nacode.com/2011/03/03/php-built-in-web-server/ [15:19] devdazed: Hi alll, I can't seem to get node 0.4.4 to build on a 32 bit machine. I previously had 0.4.3 installed. i am using nvm [15:19] devdazed: http://pastie.org/1735358 [15:19] tanepiper: i think php feel threatened by node :D [15:19] Aikar: O.o where the hell is native_module now? [15:20] freakyfractal has joined the channel [15:20] Aikar: oh right src/node [15:20] HerrTopf has joined the channel [15:20] colinclark has joined the channel [15:20] mraleph: devdazed: open deps/v8/SConstruct, search for -O3, add -fno-strict-aliasing near that place. [15:21] freakyfractal has left the channel [15:21] jetienne: devdazed: if you want i got a ubuntu .deb for 0.4.4 [15:21] devdazed: im using centos, i was hoping to let nvm install it [15:22] evanmeagher has joined the channel [15:23] ohtogo has joined the channel [15:24] christophsturm has joined the channel [15:25] jetienne: devdazed: so to follow mraleph instructions is your best chance [15:25] ckknight has joined the channel [15:26] mraleph: piscisaureus: ping [15:26] piscisaureus: mraleph: pong [15:26] broofa has joined the channel [15:26] rfay has joined the channel [15:27] mraleph: piscisaureus: I thought you change with -fno-strict-aliasing detection was in node. but apparently people still have some problems [15:27] mraleph: devdazed: what does your gcc -v say? [15:27] rfay has joined the channel [15:27] evanmeagher has joined the channel [15:27] piscisaureus: mraleph: yes it is in node [15:28] devdazed: mraleph: i changed the SConstruct in the ~/.nvm/src/node-v0.4.4 and retarballed it and it seems to be building again [15:28] piscisaureus: or maybe it got backed out on the last v8 upgrade, I'll check [15:28] ryanfitz has joined the channel [15:28] eb4890 has joined the channel [15:28] dominictarr has joined the channel [15:28] piscisaureus: no, it's still there [15:29] mraleph: hmm [15:29] mraleph: devdazed: which gcc version does your CentOS box have? [15:30] devdazed: gcc version 4.4.4 20100726 (Red Hat 4.4.4-13) (GCC) [15:30] mraleph: hmm [15:30] mraleph: thanks [15:30] devdazed: np [15:30] devdazed: mraleph: would you like to see what it was configure with also? [15:30] piscisaureus: mraleph: It is only supposed to set no-strict-aliasing for gcc 4.5.* [15:30] stagas has joined the channel [15:31] mraleph: devdazed: nope [15:31] mraleph: piscisaureus: yep I understand that. [15:31] mraleph: piscisaureus: evil strict aliasing strikes back every now and then. [15:32] piscisaureus: mraleph: no offense, but I think that v8 actually does break strict aliasing rules :-) [15:32] mraleph: that is true [15:33] tjholowaychuk has joined the channel [15:33] mraleph: but places where V8 does that are nicely localized. [15:33] piscisaureus: only gcc 4.4 is not smart enough to optimize at those points so you can safely have strict aliasing on [15:33] bitmonk has joined the channel [15:33] mraleph: gcc 4.5 is also smart enough to do correct optimization [15:33] mraleph: there problem is that they actually have the bug [15:33] sprout has joined the channel [15:34] mraleph: in their aliasing analysis [15:34] piscisaureus: what is the bug exactly? [15:34] galaxywatcher has joined the channel [15:34] softdrink has joined the channel [15:35] piscisaureus: is it localized to one specific spot in the code? [15:36] reid has joined the channel [15:36] useware has joined the channel [15:36] darshanshankar has joined the channel [15:36] mraleph: when propagating aliasing information through builtin memcpy they lose part of it... so if you have pointer p and you copy it's value into pointer q through memcpy, then sometimes q does not inherit correct aliasing information from p. [15:37] perezd has joined the channel [15:37] vipaca has joined the channel [15:37] mraleph: and gcc starts to think that q can only point to locals or something like that. so all writes through q that have no corresponding reads through q suddenly disappear into void. [15:38] piscisaureus: hmm [15:38] piscisaureus: if you would know where it happens you could work around it [15:38] mraleph: the problem here is that we use memcpy to trick gcc to think that there is no strict aliasing violations :-) [15:38] piscisaureus: e.g. copy the pointer into another that is declared volatile [15:39] mraleph: if we remove memcpy from that bad place, it breaks because it starts complaining about strict aliasing violations. [15:39] mraleph: volatile does not help. [15:39] isaacs: tanepiper: i dunno. this is putting php in even more places :) [15:39] isaacs: why would that be threatening? [15:40] mraleph: there is no salvation :-) [15:41] piscisaureus: hmm. If you say so I will believe you [15:42] piscisaureus: I would try stuff like [15:42] piscisaureus: volatile int x = 0; [15:42] piscisaureus: *(ptr + x) = *ptr; [15:42] eresair has joined the channel [15:42] mraleph: compiler can see through that. if x is local. [15:43] piscisaureus: the fucking bastard [15:43] teemow has joined the channel [15:43] piscisaureus: maybe an asm statement [15:46] yozgrahame has joined the channel [15:47] bradleymeck has joined the channel [15:47] stagas has joined the channel [15:47] Guest74359 has joined the channel [15:49] flippyhead has joined the channel [15:50] pdelgallego has joined the channel [15:51] piscisaureus: instead of memcpy [15:53] Yuffster_work has joined the channel [15:54] eb4890 has joined the channel [15:57] mike5w3c_ has joined the channel [15:58] piscisaureus: mraleph: where is that offending memcpy? [15:58] mraleph: in BitCast [15:58] mraleph: which is used in Handle<>::cast() [15:59] jakehow has joined the channel [15:59] timcosgrove has joined the channel [15:59] timcosgrove has left the channel [16:00] mraleph: we do not want to have any assembly [16:00] mraleph: there [16:00] mraleph: cause we whant it to be no-op [16:01] nciagra has joined the channel [16:02] dominictarr has joined the channel [16:02] marcosvm has joined the channel [16:03] stagas has joined the channel [16:03] zakabird has joined the channel [16:04] dominictarr has joined the channel [16:04] some1else has joined the channel [16:04] micheil: mraleph: hey, are you good with statistics by any chance? [16:05] mraleph: I can add some numbers together [16:05] mraleph: whats the question? [16:05] micheil: okay, so, if I have an exponential amount of variable assignments [16:06] micheil: and as this number of assignments increases, my application gets slower, what could you think of to try and optimise these assignments (currently they are working with something as an object's member, this.current) [16:07] piscisaureus: mraleph: I think you can also get around the strict aliasing warning at that point with something like #pragma diagnostic [16:08] piscisaureus: #pragma GCC diagnostic ignored "-Wstrict-aliasing" [16:08] piscisaureus: probably [16:08] mraleph: micheil: I would think about decreasing number of assignments :-) [16:08] micheil: mraleph: only I can't. [16:08] micheil: i need them to keep state [16:08] mraleph: hmm. but why exponential? [16:09] micheil: https://github.com/miksago/node-doctool/blob/new/lib/parser.js [16:09] mraleph: it's a bit hard to reason about the code without specifics. [16:09] mraleph: ah [16:09] mraleph: let me see [16:09] micheil: see all the this.current assignments? [16:09] devrim has joined the channel [16:09] micheil: it's basically the only way I could think of to reliable keep the current tree node [16:10] micheil: it bashes your CPU a bit when it runs, but it's still fast [16:10] pandeiro has joined the channel [16:10] micheil: I want to make it a little less CPU intensive [16:10] Aikar: does it use multi cores? :P [16:10] micheil: the OS seems to load balance it, but otherwise no [16:11] mraleph: whats bad about using 100% of CPU? [16:11] seanouimet has joined the channel [16:11] Aikar: MAH MEGAHURTZ [16:11] tschundeee has joined the channel [16:11] dominictarr has joined the channel [16:12] mraleph: let me just clone your repo and play a bit with it. [16:12] micheil: mraleph: I'd just rather I didn't. If there's a better way to do it, I'm all ears [16:12] galaxywatcher has joined the channel [16:12] micheil: mraleph: I'll just commit the latest [16:12] daniellindsley has joined the channel [16:13] micheil: done. [16:13] tjholowaychuk: micheil: trying to unroll the parser? why though? it's just docs [16:13] tjholowaychuk: faster is always good [16:13] tjholowaychuk: but its not a huge deal for docs [16:13] fictorial has joined the channel [16:13] micheil: tjholowaychuk: yeah, but I have a feeling that I'm doing it wrong. [16:14] llkazu has joined the channel [16:14] tjholowaychuk: micheil: why not just stick with recursive descent? [16:14] micheil: 16,000 line document, and we get up to something like 4.61 seconds lag, and only 3 lines / second [16:14] tjholowaychuk: yikes [16:14] micheil: recursive descent? [16:14] tjholowaychuk: one sec [16:14] mraleph: micheil: what should I do to run it? node sample/run-sample.js ? [16:15] llkazu: holy crap, what are you doing that you can only process 3 lines/second? (i missed the first part of the convo) [16:15] micheil: yet on a 1000 line document 0.12 seconds, 19 lines per second. [16:15] micheil: mraleph: yeah [16:15] tjholowaychuk: i forget the syntax you are parsing [16:15] micheil: see sample/fs.nd [16:15] tjholowaychuk: i guess you might not need something recursive, probably just some splits [16:16] mraleph: micheil: TypeError: Cannot read property 'description' of undefined [16:16] micheil: tjholowaychuk: the flow of a document: https://github.com/miksago/node-doctool/blob/new/node-relationships.txt [16:16] micheil: :/ [16:16] micheil: works for me.. [16:16] micheil: mraleph: check out the new branch [16:16] vjvjftft has joined the channel [16:17] brianloveswords has joined the channel [16:17] dingomanatee has joined the channel [16:17] mraleph: micheil: ok it works. now where can I get big document? [16:17] micheil: mraleph: or do a git pull on master [16:17] nibblebot has joined the channel [16:17] mraleph: like 10000 or whatever lines you need [16:18] micheil: mraleph: for a large document, just duplicate the content in fs.nd a few times [16:18] micheil: (that's the only way I have for it atm [16:18] norviller has joined the channel [16:19] mraleph: ok [16:20] rfay has joined the channel [16:20] jelveh_ has joined the channel [16:20] mraleph: so micheil [16:20] mraleph: judging from the profile [16:20] mraleph: 8726 42.4% 48.8% LazyCompile: *substr native string.js:648 [16:20] mraleph: 1685 8.2% 9.4% LazyCompile: ~substr native string.js:648 [16:20] mraleph: you create too much substrings somewhere. [16:21] Shrink has joined the channel [16:21] unlink has joined the channel [16:21] jelveh_ has joined the channel [16:21] beawesomeinstead has joined the channel [16:21] mraleph: 8726 100.0% LazyCompile: *Lexer.consume /usr/local/google/home/vegorov/src/temp/node-doctool/lib/lexer.js:26 [16:22] micheil: mraleph: in which case tjholowaychuk's jade will suffer the same problem [16:22] eirikurn_ has joined the channel [16:22] tjholowaychuk: micheil: yes, but it's irrelevant [16:22] tjholowaychuk: templates are parsed only once [16:22] mattrobenolt: When performing a regex match many many times, do you guys ever actually compile() it? I don't seem to get any benefit from it. [16:22] noahcampbell has joined the channel [16:22] tjholowaychuk: it's not designed to compile fast [16:22] harth has joined the channel [16:23] k1ttty has joined the channel [16:23] micheil: mraleph: hmm, so I need a way of searching a document then, in a fast and reliable manner [16:23] tjholowaychuk: micheil: it's a convenience thing, recursive descent is not the ideal way to parse operator prescedence either, but it's simple [16:23] tjholowaychuk: it just doesn't matter for things that compile once [16:23] tjholowaychuk: if you optimize like mad, it ends up being a 4k file to parse a few tiny strings like node's http parser [16:24] steffkes has joined the channel [16:24] micheil: tjholowaychuk: but at the same time, I'd like to have only reasonable cpu usage on a large amount of data [16:24] micheil: eg, 50%, instead of 100% [16:25] tjholowaychuk: IMO it doesnt matter, you dont parse docs every 10 seconds [16:25] mraleph: micheil: ah, I see the problem. you are using substring to cut away consumed part. heh. no surprise that it's slow. [16:25] micheil: mraleph: any suggestions then? ;P [16:25] tjholowaychuk: micheil: look at ejs [16:25] Aikar: micheil: use a buffer and do slice? [16:25] tjholowaychuk: for another example [16:25] mraleph: or write your own sliced strings. [16:25] Aikar: slice just shifts the offset [16:25] mraleph: or implement slices in V8. [16:26] mraleph: V8 had them some time ago [16:26] mraleph: but then they were removed [16:26] Aikar: var str = new Buffer(str); [16:26] Aikar: str = str.slice(10); [16:26] Aikar: doesnt modify memory, just adjusts offset [16:26] Aikar: then str.toString() [16:27] micheil: buffer's don't have regex. [16:27] Aikar: str.toString.regex? [16:27] Aikar: ()* [16:27] micheil: that's going to be creating a thousand and one buffers [16:27] TheFuzzball has joined the channel [16:28] micheil: mraleph: there has to be a fast way to return only a portion of a string [16:28] rudebwoy has joined the channel [16:28] Kinbote has joined the channel [16:29] Aikar: micheil: no [16:29] Aikar: it doesnt reallocate buffer [16:29] Aikar: it uses the exact same memory and simply adjusts an offset [16:29] tanepiper: isaacs: because php is terrible [16:29] tanepiper: but i digress, i need to head home before i continue bashing PHP :) [16:29] micheil: Aikar: in which case it'll be slow due to all the toStrings() [16:29] saikat has joined the channel [16:30] Aikar: micheil: so figure out a way to not use tostring :P [16:30] Aikar: micheil: your doing C++ code right? [16:30] aho has joined the channel [16:30] micheil: not really [16:30] micheil: the parser in this case is just javascript. [16:30] Aikar: pass the buffer back to C++, get the handle to the data, and do an sscanf for finding the symbols you need etc [16:30] micheil: and pretty much has to stay that way [16:30] sprout has joined the channel [16:31] mraleph: micheil: currently there is none. [16:31] micheil: can't. needs to be javascript only. [16:31] Aikar: why does it need to be [16:31] mraleph: micheil: so it spends all the time copying this huge tail of your document. [16:31] tjholowaychuk: micheil: with a "real" parse, you would just ++ the pointer or w/e within the lexer, come up with the tokens you need, and parse those [16:31] pyrony has joined the channel [16:31] tjholowaychuk: but for our convenience of regexps etc in js, it is slow [16:32] micheil: mraleph: is that where the sole amount of time is spent? [16:32] micheil: it's not actually in building the tree? [16:32] Aikar: i get the joys of writing libs to use the streaming support of messagepack tonight [16:32] sprout has joined the channel [16:32] davidwalsh has joined the channel [16:33] Aikar: pgriess's msgpack lib ive forked and updated for 0.3.x but i want to move to the streaming version instead of all the buffer stuff [16:33] syskk: how am I supposed to package a native c extension? any docs on that? [16:34] Aikar: BSD license permits me to reuse some functions from a BSD licensed module in an MIT licensed one right? [16:34] Aikar: syskk: with npm easy, preinstall build event just issue the make command [16:34] Aikar: and make your makefile move the .node file to a proper directory [16:34] Aikar: here check this [16:34] eirikurn_ has joined the channel [16:34] Aikar: https://github.com/aikar/wormhole [16:34] isaacs: syskk: http://howtonode.org/how-to-module [16:34] mraleph: micheil: as far as I see creating this substrings dominate everything at the moment. [16:34] _derferman has joined the channel [16:34] Aikar: i have it setup for npm there [16:34] syskk: thanks ;) [16:35] isaacs: syskk: check out the bit on compiled modules [16:35] mraleph: micheil: instead of consuming the start of the string you should have an index which says where unconsumed part of the string starts. [16:35] synkro has joined the channel [16:35] duopixel has joined the channel [16:35] micheil: but then how would I regex from there? [16:36] tjholowaychuk: would be cool if regexps could take an index [16:36] mraleph: regexp does not take an index? [16:36] MikhX has joined the channel [16:36] tjholowaychuk: not that I know of [16:36] mraleph: javascript sucks [16:36] tjholowaychuk: hahaha [16:36] scrogson has left the channel [16:36] scrogson has joined the channel [16:36] tjholowaychuk: if it does, then I have some refactoring to do haha [16:37] isaacs: yeah, String#match doesn't have the start param like indexOf or lastIndexOf [16:37] malkomalko has joined the channel [16:37] duopixel: Hey, node.js is failing one test... [16:37] isaacs: duopixel: which test? [16:38] duopixel: on make test [16:38] duopixel: ENOSYS, Function not implemented at Object.futimesSync (fs.js:477:11) [16:38] duopixel: should I be concerned about this? [16:38] isaacs: duopixel: no, it just means that you're on a system that doesn't have futimes [16:38] micheil: isaacs: indexOf, hmm.. is that usually first indexOf? [16:38] isaacs: duopixel: what test is it, though? it should say the filename [16:38] isaacs: micheil: yes, always [16:38] isaacs: micheil: or -1 [16:38] micheil: hmm, that may work. [16:38] duopixel: Path: simple/test-fs-utimes fs.js:477 [16:39] tjholowaychuk: micheil: indexOf() accepts an index from which it operates from [16:39] isaacs: v8: s = "asdfasdfasdfasdf"; [s.indexOf("asdf"), s.indexOf("asdf", 2), s.indexOf("asdf", 5) ] [16:39] v8bot: isaacs: [0,4,8] [16:39] tjholowaychuk: we were just saying it would be cool, if the regexp methods had that [16:39] llkazu: nice. [16:39] tjholowaychuk: instead of substring crap [16:39] isaacs: mraleph: doesn't String#substr actually do some copy-on-write tree stuff anyhow? [16:40] mraleph: nope [16:40] suckerpunch has joined the channel [16:40] isaacs: i mean, couldn't you do this with relatively little pain? String.prototype.imatch = function (m, i) { return this.substr(i).match(m) } [16:40] ntelford has joined the channel [16:40] isaacs: mraleph: oh, ok, then [16:40] isaacs: :) [16:40] mikl has joined the channel [16:41] isaacs: so that'd actually copy the bytes into a whole new string object in v8's memory pile? [16:41] scrogson: isaacs: I ended getting npm 0.3 running last night...couldn't get the latest rc to work [16:41] isaacs: scrogson: weird. care to gist the log file? [16:41] saikat has joined the channel [16:42] mraleph: yep [16:42] isaacs: scrogson: curl http://npmjs.org/install.sh | npm_install=rc sh ; and then if that fails, gist the npm-debug.log file it writes in the cwd [16:42] admc1 has joined the channel [16:42] mraleph: we might reintroduce string slices to optimize that case again [16:43] scrogson: this is what I pastied last night right before you left: http://pastie.org/1734011 [16:43] isaacs: mraleph: was that how it worked once upon a time? why'd it change? [16:43] mraleph: yep, but I was not around, so I don't know why they were ripped off. [16:43] isaacs: scrogson: aha, homebrew, my old nemesis... [16:43] mhooker has joined the channel [16:43] aklt has joined the channel [16:44] scrogson: isaacs: is it because I installed node with homebrew? [16:44] isaacs: scrogson: yes, but that should work [16:44] Aikar: < isaacs> mraleph: doesn't String#substr actually do some copy-on-write tree stuff anyhow? [16:44] isaacs: so something broke in npm [16:44] Aikar: < mraleph> nope [16:44] Aikar: really O.o? thats bad... [16:44] Aikar: PHP even does copy-on-write! [16:45] Aikar: well maybe not for substr [16:45] isaacs: scrogson: i'm brewing node now. should have a fix today for the 1.0 rc [16:45] Aikar: "brewing" ? [16:45] isaacs: Aikar: brew install node [16:45] mraleph: for starters strings are immutable, so copy-on-write does not make much sense for them [16:45] Aikar: i thought the mac thing was out of date [16:45] scrogson: isaacs: no worries buddy...great work on npm...I'm just getting into Node...well...I've been interested for awhile now but I'm finally really checking it out [16:45] langworthy has joined the channel [16:45] mraleph: for some arrays V8 does copy on write [16:45] isaacs: scrogson: kewl, thanks for reporting the bug :) please report the next one you find, too [16:45] F1LT3R_ has joined the channel [16:46] scrogson: will do [16:46] eb4890 has joined the channel [16:46] temp01 has joined the channel [16:47] creationix has joined the channel [16:47] creationix has left the channel [16:49] balupton has joined the channel [16:51] temp02 has joined the channel [16:51] perezd has joined the channel [16:52] bitmonk has joined the channel [16:53] galaxywatcher_ has joined the channel [16:54] syskk: mmm I'm getting "npm ERR! RangeError: Maximum call stack size exceeded" [16:54] isaacs: syskk: gist the error, plz [16:54] isaacs: syskk: also, throw "-dd" on there if it's short so you can get more noise [16:55] syskk: thanks isaacs [16:55] gozala has joined the channel [16:55] rfay has joined the channel [16:57] tokumine has joined the channel [16:57] pquerna: joyent-er; for node office hours, is there a procedure for someone with a bike? [16:57] syskk: Error: The build command should only be used on folders inside the npm folder [16:57] syskk: I guess I'm doing it wrong :) [16:57] sunnyohno has joined the channel [16:58] isaacs: syskk: don't call `npm build`, no [16:58] isaacs: syskk: what are you trying to do? [16:58] ryah: pquerna: lock it up outside [16:58] syskk: just trying to test my package.json file [16:58] isaacs: syskk: `npm link` [16:58] isaacs: syskk: or `npm install` [16:59] isaacs: syskk: found that 1.0 homebrew bug. regression when i abstracted out the config stuff to nopt [16:59] syskk: thanks [16:59] jeff_horton has joined the channel [17:00] isaacs: ryah, pquerna: i think you can also lock it up in the building garage, if you're unwilling to have it stolen. [17:00] Aikar: syskk: you dont call npm build to compile your module (at least im pretty sure not?) [17:00] davidascher has joined the channel [17:00] syskk: seems to work now :) [17:00] Aikar: syskk: on 'npm install' it runs the preinstall task [17:00] isaacs: syskk: you can also do `npm run-script preinstall` [17:01] isaacs: or `npm run-script install` [17:01] isaacs: run-script is a plumbing-ish feature [17:01] ryah: isaacs: after hours? [17:01] isaacs: ryah: yeah, i think so [17:01] mike5w3c has joined the channel [17:01] Aikar: syskk: check out my package.json https://github.com/aikar/wormhole/blob/master/package.json [17:01] raidfive has joined the channel [17:01] isaacs: ryah: i've locked my bike down there when the freight was out, and left after 7 [17:01] Aikar: you can see the preinstall script is running 'make makelibs' [17:02] zylo has joined the channel [17:02] Aikar: and isaacs i have test: 'runTests.js' is that gonna be ok or does it need to be ./runTests.js ? [17:02] isaacs: Aikar: need the ./ [17:02] syskk: Aikar: yep. it seems to work now. I'm just running "preinstall" : "node-waf configure && node-waf build" [17:02] Aikar: ok [17:02] isaacs: Aikar: or `node runTests.js` is fine [17:02] Aikar: i set the script up with shebang/executable [17:02] isaacs: syskk: node-waf lets you specify multiple things if you prefer: `node-waf configure build` [17:03] isaacs: syskk: also! npm will default to node-waf configure build if you have a wscript with those steps. [17:03] syskk: isaacs: nice, didn't know about that [17:03] mscdex has joined the channel [17:03] isaacs: syskk: yeah, a lot of people were complaining back in the old days that npm didn't Just Work like that [17:03] Aikar: heh i made my default npm task build modules and then cleanup build files. no reason to litter the folder with build files if its just a simple npm install [17:04] Aikar: and plain 'make' wont cleanup files [17:04] isaacs: i see [17:04] isaacs: yeah, the default behavior leaves a build/ folder around with some crud in it, and a .lock-wscript, but whatever. [17:04] Aikar: https://github.com/aikar/wormhole/blob/master/Makefile [17:04] Aikar: well this uses the messagepack lib so its alot more being built than just node-waf stuff [17:08] baudehlo: anyone ever get this: [17:08] baudehlo: node(66989,0x126511000) malloc: *** error for object 0x1262002e8: incorrect checksum for freed object - object was probably modified after being freed. [17:08] baudehlo: *** set a breakpoint in malloc_error_break to debug [17:08] CIA-1: node: 03Ryan Dahl 07master * r75db199 10/ (lib/module.js lib/vm.js src/node.js src/node_script.cc): [17:08] CIA-1: node: Don't conflict with V8's Script class [17:08] CIA-1: node: Closes GH-203. - http://bit.ly/ho4y1p [17:08] baudehlo: (happens when using multi-node and sqlite3 and high loads) [17:08] datapimp has joined the channel [17:09] mattrobenolt: On middleware for Express, is there a nice way to determine which pass is being processed? A request pass or response pass? [17:09] mattrobenolt: Or does Middleware for Express not work that way? [17:10] omni5cience has joined the channel [17:10] tjholowaychuk: mattrobenolt: each function is only invoked once [17:10] tjholowaychuk: to operate on the response you have to "proxy" the methods [17:11] tjholowaychuk: aka re-assign them, and call the original within those [17:11] mattrobenolt: Ahh, gotcha. I come from a Django background, and their middleware is passed through twice. Once for a request and once on a response. [17:11] deepthawtz has joined the channel [17:11] mattrobenolt: So you can hook things in when needed at different times. [17:11] tjholowaychuk: gotcha [17:12] mattrobenolt: Have an example of the proxying to handle the response laying around? [17:12] Aikar: ryah: is CIA the official github bot? I setup IRC for my server but it disconnects after it posts message, was just wondering if freenode specially sticks around [17:12] tjholowaychuk: check out the connect middleware [17:12] liar has joined the channel [17:12] m00p has joined the channel [17:12] pquerna: Aikar: http://cia.vc/ [17:13] hosh_work has joined the channel [17:13] pquerna: Aikar: its not related to github; github just pushes to it via an api [17:13] Aikar: oh [17:13] Aikar: github does an almost identical IRC message you can setup as a post-receive, but it just connects/posts message/quits [17:13] devinus has joined the channel [17:14] omni5cience: I could never get the IRC hook to work [17:14] yozgrahame has joined the channel [17:15] mjr_ has joined the channel [17:15] dominictarr has joined the channel [17:16] markc has joined the channel [17:16] blueadept has joined the channel [17:17] timmywil has joined the channel [17:18] mdoan has joined the channel [17:18] MikhX_ has joined the channel [17:19] meandi has joined the channel [17:19] kmiyashiro has joined the channel [17:20] thomblake has joined the channel [17:20] Aikar: omni5cience: filled out server/port/channel/username, and checked active? [17:20] sirkitree has joined the channel [17:20] omni5cience: yeah [17:20] Aikar: does Test Hook work? [17:21] omni5cience: I should mention, it was a while ago though [17:21] Aikar: i wish github had a facebook hook [17:21] CIA-1: node: 03Ryan Dahl 07v0.4 * r6394ba2 10/ test/simple/test-assert.js : [17:21] CIA-1: node: Add test for circular refs in deepEquals [17:21] CIA-1: node: Closes GH-207. - http://bit.ly/gMAGws [17:21] omni5cience: lol that would be pretty badass [17:21] omni5cience: ACTION looks into it [17:22] Aikar: im too lazy to write a custom post receive url hook [17:22] jpick has joined the channel [17:22] timcosgrove has joined the channel [17:22] Aikar: O.o email hook only allows 1 address lol? [17:22] Aikar: and email doesnt even do diffs [17:22] omni5cience: interesting [17:23] Aikar: i mirror my github to my own server and run a fancy git-commit-notifier with diffs [17:23] timcosgrove has left the channel [17:23] Aikar: that lets me send to multiple addresses too [17:23] llkazu: you know a dev community is full of fronted developers when: they want a Facebook hook for their code commits [17:23] llkazu: ACTION ducks [17:23] llkazu: *frontend [17:23] omni5cience: :P [17:23] Aikar: llkazu: nah im backend mainly, im just lazy :P [17:23] llkazu: ACTION laughs [17:23] Aikar: too much effort for too little gain [17:24] omni5cience: ACTION *pouts* I'm a full stack developer [17:25] llkazu: lol, me too :-p [17:27] nivoc has joined the channel [17:27] vish_ has joined the channel [17:28] pdelgallego has joined the channel [17:29] olauzon has joined the channel [17:29] qFox has joined the channel [17:31] tfe_ has joined the channel [17:31] vckt has joined the channel [17:34] ako has joined the channel [17:36] gerad has joined the channel [17:37] ilya_ has joined the channel [17:37] mcantelon has joined the channel [17:38] ilya_: I'm trying to add a standalone attachment to couchdb which requires sending raw image data (binary, I guess). Is node unable to send binary data in requests? [17:39] adulteratedjedi has joined the channel [17:39] tilgovi has joined the channel [17:39] mjr_: node will send binary data into CouchDB [17:40] mjr_: Beware the conversion from Buffers to JavaScript Strings. [17:40] liar has joined the channel [17:40] ilya_: i'm using couch-client module to interact with couch, though. [17:40] Spion has joined the channel [17:40] mjr_: I dunno about that, I just use node's HTTP client API to talk to CouchDB [17:41] Rodtusker has joined the channel [17:41] mjr_: I'll bet there's a way to do it though. [17:41] ilya_: couch-client has a simple wrapper for that, basically allows to write your own requests to couch [17:41] m00p has joined the channel [17:41] langworthy has joined the channel [17:41] pandeiro: yes it can be done i'm working on same right now [17:41] ilya_: so, you saying that i should send Buffer in requests? [17:42] Rodtusker has joined the channel [17:42] mjr_: ilya_: you probably got this binary data from reading a file, right? [17:42] mjr_: The file operations give you a Buffer. You can send those same Buffers right back out. [17:43] abraham has joined the channel [17:43] mjr_: This ends up being very efficient in node, because the Buffer memory isn't part of the V8 heap, so there's no copying back and forth. [17:44] ilya_: yes, I read uploaded file into my var: [17:44] ilya_: fs.readFile(files.uploader.path, 'binary', function(err, data){ [17:44] ilya_: body = data; [17:44] ilya_: }); [17:44] piscisaureus: ryah: so, a patch that fixes cygwin support and the toolchain/no-strict-aliasing patches got landed in v8 [17:45] duopixel: Hey, npm is not outputting enough info, anyone know what might be wrong? [17:45] ilya_: and then this is passed down the chain to couch-client and I'm checking body.length along the way to see where is gets messed up and it seems fine right until couch-client does request.write(body, 'utf8'); [17:45] duopixel: PV-3:app Xavier$ sudo npm install jade jade@0.10.1 /Users/Xavier/node_modules/jade [17:45] qFox has joined the channel [17:45] isaacs: duopixel: that's not enough info? [17:45] isaacs: duopixel: ;) [17:45] dominictarr has joined the channel [17:46] duopixel: But I'm seeing my coworker's and he's getting a bunch of info [17:46] ilya_: and, obviously, there's utf8 there, but i tried sending buffer with just request.write(body) and my requests just hang then. [17:46] duopixel: and I'm not :( [17:46] Shrink has joined the channel [17:46] isaacs: duopixel: he's got a different verison of npm, probably [17:46] isaacs: duopixel: npm config set loglevel info [17:47] micheil: ryah: so, I've just tonight landed a working parser for the new doc format [17:47] dominictarr has joined the channel [17:47] mjr_: ilya_: not sure what's going on. You don't want to use utf8 encoding on binary data, obviously. [17:47] mjr_: ilya_: for this special case of uploading large binary attachments, why not just use node's HTTP API directly? [17:47] ilya_: of course. Perhaps there's conversion somewhere along the way, though, I have to check [17:48] gilesgoatboy has joined the channel [17:48] ilya_: you mean just make requests to couch directly omitting clients? [17:48] mjr_: For bonus awesomeness points, you could stream it from the filesystem into CouchDB [17:49] gilesgoatboy: got a question: is there a way that I can install node modules in the vendor directory of a rails app, using npm? [17:49] ryah: micheil: cool [17:49] isaacs: gilesgoatboy: of a rails app? [17:49] dguttman has joined the channel [17:49] micheil: ryah: doesn't generate to html yet, and as for github, use the file extension of .nd, then it's plain text [17:49] mjr_: ilya_: yeah, the CouchDB API is so simple and so HTTP, and node is so HTTP, why not just talk directly to CouchDB? [17:49] gilesgoatboy: isaacs: yep! [17:50] ilya_: mjr_: yeah, you have a point there [17:50] ilya_: I gotta try that [17:50] ilya_: thanks! [17:50] bingomanatee: to me that is one of Couch's big selling points - the built in REST. [17:51] piscisaureus_ has joined the channel [17:51] mjr_: Yeah, it is a wonderful match with node. [17:51] mjr_: Now if only it didn't burn up my disk drives. [17:51] ilya_: what [17:51] ilya_: what's that about disks? [17:51] bingomanatee: yes please elaborate. [17:51] sunnyohno has joined the channel [17:52] mjr_: well, EVERYTHING goes on the disk [17:52] mjr_: Nothing is explicitly kept in memory. [17:52] gilesgoatboy: isaacs: I know from yr blog that npm can do like anything on earth...checking the help files [17:52] bingomanatee: well and good [17:52] tbranyen: mjr_: thats with direct write ? [17:53] tbranyen: you can have delayed writes [17:53] tbranyen: iirc [17:53] tbranyen: in fact i think thats enabled by default [17:53] mjr_: Sounds fine, really, except when your database gets really large, like 10M docs or so, and you use the results of reduce views. [17:53] ilya_: tbranyen: in node or couch? in couch that's disabled by default. [17:53] mjr_: Oh yes, I had to go back to delayed_commits, even though it scares me. [17:53] MikhX has joined the channel [17:54] tbranyen: ilya_: https://issues.apache.org/jira/browse/COUCHDB-449 heh its been a while since i've used couch apparently [17:54] tbranyen: I call lazy consensus that we keep delayed_commits on by default. Please reopen if you disagree. [17:54] ilya_: tbranyen: yeah, that's just not safe to be enable by default [17:54] mjr_: So if you have a giant view and you want to reduce it all up, querying that top level value will likely cause several reads and re-javascripting your data. [17:54] tbranyen: hmmm [17:55] tbranyen: that was last year, dunno if thats since changed [17:55] lukegalea has joined the channel [17:55] mjr_: Because the btree isn't necessarily built the same way that your data reduces. [17:55] saschagehlich has joined the channel [17:55] mjr_: Anyway, it's obviously a tradeoff. Dealing with large datasets in any system is not something that just works for free, right away. [17:56] tbranyen: i just store my entire datasets in volatile memory [17:56] hvgotcodes has joined the channel [17:56] nibblebot: is there a better way to handle runtime errors than Forever + tail -f? [17:56] Sembiance: ACTION is a big fan of redis. [17:56] mjr_: On the plus side, it did give me an excuse to buy some sweet new computers with SSDs. [17:56] ilya_: nice [17:56] hvgotcodes: in generate to run tests is it just node testfile.js [17:56] hvgotcodes: i mean in general [17:57] mjr_: ACTION flashes Redis gang sign to Sembiance  [17:57] Sembiance: hehe [17:57] pquerna: but i can't buy 40tb of ram [17:57] pquerna: s/can't/won't/ [17:57] mjr_: If all of my data fit in memory, I'd never leave Redis. [17:57] mif86 has joined the channel [17:58] hosh_work has joined the channel [17:58] mjr_: pquerna: cassandra: love or hate? [17:58] Sembiance: mjr_: yah, when I think about needing to work with "larger than RAM sized" data sets, I start looking at things like mongodb [17:58] Sembiance: haven't used mongodb yet, but I've heard good things and from what I read it looks nifty :) [17:59] qFxo has joined the channel [17:59] deedubs has joined the channel [18:00] raidfive has joined the channel [18:00] ay: ACTION prefer mongodb for documentstore. And redis and or riak for sessions etc. and percona mysql for everything else.  [18:01] mike_miller has joined the channel [18:02] gilesgoatboy: isaacs: ping? [18:02] isaacs: meeting brb [18:02] gilesgoatboy: np [18:02] luke` has joined the channel [18:03] Sembiance: I'd still like to utilize a graph DB (like neo4j) in some project [18:03] Sembiance: just don't have a project that has enough data that is graph suitable :) [18:03] gilesgoatboy: does anybody know if npm bundle is living or dead? I see a lot about it on the Googles, but I just installed 1.0.1rc2 and there's no help file for bundle and it's not listed in the default help file. so I'm assuming it died... [18:04] isaacs: gilesgoatboy: it's gone. just do a local install [18:04] gilesgoatboy: ok, thx [18:04] isaacs: gilesgoatboy: http://blog.nodejs.org/2011/03/23/npm-1-0-global-vs-local-installation/ [18:04] gilesgoatboy: merci! [18:04] Sembiance: gilesgoatboy: sorry, I don't use npm [18:04] gilesgoatboy: np [18:05] mikegerwitz has joined the channel [18:05] malkomalko: booya [18:05] gilesgoatboy: I haven't used it much on my personal hacks but I'm doing a project with somebody new to Node so I figured I should start them with something convenient [18:05] gilesgoatboy: although they could handle it if I made them do it the hard way, actually [18:06] Sembiance: I use gentoo, so it's no surprise that I do things 'the hard way' and don't use npm :) [18:06] isaacs: Sembiance: you could check out ryp [18:06] isaacs: Sembiance: so that you can still install npm-published modules [18:06] Sembiance: isaacs: ryp? [18:07] Sembiance: ahh https://github.com/isaacs/ryp [18:07] tbranyen: its not really hard to copy a folder into the node_path to load a module [18:07] malkomalko: I've gotten into the habbit of including a little install_modules script with my projects that just npm install whatever I need.. is that pointless isaacs? [18:07] isaacs: malkomalko: a little :) [18:07] tbranyen: i mean npm does way more than that under the hood, but at the end of the day thats what you want [18:07] isaacs: malkomalko: you could just have a package.json [18:07] malkomalko: true [18:07] mikeal has joined the channel [18:07] malkomalko: I don't have to publish it.. just use it for local [18:08] malkomalko: but then you have to install your application right? [18:08] isaacs: malkomalko: pre-1.0, that's what `npm bundle` does. in 1.0, you can do `npm install` in your project dir to install your deps [18:08] luke` has joined the channel [18:08] tbranyen: malkomalko: i just put that in my Makefile [18:08] tyler_boyd has joined the channel [18:08] pquerna: mjr_: love [18:08] pquerna: mjr_: working on talking to it natively from node now :) [18:08] mjr_: that was my next question [18:09] pquerna: another racker is starting to hack on making a high level clint like pycassa [18:09] malkomalko: like if you are building a web app.. will npm install just install your dependencies or would it also install your web app as well? [18:09] vuliev has joined the channel [18:09] mjr_: It looks like it was designed for my exact use case, except the lack of node driver. [18:09] mostlygeek has joined the channel [18:09] pquerna: (the popular python one) [18:09] isaacs: malkomalko: in 1.0, when you do `npm install` in your project dir, it installs your deps in ./node_modules [18:09] malkomalko: ok awesome [18:09] malkomalko: I'll just go read your article :) [18:09] isaacs: :) [18:10] malkomalko: no reason to beat a dead horse [18:10] isaacs: malkomalko: or install 1.0, and do `npm help install` [18:10] omni5cience has left the channel [18:10] lukegalea has joined the channel [18:10] mikl has joined the channel [18:10] omni5cience has joined the channel [18:10] malkomalko: any backwards compat when upgrading to 1.0 that you have to worry about? that's my last question [18:12] indutny has joined the channel [18:12] rfay has joined the channel [18:13] stephank has joined the channel [18:16] zachsmith has joined the channel [18:16] Me1000 has joined the channel [18:17] mikeal has joined the channel [18:17] nivoc has joined the channel [18:19] mytrile has joined the channel [18:19] nivoc has joined the channel [18:19] Vladimir1 has joined the channel [18:20] meandi2 has joined the channel [18:20] deedubs: has anyone here used fiveruns tuneup before? It used to add a bar like this http://asciicasts.com/system/photos/99/original/E161I07.png to the top of your pages on ruby-rack apps [18:20] maushu has joined the channel [18:22] davidascher has joined the channel [18:22] bingomanatee_ has joined the channel [18:22] deedubs: I imagine it would be possible to tie into connect/express/mongoose to instrument things in the same way [18:23] dgathright has joined the channel [18:24] markc has joined the channel [18:24] ringomanatee has joined the channel [18:25] lukegalea has joined the channel [18:25] kjeldahl has joined the channel [18:26] dominictarr has joined the channel [18:27] nils_r has joined the channel [18:28] Eber has joined the channel [18:28] dominictarr has joined the channel [18:32] barce has joined the channel [18:33] eee_c has joined the channel [18:34] jeromegn: anyone knows if there's a npm for that? run functions in parallel, but call their callbacks in order. basically FIFO that processes in parallel. [18:35] SubStack: jeromegn: https://github.com/substack/node-seq can do that [18:36] jeromegn: SubStack: looking it up, thanks! [18:36] SubStack: oh how do you mean callbacks in order? [18:36] pquerna: jeromegn: https://github.com/caolan/async [18:36] SubStack: if you mean get the result in the same order in which the functions were listed then that is what I am thinking of [18:36] losing has joined the channel [18:38] SubStack: jeromegn: specifically Seq.ap(xs).parMap(fn).seq(function (ys) { ... }) [18:38] kkaefer: jeremyselier: step [18:38] colinclark has joined the channel [18:38] kkaefer: https://github.com/creationix/step [18:38] troessner has joined the channel [18:38] SubStack: jeromegn: do you want to operate on a list or individual actions? [18:39] seivan has joined the channel [18:39] jeromegn: SubStack: Yes, somewhat. Not only get them in the same order, but call their respective callback in order, as soon as it's ready. Basically it should check if the function is the first one in the queue, if it is, call the callback, then check if the next function is also ready, then call the callback, etc. [18:39] V1 has joined the channel [18:40] SubStack: hmm that is a bit different [18:40] jeromegn: Indeed [18:40] SubStack: that's more like lazy evaluation [18:41] brainproxy: anyone else notice that .toString() for functions works differently between safari, chrome and firefox (and node.js v8) [18:41] hvgotcodes: hmm im stuck running the tests for a node module i am working on -- i try node alltests.js, and it errors out trying to load a module. I have checked that the module file is present but don't know what else to do... [18:41] mjijackson has joined the channel [18:42] bradleymeck: hvgotcodes, paste us much more info [18:42] brainproxy: node.js v8 / chrome .toString() for a function gives you a representation that looks just like the function literal spec'd in ones code; with safari and firefox you get semicolon insertion, \n escapes, etc. [18:42] hvgotcodes: bradleymeck: sorry since im so new to this don't know what you need -- would the github address help? [18:42] V1 has left the channel [18:43] bradleymeck: the stack trace of the error, and source would be a good start [18:43] hvgotcodes: ok source is at https://github.com/mauritslamers/Thoth [18:43] Max-Might has joined the channel [18:43] V1 has joined the channel [18:44] hvgotcodes: and this is what i tried: https://gist.github.com/894982 [18:44] brainproxy: oh, and firefox will evaluate statements in the function literal it seems, whereas node.js v8, chrome, safari don't [18:44] liquidproof has joined the channel [18:46] bradleymeck: hvgotcodes, your odd require pathing scheme is wrong its checking in 'tests' [18:46] bradleymeck: i would recommend just relative requires instead of all of that jaz [18:46] bradleymeck: or at least using path.combine [18:46] bradleymeck: path.join* [18:47] jeromegn: SubStack: I guess it's a queue of functions, ran in parallel but each queue item's callback is evaled in order and only if the item is ready. Here's the use case: I process tweets, but they don't all take the same time to process, but I still want the client to receive them in the right order. [18:47] hvgotcodes: bradleymeck: i didnt write this -- im just trying to extend this -- so im starting by running the tests -- are you saying that the path to the SocketListener module is incorrect? the path looks ok to me, meaning the file exists where it is trying to get it from [18:47] deedubs: jeromegn: Would something like this work? https://github.com/technoweenie/node-chain-gang [18:47] hvgotcodes: bradleymeck: ooooohhh the path is not correct [18:47] bradleymeck: Thoth/tests/lib is being pulled in instead of thoth/lib [18:48] hvgotcodes: bradleymeck: yep -- sorry you are correct [18:48] hvgotcodes: dang [18:48] bradleymeck: and its hard to debug all that pathing [18:48] hvgotcodes: they must not have actually run their own tests [18:48] kkaefer: I'm looking for a continuous integration server for node applications [18:48] kkaefer: anything that is in common use/ [18:48] kkaefer: ? [18:49] bradleymeck: hvgotcodes, i see the issue, it chains up to the main module when doing that funky dir stuff [18:49] hvgotcodes: bradleymeck: ok, so if i run the tests from the project root and not the tests dir itself, i get a cannot find module jasmine [18:50] bradleymeck: thats a different issue [18:50] hvgotcodes: bradleymeck: right, i tried npm install jasmine, but got a 404 [18:50] jeromegn: deedubs: maybe, only if it can call each "tasks" callback in order of their addition! it's a special case I have here I think, will need to do this manually I guess [18:51] bradleymeck: hvgotcodes it doesnt matter *where* you run the tests they will never run the way this is set up [18:51] isaacs: hvgotcodes: $ npm se jasmin [18:51] fly-away has joined the channel [18:51] isaacs: jasbin Simple command line runner for jasmine, a BDD Javascript Testing Framework =eugenew [18:51] isaacs: jasmine-node DOM-less simple JavaScript BDD testing framework for Node =mhevery testing [18:51] SubStack: jeromegn: seems like it. I can't think of any flow control lib that has a function to do this out of the box [18:51] SubStack: jeromegn: but here is a long list anyway https://github.com/joyent/node/wiki/Modules#async-flow [18:51] isaacs: kkaefer: in npm 1.0, set `npm config set npat true`. then it'll test on every install. that's a good first step [18:52] kkaefer: isaacs: ah, interesting [18:52] isaacs: kkaefer: the next step is to build a site where we can upload those test results, and try to get the various popular test runners to output a consistent parseable format (TAP) [18:52] bradleymeck: hvgotcodes move alltests.js into lib and it might work [18:52] hvgotcodes: bradleymeck: im sorry can you explain that a bit more? [18:52] jeromegn: SubStack: thanks, appreciated. btw: love your art on browserify :) [18:52] drunknbass has joined the channel [18:52] kkaefer: TAP? [18:52] isaacs: kkaefer: step 3 is to set up a bunch of build bots that install every new package as it comes in, and report the results [18:52] MikhX has joined the channel [18:53] isaacs: kkaefer: http://en.wikipedia.org/wiki/Test_Anything_Protocol [18:53] isaacs: kkaefer: i've got a good start on a tap consumer and producer [18:53] isaacs: kkaefer: basically a conceptual port of Perl's Test::Builder [18:53] MrWarGames1 has joined the channel [18:54] isaacs: so, once we have the buildbots, *just publishing a module* will be your CI [18:54] MrWarGames1 has joined the channel [18:54] nils_r has joined the channel [18:54] bradleymeck: hvgotcodes the directory of the module given to node at start will be "rootDir" of thoth it seems, therefore given its directory structure it will never work as Thoth assumes it's root dir is / but when your run anything file living in /test/ it will make the root dir /test/ [18:54] SubStack: isaacs: isn't dominictarr hacking up something like that? [18:54] isaacs: also, if it *starts* failing on some new OS release or dependency change or something, you'll be able to detect it, as well as seeing which os's you should taret. [18:54] isaacs: *target [18:54] bradleymeck: so throw alltests into / or /lib and try out there, though i must say they made that function terribly [18:55] isaacs: SubStack: yeah, i think he'd done some interesting investigation [18:55] bradleymeck: makes me think of php stuff [18:55] isaacs: SubStack: we actually really really want this at joyent. [18:55] zomgbie has joined the channel [18:55] isaacs: it's officially on my corporate todo list/roadmap [18:55] hvgotcodes: bradleymeck: yep, its stuck at the jasmine module now [18:55] isaacs: ACTION gets his bosses to force him to do fun things he wants to do [18:55] devinus: why the hell did google have to pick kansas city [18:56] hvgotcodes: isaacs: what was that jasmine out you showed me earlier? [18:56] reid_ has joined the channel [18:56] isaacs: hvgotcodes: yeah. it's not called "jasmin", it's called "jasmin-node", i guess [18:56] zomgbie has joined the channel [18:56] isaacs: SubStack, kkaefer: basically, i just can't accept comfortably that any other system has any particular thing that is better than the one of those that node has [18:56] MrWarGames1 has joined the channel [18:56] isaacs: not ok [18:57] SubStack: haha [18:57] isaacs: not ok 1 Node must have the best test runner and CI system [18:57] eee_c has joined the channel [18:57] vuliev has joined the channel [18:57] hvgotcodes: isaacs: what was the npm se command -- didn't work for me on the command line, is it just for irc? [18:58] isaacs: hvgotcodes: sorry, npm search [18:58] ryah: apparently 64 fds for select on windows is BS [18:58] isaacs: hvgotcodes: se is an alias that i just added because i also use pkgin, which aliases "search" to "se [18:58] isaacs: ryah: oh? it's got more? [18:58] ryah: it can scale to the upper bound of FDs - 2096 [18:58] cadorn has joined the channel [18:58] hvgotcodes: isaacs: ok gotya [18:58] isaacs: oh, where'd the 64 number come from, then? [18:59] ryah: that's the default of FD_SETSIZE [18:59] hvgotcodes: dang i installed all the jasmine related libraries i could find and those tests still won't run [18:59] BigWookie has joined the channel [19:00] techwraith has joined the channel [19:00] mytrile has joined the channel [19:01] jpick has left the channel [19:02] eyesUnclouded has joined the channel [19:02] piscisaureus_: ryah: yes this 64 FD limit is bull. But select() on windows scales very poorly with a large amount of sockets because every time you're adding and removing a socket the entire table is scanned [19:03] dominictarr has joined the channel [19:03] mjr_: same as on unix. [19:03] piscisaureus_: ryah: and the limit is not even 2096 afaict [19:03] dnyy has joined the channel [19:03] stevereed has joined the channel [19:05] hvgotcodes: bradleymeck: i think these tests are supposed to be run with jasbin [19:05] bradleymeck: further down the rabbit hole [19:05] hvgotcodes: lol [19:06] hvgotcodes: when i run with jasbin at least i dont get an error [19:06] hvgotcodes: but its not running any tests [19:06] hvgotcodes: should console.log print to a terminal? [19:06] davidascher has joined the channel [19:07] bradleymeck: yes generally [19:07] Validatorian has joined the channel [19:08] hellp has joined the channel [19:08] ryah: 2048 [19:09] ryah: as noted in http://msdn.microsoft.com/en-us/library/6e3b887c.aspx [19:09] losing has joined the channel [19:09] piscisaureus_: ryah: that is the FD limit. But select() takes SOCKET handles and not FDs. You can create as much SOCKETs as you want [19:10] maushu: Man, socket.io is just overkill. [19:10] m64253 has joined the channel [19:10] bradleymeck: lol [19:10] V1: overkill o.O? [19:10] maushu: websockets or ajax is enough for me. [19:11] mjr_: why kill something when you can OVERkill it? [19:11] maushu: I don't really care about flash, comet, silverlight, java, ... [19:11] tbranyen: maushu: are you just throwing terms around or do you know what they mean? [19:11] tbranyen: because what you're saying doesn't make any sense [19:12] bradleymeck: it would be nice if it cached what a computer could do and prevented just running through the steps every time [19:12] maushu: bradleymeck, technically it does, but I think its not working right. [19:12] tbranyen: bradleymeck: that isn't the best idea, what's the actual penalty cost if someone doesn't have websockets enabled? [19:12] suckerpunch has joined the channel [19:12] tbranyen: it runs down the list very quickly [19:13] maushu: Why can't everybody just use chrome. [19:13] tbranyen: good q [19:13] maushu: I, for one, welcome our google overlords. [19:13] ryah: piscisaureus_: ah, thanks [19:13] tbranyen: although now that i have opera websockets enabled, i've been quite happy [19:14] bradleymeck: tbranyen then it would cache that they didnt and the cache would expire? im not talking about tons of time, just a session cookie for while browser is open etc [19:14] tbranyen: bradleymeck: yeah that'd be a pretty perfect use for sessionStorage [19:14] tjholowaychuk: req.socket.socket.remoteAddress [19:14] tjholowaychuk: awesome [19:15] pyrony has joined the channel [19:15] tjholowaychuk: :p [19:15] markwubben has joined the channel [19:16] techwraith: +1 for the socket.io sessions :) [19:17] V1: techwraith: Feel free to fork/ add / commit / send pull request ;) [19:17] naneau: polling connections might not be very efficient for sessions, since you'd add the cookie data to every poll [19:18] techwraith: I'll look into what it would take :) [19:18] devaholic has joined the channel [19:18] V1: Small offtopic question, If I put a