[00:00] jesusabdullah: Man, installing node on a completely fresh linode [00:00] jesusabdullah: Easy to forget just how much stuff is missing when you start out [00:00] jchris has joined the channel [00:01] Throlkim has joined the channel [00:02] devinus_ has joined the channel [00:03] devinus_ has joined the channel [00:07] voodootikigod has joined the channel [00:07] MikhX has joined the channel [00:16] [[zz]] has joined the channel [00:20] rauchg_ has joined the channel [00:20] benburkert has joined the channel [00:22] justin_: hmm, npm adduser isn't working for me [00:22] bpot has joined the channel [00:22] justin_: just keeps saying "cancelled" [00:23] justin_: anybody else running into that? [00:24] benburke_ has joined the channel [00:24] rauchg_ has joined the channel [00:26] temp01 has joined the channel [00:29] ph^ has joined the channel [00:32] Utkarsh has joined the channel [00:34] aldosarmiento has joined the channel [00:38] rauchg_ has joined the channel [00:40] rikarends has joined the channel [00:41] indexzero: justin_: what version of npm are you on? [00:42] indexzero: also: are you running as sudo? [00:42] justin_: 0.2.7-1 [00:42] justin_: and no [00:42] justin_: it wasn't working with 0.2.6 either [00:42] indexzero: 0.2.7-1? I've been out of the loop I guess [00:42] indexzero: I'm still on 0.2.5-1 [00:42] justin_: i think it came out like 15 minutes ago :) [00:42] indexzero: haha [00:43] indexzero: I haven't seen that issue, but I know isaacs had some issues with config files with fixes going into 0.2.6-1 [00:43] indexzero: you can manually specify the userconfig by doing --userconfig /path/to/some/npmrc file [00:44] justin_: ah [00:44] justin_: so i downgraded to 0.2.5-1 and it worked [00:44] justin_: so apparently something recently broke [00:45] indexzero: open an issue on GitHub, I'll remind isaacs if he swings in [00:45] justin_: sounds good [00:46] davidascher has joined the channel [00:47] davida has joined the channel [00:49] agoston has joined the channel [00:49] agoston: hi [00:52] bbttxu has joined the channel [00:56] jfd1 has joined the channel [00:56] ossareh has joined the channel [00:57] rikarends has joined the channel [01:02] necrodearia has joined the channel [01:02] eshton has joined the channel [01:07] brianmario has joined the channel [01:10] softdrink1 has joined the channel [01:15] Utkarsh has joined the channel [01:18] gkatsev: anyone used/looked at node-boilerplate? it looks and works pretty sweet. What I don't really understand though is how it knows to use the layout.ejs file as the base file for all the rendering of the templates? [01:18] jrockjiggz has joined the channel [01:19] shadow_walker has joined the channel [01:19] gerad has joined the channel [01:19] mape_: gkatsev: <%- body %> [01:20] rossij has joined the channel [01:21] gkatsev: is layout.ejs the default file then? [01:22] admc has joined the channel [01:22] rossij: anyone know of node.js dns server? [01:22] mape_: gkatsev: yes [01:22] TomsB has joined the channel [01:22] gkatsev: mape_: ah, cool. [01:23] marshall_law has joined the channel [01:26] Twelve-60` has joined the channel [01:26] __swanson_ has joined the channel [01:27] zeekay has joined the channel [01:29] antris_ has joined the channel [01:29] nsm_ has joined the channel [01:29] rednul_ has joined the channel [01:29] ashleyde1 has joined the channel [01:30] liar has joined the channel [01:30] _alex has joined the channel [01:30] v8bot has joined the channel [01:31] Tobias| has joined the channel [01:31] mikew3c has joined the channel [01:31] rbranson: node.js dns server eh? [01:32] tmpvar has joined the channel [01:32] rbranson: soon someone's gonna write a friggin web server in node.js! what tom-foolery! [01:32] tlrobinson has joined the channel [01:32] rossij: rbranson: yeah would love to play with one [01:33] jvolkman-work has joined the channel [01:33] rbranson: could always play with bind [01:33] aurynn has joined the channel [01:33] rossij: blah not as fun - I could also play with Twisted Names, but I want try out me sone node.js [01:34] rbranson: why so domain specific? [01:35] d4ilycow has joined the channel [01:35] ivan has joined the channel [01:35] rossij: just happens to be what I am playing with right now and want to work with - nothing more ;) [01:36] rbranson: hehe, well, sounds interesting nonetheless [01:36] kriszyp has joined the channel [01:36] rbranson: i'm sure you'll have to write your own [01:37] rossij: looks like some people on the mailing list talked about it, but i can find zero code [01:37] twoism has joined the channel [01:37] rossij: ACTION goes reads the code in python and rfc [01:40] shadow_walker has joined the channel [01:40] loke_ has joined the channel [01:40] loke_: anyone from USA? [01:41] shadow_walker has joined the channel [01:41] justin_ has joined the channel [01:42] abstractj has joined the channel [01:42] wilmoore has joined the channel [01:43] Utkarsh has joined the channel [01:44] okuryu has joined the channel [01:44] mikew3c_ has joined the channel [01:45] rcy has joined the channel [01:51] rbranson: Sun Nov 7 01:51:16 [conn3] insert freebase.topic 1271310310ms [01:52] rbranson: mongodb lies [01:53] saschagehlich has joined the channel [01:56] johan_bouveng: �lala [02:01] twoism has joined the channel [02:02] charlenopires has joined the channel [02:11] Utkarsh has joined the channel [02:14] nsm has joined the channel [02:15] iheartnodejs has joined the channel [02:15] iheartnodejs: :-D [02:17] rbranson: groupies [02:20] Utkarsh has joined the channel [02:22] c4milo has joined the channel [02:25] marienz has joined the channel [02:26] pandark_ has joined the channel [02:28] jakehow has joined the channel [02:29] softdrink has joined the channel [02:31] wilmoore_ has joined the channel [02:33] jrockjiggz has joined the channel [02:33] wilmoore has joined the channel [02:33] Utkarsh has joined the channel [02:35] wilmoore_ has joined the channel [02:37] jigz has joined the channel [02:39] ryah_: i have an idea! [02:39] rbranson: mongodb is web scale? [02:39] ryah_: what about a node library for distributed systems [02:39] halfhalo: ewww, distributed [02:40] halfhalo: that means effort [02:40] ryah_: you start a server and point it to one other node in the network [02:40] rbranson: like the 15 other ones? [02:40] ryah_: it connects [02:40] ryah_: gets a list of all the other nodes [02:40] ryah_: through gossip [02:40] halfhalo: ACTION watches and makes popcorn [02:40] rbranson: oh, gossip is hot [02:40] ryah_: presents that to you as $allServer [02:40] ryah_: $allServers == [ "123.23.23.3:8123", "54.32.3.4:8123" ] [02:41] ryah_: so the library does the auth - or whatever [02:41] ryah_: so now you can do [02:41] ryah_: $allServer[3].msg("hello!") [02:41] loke_: Is node.js running Ecmascript5? [02:42] loke_: and which browsers are running ecmascript5? [02:42] ryah_: and then you can even do: $allServer[3].send("./lib/module.js", "module.startHTTPServer(80)" ) [02:42] ryah_: like send it code [02:43] eisd: loke_: "node" isn't running ES5, but v8 implements most of it [02:43] ryah_: just like an abstract bot net [02:43] loke_: yeah =) [02:43] eisd: ryah_: I like that idea [02:43] __swanson: man chrome vs firefox is really noticeable when using socket.io [02:43] halfhalo: goodtimes... botnets [02:43] loke_: eisd: and what about the browsers? are they all running ecmascript5? even IE? [02:43] __swanson: or rather flashsocket fallback must be slower :) [02:44] eisd: loke_: IE6-8 are ES3 [02:44] eisd: v8 doesn't implement strict mode and maybe a few other minor things [02:44] rbranson: ryah_: what would the topology be? [02:44] loke_: okay [02:44] loke_: thx [02:44] eisd: ...but you don't really need strict mode either, np [02:44] __swanson: rbranson: token ring or bust [02:44] c4milo has joined the channel [02:45] rbranson: tt;u [02:45] rbranson: ttly [02:45] ryah_: rbranson: maybe you can set the number of nodes that you want to maintain connections to [02:45] ryah_: $connections = 4; [02:45] ryah_: or something [02:45] elijah-mbp has joined the channel [02:46] rbranson: ah so all messages would travel over the gossip transport? [02:46] rbranson: or would you be peer-to-peer with anything adhoc? [02:46] ryah_: peer to peer [02:46] rbranson: yeah i agree with that [02:46] ryah_: although we'd need to look up some algorithms [02:46] Utkarsh has joined the channel [02:47] rbranson: definitely need a sort of canned gossip network though, it is incredibly useful [02:47] ryah_: i guess just how IP works.. [02:47] ryah_: well maybe not [02:47] rbranson: IP routing is probably a little more scalable than it would need :P [02:47] ryah_: i mean, i think we can assume each node can know the name of every other node [02:47] halfhalo: what if the nodes are on the same machine 0_o [02:48] rbranson: they'd be IP:port pairs [02:48] ryah_: i'm just thinking... how does one node know how to route a message to another [02:48] alexfner has joined the channel [02:48] ryah_: say it has connections == 4 [02:48] charlenopires has joined the channel [02:48] rbranson: yeah it would have to know the topology [02:49] rbranson: and have a model of it in-memory [02:49] halfhalo: node[s0].blah? [02:49] halfhalo: nodes[0]* [02:49] rbranson: halfhalo: the topology is more like a graph [02:49] halfhalo: and nodes.ramdom for those special moments... [02:49] ryah_: rbranson: right.. yeah this would be fun [02:49] ryah_: i be graphs are super easy in js :) [02:49] ryah_: i mean - it's nice - we can assume nodes < 1000 [02:49] elijah-mbp: love you some javascript matrix math. ;) [02:49] rbranson: that's a decent goal [02:50] ryah_: so we probably don't need to worry about blocking the server on computation [02:50] ryah_: although - i guess that can always be moved out of process if necessary [02:50] rbranson: even then, there are ways around that [02:50] rbranson: you can use fancy DHT mechanisms [02:50] rbranson: like supernodes [02:51] Blackguard has joined the channel [02:51] ryah_: would need to abstract it in a way that we can switch out peer-to-peer implementations [02:51] ryah_: so we can start with something really trivial [02:52] ryah_: like just ignore the max connection setting and connect to every host [02:52] rbranson: http://en.wikipedia.org/wiki/Distance-vector_routing_protocol [02:53] pquerna: peer to peer implementations? [02:53] rbranson: LOTS of academic stuff in this type of message routing [02:53] ryah_: yeah, i can imagine [02:53] pquerna: oh, gossip [02:53] ryah_: sounds like something everyone was geeking out on in 2000 :) [02:53] ryah_: in the uni scene [02:54] ryah_: pquerna: read my idea - above [02:55] ryah_: pquerna: that would be a nice abstraction for a lot of people [02:55] pquerna: http://wiki.apache.org/cassandra/ArchitectureGossip [02:55] pquerna: yes [02:55] pquerna: ideall tbh, one that gossip'ed and provided somehting like an EventEmitter [02:55] rbranson: http://wiki.apache.org/cassandra/ArchitectureGossip [02:55] rbranson: damnit [02:55] rbranson: beat me to it [02:55] ryah_: pquerna: we could have something like: otherServer.fireForget("blah!") [02:56] ryah_: pquerna: oh yeah - that'd be sweet [02:56] rbranson: you'd want query/response too [02:56] pquerna: http://www.cs.cornell.edu/home/rvr/papers/flowgossip.pdf [02:56] rbranson: so you can query the whole network and collect responses [02:56] pquerna: anyways, there are some more recent papers since that amazon one [02:56] halfhalo: ACTION would just want to see ways of assigning tasks at random, based on cpu usage, other metric, etc [02:56] ryah_: otherServer.emit("blah", { name: "ryan" , skillz: "sux" }) [02:56] Throlkim_ has joined the channel [02:56] pquerna: but i'd vote starting there with what cassandra does, its a relatively good implemenation [02:57] pquerna: (and how its failure detector works) [02:57] pquerna: i'd like to help with it, but lets merge http-streams first :) [02:57] ryah_: pquerna: okay - you want that now? [02:57] pquerna: https://svn.apache.org/repos/asf/cassandra/trunk/src/java/org/apache/cassandra/gms/FailureDetector.java [02:57] ryah_: is it ready? [02:58] pquerna: ryah_: no, I fixed ssl on end(), but that broke non-ssl on end. So, need to rethink it. [02:58] pquerna: the whole half-closed situation / ending a request etc is what is sucking. [02:58] pquerna: just been at apachecon all week and too much drinking to really code [03:01] rbranson: do we have any standard libs for message framing yet? [03:01] Utkarsh has joined the channel [03:01] ryah_: im really excited to have ssl and writev [03:01] ryah_: shit's going to start getting real. [03:02] pquerna: hah [03:02] ryah_: i'm pretty excitd about this distributed computing system too [03:03] ryah_: how many people would build stuff on top of that! i think a lot [03:03] pquerna: (fwiw, before I broke end, it was passing 100% of the non-ssl tests) [03:03] rbranson: i am hacking a prototype [03:03] rbranson: called "tmz" [03:03] ryah_: rbranson: sweet :) [03:03] ryah_: rbranson: what's tmz? [03:05] bpot has joined the channel [03:05] __swanson: like the gossip site? [03:05] rbranson: yup [03:05] rbranson: dry humor [03:05] __swanson: but then all your client libs will end up named JustinBieber [03:06] __swanson: etc [03:06] __swanson: :( [03:06] rbranson: srsly though, i am not writing a fucking framing implementation [03:06] rbranson: 2010 and stuff [03:06] ryah_: rbranson: just netstrings [03:06] benburkert has joined the channel [03:06] ryah_: netstrings! [03:06] marienz has joined the channel [03:07] pquerna: huh? framing? [03:07] rbranson: that's fine [03:07] pquerna: yeah i mean [03:07] rbranson: netstrings works [03:07] pquerna: just use json [03:07] pquerna: int lenght, [03:07] rbranson: still need framing, even if I use json [03:07] ryah_: we'll pump it through gzip later [03:07] pquerna: 2,{} [03:08] ryah_: (ascii hex strings) \r\n (body) \r\n [03:08] pquerna: man, i can't support netstrings [03:08] ryah_: 0\r\n\r\n terminates [03:08] pquerna: so much pain in past lifes [03:09] ryah_: chunk-encoding is the boss. [03:09] rbranson: haha [03:09] rbranson: probably going to go with pquerna's idea [03:09] JimBastard: if i wanted to build a node app that would require massive amounts of DB read and writes in real-time, do you guys think riak is a good choice? too early? redis instead? [03:09] ryah_: no really - do the chunked encoding one - make it so easy to debug [03:09] ryah_: you got to have \r\n [03:10] mjr_: JimBastard: redis is the fastest. If you don't care about durability, then it is the best choice. [03:10] rbranson: how is pquerna's idea hard to debug? [03:10] ryah_: rbranson: you ahve to pipe it rhough a decoder [03:10] rbranson: redis can be durable :) [03:10] rbranson: you just need a BBWC [03:10] ryah_: rbranson: much better to socat into it [03:10] JimBastard: mjr_: any idea how many read-writes ill be able to pump out of one server? [03:10] pquerna: JimBastard: riak is fine. It's parent business model is open core, so cool features like multi-master are not available without paying. [03:10] JimBastard: mjr_: can you link up multiple redis instances easily? [03:10] JimBastard: pquerna: thats good to know [03:11] mjr_: riak is pretty cool if it meets your needs. [03:11] mjr_: riak links multiple instances while from its birth. redis doesn't have a good way to link multiple instances, but it can certainly do it. [03:11] rbranson: ryah_: what are (ascii hex strings) ? [03:11] rbranson: i mean I know what those are, but what are you meaning by that? [03:12] mjr_: JimBastard: You can do 30K reads /sec without much trouble on redis. [03:12] ryah_: rbranson: i mean not binary [03:12] ryah_: don't encode the length in binary [03:12] rbranson: oh, duh [03:12] JimBastard: mjr_: that seems like it might work. the last time i tried to build this site i used mediawiki and mysql, it didnt work out well [03:12] JimBastard: collapsed on itself in days [03:13] rbranson: ryah_: i know you have something like this implemented somewhere that I can jack [03:13] ryah_: rbranson: i can imlement it for you right now, if you'd like [03:13] rbranson: hehe, I can do it... I'm just lazy :P [03:14] pquerna: tbh [03:15] pquerna: when i was looking at doing this this summer [03:15] pquerna: i was just going to use http [03:15] pquerna: it makes it nicer for monitoring systems to pull out information too :) [03:15] ryah_: i mean, i think these things can start http servers too if they want [03:15] ryah_: but that should be on top [03:15] ryah_: no need for the internal gossip to speak that [03:15] pquerna: well one request [03:16] pquerna: make it possible to either have a shared secret [03:16] pquerna: so you can include an HMAC [03:16] pquerna: or ssl it [03:16] pquerna: or somehting [03:16] JimBastard: pquerna: whats up with cast? are you guys using that in prod yet? [03:16] pquerna: JimBastard: october was ... distracting. [03:16] ryah_: pquerna: yeah, just have a password for the network [03:17] JimBastard: lol, for sure [03:17] halfhalo: ACTION votes ssl [03:17] unomi has joined the channel [03:17] softdrink has joined the channel [03:17] ryah_: pquerna: when you try to add a node it says "Enter password for BoTNET: ****" [03:17] pquerna: no comment. [03:17] JimBastard: node-drop [03:18] ryah_: pquerna: each node trusts each other completely [03:18] pquerna: yes [03:18] pquerna: that is common in most p2p network designs. [03:18] pquerna: well. [03:18] pquerna: anways. [03:18] pquerna: this is a better bar conversation :) [03:18] ryah_: pquerna: yeah. beer? [03:18] ryah_: :) [03:19] pquerna: well, roomate insisted on watching empire strikes back... asteroids are exploding right now. [03:19] ryah_: ACTION tries to coerrese people into drinking by lure of botnet chatting [03:20] SubStack: botnet what [03:20] ryah_: SubStack: making the first programable botnet [03:20] unomi: it might be interesting to get operational transforms in there [03:21] SubStack: the first? [03:21] unomi: when passing state changes around [03:21] SubStack: pretty sure they are already highly sophisticated [03:21] pquerna: ryah_: well, if you want it to be a 'good' botnet, you embed an RSA key into the initial payload, and then distributed updated code via the p2p protocol, with the code signed by the publ key... [03:21] SubStack: polymorphic, fault-tolerant, decentralized [03:21] unomi: SubStack: more like gridcomputing [03:21] rpflo has joined the channel [03:22] unomi: I am already using all the visitors to my site to try to bruteforce insurance.aes via webworkers [03:23] SubStack: ahaha [03:23] SubStack: maybe wikileaks doesn't actually know what's in that file [03:24] SubStack: and is just releasing it so that somebody will crack it [03:24] SubStack: that would be pretty clever of them [03:24] unomi: perhaps [03:24] wink_ has joined the channel [03:24] bruse: cat /dev/urandom > insurance.aes [03:24] bruse: that's how it's made [03:25] SubStack: I recall reading that the collateral murder video had to be decrypted somehow [03:25] unomi: I remember talk of them needing to crack open the encryption for their collateral damage video, though that could just be disinformation [03:25] unomi: hah [03:25] unomi: yah [03:25] SubStack: ^_^ [03:25] bruse: encryption is not what hollywood tells us, people [03:26] booths has joined the channel [03:26] pquerna: http://mtc.sri.com/Conficker/P2P/index.html#download-management [03:26] booths: How's it going guys [03:28] unomi: interesting read pquerna [03:29] unomi: ryah_: are you going to feel guilty when you find out you are responsible for the network that gave rise to the first sentient ai? [03:29] pquerna: conficker wasn't the first, but the disassembly of it is one of the best analysises [03:30] benburkert has joined the channel [03:31] unomi: I think we should quickly move to scrub the word 'robot' and ban the use of automatons for sexual gratification. [03:31] unomi: otherwise we might be starting off on the wrong foot [03:32] pquerna: the spice must flow man [03:32] unomi: the sleeper must awaken [03:32] pquerna: heh [03:34] mrjjwright has joined the channel [03:34] wilmoore_ has joined the channel [03:34] MikhX has joined the channel [03:34] Utkarsh has joined the channel [03:35] ryah_: can we call this lib skynet? [03:35] ryah_: i think it's better than the gossip pun :) [03:35] unomi: http://fanedit.org/350/ this btw is a great version of the movie [03:35] ryah_: rbranson: im writing a parser for you [03:35] gkatsev: isn't there already some kind of cloud app/server in the UK called skynet? [03:35] ryah_: rbranson: for the netstring framing protocol [03:36] unomi: there is a robotics company called skynet [03:36] unomi: oh and: http://en.wikipedia.org/wiki/Skynet_(satellites) [03:36] rauchg_: Thus, a downloaded binary can hot patch critical data within a live C process, such as peer lists, the DGA's top level domains (TLD) arrays, and other variables or seed data. [03:36] rauchg_: hawt [03:36] unomi: Skynet is a family of military satellites, now operated by Paradigm Secure Communications on behalf of the UK Ministry of Defence, which provide strategic communication services to the three branches of the British Armed Forces and to NATO forces engaged on coalition tasks. [03:37] unomi: rather, there is a robotics company called cyberdyne [03:37] rbranson: ryah_: I'm already deep in this shit :P writing it chunk encoded [03:37] ryah_: oh okay :) [03:37] unomi: s a Japanese robotics and technology company most noted for the marketing and distribution of the HAL 5 robotic exoskeleton suit. [03:38] unomi: http://en.wikipedia.org/wiki/HAL_5 [03:38] ryah_: rbranson: are you just doing it with indexOf? and doing setEncoding? [03:38] rbranson: ryah_: yeah, probably not the best, but it's a start [03:38] ryah_: yeah, that's probably good. [03:39] ryah_: i was doing the whole binary steper [03:39] ryah_: you're is probably faster though too :) [03:39] rbranson: for V8 probably yeah [03:39] rbranson: any reason for the tailing \r\n? [03:39] ryah_: *your's [03:40] ryah_: rbranson: that's what chunked encoding does [03:40] rbranson: I was just going to do [03:40] rbranson: \r\n [03:40] ryah_: well you want a new line before the next length [03:40] ryah_: if you're talking on the telnet [03:41] rbranson: hmm, do we really need to stream the data? [03:41] rbranson: messages should be fairly small [03:41] ryah_: rbranson: start with tcp [03:41] ryah_: maybe we'll add a udp protocol to it too [03:41] rbranson: yeah it'll be tcp [03:42] rbranson: what i'm saying is that you know the message size ahead of time [03:42] rbranson: so a simple length followed by message payload is fine [03:42] ryah_: oh yeah [03:42] rbranson: chunked encoding is good if you don't know the length of the payload ahead of time [03:42] ryah_: andif you have to send them a file, then it's your job to send it and reassemble [03:42] rbranson: yeah def [03:42] gkatsev: unomi: right, thanks. I remembered something with skynet/cyberdyne or w/e. [03:42] ryah_: i mean, maybe we can add something [03:42] rbranson: yeah that'd be fairly trivial to overlay [03:43] unomi: gkatsev: yeah, they are both real at this point [03:43] ryah_: we're going to have our own json protocol inside this too [03:43] ryah_: well, i guess that's clear :) [03:43] unomi: gkatsev: one is a military satellite system for controlling joint operations, the other makes robotic exoskeletons [03:43] ryah_: but - yeah we'll have a new layer for the user's messages [03:43] rbranson: yeah all the comm is going to assume user messages are opaque [03:44] gkatsev: "When in panic, fear, or doubt, run in circles, scream, and shout". [03:44] gkatsev: ACTION runs around in circles screaming and shouting. [03:44] ryah_: you know if we have to send a big file [03:44] ryah_: we can always open a connection directly to the host [03:44] pquerna: +1 [03:44] rbranson: yeah it would be bad to stream a file over the gossip [03:46] benburkert has joined the channel [03:47] ryah_: tmz = require('tmz'); var handle = tmz.connect("8123", "82.52.53.12"); [03:47] pquerna: well [03:47] pquerna: kinda [03:47] pquerna: ideally, its a list of seeds [03:47] pquerna: but meh :) [03:47] ryah_: handle.on("serverList", function (list) { myCache = list })' [03:48] JimBastard: tmz? [03:48] rbranson: host:port string as the "primary key" for an instance [03:48] rbranson: like memcached [03:48] marienz has joined the channel [03:49] ryah_: list.msgAll("yo!") [03:49] ryah_: or something :) [03:50] pquerna: well [03:50] pquerna: ideally don't use ip:port as the instance ID [03:50] pquerna: this will run into problems on multi-path routing / split views [03:50] pquerna: consider EC2's internal addresses vs external addresses [03:51] rbranson: yeah, now that I think about it, ideally it would work on a heterogenous network [03:51] rbranson: like you could have nodes that straddle internal/internet [03:51] jetienne has joined the channel [03:52] rbranson: but I think the originaly idea was to keep it simple and assume connectivity [03:52] pquerna: well, just a suggestion from experience, give nodes IDs, but they shouldn't be an IP [03:52] rbranson: perhaps we use a self-generated GUID [03:52] rbranson: so if a node switches IPs [03:53] rbranson: whatever state bound to that instance can be resumed [03:53] ryah_: rbranson: yes [03:53] ryah_: also hard for nodes to know their own ip [03:53] ryah_: well "hard" [03:54] rbranson: it would have to be configured [03:54] ryah_: but i think you want to have all the ips too.. [03:54] rbranson: unless during the bootstrap process you can assume the source IP for the connection = valid for connecting back [03:55] rbranson: and use that value implicitly [03:55] ryah_: rbranson: you could go to what's my ip [03:55] ryah_: to get your ip :) [03:55] ryah_: or - no - your peer just shuld tell you it [03:55] rbranson: haha [03:55] pquerna: +1 [03:56] pquerna: peers tell you your 'apparent' IP [03:56] rbranson: I think we allow configurable self-IP [03:56] rbranson: and if that's not there [03:56] rbranson: it falls back to peer [03:56] pquerna: you contact a series of peers [03:56] pquerna: * seeds [03:56] ryah_: pquerna: then as part of the handshake - you yourself start a server [03:56] pquerna: they all tell you the observed IP [03:56] ryah_: the peer connects to it [03:56] ryah_: tells you if it works [03:56] pquerna: yup [03:56] pquerna: and now you have done NAT detection [03:56] ryah_: man [03:56] pquerna: then you can start STUN [03:56] ryah_: node is a good system for this :) [03:56] pquerna: if you want to do NAT piercing [03:57] rbranson: NAT piercing is probably inviting the wrong kind of crowd :D [03:57] pquerna: http://upload.wikimedia.org/wikipedia/commons/6/63/STUN_Algorithm3.svg [03:57] pquerna: well [03:57] WRA has joined the channel [03:57] pquerna: STUN is a good way to discover how you are firewalled [03:58] pquerna: and if you need a middle-peer to relay messgs to another peer [03:58] ryah_: how awesome would this be to combine this with tom hughes croucher's dns server [03:58] ryah_: instant dns - web load balancer [03:59] ryah_: the nodes broadcast how many clients they have connected [03:59] ryah_: (say it's a chat server) [03:59] rbranson: CHAT SERVER DEMO! [03:59] pquerna: well, dns for load balancing isn't great once you go past 8-10 [03:59] pquerna: you can't use udp anymore [03:59] pquerna: (see: dns is a terrible old protocol) [04:00] ryah_: what do you mean? [04:00] gkatsev: how do you guys usually do url routing in node? (assuming you are not using express) [04:00] pquerna: well, in original dns [04:00] pquerna: you can only have 512 bytes max in a response [04:00] pquerna: there are extensions to go past that [04:00] ryah_: oh but only returning 8-10 is okay [04:01] ryah_: we'd just give the query the least busy servers [04:01] ryah_: the top 4 [04:04] pquerna: to the beer pong table. [04:09] AAA_awright has joined the channel [04:10] dmachi has joined the channel [04:14] dmachi: is there a trick to getting node-waf to compile node-jpeg on a mac? [04:15] ryah_: why don't we just call this lib 'conficker' and get it over with [04:15] ryah_: copyright free :) [04:15] dmachi: heh, i guess i touched on a sensitive subject ? [04:18] boaz has joined the channel [04:19] ryah_: okay - im having many idea about this lib [04:19] ryah_: i think it's going to be awesome [04:19] ryah_: i want to allow rsync-ing a directory of files [04:20] ryah_: it would be nice if i could speak to rsync over stdio [04:20] ryah_: and pipe that through the gossip stream [04:21] rbranson: i'm sure you could easily make a "channels" overlay ontop of the protocol [04:21] ryah_: rbranson: yeah [04:21] rbranson: and create a netcat-ish command to pipe to a channel [04:21] ryah_: :P~ [04:21] ryah_: abstracting this so that people could use it - would be really nice [04:22] rbranson: tar -cO /path/to/stuff | node tmz-stream-to-channel.js 1.2.3.4:666 world-domination [04:22] ryah_: rbranson: :D [04:23] saschagehlich_ has joined the channel [04:23] ryah_: yeah, you can just open a little tcp server [04:23] ryah_: pipe connections across the channel [04:25] Aria has joined the channel [04:25] rbranson: that be a IPv6 IP [04:26] Aria: Mmm, v6. [04:26] rbranson: I am all IPv6 ready at home [04:26] rbranson: 6to4 :/ [04:27] TomsB has joined the channel [04:28] marienz has joined the channel [04:29] jakehow has joined the channel [04:36] dquestions has joined the channel [04:36] Aria: Mmm. I'm 6to4ed and tunneled to Hurricane Electric. [04:37] Aria: Both home and all my servers. [04:39] rbranson: haven't gone that far, just randomly found out my WRT610N was IPv6 compat and tried it out [04:40] admc has joined the channel [04:41] tmpvar: Aria, you are a huge nerd. [04:41] tmpvar: :) [04:41] Aria: Yes. Also, I have a loathing for NAT. [04:41] Aria: Utter and complete contempt. [04:42] tmpvar: lol [04:42] boaz has joined the channel [04:42] tmpvar: there is a way to traverse using UDP, no? [04:44] tmpvar: http://samy.pl/pwnat/ [04:44] tmpvar: horrah [04:46] MikhX has joined the channel [04:47] gkatsev: heh, samy.pl's homepag is kind of awesome [04:55] Aria: Yeah, traversal with UDP, there's several modes -- teredo among them. [04:55] noahcampbell has joined the channel [04:55] prettyrobots has joined the channel [04:57] Aria: Wow, brilliant. [04:57] aconbere has joined the channel [04:58] Tobsn has joined the channel [04:58] JimBastard: tmpvar: you should talk to binary42 about that [04:58] WM has joined the channel [04:58] JimBastard: we were looking into that samy tool a while back [04:58] tmpvar: yeah, we talked heh [04:59] tmpvar: many moons ago [04:59] tmpvar: back when he used to hang [04:59] JimBastard: le girlfriend, lol [04:59] JimBastard: Disregard women, acquire node.js modules. [05:01] Aria: Acquire girlfriend who writes node.js modules. [05:01] Aria: Oh, wait. I AM that girlfriend. [05:01] tmpvar: Aria, stop fishing [05:01] Aria: Hee. Also, happily married ;-) [05:01] Aria: And while open, not that open. [05:02] tmpvar: hah [05:03] JimBastard: o.O [05:05] Utkarsh has joined the channel [05:07] Aria: ACTION wags her eyebrows at JimBastard  [05:08] marienz has joined the channel [05:09] JimBastard: i wonder if github applied correctly https://github.com/Marak/Faker.js [05:11] boaz has joined the channel [05:11] boaz_ has joined the channel [05:17] ryah_: damn colorado hippies [05:18] Aria: ACTION grins. [05:18] Aria: Hey, now. I resemble that remark. [05:19] benburkert has joined the channel [05:23] WRA has joined the channel [05:25] tmpvar: heh, my uncle has a cabin out there.. never been though [05:26] tmpvar: anyhow, night [05:29] janm has joined the channel [05:37] nsolsen has joined the channel [05:38] ryah_: http://mtc.sri.com/Conficker/P2P/index.html#download-management [05:38] ryah_: oops [05:39] davidascher has joined the channel [05:41] MikhX has joined the channel [05:42] hornbeck has joined the channel [05:52] sonnym has joined the channel [05:56] unomi has joined the channel [06:02] Utkarsh has joined the channel [06:09] fangel has joined the channel [06:12] amerine has joined the channel [06:14] booths has joined the channel [06:15] hamsterspider has left the channel [06:18] Blink7 has joined the channel [06:25] hzin has joined the channel [06:28] loke_: do we have the creator of expressjs here? [06:36] rauchg__ has joined the channel [06:39] mikew3c has joined the channel [06:45] path[l] has joined the channel [07:00] dnolen has joined the channel [07:03] trentm_ has joined the channel [07:08] MikhX has joined the channel [07:17] jakehow has joined the channel [07:17] alcuadrado has joined the channel [07:18] WRA: I have two nodejs servers communicating to each other over a TCP socket (server a and server b). Server A sends an extremely long string to server B. Is server b guaranteed to get the complete string when on('data') is called or could it be partial? [07:22] trentm has joined the channel [07:24] rbranson: ryah_: http://github.com/rbranson/tmz.git :D [07:24] rbranson: it does handshake IP recognition, gossips the connection table, and tries to keep 3 connections open right now [07:25] rbranson: no message routing yet [07:28] path[l] has joined the channel [07:32] rbranson: WRA: no [07:32] rbranson: WRA: you have to use some kind of framing [07:32] WRA: just going to use websocket framing then [07:32] rbranson: WRA: you might also get 2 messages concatenated together within the same data event [07:33] WRA: yeah [07:33] WRA: I didn't know if nodejs automatically added framing or not [07:33] rbranson: it doesn't, thankfully :) [07:36] cferris has joined the channel [07:39] CrabDude has joined the channel [07:41] CrabDude: so, I'm setting up a production env using express and the docs mention setting NODE_ENV, but I don't understand what I'm setting it to.. (EX from docs: "$ NODE_ENV=production node app.js") [07:41] CrabDude: anyone know? [07:48] jacobolus has joined the channel [07:49] WRA1 has joined the channel [07:52] MikhX has joined the channel [07:53] faust45 has joined the channel [07:59] agnat has joined the channel [08:14] peutetre has joined the channel [08:27] themiddleman has joined the channel [08:31] Nohryb has joined the channel [08:34] ph^ has joined the channel [08:35] femtoo has joined the channel [08:35] Tobsn: loke_, yep [08:36] loke_: Tobsn: yep to what? [08:37] WRA1: offtopic question: Anyone know of any decent javascript game engines? [08:38] zomgbie has joined the channel [08:40] aurynn: someone needs to wrap node-canvas around SDL [08:41] WRA1: I may reimplement Flixel using canvas [08:44] Tobsn: WRA just make it plugin-able [08:45] Tobsn: loke_, expressjs writer is here [08:45] Tobsn: sometimes [08:45] Tobsn: just write him a msg on github [08:45] aho: aurynn, http://www.phoboslab.org/log/2010/10/impact-for-ios [08:45] Tobsn: hmm crossover doesnt support IE8 [08:45] Tobsn: :/ [08:46] aho: (i don't really see much of a reason to base something like that on node-canvas though) [08:46] JimBastard has joined the channel [08:46] Tobsn: yeah node makes no sense [08:46] Tobsn: but if you build it around html5/js [08:46] Tobsn: you could compile it with phonegap [08:47] Tobsn: or what those guys with impact game engine do [08:47] Tobsn: thats pretty sweet [08:47] Druid_ has joined the channel [08:48] aho: "The game is running in its own process and is not using the iPhone's browser at all. Instead, it's just using the JavaScriptCore Framework to run the game. All the necessary calls to the Canvas API have been reimplemented with OpenGL-ES and the touch input is passed over to JavaScript to be evaluated by the engine." [08:48] Tobsn: http://vimeo.com/14920760 [08:48] Tobsn: thats pretty sweet [08:48] Tobsn: he even has a level editor in js [08:49] aho: ye, i was one of the beta testers :> [08:49] Tobsn: its awesome [08:49] SamuraiJack has joined the channel [08:50] Tobsn: is it open source or is it for a company? [08:50] JimBastard: im regretting not getting a mcrib [08:50] aho: well, the engines is open source :> [08:50] WRA has joined the channel [08:50] Tobsn: hmm [08:51] WRA: which engine? [08:51] WRA: impact? [08:51] aho: http://impactjs.org/ <- woops... not done yet :> [08:53] Tobsn: yep [08:53] Tobsn: its nice [08:53] WRA: doesn't have sound support [08:53] Tobsn: hmm the guy is german [08:53] WRA: (yet) [08:54] aho: so am i [08:54] WRA: http://www.kesiev.com/akihabara/ [08:54] WRA: tho impact does seem way closer to what flixel delivers [08:55] aho: my own framework also isn't ready yet, but it doesnt do anything fixel does [08:55] Tobsn: oh well, sometimes germans can create useful things too ;) [08:56] aho: it's all about boiler plate and x-compiling [08:56] aho: <: [08:56] aho: (to flash9+) [08:56] WRA: if only WebGL was further along [08:56] Tobsn: the problem with all those new techniques is that just a few browsers support it fully [08:56] Tobsn: and its not really backwards compatible... [08:57] altamic has joined the channel [08:57] aho: my stuff works on 99.99% of the machines out there... ;> [08:57] loke_: anyone that could give me some feedback on my new validation framewrok [08:57] loke_: http://pastie.org/1278699 [08:57] WRA: yeah, so I created a multiplayer game framework but to show it off I want to also have the client implemented in javascript [08:57] loke_: the javascript version is mine [08:58] stephank: justin_: Oh hey, you're on IRC. That's good to know. ;) [08:58] loke_: also here: http://pastie.org/1278729 [08:58] loke_: please look at it and give some feedback [08:58] justin_: stephank: ah, hey... yeah i'm around from time to time [08:58] justin_: tinkering with node is purely a side project though, so not as much time as i'd like :( [08:59] WRA: All the javascript game engines I've considered so far have been junk tho [08:59] stephank: justin_: Same here, but it's become a huge time sink. ;) I don't think mlc hangs here, fwiw. [09:01] qFox has joined the channel [09:03] loke_: anyone? [09:03] stephank: WRA: link? [09:03] WRA: http://www.kesiev.com/akihabara [09:03] ajsie: JimBastard: you are there? [09:03] justin_: stephank: too bad... you guys are doing great work on the zmq stuff, btw, gotten me back into it :) [09:03] JimBastard: yeah yeah [09:03] WRA: http://www.renderengine.com/ [09:03] ajsie: JimBastard: could you just give me 1 min [09:03] ajsie: JimBastard: http://pastie.org/1278729 [09:03] JimBastard: sup [09:03] ajsie: what do you think? [09:04] WRA: https://github.com/lostdecade/diggy [09:04] stephank: WRA: But, I meant yours. :) [09:04] WRA: oh :D [09:04] justin_: loke: without digging very deep, it seems like a lot of repeated code [09:04] ajsie: JimBastard: my validation class for my new framework . [09:04] WRA: I thought you meant all the JS game engines I've considered [09:04] JimBastard: ajsie: hard to say [09:04] ajsie: justin_: its not repeated .. its modular [09:04] ajsie: every added method is for a validation [09:05] ajsie: chained into a validation sentence [09:05] JimBastard: id have to see it in action [09:05] ajsie: JimBastard: it works [09:05] ajsie: what about the idea [09:05] ajsie: you can just switch method...replace AND with OR [09:05] ajsie: it makes a difference in validation as you see [09:06] justin_: ajsie: ah, i see, those were all just separate test cases [09:06] justin_: pretty cool overall [09:06] ajsie: justin_: yeah thanks [09:06] ajsie: like rspec but it actually have a consistent grammar [09:06] justin_: ajsie: yeah, cool... how about asyn? [09:06] justin_: *async [09:07] ajsie: you can write whatver in the argument list of the functions and in any number [09:07] mikeal has joined the channel [09:07] ajsie: the methods are predeclared .. so when you hit . you see all methods you can use to chain [09:07] stephank: WRA: I've seen some of those before. I may be getting the wrong impression, but it looks like many of those engines are created for the purpose of creating an engine. Whereas, a good place to start in my opinion would be an actual game, and extract generic parts into an engine. [09:07] WRA: stephank: been keeping it close while I work out the kinks but I think I'll toss it up on github now [09:07] ajsie: justin_: havent thought about that yet ... but it has to be synched? [09:08] WRA: Stephank: yeah, flixel came about that way [09:08] ajsie: the methods are saving state in the Validator object .. so that the subsequent methods can operate on the previous validation [09:08] ajsie: justin_: what do you need asynch for? [09:09] stephank: WRA: flash people are a bit more experienced. :) [09:09] ajsie: in this case .. i cant figure out what the gain would be [09:09] stephank: ooh, they have a new website [09:09] Tprice has joined the channel [09:09] WRA: Stephank: I'm actually making a round based multiplayer game with persistence but keeping the generic bits seperate [09:10] WRA: basically trying to remake SS13. [09:10] stephank: SS13? [09:10] ajsie: justin_: cause the validation has to pass before the next statement executes right .. if it doesnt pass it will throw an error and my code will do something about it to let the user know [09:10] WRA: space station 13 [09:10] WRA: its a social round based game [09:11] justin_: ajsie: yeah, makes sense.... makes it harder for when your output is actually an argument to a callback though [09:11] stephank: WRA: Sounds neat. Definitely link me if there's some to see. :) [09:11] WRA: basically you are given a role at teh start of each round and a random game type is selected. If you are given a win objective you are a subversive, if you are not given one you are trying to stop the subversives. [09:11] ruxkor: hey everybody! can somebody tell me why, if I write 'asynchronous' functions (with callbacks methods), I am not RETURNing the callback, but calling it? [09:12] ajsie: justin_: right [09:12] WRA: I've been delaying putting it up on github because I don't have all the game specific stuff tore out of it yet [09:12] Tobsn: damn, my brother in germany is already playing COD black ops [09:12] Tobsn: bastard just send me pictures with his smartass face in it and a comment in the mail saying "whos first now?" [09:13] Tobsn: when GTA4 came out i send him pictures the other way... [09:13] Tobsn: :/ [09:13] ajsie: justin_: ill throw in a callback arg.. if a function is passed then it sends the output asynch [09:14] Tobsn: now where do i find a highres image of a toolbar [09:14] justin_: ajsie: might work... makes things uglier though :/ [09:15] justin_: pretty much inevitable when you start diving into the world of callbacks though [09:16] Tobsn: fyi im soon gonna render html5 into toolbars over nodejs and socket.io :D [09:16] Tobsn: and nobody will know [09:17] ajsie: justin_: yeah .. lets see if i can make it beautiful [09:17] ajsie: basically i want all my libraries for my new OS backend framework to be like this [09:17] ajsie: creating readable code [09:18] Tobsn: i gave up with that kind of approach [09:18] Tobsn: ;) [09:18] ajsie: i want when you come back to a project one year later. you just read what your code is doing even though its very complex: Validator['expects'](list)['to not contain'](1, 'shit')['and'](100)['but']('email', 'url')['or'](1001)['also'](1, 3)['and'](101) [09:19] ajsie: that is a very complexed validation if you do it manually..even if you made it you cant read it like that =) [09:20] ajsie: and you have to recreate everything again next time you need a validation [09:20] justin_: ajsie: sounds awesome [09:21] faust45 has joined the channel [09:23] justin_: stephank: i noticed you tend to prefer moving stuff into JS instead of doing it in c++ [09:23] justin_: any particular reason for that? [09:24] benburkert has joined the channel [09:27] stephank: justin_: It seems to require a lot less code and makes the whole thing easier to follow for me. It also reduces on magic, such as keeping V8 Handles in stdc++ vectors and lists. ;) [09:27] jesusabdullah: ajsie: What is that?! [09:27] justin_: stephank: true, those lists were pretty ugly... [09:28] stephank: justin_: but the real reason I started doing it is because that's the way node itself does it. :B [09:29] justin_: stephank: yeah, v8 too... [09:29] stephank: Yeah! I only just noticed. I was nosing around, because I couldn't find C++ Array Push method, and it turns out it does that all in JS. Pretty cool. [09:29] justin_: definitely [09:30] justin_: i had the vague goal starting the Ømq stuff to keep it to one file, but i never really thought it would get this complex [09:32] justin_: really the original plan was a straight 1-1 mapping of the C API with a separate JS library to make it all node like, but as time went on it became more clear that it's actually easier to make it node like as you go [09:32] justin_: so how you have it organized is probably the best approach [09:32] TobiasFar has joined the channel [09:32] stephank: justin_: It basically is a straight 1-1 mapping, with a node library now. [09:32] stephank: If for some odd reason someone wishes to use the 1-1 mapping, they can use zeromq.capi. [09:33] justin_: yeah [09:33] captain_morgan has joined the channel [09:34] justin_: i still have a basic distrust of splitting libraries over language barriers since you never really know where the actual implementation is in that case [09:34] justin_: but for anything non-trivial, it does make everything simpler [09:34] justin_: except for the guy who's trying to find out where your bug is :) [09:35] sveimac has joined the channel [09:36] stephank: Well, halfway through the work I was still mixing things, by simply extending the prototype of the C++ class in JS. But as it is now, I've tried to make the split as obvious as possible. The C++ stuff can function stand-alone, I believe. [09:37] altamic has joined the channel [09:37] mikeal has joined the channel [09:39] justin_: stephank: yeah, i just started looking over the pull request and it's looking pretty good [09:39] justin_: using new instead of malloc though? [09:39] justin_: what did malloc ever do to you ;)? [09:40] Lorentz: Cause cancer, obviously. [09:41] stephank: justin_: The `outgoing_message` struct contained a C++ class, but you completely bypass constructors and deconstructors by using malloc/free. [09:42] stephank: justin_: I'm not sure if it mattered for a simple handle, and I later discovered I missed replacing the the free call. But that's all in the past. :) [09:42] justin_: stephank: yeah, i totally agree, i was just giving you a hard time for removing my hacks and doing it right [09:44] stephank: justin_: the mongrel2 stuff makes me wonder, is ØMQ master compatible with 2.0? [09:45] justin_: not entirely [09:45] justin_: but pretty close [09:46] justin_: stephank: you fixed one of the issues i was running into earlier though [09:46] stephank: which one? ) [09:46] justin_: and i'm too tired to track down the other right now [09:47] justin_: where it was GCing the socket too early [09:47] stephank: ah, okay [09:49] iszak has joined the channel [09:49] iszak: I think it should be mentioned that net.createConnection() will resolve the host if a domain is provided. [09:52] WRA has joined the channel [09:53] justin_: stephank: when i built mongrel2, i linked it against Ømq trunk, and it built just fine [09:53] justin_: to the API is at least pretty close to compatible [09:54] stephank: Ah, good plan. I'll give it a shot soon. [09:54] jesusabdullah: ?mq? [09:54] jesusabdullah: WAIT [09:54] jesusabdullah: IS THAT A UNICODE? [09:54] jesusabdullah: ffffuuuuu--- [09:55] v8bot: jesusabdullah has taken a beer from ffffuuuuu-. ffffuuuuu- now has -1 beers. [09:55] path[l] has joined the channel [09:56] zedas: stephank: no, 2.1 doesn't work right with mongrel2. you'll have problems shutting down and other stuff. [09:57] zedas: stephank: stick to 0mq 2.0.x latest. [09:57] stephank: zedas: Ah, good to know. But we have bindings that rely on node.js 0.3 and ØMQ 2.1 ZMQ_FD stuff, so... ;) [09:57] stephank: zedas: we'll be patient ;) [09:58] stephank: jesusabdullah: next time, use unicode em-dashes, so v8bot doesn't take away your beers. ;) [10:00] masm has joined the channel [10:01] mbrochh has joined the channel [10:01] mbrochh has joined the channel [10:04] ajsie: jesusabdullah: what is what? [10:05] ajsie: my validation library? [10:08] justin_: zedas: imagine that, those are exactly the problems i'm having! :) [10:09] superjudge has joined the channel [10:10] kjeldahl has joined the channel [10:11] slaskis has joined the channel [10:11] rikarends has joined the channel [10:11] marienz has joined the channel [10:13] ajsie: anyone that uses vowsjs? [10:14] ajsie: it uses assert library .. where is the github for that? is that part of vowsjs or a 3rd party library? [10:15] cferris has joined the channel [10:15] micheil: ajsie: it's part of node [10:16] ajsie: an now i see [10:16] ajsie: thx [10:21] vandenoever has joined the channel [10:23] fangel: but vowsjs also adds a bit more than what is provided by the node-library, see https://github.com/cloudhead/vows/blob/master/lib/assert/macros.js [10:25] fangel: and this is js stuff built into node: https://github.com/ry/node/blob/master/lib/assert.js [10:28] vandenoever: has anyone tried a webdav server on top of node yet? [10:29] vandenoever: i quite like pywebdev with pluggable file system, but who knows, node might have something better [10:33] d0k has joined the channel [10:35] intacto has joined the channel [10:35] intacto: hi [10:36] intacto: i need some help with 3.0 [10:36] intacto: i cant build it on centos 5.5 [10:36] intacto: it throws an error like undefined reference to `sync_file_range' [10:37] intacto: as far as i know sync_file_range is introduced in glibc 2.6 [10:37] intacto: my version is 2.5 [10:37] intacto: could it be about it? [10:38] micheil: intacto: I'm not sure, try asking on the mailing list, nodejs@googlegroups.com [10:38] intacto: Someone has already asked it on the list [10:39] intacto: but no answer [10:39] intacto: I wanted to try my chance here [10:42] alexandere has joined the channel [10:42] micheil: hmm, I don't see any thread about it. [10:44] intacto: http://groups.google.com/group/nodejs/browse_thread/thread/14c9e48862cc88bc/4ee5f1867b9fe9b5?pli=1 [10:45] intacto: and [10:45] intacto: http://groups.google.com/group/nodejs/browse_frm/thread/2d5eb964acba01c?scoring=d& [10:45] JimBastard: ajsie: we use vows for all our projects [10:46] JimBastard: we've standardized on it for testing [10:46] ajsie: yeah im learning it now [10:46] JimBastard: :-) [10:46] ajsie: you have added custom functions to assert? [10:46] JimBastard: i'd take a look at the unit tests for kyuri, http-proxy, cloudservers, etc [10:46] JimBastard: there are some decent examples in there [10:46] JimBastard: also, all of cloudheads projects for the most part [10:47] ajsie: JimBastard: there is no assert.isString() in node.js documentation [10:47] ajsie: that is added by you? [10:47] JimBastard: vows adds methods [10:48] JimBastard: www.vowsjs.org [10:48] JimBastard: http://www.vowsjs.org/#reference [10:48] ajsie: okay [10:48] Moominpapa: Speaking of vows, is anyone using it via PUTTY? [10:48] ajsie: yeah ill definitely use Kyuri [10:50] Moominpapa: I'm not sure about Kyuri: it's one way. You write gherkin, it makes vows. [10:50] Moominpapa: Cucumber doesn't work that way. [10:51] cferris has joined the channel [10:51] WRA1 has joined the channel [10:58] yeevgen has joined the channel [10:58] ajsie: JimBastard: how is it going with nodejitsu? [10:58] ajsie: ETA? [10:59] ajsie: never mind the ETA..its already 7 days passed =) [10:59] vvsh has joined the channel [11:03] cognominal has joined the channel [11:04] sveisvei has joined the channel [11:05] JimBastard: ajsie: indexzero was really adamant about not letting people on the platform until we have better internal logging and analytics [11:05] JimBastard: http://twitter.com/indexzero [11:06] JimBastard: also, we are currently putting all the server costs on a credit card >.> [11:06] JimBastard: im suppose to be getting us a big check today... we'll see ... [11:07] unomi has joined the channel [11:07] Anti-X: it seems you are the one who actually think shipping is a feature and he's the one who wants to make everything perfect and so it will never be shipped? [11:07] JimBastard: yes, we make a great team [11:08] JimBastard: :-D [11:08] JimBastard: im taking the extra time this week to polish the UX for the client app [11:10] ajsie: yes i want the shipping feature now!=) [11:10] iszak: the whole ship when everything perfect is over rated. [11:10] Nomon: I am new to node and trying to figure out proper error handling patterns, seems like most stuff uses callbacks with error as first parameter but after that it gets fuzzy, some code just proxies the callback never using exception handling while other wrap their stuff in a try {code;} catch(error) {callback(error,null)} and throw errors there and on succesfull execution call the callback. And then there is some who pass separate callback for successfull and erro [11:10] ajsie: iszak: but maybe they cant ship it at all right now? [11:10] iszak: Perhaps, it's just often you may develop this feature and then find out no one wants it or barely anyone uses it. [11:10] ajsie: JimBastard: how is it with the current condition btw, could it be shipped? [11:11] ajsie: iszak: yeah true [11:11] iszak: I mean sure it shouldn't be bug filled, but often there are edge case bugs that you won't find but the users will. [11:11] ajsie: so its better to ship earlier than to late .. only all the tests are passing [11:11] JimBastard: ajsie: we'll see whats up in the next few days [11:11] ajsie: ok [11:11] JimBastard: it looks like the elastic provisioning pool is working [11:11] JimBastard: so in theory, we might just be able to turn on the faucet [11:12] JimBastard: im sure the LB will eventually choke though [11:12] ajsie: yeah hit it [11:12] superjudge has joined the channel [11:12] JimBastard: im waiting on indexzero's okay [11:12] iszak: Why is it so hard to get flash on ubunt :( [11:12] ajsie: let the judgement day come [11:13] ajsie: JimBastard: could I not use assert with vowsjs? [11:13] JimBastard: ask and ye shall node [11:13] ajsie: and use another unittest library? [11:13] JimBastard: ajsie: what do you need that vows cant do? [11:13] ajsie: JimBastard: its not vows its assert [11:14] ajsie: i dont like its syntax =) [11:14] ajsie: im pretty sure it can do anything [11:14] zorzar has joined the channel [11:14] ajsie: JimBastard: im creating a backend framework with my own validation library : Validator['expects'](value)['to have'](3)('characters') [11:15] ajsie: so i would like to use it on testing too .. is it possible to replace assert in vows with my own lib? [11:15] Anti-X: Validator.expects(value).toHave(3).length [11:15] JimBastard: ajsie: try it [11:15] JimBastard: i think you can just return true; [11:15] JimBastard: return false; [11:15] JimBastard: the assert methods are just returning a boolean value [11:16] JimBastard: i stub out tests all the time [11:16] JimBastard: by returning false [11:16] adambeynon has joined the channel [11:16] JimBastard: i think [11:16] ajsie: okay ill try [11:16] ajsie: better to having to write a bdd framework from scratch =) [11:17] ajsie: better than having to... [11:18] ajsie: lately ive been all about syntax [11:18] ajsie: :) [11:18] abstractj has joined the channel [11:21] [[zz]] has joined the channel [11:22] captain_morgan has joined the channel [11:22] iszak: hmm. [11:23] omarkj has joined the channel [11:23] iszak: Ever think Node.JS will get cryptology built in? I know you can already get it, but it's not near as fast as C/C++ code. [11:24] iszak: nvm.. [11:25] iszak: It already has, just was looking at some node.js related code which implemented sha1. [11:25] olivvv_ has joined the channel [11:27] Akufen has joined the channel [11:27] Akufen has joined the channel [11:28] stride: iszak: http://nodejs.org/api.html#crypto-250 [11:29] iszak: yeah I saw ;) [11:33] mr_daniel has joined the channel [11:38] captain_morgan has joined the channel [11:41] Throlkim has joined the channel [11:43] rikarends has joined the channel [11:45] mbrochh has joined the channel [11:45] mbrochh has joined the channel [11:47] abstractj has joined the channel [11:55] iszak: I wish node.js would get a database adapter/interface.. [11:56] iszak: baked in. [11:56] deoxxa: oh really? [11:56] deoxxa: and what database would you like it to support, sir? [11:57] iszak: That's a good question, I guess it would be based on demand. [11:58] deoxxa: i think you should just skip to the end of this train of thought and suggest one metafunction that magically infers what you want your application to do and implements all the required pieces to perfection [11:58] Kaitsu has joined the channel [11:59] deoxxa: putting things like that in core are a quick way to becoming something like PHP [11:59] iszak: deoxxa, it's not stupid to implement commonly used functionality. [11:59] iszak: I mean why did they bother adding crypto when you can easily find on the web SHA1, MD5, etc, implementions in JS? [11:59] iszak: Don't tell me performance either. [12:00] deoxxa: because that's an absolutely integral part of preeeetty much any application [12:00] iszak: Not at all. [12:00] iszak: However It's almost as common as database access. [12:01] Lorentz: Probably because people often use nodejs as a http server, and https was very important to them, is why the crypto being included by default. [12:01] iszak: and what about those who do not use node.js as a https? server? we just neglect their needs? [12:01] Lorentz: Database adapter/interface would be a whole another thing. [12:02] iszak: Sure we can't bundle every thing, I understand that. [12:02] deoxxa: no, only the things you want. [12:02] deoxxa: isn't that right, iszak? [12:02] iszak: No, of course not. [12:02] iszak: I know there is database adapters out there for node.js, I was looking them up. [12:02] Lorentz: And it's next to trivial to add modules to nodejs anyway. [12:02] deoxxa: well... then... [12:03] deoxxa: ACTION motions for this discussion to reach its point [12:03] iszak: What statistic of applications would not use database would you say? [12:04] stride: deoxxa: you didn't even mention unicorns yet.. [12:04] Lorentz: iszak: Dunno, but it's not integral to nodejs. [12:04] deoxxa: based on a sample set of "everything i have written in node.js", i would say precisely 0%, iszak :D [12:04] Lorentz: How many servers have apache, why don't apache have a native database layer since most everyone does lamp installs? [12:04] iszak: Lorentz, because it's not really designed for that. [12:05] deoxxa: DING DING DING [12:05] iszak: I feel node.js blurs the lines however between web server and application. [12:05] stride: it would be nice if the rdbms & nosql folks would discuss some common interface but I'm pretty sure there'll be a time for that [12:05] sideshowcoder has joined the channel [12:05] inimino: "one metafunction that magically infers what you want your application to do and implements all the required pieces to perfection" -- I think this should be in core [12:06] deoxxa: inimino: i think it should be core, period [12:07] inimino: yes :) [12:07] stride: iszak: node.js can't just be used for http servers. why would you want to put stuff in the core that's non-essential? [12:07] inimino: you should implement it [12:07] deoxxa: every application would just consist of one invocation of `node --infer-desires --build-project` [12:07] stride: npm install foo isn't really that hard now, is it? :) [12:07] iszak: stride, is that to say everything in the core is essential? [12:07] stride: deoxxa: can we have --autoupdate-on-clientrequest as well? [12:08] mraleph has joined the channel [12:08] cferris has joined the channel [12:08] stride: iszak: last time I checked it contained a pretty defined set of functionality that's enough for the platform aspect of node, yeah [12:08] inimino: iszak ⋱ Implementing SSL in JavaScript would be completely impractical [12:09] inimino: iszak ⋱ You can still build without it, though. [12:09] stride: I think ryah does a pretty good job on keeping unnecessary stuff out [12:09] iszak: inimino, I never said anything about SSL? [12:09] deoxxa: stride: you just run it recursively to generate a new copy of node that contains that feature! [12:09] stride: deoxxa: great! [12:10] inimino: iszak ⋱ you were discussing crypto support, right? [12:10] Throlkim has joined the channel [12:10] iszak: most specifically things like sha1. [12:11] iszak: oh crap, I'm without crypto if it relies on OpenSSL [12:11] Utkarsh has joined the channel [12:12] Kaitsu has left the channel [12:13] CrabDude has joined the channel [12:14] iszak: hm [12:14] iszak: I guess I see what you mean, if you want database then you'd want say memcached adapters. [12:15] micheil: iszak: why can't you get libssl-dev? [12:16] oal has joined the channel [12:16] iszak: micheil, is that what node.js relies on? [12:16] micheil: yes [12:17] micheil: which, in turn is openssl [12:17] user__ has joined the channel [12:17] iszak: I was wondering why it couldn't find openssl [12:17] micheil: all unix systems (os x included) should have openssl available to them [12:17] iszak: I had OpenSSL however it wasn't finding it. [12:17] micheil: I'm pretty sure the package name is call libssl-dev [12:17] iszak: Install the dev release fixed it. [12:17] micheil: okay [12:17] iszak: Thanks [12:18] micheil: so, you're all good with ssl now? [12:18] iszak: yeah, just remaking it. [12:19] iszak: Why isn't 0.3.0 stable? [12:19] iszak: It's stable for me, is it purely because it's a .0 release? or are there known bugs? [12:25] danslo has joined the channel [12:25] unomi has joined the channel [12:27] sveisvei: iszak: I guess the api is unstable [12:27] iszak: oic. [12:27] sveisvei: 4.0 is next stable release [12:27] iszak: thanks. [12:28] iszak: I would ask when that's to be released but, y'know ;) [12:28] sveisvei: Probably after ssl, and some other internal rewrites land... [12:30] iszak: okay, so is that to say most people aren't using 3.0? [12:30] micheil: iszak: current stable is 0.2.4, 0.3.0 has a lot of changes. [12:31] micheil: we currently recommend people to use 0.2.4 iirc. [12:31] iszak: best more of the software out there is compatible? [12:31] iszak: s/software/classes [12:31] micheil: uhh, well, anything that's changed heavily in 0.3.X should have a backwards compatible API [12:32] iszak: oh nice. [12:32] micheil: like, requiring the "sys" module in 0.3.x will give a warning message, but won't break things terribly bad [12:34] modular has joined the channel [12:40] sveisvei: iszak: btw, watch this http://jsconfeu.blip.tv/file/4306320/ for some of the stuff thats being worked on [12:40] jfd1 has joined the channel [12:42] iszak: thanks sveimac. [12:50] meandi has joined the channel [12:51] skohorn has joined the channel [12:52] bobry has joined the channel [12:52] unomi has joined the channel [12:53] bobry: is it possible to get client's MAC address somehow in node? [12:54] iszak: over HTTP? [12:54] Anti-X: the mac address is only relevant on the local network [12:55] Anti-X: and barely even then [12:55] iszak: that's why online games often ban via mac addresses. [12:55] Anti-X: do they? [12:55] bobry: well, i'm making an app for the local network, so it is the case for me :) [12:55] iszak: Anti-X, quite a few yeah [12:55] bobry: and yeah, i have an http request [12:56] Anti-X: they would then ban the mac address of the user's router [12:56] Anti-X: since that's the one making the socket connection [12:56] iszak: Anti-X, exactly :) [12:56] iszak: often they do mac + IP. [12:57] rnewson has joined the channel [12:57] bobry: so, folks, any hints? [12:57] iszak: don't think you can with http? [13:01] stephank: I doubt you'll see the user's router. You 'lose' the mac address at each hop. Your application server will only see its own router. [13:02] dgathright_ has joined the channel [13:02] stephank: If a game is doing that, it's likely just asking the client the provide its mac address (and ensuring or assuming the client is authentic) [13:03] Anti-X: that's like asking the browser to create a unique idea [13:03] jamescarr has joined the channel [13:03] Anti-X: idea? [13:03] Anti-X: id [13:04] jamescarr: so websockets support cookies [13:04] jamescarr: didnt know that [13:04] Anti-X: JS supports cookies [13:04] stephank: Anti-X: yeah, it'd be about the same. [13:04] jamescarr: Anti-X, duh.Thats comparing apples to oranges [13:04] stephank: bobry: also, in theory, the mac address of the next hop to some host may change during the connection. [13:05] jamescarr: I just didnt know the prototcol for ws supported them [13:05] Anti-X: apples and oranges are the same, aren't they? [13:12] Ezku\_ has joined the channel [13:13] fbits has joined the channel [13:14] JimBastard: ✓ OK » 121 honored [13:14] JimBastard: fucking finally [13:16] Anti-X: yay! [13:16] Anti-X: what? [13:16] jamescarr: 1,258 honored [13:16] jamescarr: :-P [13:16] jamescarr: JimBastard, btw, are you guys hosting nodjistus instances in house, on amazon, or...? [13:17] JimBastard: jamescarr: all your cloud utility providers are belong to us [13:17] jamescarr: lol [13:17] JimBastard: we are gonna switch on ec2 asap [13:17] JimBastard: and then no.de when its ready [13:17] kriszyp has joined the channel [13:17] JimBastard: for now its all rackspacecloud [13:17] JimBastard: is there a good node ec2 wrapper? [13:18] jamescarr: JimBastard, no idea, but it should be a simple matter to set up a chef cookbook to do it [13:19] JimBastard: we really need it as node api calls [13:19] JimBastard: maybe a wrapper or something [13:20] jamescarr: ah [13:20] jamescarr: btw, is no.de still handing out ccounts like candy? [13:20] jamescarr: beta accounts that is [13:20] JimBastard: i get an email everytime i run our test suite [13:20] JimBastard: lol [13:20] Anti-X: how does that help? [13:21] jamescarr: JimBastard, I get the same thing when running paynode's test suites :) [13:21] jamescarr: always get order notifications from Authorize.net [13:22] jfd1 has joined the channel [13:22] kjeldahl_ has joined the channel [13:27] tanepiper: Yea, the good thing with EC2 just now is for new signups, they are handing out free micro instances :D [13:27] tanepiper: node takes a while to compile, but woop! free lunix hosting [13:33] JimBastard: tanepiper: you have no idea, i've been watching 50 servers install node at a time all week [13:33] JimBastard: >>>><<<<< [13:36] fbits has joined the channel [13:37] tanepiper: JimBastard: that's quite a lot of node :D [13:37] tanepiper: A _____ of nodejs (fill in the blank :D) [13:38] stephank: boatload, metric effton, giant pile, whoopla [13:38] johan_bouveng: morning [13:39] iszak: I can't seem to get the stats object.. [13:40] iszak: fs.Stats? [13:40] stephank: We should settle on an official group word for node.js. You know, like “a pack of mongrels”, only for node. [13:40] frodenius: node -> graph? [13:40] frodenius: a graph of nodejs? [13:40] stephank: hehe, not bad not bad [13:40] iszak: nvm [13:41] smtlaissezfaire has joined the channel [13:42] stephank: oh, the term I was looking for is apparently 'collective noun' [13:43] JimBastard: ninjas [13:44] JimBastard: fucking those node ninjas taking all our money and women [13:44] JimBastard: ACTION shakes fist [13:44] johan_bouveng: hi, im rather new to node, rather old to web dev and js. im missing som more advanced tutorial that shows how to solve the most common tasks that you need in a simple webapp. know any one, or have some code somewhere one can peek at? :) [13:44] micheil: the words like "ninja", "pirate", and "rockstar" have been watered down by the popular cult use of them [13:45] micheil: johan_bouveng: common problems like? [13:45] mbrochh has joined the channel [13:47] stephank: wikipedia has lots of fun stuff. You can apparently say 'a cloud of grasshoppers', but cloud is also a really cheesy term these days. [13:47] johan_bouveng: micheil: hm,, smart way to structure your app, if i should define all my routes with get(), how to deal with sessions, authentication, collecting form data, store things in whatever db u use, common app logic, etc. i have installed my node.js on my instance at amazon, along with mongodb,express.js and haml. [13:47] tanepiper: micheil: lets take back ninja for node :D [13:48] tanepiper: ruby can keeps it's rockstars though [13:48] micheil: johan_bouveng: hmm, well, the express documentation should aid as to how to structure your app. [13:48] tanepiper: also: Zed Shaw (ugh) [13:48] femtoo has joined the channel [13:48] johan_bouveng: micheil: yes. but more on code level. [13:48] stephank: tanepiper: he's here, you know [13:48] micheil: johan_bouveng: a common thing I've seen is to take the similar structure of an MVC app from ruby or python and apply it to node (which works fairly well) [13:49] tanepiper: stephank: so? [13:49] stephank: okay, just saying. :) [13:49] johan_bouveng: micheil: im just looking for some more basic tips, perhaps from someone who has built an little webapp, some best practices. its mostly blog and hello world examples. [13:49] johan_bouveng: micheil: :) [13:50] johan_bouveng: micheil: express seems to go the mvc route, thats ok. [13:50] micheil: johan_bouveng: well, with node, the design patterns that we've used in previous frameworks can be brought across, being node is so new, there isn't really any "best practices" [13:50] johan_bouveng: micheil: i just want to see and learn from others before me. [13:51] johan_bouveng: micheil: instead of "solving" all things myself. [13:51] micheil: well, with using express there isn't much that you need to "solve", imo. [13:51] johan_bouveng: micheil: for example, lots of people using a httpd in front of node, not many people say why. [13:51] micheil: depends on your needs. [13:52] johan_bouveng: micheil: im want to build a simple app, that allows users to register, along with some metadata, then be able to list that . [13:52] micheil: johan_bouveng: okay, that was on recommendation from ryah, being node is so new, any exploits that may possibly exist could be minimised by fronting with something like nginx [13:53] stephank: also caching, load balancing, I suppose? [13:53] micheil: yeah [13:53] johan_bouveng: micheil: okay. hmm. i just used to iptabels to front my node to port 80. [13:53] micheil: and stability iirc. [13:53] johan_bouveng: what are the common issues? [13:53] micheil: johan_bouveng: that's a perfectly fine solution [13:53] johan_bouveng: load balancing i can do on another level since im at amazon [13:54] johan_bouveng: micheil: yeah it seemed like the simplest sol. [13:54] micheil: johan_bouveng: consider that the recommendation to front node with nginx or lighty was one from about a year ago (iirc) [13:54] johan_bouveng: its a rather fresh project [13:54] johan_bouveng: most stuff is like a couple of months old. [13:54] johan_bouveng: but i like it alot. [13:54] johan_bouveng: being an old js ninja. [13:55] micheil: like, if your application is going to have hundreds of different routes, you might want to look into not having all your routes in one file (or declare routes in one file and use resources from other files) [13:55] res99 has joined the channel [13:55] johan_bouveng: and i have this txt file where i have put all my setup related things into. [13:56] johan_bouveng: micheil: it will probably wont have 100s, perhaps 5,6 different. /,/register,/login,/forgot,/list,/detail [13:56] micheil: okay, in which case, you could do something like... [13:56] johan_bouveng: /detail/:id [13:57] micheil: ACTION is just loading some stuff up. [13:57] johan_bouveng: =) [13:58] johan_bouveng: really tried to find documentation yesterday on how to extract the createdate (which is hidden inside the _id) from a document in mongodb. [13:59] johan_bouveng: i also wonder if that id is static once set, or if it changes on update, if its good enough to use as a unique key [14:00] micheil: http://d.pr/XRxI [14:00] micheil: that's how you could theoretically structure a large app. [14:00] dguttman has joined the channel [14:01] johan_bouveng: micheil: mm mvc [14:01] micheil: then you'd just require() in each of the files and set your routes in routes.js [14:01] Anti-X has joined the channel [14:01] micheil: then server.js just creates the express server and loads up routes.js calling them in passing the context of server.js [14:01] micheil: or something [14:02] johan_bouveng: micheil: have u built anything fun? [14:02] micheil: there's really no hard rule as to how you structure your apps [14:02] jacobolus has joined the channel [14:02] micheil: johan_bouveng: I've mainly been working on core & node-websocket-server [14:02] micheil: although, I do have a few small (closed-source) apps [14:02] johan_bouveng: oh u dev on node? [14:02] micheil: yeah [14:03] micheil: so do all these people: https://github.com/ry/node/contributors [14:04] mape_: exlusive club ;) [14:04] olivvv_: if I do a search on server.js in the node_chat example, there is no response.end [14:04] olivvv_: how does it output ? [14:05] micheil: olivvv_: you don't exactly need to call response.end() to output data [14:05] micheil: each time you do a response.write() it writes to the socket [14:05] micheil: .end() actually writes the optional data it's passed and then closes the connection [14:06] micheil: olivvv_: things to look into here would be long polling and comet [14:06] sixtus42 has joined the channel [14:06] johan_bouveng: micheil: ok nice =) [14:06] stride: ACTION thinks micheils structure is clearly lacking ./tests/, ./magic/, ./dirty-workarounds/ [14:06] johan_bouveng: micheil: where u based? [14:07] micheil: stride: I'm always lacking tests, you should know that, ;P [14:07] micheil: johan_bouveng: australia [14:07] micheil: (currently) [14:07] johan_bouveng: micheil: im in sweden, working in copenhagen [14:07] stride: micheil: you could at least start symlinking ./tests/ to /dev/null or something with all the TDD/BDD guys in here :> [14:07] olivvv_: micheil:I'm trying to get the basics of the syntax [14:08] micheil: stride: true. Actually, did I mention I now have a testing strategy for node-websocket-server? [14:08] olivvv_: and I'd like to understand how the example works [14:08] micheil: olivvv_: the chat example (imo) isn't the best example [14:08] stride: micheil: no way. let me guess, you open an example in your browser and see if it works? :) [14:08] micheil: stride: that was the old way. [14:08] olivvv_: micheil:then with what should I start ? [14:09] micheil: stride: I "stole" this method from felixge [14:09] micheil: olivvv_: I'd recommend the tutorials on howtonode.org and nodecasts [14:09] johan_bouveng: micheil: have read some of isaacs stuff. [14:10] stride: olivvv_: what's it you're trying to build? [14:10] micheil: johan_bouveng: uhh, like? [14:10] micheil: ACTION didn't think isaacs blogged.. [14:10] tanepiper: anyone know anythign about manpath? doing a fresh install of node + npm and it says: It seems /home/tanepiper/node/share/man might not be visible to man [14:10] johan_bouveng: micheil: some of his blog posts regarding node, set up, cant remember exactly what at the moment. [14:10] tanepiper: so I do MANPATH="$HOME/node/share/man" [14:10] tanepiper: but it still complains [14:10] micheil: tanepiper: hmm.. I think there's an env variable for that.. not sure, like $PATH I think. [14:11] tanepiper: micheil: yea, MANPATH apparently, but it still complains [14:11] micheil: tanepiper: `man` may not read that directory, it's just a friendly warning I'm guessing [14:12] tanepiper: hmm actually, yea manpath does seem to see it [14:12] tanepiper: weird [14:12] micheil: tanepiper: I'd take it as a friendly warning. [14:12] olivvv_: stride:well, a chat thingy would be a good achievement [14:12] fbits has joined the channel [14:14] stride: olivvv_: the Socket.IO node package has a chat example, that's a lot smaller and comprehensable than the full chat demo thingy iirc - maybe that'll help you to get started [14:16] mif86 has joined the channel [14:16] ceej has joined the channel [14:16] liar has joined the channel [14:17] micheil: I swear markdown parsers are crazy. [14:21] braddunbar has joined the channel [14:23] dnolen has joined the channel [14:24] c4milo has joined the channel [14:24] johan_bouveng: micheil: looking at the node-boilerplate to get ideas =) [14:27] WRA has joined the channel [14:27] smtlaissezfaire has joined the channel [14:27] tanepiper: hmm, anyone know anything about the traits package in npm? [14:27] tanepiper: i'm getting a weird exception since i've done a fresh install of node-couchdb, which uses it [14:29] tanepiper: https://gist.github.com/029a9300293ede06fa1a [14:30] tanepiper: but it worked before i did a clean install [14:30] ooooPsss has joined the channel [14:31] path[l] has joined the channel [14:31] micheil: hey, ryah_, when we reverted back to waf, we forgot about including the make doc stuff in there. [14:33] stride: wasn't there an introduction to developing C / C++ modules for node somewhere? can't remember the title to search for.. [14:34] micheil: stride: there's some basic documentation on the node api documentation [14:34] micheil: but I will be looking to expand on that. [14:35] stride: oh. great, I missed that. thanks [14:35] micheil: there's also some repo out there, but I can't remember the name of it. [14:36] stride: that's okay, just needed a rough starting point [14:37] Athox has joined the channel [14:37] faust45 has joined the channel [14:39] johan_bouveng: micheil: what you do you think would be a nice way to do templating etc? haml? ejs? [14:39] micheil: hmm, question: with http://static.brandedcode.com/node-doc/ should the individual pages have tocs? [14:40] micheil: johan_bouveng: I quite like Jade [14:40] micheil: johan_bouveng: it's like HAML sans the %'s [14:40] Anti-X has joined the channel [14:41] johan_bouveng: micheil: ah ok, havent looked at it really. will do. thanks. i do like the control you seem to have in ejs, and the flexibility. [14:41] micheil: johan_bouveng: I've not used ejs to be honest [14:42] softdrink has joined the channel [14:44] tanepiper: gahh! couchdb in npm is node felixge's node-couchdb [14:44] tanepiper: how annoying [14:45] qFox has joined the channel [14:45] micheil: tanepiper: heh, watch out with those sort of things. [14:45] johan_bouveng: micheil: nah ok, nut u have seen the syntax? [14:45] blaines has joined the channel [14:45] johan_bouveng: micheil: but [14:45] micheil: no, I haven't. [14:46] johan_bouveng: micheil: oh ok, u have template , page.ejs and u feed it a object with data [14:46] micheil: tanepiper: what do you think of this style of permalinking? http://static.brandedcode.com/node-doc/http.html#CLIENT_GETPEERCERTIFICATE [14:46] johan_bouveng: micheil: template contains

<%something%> [14:46] tanepiper: micheil: this the new docs? [14:46] micheil: yeah, ruby-esque [14:46] micheil: tanepiper: yeah. [14:47] micheil: tanepiper: I'm trying to figure out the best way to format them [14:47] marshall_law has joined the channel [14:47] tanepiper: looks fine to me, athough how will you display it as an index? [14:47] micheil: as an index? [14:48] micheil: http://static.brandedcode.com/node-doc/index.html [14:48] tanepiper: yea, but that is just the modules, not the methods [14:48] fangel: looks good - but would be cool if classname cross-linked (ie, right now you have EventEmitter in , but it would be nice if it linked to the docs on EventEmitter) [14:48] tanepiper: there is nothing linking to client.getPeerCertificate [14:48] micheil: tanepiper: yeah [14:48] micheil: true [14:49] johan_bouveng: micheil: u tweet btw? [14:49] MattJ100 has joined the channel [14:49] micheil: I'm not sure if I should generate the TOC per section onload or make the doctool do it. [14:49] fangel: but I take it the raw docs are just something `EventEmitter`, which would make it hard to detect which are inline examples, and which are class-references [14:49] micheil: johan_bouveng: feel free to google me. "Micheil Smith" [14:50] bradleymeck has joined the channel [14:50] nsolsen has joined the channel [14:50] micheil: fangel: https://github.com/ry/node/raw/e190c9616ed0b05eb66e1ae6681a8bb4a5f5f3e5/doc/api/net.markdown [14:51] johan_bouveng: micheil: :) feel free to google me "Johan Bouveng" [14:51] johan_bouveng: kind of obvious, heh [14:51] micheil: johan_bouveng: I generally have no real interest in googling people unless they're going to hire me. ;P [14:52] fangel: exactly.. so it's hard to tell the difference between `timeout` and `EventEmitter`, so hard to know that `EventEmitter` should link to events.html#EventEmitter.. could be done, but would probably be hard.. [14:52] johan_bouveng: hah [14:52] johan_bouveng: micheil: http://twitter.com/jbouveng [14:52] micheil: johan_bouveng: heh, okay [14:52] fangel: *so it's hard to know that.. what's up with my spelling today [14:54] micheil: fangel: I'm not sure what you mean.. [14:54] micheil: fangel: timeout is on a different page to eventemitter [14:54] micheil: timers: http://static.brandedcode.com/node-doc/timers.html [14:54] micheil: events: http://static.brandedcode.com/node-doc/events.html [14:55] fangel: I'm just suggesting that when you read the docs on http://static.brandedcode.com/node-doc/http.html, on http.Server - it says "this is an `EventEmitter` with .." - it would be cool if `EventEmitter` linked to the docs on EventEmitter [14:55] micheil: oh [14:55] micheil: yeah, that'll be coming. [14:55] micheil: for now I'm working on other stuff [14:56] dmachi has joined the channel [14:56] micheil: hey dmachi [14:56] micheil: dmachi: long time no see. :) [14:56] fangel: and then suggesting that it's a non-trivial thing to do, because of conflicts of operators ( `keyword` is used for both class-references and inline code), and because of possible naming conflicts (ie, http.Client vs something.Client) [14:57] micheil: fangel: it'd be done manually. [14:57] fangel: well, that's no fun.. ;) [14:57] micheil: fangel: doing it automatically could run into all sorts of trouble. [14:58] fangel: but probably the best solution, without changing the raw docs to have some more info on references [14:58] micheil: well, yeah, it'd be a change made to the raw documentation. [14:58] micheil: I think that would be the best way to go. [14:58] fangel: I agree [14:59] micheil: (like interwiki links) [14:59] fangel: yeah.. [14:59] johan_bouveng: micheil: regarding buffering.. is there some way to do flushing? or do i think the wrong way now regards node= [14:59] micheil: but for now I'm working on the compiling side of things [15:01] fangel: you _could_ do something like markdown links with references that are autogenerated - like [EventEmitter][xref-events-EventEmitter] and then prepopulate the list of known references in the Markdown parser with all the cross-references (I've done something similar for another project) [15:01] micheil: johan_bouveng: net.Stream has a flush method. [15:01] micheil: johan_bouveng: so, I think it'd be res.flush() [15:01] johan_bouveng: nice =) [15:01] micheil: fangel: yeah, but the markdown parser is hardly nice. [15:01] johan_bouveng: chunked responses are rather hot [15:02] fangel: of course that would make the standard docs "uncompilable" without a link-ref-prepopulator.. soo [15:02] johan_bouveng: html -> div.head -> flush() -> div.body. =) [15:02] rauchg_ has joined the channel [15:03] micheil: johan_bouveng: each time you call res.write() it tries to write to the socket, iirc. [15:03] fangel: if you use the "standard" Showdown parser, it's fairly easy to pre-populate it with initial link-references.. but with the showdown-node library it's harder because it hides access to the Showdown object - but other ways are probably a better idea.. :) [15:04] micheil: fangel: I'm actually thinking a simpler parser is possible, but I've been told it's not possible. [15:04] johan_bouveng: micheil: okay, handy to know, take care, got to get something to eat, nice talking to you, id follow u on twitter. [15:05] johan_bouveng: micheil: and btw, we are always looking for bloodthirsty developers at my work. [15:05] micheil: johan_bouveng: fwiw. you can find me pretty much anywhere on the net as "miksago" [15:06] johan_bouveng: but are u australian? or ju just ended up there? [15:06] johan_bouveng: micheil dosent sound so au. =) [15:06] confoocious has joined the channel [15:06] confoocious has joined the channel [15:06] micheil: johan_bouveng: I'm definitely australian. [15:06] fangel: micheil: a simpler-than-Markdown parser to parse the doc-Markdown-subset, or a simple-than-Showdown parser to parse the doc-Markdown-subset? [15:07] micheil: the name has scottish (or "hippy" as mikeal likes to put it) inspiration [15:07] johan_bouveng: micheil: 100%? [15:07] johan_bouveng: ok [15:07] johan_bouveng: its almost a eastern europe spelling of michael. [15:07] fangel: .. are you sure you're aussie? you haven't written "heaps" yet - that's normally my way of spotting aussies ;) [15:07] micheil: johan_bouveng: well, no-ones' 100% "australian", but considering born and breed, then yes. ;P [15:08] micheil: fangel: there's heaps of us aussies here, we just like hiding. [15:08] johan_bouveng: ok =) [15:08] micheil: same with the kiwi's [15:08] micheil: :P [15:08] johan_bouveng: micheil: http://tradeshift.com/?jobs :) [15:09] fangel: well, it's hard to spot kiwi's because you can't hear if they pronounce vowels when you only see their writing.. :P [15:09] fangel: (okay, will stop silly stereotypes now) [15:09] micheil: fangel: haha, true [15:10] stride: "As a minimum know the rules of foosball" heh.. :D [15:10] sixtus42: checkout this guy http://www.collegehumor.com/video:1941875 [15:11] boaz has joined the channel [15:12] fangel: well, football is.. difficult.. for aussies, because it could be Soccer, NFL or AFL.. way too many options... :) [15:12] malkomalko has joined the channel [15:13] stride: "stuff involving men chasing a ball" [15:15] fangel: well, that could be almost any sport.. cricket partly involves chasing a ball, but that still doesnt make it football ;) [15:15] micheil: stride: hey, gotta be politically correct: "sports involving people chasing balls" [15:16] jagwio_ has joined the channel [15:19] gf3 has joined the channel [15:19] aconbere has joined the channel [15:22] mape_: Would would I go about to cause this: { message: 'assertion error', stack: [Getter/Setter] } Error: assertion error at node.js:27:17 at Timer.callback (timers.js:92:28) at node.js:616:9 ? [15:23] micheil: mape_: what node version? [15:23] mape_: Latest from github [15:24] mape_: v0.3.1-pre [15:24] micheil: mape_: hmm.. [15:26] micheil: I really hate process.assert() [15:27] tanepiper: the clue is in ass [15:27] micheil: assert(first !== peek(list)); [15:27] micheil: that's what's throwing. [15:27] micheil: as to why, I'm not sure. [15:27] faust45 has joined the channel [15:28] micheil: mape_: got some example code? [15:28] mape_: micheil: Not really, the app is closed source and like 2k loc [15:29] micheil: oh. ouch [15:29] mape_: And since there is no trace to find where stuff breaks it isn't easy to know what breaks [15:30] mAritz has joined the channel [15:32] unomi has joined the channel [15:33] slaskis_ has joined the channel [15:33] jfd1 has joined the channel [15:33] jchris has joined the channel [15:34] d0k has joined the channel [15:35] micheil: mape_: the most I could do is make guesses [15:37] mape_: Have any good ones? ;) [15:37] micheil: umm, net.setTimeout or similar [15:39] micheil_mbp has joined the channel [15:42] rauchg_: mape_: [15:43] rauchg_: i've got that [15:43] rauchg_: many times [15:43] rauchg_: as well [15:43] mape_: rauchg_: Yeah using socket.io [15:43] rauchg_: not sure [15:43] rauchg_: how to debug [15:43] rauchg_: :D [15:44] mape_: Yeah, while we are at it, you know how to "fix" "Data incorrectly framed by UA. Dropping connection" when using socket.io? [15:44] mape_: the flash implementation that is broke? [15:44] rauchg_: i think we might need to buffer the data received [15:44] rauchg_: until we get another frame [15:45] rauchg_: another null byte [15:45] rauchg_: i'll look into it when i get back [15:45] booths has joined the channel [15:45] Moominpapa: Anyone seen this error from vows? "Cannot read property '_skip' of undefined" [15:45] mape_: rauchg_: Awsome :) [15:45] mbrochh has joined the channel [15:46] softdrink has joined the channel [15:49] slaskis has joined the channel [15:50] bnoordhuis has joined the channel [15:52] Athox has joined the channel [15:53] DoNaLd`: some of applicable porocedure as translate EJS template for more languages ? [16:01] oal has joined the channel [16:01] saschagehlich has joined the channel [16:04] BillyBreen has joined the channel [16:08] nolkyan has joined the channel [16:09] johngbrooks has joined the channel [16:11] modular has joined the channel [16:15] Max-Might has joined the channel [16:15] eee_c has joined the channel [16:20] steadicat has joined the channel [16:22] tapwater has joined the channel [16:23] gerad has joined the channel [16:24] bpot has joined the channel [16:26] steadicat has joined the channel [16:26] gerad has joined the channel [16:28] Utkarsh has joined the channel [16:29] cloudhead has joined the channel [16:31] smtlaissezfaire has joined the channel [16:31] elijah-mbp has joined the channel [16:31] JohnDav has joined the channel [16:32] Anti-X has joined the channel [16:34] _mythz has joined the channel [16:34] modular^2 has joined the channel [16:35] brianmario has joined the channel [16:36] omarkj has joined the channel [16:42] oal has joined the channel [16:43] Utkarsh has joined the channel [16:43] smtlaissezfaire has joined the channel [16:44] micheil has joined the channel [16:46] oal has joined the channel [16:50] Zeph\k0d3: http://blokmodular.com/dev/test19.htm <-- now with improved font handling (as opposed to yesterday http://blokmodular.com/dev/test18.htm ) [16:51] davidascher has joined the channel [16:53] captain_morgan has joined the channel [16:54] Utkarsh has joined the channel [16:55] bpot has joined the channel [16:55] c4milo has left the channel [17:03] micheil: ryah_: still working on the documentation, I'm thinking that maybe it'd be an idea to document a few core concepts, like the callback style & event emitters. [17:03] micheil: so then we have a bit more of an "api" documentation: http://static.brandedcode.com/node-doc/index.html [17:07] aconbere has joined the channel [17:08] unomi has joined the channel [17:10] MikhX has joined the channel [17:10] mape_: Zeph\k0d3: Was thinking of something like this http://mape.me/canvas-test/ [17:13] Zeph\k0d3: :-) [17:13] Zeph\k0d3: trippy [17:14] mape_: Hehe, i find it easy to quickly sweep for differences [17:16] jfd1 has joined the channel [17:16] phiggins has joined the channel [17:17] trotter has joined the channel [17:17] eee_c has joined the channel [17:17] Zeph\k0d3: I think I'd prefer a more static image [17:17] dquestions has joined the channel [17:17] Zeph\k0d3: with A, B, A+B images [17:17] Zeph\k0d3: or even direct pixelmangling A-B since client canvas can do that [17:18] twoism has joined the channel [17:18] mape_: Hmm yeah, would be neat [17:18] Zeph\k0d3: difference plot [17:19] Zeph\k0d3: negated to show maximum difference [17:19] Zeph\k0d3: still - first I need to add LOTS more tests [17:19] javruben: zeph is pretty close to safari though, besides the gradients I only see 2 diffs [17:20] Zeph\k0d3: integration1 is ofcourse different since it depends on random input (will have to remove those) [17:20] javruben: right then only 1 :) [17:20] mape_: seems all text based things are a little of [17:20] Zeph\k0d3: which one? invalid stroke/fill? [17:20] Zeph\k0d3: text rendering is very much AA-dependent [17:20] javruben: yes [17:21] Zeph\k0d3: I am using a different library to calculate the antialiasing [17:21] Zeph\k0d3: so pixelshifts are pretty much unavoidable [17:21] sveimac has joined the channel [17:21] mape_: The awsome one seems to be letter-spacing though [17:21] Zeph\k0d3: yes [17:22] Zeph\k0d3: width of characters is also dependent on the AA kerning etc [17:22] javruben: foo seems to be too bold/not bold enough [17:22] Zeph\k0d3: and subpixel accuracy [17:22] javruben: in fillText() transform [17:22] Zeph\k0d3: bold property is not set yet [17:22] Zeph\k0d3: so that is correct [17:22] danslo has joined the channel [17:22] javruben: k [17:22] mape_: Zeph\k0d3: might be a good idea to work with tj to get a ton of tests, should be beneficial for everyone [17:23] Zeph\k0d3: yeah [17:23] javruben: clip() has a small break on the right in the border [17:23] Zeph\k0d3: seems most of the canvas implementations are revolving around cairo (since that is pretty much where the standard originally came from) which really does not help the industry [17:24] Zeph\k0d3: spec-after-the-fact :( [17:27] booths has joined the channel [17:27] dgathright has joined the channel [17:28] necrodearia has joined the channel [17:33] Zeph\k0d3: http://philip.html5.org/tests/canvas/suite/tests/ we should convert these to serverside [17:37] dquestions has joined the channel [17:38] sudoer has joined the channel [17:39] Draggor has joined the channel [17:44] programble has joined the channel [17:47] davidascher has joined the channel [17:53] jakehow has joined the channel [17:54] jchris has joined the channel [17:56] isaacs has joined the channel [18:00] aconbere has joined the channel [18:05] zomgbie has joined the channel [18:09] booths has joined the channel [18:10] isaacs: ryah_: a cb on write() would be awesome. [18:11] sudoer has joined the channel [18:11] isaacs: ryah_: i just realized how often i do stuff like this: if (!s.write()) s.on("drain", function D(){ s.removeListener("drain", D) ; cb() }) ; else cb() [18:12] isaacs: ryah_: could just be s.write(foo, cb) [18:12] nsolsen has joined the channel [18:12] gwoo has joined the channel [18:13] Anti-X: good idea [18:13] kixxauth has joined the channel [18:13] isaacs: Anti-X: yeah, i think it was ryah_ or mikeal or pquerna who pitched that. [18:15] Blink7 has joined the channel [18:16] jeromegn has joined the channel [18:16] rbranson: why not just allow the write to flush? blocking? [18:18] johan_bouveng: isaacs: hi man. [18:18] johan_bouveng: isaacs: found your writings useful. [18:18] sixtus42 has joined the channel [18:18] isaacs: johan_bouveng: thanks :) [18:18] johan_bouveng: isaacs: so thanks for that. [18:18] isaacs: er, you're welcome :) [18:19] johan_bouveng: isaacs: not so much writings available though :/ [18:19] johan_bouveng: i kind of just jumped on this train. [18:19] isaacs: the node train? [18:19] benburkert has joined the channel [18:19] johan_bouveng: being an agile & pragmatic web dev since > 10 years back, with strong skills in js, this suits me perfectly [18:20] aurynn: toot toot. [18:20] isaacs: johan_bouveng: check this out: http://howtonode.org/ [18:20] johan_bouveng: even more since im rather perf. savvy. [18:20] johan_bouveng: seen it i thin. [18:20] johan_bouveng: talked earlier with micheil [18:20] johan_bouveng: but as a web dev i want to start get apps up there! [18:21] micheil: isaacs: good point with the cb's on write() [18:21] johan_bouveng: still so many fundamental questions unanswered =) [18:21] micheil: isaacs: although, watch with the optional encoding. [18:21] isaacs: micheil: that's not hard to work around. [18:21] johan_bouveng: micheil: i went with jade, after all. [18:21] isaacs: if (typeof encoding === "function") cb = encoding , encoding = null [18:21] micheil: true, but which should be the fast and which should be the slow case? [18:22] micheil: write(data, enc, cb) [18:22] micheil: yeah? [18:22] isaacs: yeah [18:22] isaacs: cb is *always* last [18:22] altamic has joined the channel [18:23] johan_bouveng: is there some nice way of deamonize mongodb or/and node? i just nohup them to background at the moment. [18:23] micheil: isaacs: come to think of it, cb on write would be a great benefit to node-websocket-server [18:23] isaacs: johan_bouveng: that's one way. you can also handle process.on("SIGHUP", function () { don't process.exit }) [18:23] micheil: ACTION would never recommend that. [18:23] isaacs: micheil: you do a lot of if (!write) handle drain? [18:24] micheil: isaacs: nup, more so !write() failed sending of message [18:24] micheil: as I need to group writes together [18:24] isaacs: micheil: well, !write() should still mean "i couldn't send all of this, but i will as soon as i can" [18:24] micheil: yeah [18:24] isaacs: it's not an EAGAIN [18:24] dguttman has joined the channel [18:25] siculars has joined the channel [18:25] johan_bouveng: /etc/init.d/node start,stop,restart would be nice [18:25] JohnDav has joined the channel [18:25] isaacs: johan_bouveng: yeah [18:25] isaacs: johan_bouveng: you can do that by catching SIGHUP, and then having some *other* signal tell it to quit [18:25] isaacs: johan_bouveng: like, listen to SIGUSR1 or SIGKILL or something [18:25] johan_bouveng: perhaps an option to make it --autorestart // on changes, kind of fuzzy to restart it everytime i do dev. [18:26] rbranson: mongodb has --fork [18:26] isaacs: johan_bouveng: check out node-supervisor [18:26] Kami_: johan_bouveng, you can use supervisor, runit or other process manager [18:26] isaacs: johan_bouveng: just for restarting on changes in dev [18:26] johan_bouveng: mm okay, later. is to much info right now :P [18:26] isaacs: supervisor's no monit, and definitely no SMF, but it's handy. [18:27] johan_bouveng: have a setup.txt where i put my steps ive taken, to run it nicely on ec2. [18:27] johan_bouveng: a mix of my own skills, mixed with stuff i picked up on the web. [18:27] isaacs: johan_bouveng: you know, you can also sorta daemonize processes that you just started by disowning them from the shell [18:27] sudoer has joined the channel [18:27] johan_bouveng: and lots of trial and error =) [18:28] isaacs: node my-server.js ; ^Z bg disown [18:28] johan_bouveng: isaacs: mm, nohup works for now. [18:28] isaacs: sure, or nohup [18:28] johan_bouveng: sudo iptables -t nat -A PREROUTING -p tcp --dport 80 -j REDIRECT --to-port 8000 [18:28] johan_bouveng: im bold! [18:28] isaacs: that wont' restart the server if it crashes, though. keep that in mind [18:28] johan_bouveng: node never crashes =)) [18:28] isaacs: HAHAHAH [18:28] rbranson: lol [18:29] johan_bouveng: actually, a hacker friend got it to stop responding by posting alot of wicked chars to it. [18:30] meandi has joined the channel [18:31] isaacs: johan_bouveng: this is a handy trick: process.on("uncaughtException", function (er) { threw an error and it wasn't caught. }) [18:31] johan_bouveng: isaacs: ok, its still beyond my level at this moment :P [18:32] johan_bouveng: isaacs: will deal with such stuff later. [18:32] isaacs: johan_bouveng: process.on("uncaughtException") is like window.onerror [18:32] liar has joined the channel [18:32] isaacs: johan_bouveng: let's you log the error without crashing the server. [18:32] johan_bouveng: isaacs: yeah i get that. [18:32] sixtus42: johan_bouveng: because try{} catch{} wasn't made for async land [18:32] isaacs: johan_bouveng: watch out coming in here, you might get more tricks than you are ready for ;) [18:32] johan_bouveng: its good! [18:33] gerad: johan_bouveng: i use upstart on ubuntu for node [18:33] bartt has joined the channel [18:33] gerad: johan_bouveng: https://github.com/fortnightlabs/lazeroids/blob/master/script/ubuntu-node [18:33] nsolsen has joined the channel [18:34] johan_bouveng: gerad: ok.. om not on ubuntu, im on ami-6a31041e from AMZN :P [18:35] guybrush: there's also a fork of spark, which supports respawning processes on file-changes https://github.com/alexkwolfe/spark [18:35] sixtus42 has joined the channel [18:35] gerad: johan_bouveng: yeah, I'm used to ubuntu and canonical provides amis, so usually use one of those :-) [18:36] Max-Might has joined the channel [18:36] MikhX has joined the channel [18:36] johan_bouveng: need to peep a screencast on jade now, brb. [18:37] johan_bouveng: OH FU*K thats an annoying bird in the background :((( [18:37] johan_bouveng: http://screenr.com/CV0 [18:37] smtlaissezfaire has joined the channel [18:38] captain_morgan has joined the channel [18:40] StanAngeloff has joined the channel [18:40] bradleymeck has joined the channel [18:42] unomi: haha [18:43] unomi: does it end with a shotgun blast and incoherent swearing? [18:44] fcoury has joined the channel [18:45] softdrink has joined the channel [18:47] Athox has joined the channel [18:48] booths has joined the channel [18:52] booths has joined the channel [18:53] sixtus42: johan_bouveng: interesting. can the embedded javascript be async (e.g. conditionally load something in) [18:53] bpot has joined the channel [18:55] qFox: can you please shoot that bird? ;p [18:56] vandenoever has left the channel [19:02] ossareh has joined the channel [19:03] booths has joined the channel [19:03] femtooo has joined the channel [19:04] fbits has joined the channel [19:05] johan_bouveng: isaacs: whats the take on abstracting config etc out in a file and get it in? [19:05] isaacs: johan_bouveng: i do that [19:05] johan_bouveng: isaacs: require() is alwaus commonjs? [19:06] admc has joined the channel [19:07] Utkarsh has joined the channel [19:07] bradleymeck: require in node is commonjs compatible [19:07] johan_bouveng: isaacs: i have a config.js that contains : http://pastie.org/1279683 , would i just import that in my app.js with require('config.js'); ? [19:07] johan_bouveng: i get exeptions on that :P [19:07] micheil: no .js [19:08] micheil: require("./config") [19:08] micheil: but you would need to assign the exports to a local variable [19:08] micheil: var config = require("./config") [19:08] isaacs: micheil: you can also put the .js on it in node [19:08] isaacs: micheil: node is not commonjs compatible in the ways that commonjs is retarded. [19:08] isaacs: :D [19:08] micheil: isaacs: i thought node got whiney about that? [19:09] isaacs: nope. not any more. [19:09] isaacs: in fact, require("./config.js") is faster. fewer stats. [19:09] johan_bouveng: micheil: hmm why ./ its in the same folder as app.js [19:09] isaacs: johan_bouveng: require("blah") is "absolute". it looks in the require paths. [19:09] isaacs: johan_bouveng: require("./bloo") is "relative" [19:10] johan_bouveng: mmm [19:10] johan_bouveng: http://pastie.org/1279692 [19:10] johan_bouveng: my app is undefined. how do i propagate that from config? [19:10] isaacs: johan_bouveng: hook something on the "exports" object [19:10] isaacs: johan_bouveng: you see, it's not just a global dumping ground like the brower. [19:10] johan_bouveng: that good tought :) [19:10] isaacs: johan_bouveng: every module has an "exports" object, and that exports object is what's returned by require() [19:11] isaacs: so, if you do exports.foo = "bar", and then require("./blah").foo === bar [19:11] isaacs: no naming conflicts. [19:11] isaacs: :) [19:11] ryah_: isaacs: yes, it's coming [19:11] ryah_: isaacs: cb on write [19:11] isaacs: sweet :) [19:11] isaacs: ryah_: you see the discussion about req.headers? [19:11] johan_bouveng: hmm [19:12] ryah_: micheil: oops - make doc stuff - can you patch me? [19:12] micheil: ryah_: I shall. [19:12] Aria has joined the channel [19:13] langworthy has joined the channel [19:14] johan_bouveng: isaacs: hm, seems 'bulky'. [19:14] isaacs: johan_bouveng: if you just wanna export one "thing" you can assign it to module.exports [19:14] johan_bouveng: isaacs: do i need to export all stuff from my config? [19:14] ryah_: isaacs: yeah - will reply soon [19:14] ryah_: ACTION away [19:15] isaacs: johan_bouveng: in app.js: module.exports = app ; in other-file.js: var app = require("./app") [19:16] davidascher has joined the channel [19:16] johan_bouveng: isaacs: i dont get that concept, i just tought that things i require would be available to the scope and file im require it to. [19:16] isaacs: johan_bouveng: nope [19:16] trotter has joined the channel [19:17] isaacs: johan_bouveng: that's the whole point. a "var" in one module is *not* shared unless you explicitly export it [19:17] johan_bouveng: ok, but in my example, http://pastie.org/1279683 , i need to export express and app. [19:19] isaacs: johan_bouveng: or you could just do require("express") in both modules. [19:19] isaacs: johan_bouveng: they're only loaded once, and cached [19:19] johan_bouveng: hm, i ditch a config.js for now. [19:19] johan_bouveng: seems to error prone for me to grasp at the moment. [19:19] johan_bouveng: =) [19:20] johan_bouveng: http://tapbit.com/ [19:20] johan_bouveng: there u go. [19:21] twoism has joined the channel [19:22] noahcampbell has joined the channel [19:22] sudoer has joined the channel [19:23] Blackguard has joined the channel [19:23] MikhX_ has joined the channel [19:24] brian_irish has joined the channel [19:25] brian_irish: Noobish question ahead: The easiest method of hitting a redis server via javascript (and possibly the only method) is through Node, yes? [19:25] sudoer has joined the channel [19:27] bartt has joined the channel [19:27] bradleymeck has joined the channel [19:28] Aria: Yeah, I think node is a good way to go for it. Anything that can get a socket or proxy to a socket connected to your code will work though [19:28] sixtus42 has joined the channel [19:28] Aria: But node's pretty much made for that sort of task. [19:28] brian_irish: Aria: Thank you [19:29] boaz has joined the channel [19:30] Throlkim_ has joined the channel [19:31] MikhX has joined the channel [19:31] johan_bouveng: hm, in a .jade, how do i put a static string after my varibale? title= title [19:32] johan_bouveng: title= title (plus something static) [19:32] johan_bouveng: about - example.com [19:32] johan_bouveng: i mean, i have a snippet i want on all pages, but the part in front of that is a locals i pass in [19:38] johan_bouveng: i want to avoid {locals:{title:'welcome - tapbit.com'} {locals:{title:'someotherpage - tapbit.com'} [19:38] langworthy has joined the channel [19:38] johan_bouveng: isaacs: did u die? :) [19:38] isaacs: johan_bouveng: not recently. just tabbed away :) [19:39] isaacs: johan_bouveng: i don't know jade. even a little. that's tj's baby [19:39] johan_bouveng: bah ok [19:39] isaacs: tj is apparently not around atm. he's visionmedia on github [19:39] johan_bouveng: i know. [19:39] johan_bouveng: so little docs :D [19:40] johan_bouveng: and jade's dont fail silently. i dont want to mess with all this logic in my app.js :/ [19:41] johan_bouveng: ..so i lave that out for now. [19:41] johan_bouveng: leave [19:41] johan_bouveng: isaacs: where u from btw? [19:42] aho has joined the channel [19:42] isaacs: johan_bouveng: i live in oakland. from ct originally [19:42] isaacs: you? [19:43] johan_bouveng: sweden, work in copenhagen at startup tradeshift inc. [19:43] micheil: by this time.. johan_bouveng is probably thinking I don't sleep.. :P [19:43] johan_bouveng: nah =) [19:43] johan_bouveng: i dont sleep either. :> [19:44] johan_bouveng: any node meetups in copenhagen area soon? [19:44] johan_bouveng: i want to dive into code, see more examples! [19:45] micheil has left the channel [19:45] micheil has joined the channel [19:45] johan_bouveng: could someone explain the middleware concept? [19:45] johan_bouveng: or is it a express.js thingy? [19:47] kjeldahl has joined the channel [19:48] pdelgallego has joined the channel [19:50] V1 has joined the channel [19:50] johngbrooks has joined the channel [19:50] teemow has joined the channel [19:51] trotter has joined the channel [19:54] johngbrooks has joined the channel [19:55] jimt_ has joined the channel [19:55] twoism has joined the channel [19:59] necrodearia has joined the channel [19:59] bradleymeck: in the context of connect/express middleware is a layer of software between an entry point and developer logic [20:01] bradleymeck: so johan_bouveng, it is akin to what most people use decorators as in Python if that makes sense [20:04] hornbeck has joined the channel [20:04] femtoo has joined the channel [20:05] AAA_awright has joined the channel [20:08] sh1mmer has joined the channel [20:11] omarkj has joined the channel [20:13] omarkj: Hah. Did you guys know that if you do a mathematical operation on two strings that only contain numbers (such as "2") you get a number out? [20:13] omarkj: In JS, so "2" + "2" = 4. Wtfjs indeed.. [20:13] aho: >>> '2'+'2' [20:13] aho: "22" [20:14] gkatsev: v8: "2"+"2" [20:14] v8bot: gkatsev: "22" [20:14] sprout has joined the channel [20:14] sh1mmer: ryah_: ping [20:14] omarkj: Put it in a variable. [20:14] gkatsev: v8: var foo = "2"; foo+foo; [20:14] v8bot: gkatsev: "22" [20:14] captain_morgan has joined the channel [20:15] omarkj: Huh, well, then my interpreter is behaving oddly. [20:15] antris_: var foo = "2"; var bar = "2"; foo+bar; [20:15] antris_: v8: var foo = "2"; var bar = "2"; foo+bar; [20:15] v8bot: antris_: "22" [20:15] gkatsev: omarkj: what are you using? [20:15] sixtus42: omarkj: I think it's v8 behaving "oddly" [20:15] AAA_awright: v8: 2+"2" [20:15] v8bot: AAA_awright: "22" [20:15] omarkj: I think this machine has node 0.2.4 [20:15] gkatsev: v8: +"2"+ +"2" [20:15] v8bot: gkatsev: 4 [20:15] Utkarsh has joined the channel [20:16] omarkj: https://gist.github.com/666379 [20:16] AAA_awright: That's multiplication [20:16] aho: v8: (+'2') + (+'2') [20:16] v8bot: aho: 4 [20:16] aho: nicer with some parens in place [20:16] gkatsev: omarkj: typeof isn't a function, fwiw. [20:16] omarkj: AAA_awright: True, but it also worked the other way around. [20:16] gkatsev: v8: "2"*"2" [20:16] v8bot: gkatsev: 4 [20:17] AAA_awright: v8: "2"*1 + "2"*1 [20:17] v8bot: AAA_awright: 4 [20:17] gkatsev: v8: ~~'2'+~~'2' [20:17] v8bot: gkatsev: 4 [20:17] omarkj: haha [20:17] AAA_awright: v8: "2.1"*1 + "2.1"*1 [20:17] v8bot: AAA_awright: 4.2 [20:17] gkatsev: yeah, ~~ makes it an ing [20:18] AAA_awright: v8: ~~"2.1" + ~~"2.1" [20:18] v8bot: AAA_awright: 4 [20:18] gkatsev: bit wise operations in javascript cast the stuff into 32bit signed ints [20:18] AAA_awright: I wonder if it's any faster than >>0 or parseInt or Math.floor or any of the other ways you can cast [20:19] gkatsev: it isn't faster than >>0, but on all but v8 it is faster than parseInt [20:19] jesusabdullah: I'd imagine that Math.round would more often be the behavior you're looking for, not Math.floor [20:19] gkatsev: v8 looks like it did some fancy stuff to make parseInt be really fast [20:19] Ori_P_ has joined the channel [20:19] gkatsev: brb [20:26] brian_irish has left the channel [20:27] omarkj: I'm wondering where the node.js issue tracker is? I'm guessing it's not at github, since the issue there seem old. [20:27] jesusabdullah: That's not it? [20:27] benburkert has joined the channel [20:28] omarkj: jesusabdullah: That's why I'm wondering where it is. [20:29] bpot has joined the channel [20:31] Aria: As far as I know, that's it... [20:31] stride: yeah, that and the mailing list. the dates of those github issues seem weird though [20:32] kgf: it sorts from oldest first...click More a few times... [20:32] kgf: "created about 16 hours ago" on the last open one. [20:32] kgf: that seem old? :P [20:32] omarkj: Nope, thanks. [20:33] kgf: and yes that's the real tracker, a request I entered there got fixed so I can say that with some certainty ;) [20:33] stride: kgf: oh.. :) [20:35] _mythz has left the channel [20:35] ryah_: pquerna: re that paper - it's assuming the gossip is over udp - and they implement their own flow control [20:36] ryah_: why not use tcp flow control - [20:36] ryah_: just don't send updates when the send buffer is full [20:38] ryah_: i would layer all this stuff under an ssl connection [20:38] ryah_: im not going to try to do some crazy udp thing [20:39] sh1mmer: is .exit not exiting on REPL an expected behaviour under any conditions? [20:39] sh1mmer: ryah_: did you get my email? [20:40] softdrink has joined the channel [20:40] ryah_: sh1mmer: yes - will attempt today [20:40] sh1mmer: ryah_: appreciated [20:41] bartt has joined the channel [20:41] johan_bouveng: ryah_: do you have a cat? [20:41] ryah_: johan_bouveng: .. no [20:41] sh1mmer: I noticed that REPL won't quit with .exit if, for example, an HTTP server is running [20:41] ryah_: sh1mmer: .exit probably just closes stdin? [20:42] sh1mmer: I was just trying to find that [20:42] sh1mmer: it should really quit [20:42] johan_bouveng: ryah_: ok. ya know, they emmit 50w worth of heat in 24h, i can see why isaacs has two. [20:42] sh1mmer: I think, anyway [20:42] tapwater_ has joined the channel [20:42] isaacs: sh1mmer: you might not want that, though [20:43] johan_bouveng: ryah_: my cat loves node.js, since its fishy ;) [20:43] sh1mmer: isaacs: for example? [20:43] sh1mmer: isaacs: I mean if that's a desired behaviour I would add a .graceful or something [20:43] isaacs: sh1mmer: let's say you start a repl on a socket so that you can connect and see your http server's status [20:44] isaacs: sh1mmer: you'd want .exit to just close the session, not kill the node process. [20:44] sh1mmer: isaacs: that makes sense, it just seems counter-intuitive that you have to send an interupt to kill the shell under some conditions [20:45] sh1mmer: that was one of the things that came up in class on Thursday [20:49] isaacs: i see [20:49] robmason has joined the channel [20:49] zomgbie has joined the channel [20:50] isaacs: maybe it could check to see if it's the main module or something, and map .exit to process.exit [20:50] isaacs: but i dunno, i really like .exit just doing ^D [20:50] isaacs: if you wanna kill it for realsies, you use ^C [20:50] isaacs: actually, .exit is more typing, and unnecessary [20:51] rikarends has joined the channel [20:51] dguttman has joined the channel [20:54] johan_bouveng: isaacs: whats the names of ur cats? [20:54] isaacs: johan_bouveng: aristotle and sage [20:54] johan_bouveng: isaacs: myone is named alfons. that means pimp in danish slang. [20:54] isaacs: johan_bouveng: i don't have them for the heat, though. i have them to make my life miserable. [20:54] isaacs: see, what happens is, people get too happy, and then they have kids. [20:55] johan_bouveng: they do to have that impact tough.. [20:55] isaacs: then it's all downhill for like 20 years [20:55] johan_bouveng: i have a cat instead. [20:55] johan_bouveng: isaacs: http://twitter.com/#!/jbouveng [20:55] isaacs: right [20:55] isaacs: cat's are more manageable [20:58] johan_bouveng: true developers have cats. [20:58] gkatsev: cats ftw! [20:58] johan_bouveng: ryah_: http://twitter.com/#!/jbouveng/status/27551099945 [20:59] gkatsev: johan_bouveng: what screen cast? [20:59] johan_bouveng: gkatsev: the peepcode one. [20:59] gkatsev: link? [20:59] johan_bouveng: gah [20:59] johan_bouveng: ok [20:59] johan_bouveng: http://peepcode.com/products/nodejs-i [21:00] gkatsev: thanks [21:00] johan_bouveng: i have a zip if you want. [21:00] gkatsev: that would be cool. [21:00] johan_bouveng: #tradingwarezinnodechannelftw [21:00] gkatsev: lol [21:01] johan_bouveng: add me on skype johan.bouveng [21:01] gkatsev: this channel is being logged [21:01] johan_bouveng: i WONT serve the zip with node.js [21:01] johan_bouveng: that would be funny tough. [21:01] gkatsev: lol [21:01] johan_bouveng: :D [21:02] gkatsev: I should probably change my skype picute. It is a terrible one. [21:02] johan_bouveng: gkatsev: it is. [21:02] johan_bouveng: how old are you? [21:02] gkatsev: 21 [21:02] stagas has joined the channel [21:02] johan_bouveng: ok. [21:02] johan_bouveng: im 31. [21:02] gkatsev: though, that pic is probably from when I was like 19 or 20 [21:03] twoism has joined the channel [21:04] johan_bouveng: decent speed. where u located? [21:04] gkatsev: boston, MA, USA [21:04] johan_bouveng: okay. [21:04] gkatsev: 20Mb down [21:04] johan_bouveng: sweden [21:04] Athox: sviden? [21:05] johan_bouveng: javisst! [21:05] johan_bouveng: gkatsev: 100/100 is default in sweden. [21:05] gkatsev: I wish [21:05] johan_bouveng: gkatsev: and blonde vicious girls. [21:05] gkatsev: heh [21:05] gkatsev: here the highest you can get is like 50/30 and you pay like $200 a month for that [21:06] gkatsev: highest residential speed is 50/20 [21:06] gkatsev: oh, only 140 a month [21:07] johan_bouveng: uh [21:07] CIA-93: node: 03Guillaume Tuton 07master * r07da49b 10/ (2 files in 2 dirs): [21:07] CIA-93: node: Set FD_CLOEXEC flag on stdio FDs before spawning. [21:07] CIA-93: node: With regression test. - http://bit.ly/9s9KkR [21:08] unomi: who's got the 0-day screencasts? [21:08] johan_bouveng: i pay like 50 dollars for my connection [21:08] jesusabdullah: I mooch off my neighbor [21:08] johan_bouveng: unomi: what? [21:08] gkatsev: johan_bouveng: it is 140 for internet, cable and phone. it is like 150 for just the internet. [21:08] jesusabdullah: That makes me a douchebag :( [21:08] unomi: http://peepcode.com/products/nodejs-i [21:08] johan_bouveng: unomi: would not call that 0day, but i have it. [21:08] unomi: get that up as a torrent asap :p [21:08] unomi: I'd like it [21:10] johan_bouveng: well, scroll history then. [21:10] fangel: I have a 35/2mbit and pay roughly 50$ for it.. [21:11] fangel: not quite Sweden.. but hey, I not far away, soo.. :) [21:12] femtoo has joined the channel [21:12] fangel: (neither price-wise or geographically) [21:12] mape_: johan_bouveng: Wouldn't say default :) Quite a lot of people who are still on ADSL [21:12] unomi: I get 6/1 for 15$ [21:13] unomi: :| [21:13] johan_bouveng: mape_: well, hm ok. :) [21:13] gkatsev: mape_: default for non-dsl? [21:13] Kami_: you can get 100/100 here in some places for 50� [21:13] Kami_: ftth of course [21:13] mape_: gkatsev: More often it is 30/30 or 100/10 [21:14] gkatsev: still better/cheaper than I have here, lol [21:14] jevin has joined the channel [21:14] BHSPitMonkey has joined the channel [21:15] robmason_ has joined the channel [21:16] jesusabdullah: unomi: Sounds cheap. That's good at least right? [21:16] robmason__ has joined the channel [21:16] halfhalo: ACTION pays way to much for way to little [21:17] ehaas has joined the channel [21:17] jevin: i'm having trouble pausing and resuming a fs ReadStream. when it resumes, it seems like it has lost data. here is the test im runnning: https://github.com/jevinskie/jevshell/blob/master/stream_test.js [21:17] unomi: well, 6mbit / 1mbit within thailand atleast :p for outside connections the dl rate rarely goes higher than 1-200kb/s [21:17] unomi: still, its fine for what I need [21:17] halfhalo: ACTION pays 55 for 15/1 from Time Crapper [21:17] jevin: i want to pause the stream, wait for the inter-frame delay, and then resume it [21:17] jevin: this is a port of the ascii star wars, btw :) [21:17] jesusabdullah: time crapper? [21:18] jesusabdullah: Oh, time-warner? [21:18] gkatsev: probably [21:18] jesusabdullah: Time Crapper sounds like a supervillain [21:18] gkatsev: lol [21:18] jesusabdullah: One thing with Alaska that's almost cool is that noe of the Big Guys are up here [21:18] jevin: also used is my framer module, it buffers N lines into a frame (requires 'lines' module) https://github.com/jevinskie/jevshell/blob/master/modules/framer.js [21:18] jesusabdullah: I mean, people still have monopolies, but they're much smaller [21:18] gkatsev: is he a supervillian on Time Cop or whatever that movie was called? [21:19] Aria: "Slime Warmer" [21:19] halfhalo: The issue is I live up in the hills, and the only internet save for dial up is through them [21:19] jesusabdullah: I was thinking "Jay and Silent Bob Strike Back" [21:19] gkatsev: satelite [21:19] jesusabdullah: "Bluntman and Chronic?" [21:19] Kami_: jevin, some data will still come in, so you need to buffer it before you pause [21:19] halfhalo: satelite uses dialup for the upload :/ [21:20] Aria: Not all. Most of the second gen satelite systems send on the sat channel. [21:20] Aria: (Wild Blue, Hughes, Direct, Dish Network) [21:20] derferman has joined the channel [21:20] jevin: Kami_: i dont follow. some data will still come in after what exactly? or do you mean some more data will come in after pause() and that needs to be buffered/ [21:21] halfhalo: ACTION is still mad that his directv wants a phone line... I mean... cmon... [21:21] jesusabdullah: drm BS? [21:22] halfhalo: not so much that but daily check in's + ppv [21:22] gkatsev: anyone know of a good tutorial for ejs? [21:22] ryah has joined the channel [21:22] johan_bouveng: gkatsev: look at the ruby ones, almost the same, i went with jade instead. [21:23] gkatsev: jade is another templating language? [21:23] gkatsev: I am wondering because I am thinking of using node-boilerplate which uses ejs and express by default [21:24] jesusabdullah: jade is kinda like haml iirc [21:24] gkatsev: ah [21:24] mape_: jup [21:25] mape has joined the channel [21:25] gkatsev: what about mustache? [21:25] jesusabdullah: I want a templating system that works well with latex, personally [21:25] mape: mustache, haml, jade, ejs, ntpl ... [21:26] gkatsev: heh, peepcode's prompt has a smiley face [21:26] gkatsev: jesusabdullah: heh, I have yet to figure out latex. [21:26] gkatsev: I may do that next semester for labwork for physics [21:27] gkatsev: anyone uses node-boilerplate? [21:27] jesusabdullah: gkatsev: Latex isn't too bad to start picking up. I recommend the latex wikibook, personally. [21:27] fangel: I use Jazz (https://github.com/shinetech/jazz) - although my use-case was HTML, I'm fairly sure it should be language-agnostic and translate well into generating latex.. [21:28] gkatsev: jesusabdullah: do you use a wysiwym editor or just an editor like vim or w/e? [21:28] jesusabdullah: gkatsev: The equation typesetting is almost unparalleled. There are other aspects of LaTeX thought that feel a bit old and creaky, and some of the advanced style changing stuff is kinda annoying [21:28] jesusabdullah: gkatsev: I personally use vim and evince, and I wrote a little script in node.js that compiles on save [21:29] sh1mmer has joined the channel [21:29] jesusabdullah: https://github.com/jesusabdullah/homework_2010/blob/master/autocompile.js [21:29] gkatsev: cool. [21:29] jesusabdullah: Not the most polished thing ever, but I find it handy [21:30] gkatsev: using snipMate or something with vim? [21:30] mape: someone should hook nodemon to compile coffee [21:30] jesusabdullah: gkatsev: I actually kinda lied about vim. I use it about half the time, but when I'm at my desktop I use gedit [21:30] sh1mmer: isaacs: I know it's more typing, but sometimes it's just useful to be intuitive as it is to be concise. You know you can always do ^C so you're cool anyway [21:31] gkatsev: jesusabdullah: heh, I like vim. It's great. [21:31] isaacs: yeah, i agree [21:31] jesusabdullah: gkatsev: Just haven't found the time to mess with vim settings and addons. I vaguely remember hearing good thigns about snipmate though [21:31] jesusabdullah: Yeah, vim has some nice stuff [21:31] gkatsev: and in vim 7.3 bram added relativenumber, which is awesome [21:31] jesusabdullah: I got to the point where I can use it <_< [21:31] jesusabdullah: relativenumbeR? [21:31] gkatsev: makes the [count] feature of commands so much more useful [21:31] jesusabdullah: ah [21:32] gkatsev: rather than showing line numbers, it shows the line number difference between your current line and the lines above and below it. [21:32] gkatsev: so, a line below the line with the cursor will be numbers 1 and 2 below will be 2 etc [21:33] jesusabdullah: Oh, neat [21:34] gkatsev: yeah, freaking awesome [21:34] jesusabdullah: So i wouldn't have to guess when I do dd [21:34] jesusabdullah: "Oh, eleven lines! Cool" [21:34] gkatsev: yes, exactly [21:34] jesusabdullah: Bangin' [21:34] gkatsev: also, if you dont know about text-objects in vim, read the help. It will change your life :) [21:34] jesusabdullah: I think I'd actually really like vim if I spent the time to customize it [21:34] jesusabdullah: I just know the basics [21:35] gkatsev: yeah, I've spent 3 years learning vim, also, I was using vimperator (a firefox extention that mimicks vim's modal editing to browsing the web) which helped me learn it even more [21:35] jherdman has joined the channel [21:36] jesusabdullah: Considered vimperator [21:36] jesusabdullah: but I have to admit I'm a sucker for being able to click things sometimes [21:36] hassox has joined the channel [21:36] gkatsev: you could still click stuff no problem [21:37] gkatsev: actually, with ff4, vimperator is getting some major redesign [21:37] gkatsev: IE, moving the command line of vimp into the url bar and merging into the awesomebar [21:37] V1: Dear, god, I'm just gonna stab my self in the eye and die. I'm having some serious cross browser issues that cannot be resolved :9 [21:37] johan_bouveng: uhm. when im inspecting the req obj in a post i dont see my posted data? :( http://pastie.org/1280028 [21:37] gkatsev: haha [21:38] johan_bouveng: V1: whats up [21:38] cagdas has joined the channel [21:38] V1: johan_bouveng: I'm toying with the indexedDB specifications. And dear god, that is gross shit to play with -_-" [21:38] Me1000 has joined the channel [21:38] johan_bouveng: V1: ok, dont know anything about that. [21:38] johan_bouveng: :) [21:39] gerad: V1: how do you tune two piccolos? [21:39] gerad: V1: shoot one [21:39] V1: gerad: That might work, or buy a shit load of ducktype and polyfill that sucker. [21:40] gerad: :-) [21:40] johan_bouveng: is this still accurate? http://debuggable.com/posts/parsing-a-form-in-node-js-1:4b0bff13-4244-4ebc-8455-4975cbdd56cb [21:42] gwoo has joined the channel [21:43] brainproxy: anyone hooking node.js to VoltDB? [21:44] jesusabdullah: gkatsev: Awesomebar merging sounds pretty cool actually. [21:44] johan_bouveng: uhm [21:45] johan_bouveng: please, a simple example on how to pick up form data must be available somewhere :S [21:45] gkatsev: jesusabdullah: yeah, it is partly because ff4 removes the statusbar and because the ff4 UI looks pretty cool, actually [21:48] gkatsev: jesusabdullah: feel free to get one of the snapshots from the google code (code.google.com/p/vimperator-labs) and or hang out in #vimperator :) [21:48] stride: johan_bouveng: the server request object has a data event for body data iirc [21:49] johan_bouveng: stride: i dont see it when i sys.inspect() it [21:53] jesusabdullah: That's nice of you gkatsev ...I use Chrome. [21:53] gkatsev: :) [21:54] jesusabdullah: Oh geez, it missed a crucial part of that sentence [21:54] TomsB has joined the channel [21:54] gkatsev: ? [21:54] jesusabdullah: s/ .../, but there's one problem... '/ [21:55] jesusabdullah: I'm dealing with >1sec lag right now, so my typing is all sorts of jacked up [21:55] gkatsev: lol, that sucks [21:55] gkatsev: stop downloading so much porn :P [21:55] johan_bouveng: AHA! app.use(express.bodyDecoder()); [21:56] johan_bouveng: now i get the body. [21:58] mAritz: just to make sure i'm not doing double work: is there a sprintf for node that is in npm and works with the 0.3.x versions? [22:00] bnoordhuis has joined the channel [22:01] jameshome has joined the channel [22:01] bartt: How does one read a base64 data and converts it to binary/raw? [22:01] bartt: I've done some experimenting with buffer but so far w/o success. [22:02] johan_bouveng: mAritz: just implement sprintf [22:02] johan_bouveng: mAritz: :D [22:03] stride: johan_bouveng: oh you're using express? :/ [22:03] johan_bouveng: stride: yes [22:03] johan_bouveng: mAritz: http://phpjs.org/functions/sprintf:522 [22:03] stride: ACTION throws away the example code [22:03] stride: meh :) [22:04] gkatsev: run-dev-server.js that peepcode uses is pretty cool. [22:04] mAritz: johan_bouveng: no, i'm just going to copy a working javascript sprintf version and add exports for node. in fact i'm already done and one enter press away from publishing to npm. i just don't want to litter npm with unnecessary stuff. [22:04] bnoordhuis: bartt: new Buffer('aaabbbcccdddd', 'base64') [22:04] bnoordhuis: the contents of the buffer will contain the base64-decoded data [22:05] bartt: bnoordhuis: Let me try that, [22:05] jameshome: I'm getting connection refused errors trying to use npm [22:05] isaacs: try again [22:05] jameshome: heh [22:05] jameshome: hah! [22:05] jameshome: that worked [22:05] isaacs: marienz: there's console.log [22:05] isaacs: mAritz: ^ [22:06] jameshome: isaacs: that's service! [22:06] isaacs: mAritz: it has some sprintf-like features. you could probably yank that bit out [22:06] mAritz: yes, but i don't want a sprintf that outputs to the console ;) [22:06] isaacs: jameshome: i think someone at couchone kicked it [22:06] isaacs: mAritz: right, so check out what console.log is :) [22:06] isaacs: console.log(console.log.toString()) [22:07] jameshome: the future is all duct tape and bailing wire [22:08] cyraxx has joined the channel [22:08] matjas has joined the channel [22:09] mAritz: isaacs: yeah, i could copy format, but i really like the functionality of http://www.diveintojavascript.com/projects/javascript-sprintf [22:09] bartt: bnoordhuis: What got me was that when you start out w/ a buffer containing base64 encoded data one has to convert the buffer first to a String. [22:09] ceej has left the channel [22:09] isaacs: mAritz: then use that :) [22:09] bartt: new Buffer(data.toString(), 'base64') [22:09] bnoordhuis: bartt: yeah, it's kinda wacky [22:09] mAritz: yeah, i will. the question is just whether i should publish it to npm or not :D [22:09] bnoordhuis: someone filed a bug about yesterday or the day before [22:10] bnoordhuis: https://github.com/ry/node/issues/issue/398 [22:10] bnoordhuis: if ryan doesn't pick it up, i will [22:10] mAritz: ah, fuck it. i'm publishing now. :P [22:11] bartt: Thanks bnoordhuis [22:11] bnoordhuis: bartt: my pleasure :) [22:12] twoism has joined the channel [22:13] necrodearia has joined the channel [22:14] captain_morgan has joined the channel [22:15] bartt: bnoordhuis: Shouldn't fs.writeFile('foo', data.toString('base64'), cb) and fs.writeFile('foo', data, 'base64', cb) both write the data to foo base64 encoded? [22:15] bartt: The latter doesn't in v0.2.4 [22:17] bnoordhuis: bartt: it should (and seems to do so in 0.3.x) [22:18] Draggor has joined the channel [22:18] bnoordhuis: bartt: but from the look of it, that code hasn't changed since 0.2.4 [22:18] bartt: Hmm, let me create a gist [22:20] bnoordhuis: oh wait, i think i see the bug [22:20] bnoordhuis: the encoding parameter is ignored [22:20] bnoordhuis: shadowed really by a local variable [22:20] smtlaissezfaire has joined the channel [22:21] Anti-X has joined the channel [22:23] pquerna: power outages suck [22:24] bartt: bnoordhuis: OK, I'll open an issue and link to my gist: https://gist.github.com/666928 [22:24] pquerna: ryah: yes, Cassandra originally used UDP, but in 0.5 i believe, ti was switched to use TCP for gossip too. [22:25] rbranson: udpoop [22:26] bnoordhuis: bartt: i think it does actually work [22:26] bartt: https://github.com/ry/node/issues/issue/401 [22:26] bnoordhuis: bartt: but in 0.2.x there is an off-by-one error [22:26] bnoordhuis: i get a nul byte after the decoded output [22:27] bnoordhuis: bartt: i think there is some confusion [22:27] bartt: Hmm, not for me. [22:28] bnoordhuis: fs.writeFile('some-image2.txt', data, 'base64', function(err){}); [22:28] bnoordhuis: that expects data to contain base64-encoded data [22:28] bnoordhuis: not 'take this binary data and convert it to base64' [22:29] bartt: Hmm, that is counter intuitive. And the documentation doesn't clarify the use of the encoding parameter [22:29] bnoordhuis: on that we agree [22:34] altamic has joined the channel [22:36] mape: anyone have a good remind me by email service? [22:36] prettyrobots has joined the channel [22:37] bruse: mape: how about gmail? [22:37] mape: bruse: you can set it to send a mail in 11 months? [22:37] mape: schedule it? [22:38] bartt: bnoordhuis: Could you take a look at https://gist.github.com/667031 ? [22:38] bartt: encoding/decoding still is working as I would expect. As you explained I expected bar.jpg === foo.jpg [22:39] bnoordhuis: let me run it [22:41] bruse: mape: yes, you can set up an appointment or so in the calendar and have it remind you about it [22:41] mape: bruse: oh neat [22:41] bruse: mape: so i guess technically it's google calendar, not gmail :) [22:42] dohtem has joined the channel [22:42] dohtem has joined the channel [22:44] jesusabdullah: mape: cron + mutt? :P [22:44] jesusabdullah: I've heard google calendar is good for that stuff too [22:44] mape: hehe gcal worked perfectly [22:46] bnoordhuis: bartt: it works when you do this: fs.writeFile('bar.jpg', data.toString(), 'base64', function(err){ [22:46] bnoordhuis: but that's non-obvious [22:47] devinus_ has joined the channel [22:47] bnoordhuis: fs.writeFile ignores the encoding when the input is a buffer [22:47] bnoordhuis: from lib/fs.js: var buffer = Buffer.isBuffer(data) ? data : new Buffer(data, encoding); [22:49] abstractj has joined the channel [22:51] bartt: bnoordhuis: I'd say that IS a bug. [22:51] rwaldron has joined the channel [22:52] bnoordhuis: bartt: i tend to agree, it violates the principle of least surprise [22:52] bartt: A variation of issue 398 perhaps. I'll add comments to 398 and 401 to clarify. [22:58] rnewson has joined the channel [22:58] rnewson has joined the channel [23:02] Anti-X has joined the channel [23:05] jevin has joined the channel [23:07] twoism has joined the channel [23:08] Aria: Whose surprise? ;-) [23:09] jchris has joined the channel [23:11] Anti-X: veeli intellesting [23:13] mAritz: i'm trying to use req.param('name') in express but req.params is undefined for some reason and thus throws an error. what's going on? shouldn't it always be defined, but empty if no params are given? (url is localhost:3000/test?name=blub) [23:13] mAritz: so, params are given but req.params isn't created. [23:13] [[zz]] has joined the channel [23:16] jashkenas has joined the channel [23:17] dguttman has joined the channel [23:18] Throlkim has joined the channel [23:19] bartt: mAritz: That's what I've seen too. req.params doesn't exist when no query parameters are given and when the handler pattern (e.g. /users/:id) doesn [23:19] bartt: 't include parameter placeholders [23:19] mraleph has joined the channel [23:20] siculars has joined the channel [23:23] mikedeboer has joined the channel [23:23] InsDel has joined the channel [23:25] johan_bouveng: ACTION is trying to generate a md5 sum for a string using crypto, but fails :D [23:26] V1: you forgot to compile node with openSSL support ;)? [23:26] tapwater_ has joined the channel [23:28] johan_bouveng: no, it is compiled with ssl [23:28] johan_bouveng: i prolly just dont know how to use crypto properly [23:29] johan_bouveng: tought is was as simple as php's md5() [23:30] breccan has joined the channel [23:30] ako has joined the channel [23:31] Aria: Heh. [23:31] Aria: md5 is a hash, not encryption. [23:31] Aria: And a hash of a known string is only one mode of operation. [23:31] johan_bouveng: mm [23:33] Aria: (It's a function that works blockwise, actually. Given a hash of a string, you can continue it as you append data) [23:33] mikew3c has joined the channel [23:33] johan_bouveng: Aria: http://pastie.org/1280266 [23:33] johan_bouveng: :) [23:34] benburkert has joined the channel [23:34] Aria: Ayep. [23:34] altamic_ has joined the channel [23:34] Aria: createhash starts with the seed value, update adds your data and hashes on the way. [23:34] Aria: and then get the bytes of the hash encoded as hex. [23:34] benburkert has joined the channel [23:34] MattDiPasquale has joined the channel [23:34] johan_bouveng: wonderful expl. thanks. [23:35] johan_bouveng: im not so elite on that stuff. [23:35] johan_bouveng: just want my md5() [23:35] johan_bouveng: )( [23:35] johan_bouveng: :) [23:35] Aria: Hehe. Takes some getting used to, seeing under the hood. [23:35] Aria: ... Also, consider using SHA-1 ;-) [23:35] johan_bouveng: aha why? [23:35] Aria: MD5 has some known attacks, useful in some uses. [23:36] johan_bouveng: im just going to hash the pwds and or session ids [23:36] johan_bouveng: "just" [23:36] johan_bouveng: :d [23:36] MattDiPasquale: okay. i know this isn't a node.js question, but what's it called when you're gettin inspiration from someone when you wrote something? like i wrote a poem, and while i was writing it i was gettin inspired by eminem [23:36] MattDiPasquale: I was 'sourcing' eminime? [23:36] MattDiPasquale: no, that's not it... [23:36] MattDiPasquale: i was 'tracking' eminem [23:36] MattDiPasquale: no... [23:36] Aria: 'channeling' ? [23:36] johan_bouveng: MattDiPasquale: inspired? [23:36] MattDiPasquale: yeah [23:36] MattDiPasquale: channeling!!! [23:36] MattDiPasquale: thanks! [23:36] MattDiPasquale: haha [23:36] johan_bouveng: ... [23:36] MattDiPasquale: haha [23:37] MattDiPasquale: thanks [23:37] Aria: Though that usually implies being-like, rather than just being inspired by. [23:37] johan_bouveng: mayby you should write poems instead of coding [23:37] johan_bouveng: influenced , also. [23:37] inimino has left the channel [23:37] johan_bouveng: if you dare to [23:37] MattDiPasquale: Aria: yeah... it's not quite channeling, but i think that's the word i was thinking of [23:38] MattDiPasquale: johan_bouveng: lol... thanks. i do both. i write poems in code, and i write code in prose [23:38] MattDiPasquale: thanks to all these new wonderful expressive dynamic languages & libraries coming out [23:38] MattDiPasquale: like node [23:39] Zeph\k0d3: ACTION waits for the first true epic library written completely in dactylic hexameter [23:39] MattDiPasquale: I think i'll make that my new status [23:39] MattDiPasquale: Zeph\k0d3: lol... [23:40] MattDiPasquale: Zeph\k0d3: yes, that would be epic [23:40] tapwater_ has joined the channel [23:41] necrodearia has joined the channel [23:44] captain_morgan has joined the channel [23:44] johan_bouveng: MattDiPasquale: :) [23:44] abstract_ has joined the channel [23:45] tapwater_ has joined the channel [23:48] Zeph\k0d3: ACTION has made lots of progress on o3-canvas again [23:50] bpot has joined the channel [23:50] bpot has joined the channel [23:50] johan_bouveng: omnomnom canvas [23:52] persson has joined the channel [23:53] Zeph\k0d3: http://blokmodular.com/dev/test21-abstractart.htm this is where I started this evening.. no making a new canvas, just save/restore context around each test... [23:53] Zeph\k0d3: http://blokmodular.com/dev/test22.htm all fixed now :) [23:55] sechrist has joined the channel [23:55] johan_bouveng: ok, ill have a look :P [23:55] tanepiper: so, can we do full 60fps canvas in node yet? :p [23:56] Zeph\k0d3: depends on what you are drawing [23:56] Zeph\k0d3: and how big your frames are [23:56] Zeph\k0d3: but fast canvas sortof relies on hardware acceleration if you want to do it really nice... and servers usually dont have nice GPUs available [23:56] tanepiper: well i'm thinking no then :) [23:57] tanepiper: ahh that's true [23:57] derferman_ has joined the channel [23:57] Zeph\k0d3: but I've not even started the optimization run yet [23:58] Zeph\k0d3: the interface library I use for my audiosoftware is easily capable of doing software-only fullscreen vectorgfx by now.. but that has the advantage of NEVER having to do anything with javascript [23:58] johan_bouveng: Zeph\k0d3: explain a little, its canvas for the server? [23:58] Lorentz: I haven't done much testing, but canvas is pretty fast. [23:58] Zeph\k0d3: yes [23:59] Zeph\k0d3: johan_bouveng: it is a node.js module that gives you the canvas object on the server, so you can share gfx code between client/server [23:59] johan_bouveng: oki, nice [23:59] johan_bouveng: and u spit out binary? [23:59] tanepiper: i'm thinking will this be useful for browser games, but i suppose not - best to just do most of it in client side canvas [23:59] Zeph\k0d3: with the option to stream base64 png straight to client, or write to disk, or make pdf etc [23:59] Zeph\k0d3: tanepiper: nah, not really for games... nice for offline report generation etc [23:59] Zeph\k0d3: print-on-demand things