00:00:36  * Lomexjoined
00:00:39  * bumbleheadjoined
00:00:50  * tesrtyquit (Quit: -)
00:00:52  * FarceLemmaquit (Ping timeout: 250 seconds)
00:02:51  * neanderslobjoined
00:03:20  * sillysluxquit (Read error: Connection reset by peer)
00:03:52  * T-2000joined
00:04:54  * T-2000quit (Read error: Connection reset by peer)
00:04:58  * aarobc_quit (Ping timeout: 265 seconds)
00:05:03  * bumbleheadquit (Ping timeout: 244 seconds)
00:06:08  * rxmthjoined
00:06:12  * Lomexquit (Ping timeout: 276 seconds)
00:06:55  * unitechquit (Ping timeout: 250 seconds)
00:07:41  * sankhajoined
00:07:50  * eyaquit (Read error: Connection reset by peer)
00:07:51  * eyyajoined
00:08:04  * Literphorquit (Quit: Literphor)
00:08:26  * veggie_quit (Quit: WeeChat 1.5)
00:09:21  * smccarthyquit (Remote host closed the connection)
00:10:54  * rxmthquit (Ping timeout: 260 seconds)
00:10:58  * smccarthyjoined
00:11:36  * silencedjoined
00:11:50  * fo0zlequit (Quit: so...sleepy...fo0zZZZZZZzle out..)
00:12:03  * sankhaquit (Ping timeout: 240 seconds)
00:13:32  * Tennisquit (Quit: Leaving)
00:13:40  * krish203quit (Quit: Leaving.)
00:14:41  * ToApolytoXaosquit (Quit: I'm off folks. Drop by at http://alifealgorithm.blogspot.com)
00:15:23  * smccarthyquit (Ping timeout: 244 seconds)
00:16:44  * eyyaquit (Read error: Connection reset by peer)
00:17:09  * eyajoined
00:17:15  * autoboxerjoined
00:18:16  * eyaquit (Read error: No route to host)
00:18:34  * eyajoined
00:18:58  * eyaquit (Read error: Connection reset by peer)
00:19:09  * eyajoined
00:19:47  * LeBlaaancquit (Excess Flood)
00:20:30  * T-2000joined
00:21:25  * nd__quit (Ping timeout: 240 seconds)
00:21:31  * elfuegojoined
00:22:04  * ericwool_joined
00:22:13  * LeBlaaancjoined
00:22:29  * LeBlaaancquit (Client Quit)
00:23:31  * nuizzyquit (Quit: nuizzy)
00:23:56  * elfuegoquit (Client Quit)
00:24:54  * gmuropquit (Ping timeout: 260 seconds)
00:25:04  * DeltaHeavyjoined
00:25:04  * DeltaHeavyquit (Client Quit)
00:25:07  * ConspiratorXquit (Quit: My Mac has gone to sleep. ZZZzzz…)
00:25:42  * ericwooleyquit (Ping timeout: 260 seconds)
00:26:27  * dommelquit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client)
00:26:52  * elfuegojoined
00:27:50  * diogogmtquit (Quit: diogogmt)
00:28:36  * phajijoined
00:29:36  * WebSpirit_joined
00:29:36  * WebSpiritquit (Read error: Connection reset by peer)
00:30:36  * dommeljoined
00:31:44  * diphtherialjoined
00:32:03  <diphtherial>hey, i'm attempting to build this thing https://github.com/nylas/N1 which apparently uses npm in some capacity
00:32:17  * dommelquit (Client Quit)
00:32:21  <diphtherial>is a 512mb VPS way too small to expect to be able to build a project? my compilation task keeps getting killed
00:32:36  <diphtherial>(i anticipate because it's running out of RAM)
00:33:16  * alanszlosekquit (Remote host closed the connection)
00:33:27  * dzmienquit (Ping timeout: 264 seconds)
00:33:37  * hextileXquit (Quit: hextileX)
00:34:54  * jaagrquit (Quit: a toute a l'heure)
00:35:13  * baweaverjoined
00:35:46  * jaagrjoined
00:35:51  * sg_quit (Quit: Textual IRC Client: www.textualapp.com)
00:35:52  * neanderslobquit (Ping timeout: 264 seconds)
00:36:26  * Sixmsjjoined
00:37:51  * Rodya_quit (Remote host closed the connection)
00:38:41  * nhahnquit (Remote host closed the connection)
00:39:08  * T-2000quit (Read error: Connection reset by peer)
00:40:23  * T-2000joined
00:41:10  * mrogne_afkchanged nick to mrogne
00:42:08  <bobby-barker>I have a few books that are node.js but were written before ES6 was implemented too much. Should I learn ES6 really well so that I know what they mean when I see things done a certain way? Not totally new to programming but I'm not a javascript guru either
00:42:51  * osum4estjoined
00:42:52  * Literphorjoined
00:43:25  <Havvy>If you're going to be reading ES6 code, it's useful to know what ES6 adds on top of ES5.
00:43:27  * ericwool_quit (Ping timeout: 258 seconds)
00:43:31  <Havvy>http://node.green/ is also useful.
00:43:41  <Havvy>Unless they are using Babel...
00:44:19  <osum4est>hello, i'm having an issue with postregresql and knex. when calling getMovies() only the first call actually finds a match and logs it. I've made sure that all rows exists for all the ids. code here: http://pastie.org/10920177
00:44:58  <osum4est>the ones after return an empty array
00:44:58  <bobby-barker>Havvy, the code is ES5 (if that's what pre-ES6 is called?)
00:45:12  * indrjoined
00:46:29  <bobby-barker>Havvy, thanks for the link though that will be helpful regardless of what I do first
00:46:31  <Havvy>Then you don't have a strong impetus to learn ES6.
00:46:46  * EyePulpquit (Remote host closed the connection)
00:47:08  <danneu>osum4est: your example only logs the success case (.then). what about adding .catch to see errors?
00:47:41  <osum4est>danneu: i'll try that. one sec
00:48:02  <bobby-barker>Havvy, okay thanks I appreciate the advice
00:48:47  * sabrehagenjoined
00:48:54  * graffix_joined
00:49:21  * kegsterquit (Quit: Shiner, TX makes good beer.)
00:50:07  <osum4est>danneu: no errors are thrown
00:50:09  * neoncontrailsquit (Remote host closed the connection)
00:50:23  * kegsterjoined
00:50:30  * dopesongjoined
00:50:41  <Havvy>osum4est: It's still a good idea to have .catch() at the final consumer of a promise.
00:50:48  * neoncontrailsjoined
00:50:59  <osum4est>Havvy: i'll keep that in mind, thanks
00:51:26  * neoncontrailsquit (Read error: Connection reset by peer)
00:51:34  <Havvy>Otherwise runtime errors caused by programmer mistakes get swallowed never to be seen again.
00:51:43  * Mamutquit (Quit: I cna ytpe 300 wrods pre mniuet!!!)
00:51:44  <osum4est>right
00:52:01  * neoncontrailsjoined
00:52:07  <danneu>osum4est: you also have a syntax error on line 3
00:52:13  * dommeljoined
00:52:19  <indr>My package has a dependency on A and B-1.1. A has a dep on B-1.0. How can I achieve that A uses the newer dependency B-1.1, which is a top-level dependency (a git fork)?
00:52:21  * neoncontrailsquit (Read error: Connection reset by peer)
00:53:08  <osum4est>danneu: whoops sorry, i accidentally messed that up when i pasted it over. it is correct in the code that i'm running
00:53:28  * eyaquit (Read error: Connection reset by peer)
00:53:41  * eyajoined
00:53:46  <danneu>osum4est: wait are you saying only the first call of getMovies works, or only the first getMovieById works instead the chain?
00:53:54  * dommelquit (Client Quit)
00:53:59  * sabrehagenquit (Ping timeout: 244 seconds)
00:54:07  * lucasemjoined
00:54:24  * leehambleyquit (Quit: My Mac has gone to sleep. ZZZzzz…)
00:55:11  * dopesongquit (Ping timeout: 244 seconds)
00:55:38  * dan2wikquit (Quit: Can't withdraw negative numbers)
00:55:54  <osum4est>danneu: only the first getMovieById, i only call getMovies once. it still makes all of the calls in the chain, because console.log gets called all five times, but only on the first one does .then() return results that aren't empty
00:56:51  * Rodya_joined
00:57:03  * smokeojoined
00:57:10  * sillysluxjoined
00:57:19  * sabrehagenjoined
00:57:28  <danneu>so getMovieById(2) by itself doesn't find a result?
00:57:51  <osum4est>by itself, outside of the chain, it does
00:57:59  * Rodya_quit (Remote host closed the connection)
00:58:18  * inflamesquit (Ping timeout: 244 seconds)
00:58:59  <osum4est>and, if i make all of the calls to getMovieById() in the chain give the same id, then it returns the match for each call
00:59:10  * Rodya_joined
00:59:43  * ironfroggyjoined
01:00:14  * smccarthyjoined
01:00:37  * flappynerdquit (Quit: = "bye")
01:00:42  <danneu>im not sure what the result of mixing promises and callbacks like that is just by looking at it. the first thing i'd do is refactor getMovieById so you're returning the promise. `return movie.where(id: id)` and then chain together the .then()'s from getMovies
01:00:54  * diphtherialpart
01:01:26  * bumbleheadjoined
01:01:28  * phajiquit (Ping timeout: 258 seconds)
01:01:35  * ironfroggy_joined
01:01:39  * timmywilquit (Quit: O.o)
01:01:43  * ironfroggyquit (Read error: Connection reset by peer)
01:01:46  * bitnode3joined
01:02:03  * eyaquit (Read error: No route to host)
01:02:04  * eyyajoined
01:02:23  <osum4est>the problem is that inside getMovieFromId() there will be some logic, that creates the row from that id if it does not exist
01:02:33  * monk_king_kongjoined
01:03:26  * devcjoined
01:03:37  <danneu>you still don't need callbacks though. return movie.where(id: id).then((movie) => if no movie, then return promise that creates one)
01:03:40  * de_henne_joined
01:04:02  <danneu>else return movie
01:04:42  * NordiQjoined
01:04:49  * smccarthyquit (Ping timeout: 250 seconds)
01:05:44  * leehambleyjoined
01:05:51  <osum4est>ok, so even though .then() is in there it won't actually be called until i do another .then()?
01:05:59  * kingarmadillojoined
01:06:19  * bumbleheadquit (Ping timeout: 260 seconds)
01:06:49  <Tr|z|D>https://www.youtube.com/watch?v=oqwzuiSy9y0
01:07:03  * texinwien_quit (Ping timeout: 244 seconds)
01:07:34  * de_hennequit (Ping timeout: 244 seconds)
01:07:45  * yonatankorenquit (Quit: ZNC 1.6.1 - http://znc.in)
01:07:45  * sabrehagenquit (Ping timeout: 240 seconds)
01:09:40  * NordiQquit (Ping timeout: 244 seconds)
01:09:48  * Swizecquit (Quit: Computer has gone to sleep.)
01:10:01  * mmmveggiesquit (Quit: Connection closed for inactivity)
01:10:02  <danneu>osum4est: not sure what you're aksing but you can do something like this https://gist.github.com/danneu/3a3075aa2ed41b4941e852abbe089e59
01:10:32  * evil_dan2wikjoined
01:10:37  * sabrehagenjoined
01:10:55  <osum4est>danneu: okay, now i see what you mean, thanks
01:11:02  <osum4est>danneu: i'll see if it works
01:11:21  * ibashquit (Remote host closed the connection)
01:11:33  <danneu>watch out for the common mistake of forgetting to `return` promises and stuff inside .then()
01:12:16  * ibashjoined
01:12:51  * afusionjoined
01:13:04  <danneu>gonna walk home, brb
01:14:40  * eyyaquit (Read error: No route to host)
01:14:59  * eyajoined
01:15:39  * dmtojoined
01:15:48  * sillysluxquit (Read error: Connection reset by peer)
01:17:28  <AAA_awright>My Node.js script is silently ignoring raised Errors and I can't figure out why
01:17:44  <AAA_awright>Actually it's messing up some of my socket connections quite badly in not quite discernable ways
01:17:45  * dommeljoined
01:17:48  * afusion_joined
01:17:50  <AAA_awright>(unix sockets)
01:19:04  * sabrehagenpart
01:19:18  * hunseopjoined
01:19:29  * afusionquit (Ping timeout: 244 seconds)
01:19:30  * dommelquit (Client Quit)
01:19:47  * phajijoined
01:20:00  * thinkt4nkjoined
01:20:00  * sillysluxjoined
01:20:01  * ed209quit (Remote host closed the connection)
01:20:02  * dmtoquit (Client Quit)
01:20:07  * ed209joined
01:20:12  * ibashquit (Ping timeout: 258 seconds)
01:20:40  <AAA_awright>Actually, I do seem to be getting a ReferenceError emitted to the console, but it's not killing the process
01:20:50  <AAA_awright>... or maybe it is
01:20:58  <AAA_awright>No, it's my child process that's not dying
01:21:12  * autoboxerquit
01:21:38  * safejoined
01:22:31  * LeBlaaancjoined
01:22:58  <AAA_awright>I think I've hit a bug where a Node.js internal worker process isn't dying and isn't in turn killing off my worker process; but the main thread dies
01:23:13  <AAA_awright>happening when I hit an uncaught Error
01:23:29  * kevireilly_joined
01:23:45  <AAA_awright>When there's an uncaught Error, my worker process is no longer a child of `node`, but there is a lingering `node` process
01:23:52  <osum4est>danneu: you back yet?
01:23:56  <danneu>osum4est: yah
01:25:07  <osum4est>danneu: same problem, with logic in, it errors because it can't insert a duplicate key. with just one in Promise.all() it works, but as soon as i put multiple it errors
01:25:52  <osum4est>danneu: without the logic and just returning movie, it returns undefined
01:26:08  * kevireilly__joined
01:27:00  <danneu>not sure what you're referring to as 'returning'. getMovies.then((movies) => console.log(movies)) fails?
01:27:26  <danneu>guess i'd need to see not just your updated code but also how you're actually calling 'getMovies"
01:27:40  <osum4est>danneu: yeah, one sec
01:28:05  * kevireilly_quit (Ping timeout: 240 seconds)
01:28:38  * sabrehagenjoined
01:28:42  * Milos|Workquit (Ping timeout: 260 seconds)
01:29:21  * kevireilly__quit (Client Quit)
01:29:23  <osum4est>danneu: http://pastie.org/10920193
01:29:36  * neoncontrailsjoined
01:29:57  * Tr|z|Dquit (Quit: Leaving)
01:32:28  <danneu>i just guessed at knex's api. looks like instead of .select('*') you should have .first('*'). docs say that .first and .select are exclusive
01:32:40  <danneu>maybe that's one issue
01:33:22  * sagerdeariaquit (Ping timeout: 260 seconds)
01:34:01  * Sucksjoined
01:34:03  * sabrehagenquit (Ping timeout: 258 seconds)
01:34:04  <osum4est>danneu: same problem still...
01:34:34  * Lee1092joined
01:34:55  * Sucksquit (Max SendQ exceeded)
01:35:39  * eyyajoined
01:35:40  * eyaquit (Read error: Connection reset by peer)
01:36:30  * eyyaquit (Read error: Connection reset by peer)
01:36:47  * eyajoined
01:36:48  * sabrehagenjoined
01:38:08  * Sucksjoined
01:38:24  <danneu>and you're saying `select * from movies where movie_id = 1` does return a row
01:38:24  * eyaquit (Read error: Connection reset by peer)
01:38:50  <osum4est>when it'd just by itself, and id 1-5 works
01:39:05  <osum4est>it doesn't return a row for any id if there are multiple
01:39:13  * eyajoined
01:39:36  <osum4est>* multiple promises in Promise.all
01:39:52  * sabrehagenquit (Read error: Connection reset by peer)
01:40:08  * polydo_squit (Ping timeout: 258 seconds)
01:40:23  <danneu>but it does with just one promies?
01:40:52  <osum4est>works with one promise. does not work with more than one promise :)
01:41:44  * stelarcfquit (Quit: stelarcf)
01:41:48  * silencedquit (Quit: My Mac has gone to sleep. ZZZzzz…)
01:43:23  * omejoined
01:43:33  <danneu>what is table_movies?
01:43:48  <osum4est>knex('movies')
01:43:58  * elfuegoquit (Quit: elfuego)
01:44:03  * phajiquit (Ping timeout: 240 seconds)
01:44:19  <osum4est>a table with one column for now, movie_id, which must be unique and is the primary key
01:44:30  <danneu>my guess is that knex(table) is what creates a new connection from the pool, so maybe you're running into an issue by trying to `table_movies = knex('movies')`
01:44:44  * ironfroggy_quit (Remote host closed the connection)
01:44:52  * tubuliferousjoined
01:44:54  <osum4est>so do knex.from('movies') instead?
01:44:54  <danneu>instead try inlining it, knex('movies').first(movie_id: id) ...
01:45:00  <osum4est>ok
01:45:38  <osum4est>holy crap
01:45:41  <osum4est>that worked
01:45:51  <danneu>good luck
01:45:52  <osum4est>thank you!!!!
01:46:04  * Rodya_quit (Remote host closed the connection)
01:46:12  <osum4est>i've been trying to fix that forever now
01:46:24  * Rodya_joined
01:46:27  * Sixmsjquit (Quit: Sixmsj)
01:47:21  * DragonPunchquit (Ping timeout: 244 seconds)
01:47:59  * LeBlaaancquit (Quit: My Mac has gone to sleep. ZZZzzz…)
01:48:42  * elfuegojoined
01:49:27  * tubuliferousquit (Ping timeout: 250 seconds)
01:50:13  * blahfoojoined
01:50:43  * Flynnnjoined
01:50:50  * thinkt4nkquit (Quit: My Mac has gone to sleep. ZZZzzz…)
01:51:08  * andrew9183quit (Quit: andrew9183)
01:51:23  <timetocode>how do I programmatically chose a port? I'm running a node app that is a game server, and rather than hardcoding a port into it, i'd like it to just pick an available port
01:51:44  * devinceartasjoined
01:51:49  * earendeljoined
01:51:55  <timetocode>it's going to communicate that port to a master server, which the game client uses to browser for servers
01:52:09  * afusion_quit (Ping timeout: 276 seconds)
01:52:13  * asteele_joined
01:52:46  * Literphorquit (Quit: Literphor)
01:52:54  <boogyman>http://bfy.tw/6vcQ @ timetocode
01:53:05  * krish203joined
01:53:11  * Cranitejoined
01:53:12  * asteelequit (Ping timeout: 260 seconds)
01:53:47  * krish203quit (Client Quit)
01:53:53  * fr_joined
01:54:06  * krish203joined
01:54:15  <timetocode>boogyman, thanks for the the link i'll bookmark that for later
01:54:29  * krish203quit (Client Quit)
01:55:44  * jeffreylevesquejoined
01:55:48  * ironfroggyjoined
01:56:02  * Limes_joined
01:56:02  * Literphorjoined
01:56:03  * leehambleyquit (Quit: My Mac has gone to sleep. ZZZzzz…)
01:56:33  * sumobobquit (Ping timeout: 250 seconds)
01:57:02  <timetocode>boogyman, there doesn't appear to be anything about that at that url
01:57:08  <timetocode>did you read that stuff
01:58:02  <danneu>timetocode: maybe https://www.npmjs.com/package/find-port
01:58:03  * frquit (Ping timeout: 244 seconds)
01:58:12  * roflmyeggoquit (Ping timeout: 244 seconds)
01:58:51  * krish203joined
01:59:08  * krish203quit (Client Quit)
01:59:26  * krish203joined
01:59:26  * krish203quit (Client Quit)
01:59:48  * Rodya_quit (Remote host closed the connection)
02:00:07  * krish203joined
02:00:14  <timetocode>danneu, perfect, ty
02:00:28  * jdelersquit (Quit: Connection closed for inactivity)
02:00:38  * rxmthjoined
02:00:49  * Rodya_joined
02:01:15  * ibashjoined
02:02:13  * bumbleheadjoined
02:02:19  * Limes_quit (Ping timeout: 260 seconds)
02:02:19  * lhdcjoined
02:02:35  <osum4est>danneu: it almost work. the only thing wrong now is that if it has to insert a new row, it returns an object that contains information about the insertion ({ command: 'INSERT', rowCount: 1, etc. }) rather that the new object
02:03:11  <osum4est>do i have to return the promise or could i run the insert command and just return the movie i inserted
02:03:56  <danneu>osum4est: maybe it's `return knex('movies').insert(...).returning('*').then(function (result) { return result.rows[0] })`
02:04:27  * silencedjoined
02:05:07  * roflmyeggojoined
02:05:16  * rxmthquit (Ping timeout: 264 seconds)
02:06:03  * dzmienjoined
02:06:39  * veggie_joined
02:06:50  <danneu>btw `return promise` vs `return promise.then(fn (row) { return row })` both return a promise. the second promise just resolves with the value 'row' inside it
02:06:51  * inflamesjoined
02:06:59  * bumbleheadquit (Ping timeout: 260 seconds)
02:08:28  * DragonPunchjoined
02:08:56  * Poeticodequit (Ping timeout: 258 seconds)
02:09:16  * FarceLemmajoined
02:10:23  <osum4est>danneu: got it, that makes more sense. that worked! just had to do result[0] rather than result.rows[0]
02:10:40  <danneu>cool
02:10:43  * csd_joined
02:12:45  * Rodya_quit (Remote host closed the connection)
02:13:20  * mixfix41quit (Quit: WeeChat 1.3)
02:13:31  * LeBlaaancjoined
02:14:11  * Rodya_joined
02:14:35  * zzo38joined
02:14:37  * afusionjoined
02:14:52  * benniblancoquit (Ping timeout: 264 seconds)
02:15:08  <zzo38>Now I made a package that has a bug report URL; my previous ones did not have it.
02:15:16  * krish203quit (Quit: Leaving.)
02:17:49  * devcchanged nick to devc`zzz
02:18:26  * eyaquit (Read error: Connection reset by peer)
02:18:32  * dommeljoined
02:18:46  * devc`zzzquit (Quit: zzz...)
02:18:58  * eyajoined
02:19:06  * neoncontrailsquit (Remote host closed the connection)
02:19:11  * zzo38part
02:20:06  * eyaquit (Read error: Connection reset by peer)
02:20:18  * eyajoined
02:20:26  * eyaquit (Read error: Connection reset by peer)
02:20:47  * eyajoined
02:21:48  * eyaquit (Read error: No route to host)
02:21:58  * eyajoined
02:22:00  * Rodya_quit (Quit: Leaving...)
02:22:27  * alilezajoined
02:22:32  * Cranitequit (Read error: Connection reset by peer)
02:22:33  * eyaquit (Read error: Connection reset by peer)
02:22:57  * eyajoined
02:23:01  * LeBlaaancquit (Quit: My Mac has gone to sleep. ZZZzzz…)
02:23:09  * Cranitejoined
02:23:53  * eyaquit (Read error: No route to host)
02:25:37  * timetocodequit (Ping timeout: 265 seconds)
02:25:59  * devcjoined
02:26:38  * Literphorquit (Quit: Literphor)
02:26:50  * dirtyonekanobijoined
02:27:30  * LeBlaaancjoined
02:28:47  * chjj_quit (Ping timeout: 260 seconds)
02:29:52  * Cranitequit (Read error: Connection reset by peer)
02:30:21  * robertmaxreesquit (Ping timeout: 258 seconds)
02:30:29  * SquadGoalsjoined
02:30:35  * Cranitejoined
02:32:19  * dirtyonekanobiquit
02:33:15  * mrognechanged nick to mrogne_afk
02:33:22  * WebSpirit_quit (Ping timeout: 244 seconds)
02:33:34  * KieronWiltshirequit (Quit: Leaving)
02:33:36  * Cranitequit (Read error: Connection reset by peer)
02:34:13  * Cranitejoined
02:34:40  * HoierMquit (Ping timeout: 264 seconds)
02:36:34  * glijoined
02:37:26  * krish203joined
02:38:31  * jdelersjoined
02:41:27  * chjj_joined
02:41:37  * xant_joined
02:41:37  * FarceLemmaquit (Ping timeout: 250 seconds)
02:42:16  * aarobc_joined
02:42:17  * Literphorjoined
02:43:30  * dvinciguerra_quit (Ping timeout: 276 seconds)
02:43:38  * aarobc_quit (Remote host closed the connection)
02:43:42  * ironfroggyquit (Remote host closed the connection)
02:44:20  * ironfroggyjoined
02:45:31  * ibashquit (Remote host closed the connection)
02:45:58  * TheSimonatorquit (Remote host closed the connection)
02:47:55  * crazyhorse18joined
02:48:41  * ironfroggyquit (Ping timeout: 244 seconds)
02:49:44  * timetocodejoined
02:49:54  * sagerdeariajoined
02:51:22  * iyogeshjoshijoined
02:54:04  * quakephilquit (Ping timeout: 240 seconds)
02:55:47  * alilezaquit (Read error: Connection reset by peer)
02:55:53  * alileza_joined
02:58:07  * smokeoquit (Remote host closed the connection)
02:58:27  * neoncontrailsjoined
02:58:43  * smokeojoined
03:00:33  * xant_part ("Textual IRC Client: www.textualapp.com")
03:03:02  * bumbleheadjoined
03:03:03  * sillysluxquit (Read error: Connection reset by peer)
03:03:17  * smccarthyjoined
03:03:22  * smokeoquit (Ping timeout: 258 seconds)
03:04:19  * elfuegoquit (Quit: elfuego)
03:04:20  * rhoquit (Ping timeout: 244 seconds)
03:05:13  * silencedquit (Quit: My Mac has gone to sleep. ZZZzzz…)
03:05:40  * braincrashquit (Quit: bye bye)
03:06:05  * alileza_quit (Remote host closed the connection)
03:07:24  * ChALkeRjoined
03:07:54  * sankhajoined
03:08:12  * bumbleheadquit (Ping timeout: 276 seconds)
03:08:22  * silencedjoined
03:09:07  * csd_quit (Ping timeout: 265 seconds)
03:11:39  * texinwien_joined
03:11:48  * leehambleyjoined
03:12:19  * sankhaquit (Ping timeout: 260 seconds)
03:16:27  * lektrikjoined
03:16:43  * niemal_joined
03:17:47  * texinwien_quit (Ping timeout: 260 seconds)
03:18:17  * graffix_quit (Ping timeout: 244 seconds)
03:18:21  * braincrashjoined
03:18:40  * devinceartasquit (Quit: Textual IRC Client: http://www.textualapp.com/)
03:19:09  * niemalquit (Ping timeout: 250 seconds)
03:19:58  * Limixjoined
03:22:12  * lektrikchanged nick to VA3VNA
03:22:40  * RedneckDonutjoined
03:23:39  * steverandyjoined
03:24:58  * alilezajoined
03:25:10  * alilezaquit (Read error: Connection reset by peer)
03:25:29  * alilezajoined
03:25:52  * rannmannjoined
03:26:04  * Limixquit (Quit: Limix)
03:26:33  * Aljone_1joined
03:26:41  * DigitalSpeedquit (Ping timeout: 250 seconds)
03:27:30  * TechnoCrunchjoined
03:28:09  * RedneckDonutquit (Remote host closed the connection)
03:29:02  * mvenjoined
03:29:26  * Aljonequit (Ping timeout: 258 seconds)
03:31:50  * benniblancojoined
03:32:01  * benniblancoquit (Max SendQ exceeded)
03:34:37  * abijeetjoined
03:35:21  * krish203part
03:36:44  * SwiftMattquit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
03:38:59  * _2E0PGS-5joined
03:39:09  * greydawgjoined
03:40:02  * dk0rjoined
03:40:39  * eyajoined
03:41:13  * ghostwalkerjoined
03:41:42  * eyaquit (Read error: Connection reset by peer)
03:42:03  * eyajoined
03:42:17  * _2E0PGSquit (Ping timeout: 260 seconds)
03:43:13  * eyaquit (Read error: Connection reset by peer)
03:43:34  * rhonabwyquit (Ping timeout: 258 seconds)
03:43:39  * eyajoined
03:44:03  * doodadjs_quit (Ping timeout: 240 seconds)
03:44:24  * niemaljoined
03:45:25  * niemal_quit (Ping timeout: 240 seconds)
03:45:37  * tubuliferousjoined
03:45:41  * plutoniixquit (Quit: Leaving)
03:45:41  * Coldblackice_joined
03:45:58  * kevireilly_joined
03:46:04  * Coldblackicequit (Ping timeout: 264 seconds)
03:46:52  * doodadjsjoined
03:47:19  * MrP[Home]quit (Ping timeout: 250 seconds)
03:48:25  * eyaquit (Read error: Connection reset by peer)
03:48:51  * eyajoined
03:49:34  * benniblancojoined
03:50:01  * eyaquit (Read error: Connection reset by peer)
03:50:27  * tubuliferousquit (Ping timeout: 260 seconds)
03:50:32  * eyajoined
03:51:24  * Swizecjoined
03:51:46  * eyaquit (Read error: Connection reset by peer)
03:52:13  * eyajoined
03:53:09  * Coldblackicejoined
03:53:25  * eyaquit (Read error: Connection reset by peer)
03:53:44  * Coldblackice_quit (Ping timeout: 260 seconds)
03:53:59  * eyajoined
03:55:02  * eyaquit (Read error: No route to host)
03:55:23  * Keverwquit (Quit: Textual IRC Client: www.textualapp.com)
03:55:37  * eyajoined
03:56:33  * boogymanquit (Read error: Connection reset by peer)
03:56:56  * eyaquit (Read error: Connection reset by peer)
03:57:19  * eyajoined
03:57:34  * Coldblackicequit (Ping timeout: 244 seconds)
03:58:29  * jxvjoined
03:58:39  * eyaquit (Read error: Connection reset by peer)
03:59:01  * eyajoined
04:00:16  * eyaquit (Read error: Connection reset by peer)
04:00:27  * sumobobjoined
04:00:42  * eyajoined
04:01:05  * tfennellyjoined
04:01:52  * eyaquit (Read error: Connection reset by peer)
04:02:00  * Keverwjoined
04:02:24  * eyajoined
04:03:33  * eyaquit (Read error: Connection reset by peer)
04:03:42  * bumbleheadjoined
04:04:05  * eyajoined
04:05:16  * eyaquit (Read error: Connection reset by peer)
04:05:31  * tfennellyquit (Ping timeout: 250 seconds)
04:05:47  * eyajoined
04:06:57  * eyaquit (Read error: Connection reset by peer)
04:07:14  * Keverwquit (Read error: Connection reset by peer)
04:07:17  * Keverw_joined
04:07:29  * eyajoined
04:08:17  * bumbleheadquit (Ping timeout: 250 seconds)
04:08:23  * apparition47joined
04:08:40  * eyaquit (Read error: Connection reset by peer)
04:09:09  * dunpealquit (Ping timeout: 250 seconds)
04:09:09  * eyajoined
04:10:14  * eyaquit (Read error: Connection reset by peer)
04:10:52  * eyajoined
04:12:05  * eyaquit (Read error: Connection reset by peer)
04:12:25  * rannmannquit (Ping timeout: 252 seconds)
04:12:31  * eyajoined
04:13:38  * eyaquit (Read error: Connection reset by peer)
04:13:39  * Swizecquit (Quit: Computer has gone to sleep.)
04:14:15  * eyajoined
04:15:19  * eyaquit (Read error: Connection reset by peer)
04:15:55  * eyajoined
04:16:40  * peb`quit (Ping timeout: 264 seconds)
04:16:43  * wazquit (Quit: My Mac has gone to sleep. ZZZzzz…)
04:17:14  * Cranitechanged nick to Cranite[Away]
04:17:15  * eyaquit (Read error: Connection reset by peer)
04:17:36  * eyajoined
04:17:56  * kevireilly_quit (Quit: kevireilly_)
04:18:58  * Flynnnquit (Quit: Auf Wiedersehen!)
04:19:12  * fyutylejoined
04:20:31  * eyaquit (Read error: Connection reset by peer)
04:21:00  * eyajoined
04:21:54  * ibashjoined
04:22:01  * imalittleteapotjoined
04:22:10  * robertmaxreesjoined
04:22:12  * eyaquit (Read error: Connection reset by peer)
04:22:40  * eyajoined
04:23:00  * silencedquit (Quit: My Mac has gone to sleep. ZZZzzz…)
04:23:05  * imalittleteapotquit (Client Quit)
04:24:01  * eyaquit (Read error: Connection reset by peer)
04:24:22  * eyajoined
04:24:26  * dommelquit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client)
04:25:15  * barajasfabjoined
04:25:49  * kevireilly_joined
04:25:50  * kevireilly_quit (Client Quit)
04:26:33  * ibashquit (Ping timeout: 258 seconds)
04:27:27  * silencedjoined
04:28:01  * marthinaljoined
04:28:12  * devcquit (Quit: zzz...)
04:28:13  * FunnyLookinHatjoined
04:28:13  * FunnyLookinHatquit (Changing host)
04:28:13  * FunnyLookinHatjoined
04:28:45  * roflmyeggoquit (Ping timeout: 240 seconds)
04:29:23  * FunnyLookinHatquit (Client Quit)
04:29:52  * eyaquit (Ping timeout: 264 seconds)
04:31:22  * eyajoined
04:31:41  * hunseopquit (Ping timeout: 244 seconds)
04:32:41  * eyaquit (Read error: No route to host)
04:32:47  * eyyajoined
04:34:43  * barajasfabquit (Ping timeout: 250 seconds)
04:37:01  * adsjfn3joined
04:37:42  * _2E0PGS-5quit (Quit: Leaving)
04:40:30  * NeverDiequit (Ping timeout: 276 seconds)
04:40:52  * Flynnnjoined
04:41:48  * bgeorgesjoined
04:41:48  * nnykjoined
04:42:06  * sankhajoined
04:43:36  * safequit (Quit: Leaving)
04:43:40  * Flynnnquit (Client Quit)
04:44:34  * abijeetquit (Remote host closed the connection)
04:46:10  * jeffreylevesque_joined
04:47:10  * Cabanossiquit (Ping timeout: 244 seconds)
04:48:24  * jeffreylevesquequit (Ping timeout: 258 seconds)
04:48:39  * Cabanossijoined
04:48:50  * doodadjsquit (Quit: Leaving)
04:49:40  * Flynnnjoined
04:53:35  * Literphorquit (Quit: Literphor)
04:55:15  * duch_kazateljoined
04:55:35  * sillysluxjoined
04:55:57  * Cohedrinquit (Quit: My Mac has gone to sleep. ZZZzzz…)
04:57:50  * bonifacejoined
04:59:17  * robertmaxreesquit (Ping timeout: 260 seconds)
05:00:03  * Literphorjoined
05:01:07  * JPTquit (Ping timeout: 244 seconds)
05:01:46  * VA3VNAquit (Ping timeout: 258 seconds)
05:02:07  * toyjoined
05:02:40  * Limixjoined
05:02:56  * toyquit (Client Quit)
05:04:34  * bumbleheadjoined
05:04:48  * subhojit777joined
05:04:56  * JPTjoined
05:06:57  * NordiQjoined
05:08:30  * joshonthewebjoined
05:09:28  * bumbleheadquit (Ping timeout: 264 seconds)
05:10:23  * jxvquit (Quit: Leaving)
05:10:23  * Literphorquit (Quit: Literphor)
05:11:44  * NordiQquit (Ping timeout: 258 seconds)
05:11:46  * timetocodequit (Quit: Leaving)
05:12:30  * alilezaquit (Remote host closed the connection)
05:12:42  * FIFOdquit (Quit: My Mac has gone to sleep. ZZZzzz…)
05:13:04  * alilezajoined
05:14:09  * sumobobquit (Ping timeout: 250 seconds)
05:14:33  * apparitionquit (Quit: My Mac has gone to sleep. ZZZzzz…)
05:16:32  * dk0rquit (Read error: Connection reset by peer)
05:16:40  * armyriadquit (Ping timeout: 264 seconds)
05:16:48  * A5101joined
05:17:49  * sankhaquit (Remote host closed the connection)
05:20:05  * alilezaquit (Remote host closed the connection)
05:20:31  * alilezajoined
05:20:39  * indrquit (Quit: Leaving)
05:21:22  * A5101_joined
05:21:35  * smccarthyquit (Remote host closed the connection)
05:21:53  * alilezaquit (Remote host closed the connection)
05:21:54  * sankhajoined
05:22:01  * alilezajoined
05:22:02  * Limixquit (Quit: Limix)
05:22:14  * A5101_quit (Remote host closed the connection)
05:24:07  * Cohedrinjoined
05:24:07  * Cohedrinquit (Client Quit)
05:25:13  * BeerLoverjoined
05:25:36  * Cohedrinjoined
05:26:57  * lpinjoined
05:28:37  * Limixjoined
05:29:45  * abernixjoined
05:30:17  * _xorjoined
05:30:28  * jdelersquit (Quit: Connection closed for inactivity)
05:31:37  * gokmenjoined
05:32:46  * sumobobjoined
05:35:29  * sillysluxquit (Read error: Connection reset by peer)
05:35:31  * Megajoined
05:36:03  * hyeonuquit (Quit: Leaving)
05:36:32  * Limixquit (Quit: Limix)
05:37:59  * ibashjoined
05:38:07  * iyogeshjoshiquit (Remote host closed the connection)
05:38:41  * flyBoiquit (Ping timeout: 250 seconds)
05:38:51  * unitechjoined
05:39:04  * flyBoijoined
05:39:54  * hyeonujoined
05:39:59  * flyBoiquit (Client Quit)
05:41:03  * clintarquit (Ping timeout: 240 seconds)
05:42:22  * thomas_25joined
05:42:47  * NeverDiejoined
05:43:04  * Sucksquit (Quit: Leaving)
05:44:47  * sputnik13quit (Quit: My Mac has gone to sleep. ZZZzzz…)
05:45:04  * graffix_joined
05:45:38  * clintarjoined
05:46:22  * tubuliferousjoined
05:46:59  * niemalquit (Remote host closed the connection)
05:47:23  * jishankaijoined
05:48:39  <Mega>Hi guys! I have a question about usage modules with ES6 classes, please take a look at this simple example! ^_^ http://paste.ofcode.org/kByL5bKTh2qrziTyzszvjn
05:48:51  * Swizecjoined
05:49:39  <ljharb>no need to cross-post; answered in ##javascript
05:49:39  * Swizecquit (Client Quit)
05:50:38  * kevireilly_joined
05:51:18  * armyriadjoined
05:51:21  * tubuliferousquit (Ping timeout: 276 seconds)
05:54:09  * smccarthyjoined
05:54:10  * edwardlyquit (Ping timeout: 252 seconds)
05:54:50  * blahfooquit (Ping timeout: 244 seconds)
05:55:33  * hadifarnoudjoined
05:55:51  <BeerLover>is there any way to exclude certain columns from knexjs return ?
05:56:11  * armyriadquit (Ping timeout: 250 seconds)
05:56:15  * edwardlyjoined
05:56:15  * edwardlyquit (Changing host)
05:56:15  * edwardlyjoined
05:56:21  * Cranite[Away]changed nick to Cranite
05:56:24  <BeerLover>I can include all using ['*'], or include the ones i want specifying like: ['user_id', 'password']
05:56:36  <BeerLover>but i want to exclude one or two fields....
05:56:43  <BeerLover>is there any way?
05:56:46  * VA3VNAjoined
05:56:55  * temmi_hoojoined
05:57:13  * Flynnnquit (Quit: Auf Wiedersehen!)
05:57:23  * alilezaquit (Remote host closed the connection)
05:58:11  * leehambleyquit (Quit: My Mac has gone to sleep. ZZZzzz…)
05:58:18  * smccarthyquit (Ping timeout: 244 seconds)
05:59:27  * hadifarnoudquit (Client Quit)
05:59:53  * alilezajoined
06:01:28  * rxmthjoined
06:02:26  * afusionquit (Ping timeout: 244 seconds)
06:02:34  * tfennellyjoined
06:02:54  * quattro_joined
06:02:54  * one_zeroquit
06:03:19  * armyriadjoined
06:03:27  * gokmenquit (Quit: I'll be back.)
06:03:48  <Mega>I found an answer how to split ES6 class to multiple files http://paste.ofcode.org/34URwSpVf5y72JRz6ThXBv8
06:04:59  * afusionjoined
06:05:14  * veggie_quit (Quit: WeeChat 1.5)
06:05:19  * bumbleheadjoined
06:05:22  <Mega>ljharb, could you tell something about the way I split it? is it completely unacceptable?
06:05:26  * csd_joined
06:05:38  * SquadGoalsquit (Quit: SquadGoals)
06:05:58  * dunpealjoined
06:06:16  * rxmthquit (Ping timeout: 252 seconds)
06:06:25  * kevireilly__joined
06:07:04  * tfennellyquit (Ping timeout: 264 seconds)
06:07:56  * adsjfn3quit (Ping timeout: 250 seconds)
06:08:02  * munch_joined
06:09:03  * bqjoined
06:09:05  * kevireilly_quit (Ping timeout: 240 seconds)
06:09:23  * bqquit (Max SendQ exceeded)
06:09:49  * bumbleheadquit (Ping timeout: 244 seconds)
06:09:50  * bqjoined
06:09:51  * bqquit (Max SendQ exceeded)
06:10:00  * csd_quit (Ping timeout: 258 seconds)
06:10:20  * alilezaquit (Remote host closed the connection)
06:10:20  * wraithgarjoined
06:10:29  * bqjoined
06:10:38  * bqquit (Max SendQ exceeded)
06:12:13  * armyriadquit (Ping timeout: 250 seconds)
06:12:35  * TyrfingMjolnirjoined
06:12:50  * thomas_25quit (Read error: Connection reset by peer)
06:12:52  * vuotojoined
06:13:14  * VA3VNAquit (Read error: Connection reset by peer)
06:13:36  * dopesongjoined
06:14:07  * wraithgarquit (Client Quit)
06:15:01  * oxhakjoined
06:16:07  * tfennellyjoined
06:16:25  * Jidoorjoined
06:17:10  * armyriadjoined
06:17:46  * rihbynejoined
06:18:29  * thomas_25joined
06:19:04  * GustavoLapastajoined
06:19:11  * alilezajoined
06:19:30  <rihbyne>how is this channel different from javascript ?\
06:19:43  * iyogeshjoshijoined
06:20:27  * Literphorjoined
06:21:05  * Mantas7776joined
06:22:37  * alilezaquit (Remote host closed the connection)
06:27:08  * jalntjoined
06:27:55  * Omnilordquit (Ping timeout: 244 seconds)
06:29:22  <LeBlaaanc>uh
06:29:42  * subhojit777quit (Ping timeout: 260 seconds)
06:29:49  <LeBlaaanc>google can probably answer that quite well
06:30:02  * thomas_25quit (Read error: Connection reset by peer)
06:30:52  <myndzi>rihbyne: node is a javascript runtime plus api functions to handle a bunch of stuff that you don't get in a browser
06:31:01  <myndzi>so... this channel is about node, the platform, more than javascript, the language
06:31:22  <lucasem>rihbyne: e.g., are you interacting with your filesystem in JS? You should probably ask that question here.
06:31:47  * Literphorquit (Quit: Literphor)
06:32:18  * A5101quit (Ping timeout: 276 seconds)
06:32:31  * quattro_quit (Quit: quattro_)
06:34:45  * silencedquit (Quit: My Mac has gone to sleep. ZZZzzz…)
06:34:51  * star_pronejoined
06:35:09  * soeejoined
06:35:13  * thomas_25joined
06:35:49  * amitkqedjoined
06:36:31  * amitkqedquit (Remote host closed the connection)
06:37:15  * thomas_25quit (Read error: Connection reset by peer)
06:37:35  * amitkqedjoined
06:39:33  * maretjoined
06:39:33  * tfennellyquit (Read error: Connection reset by peer)
06:40:07  * thomas_25joined
06:40:55  * armyriadquit (Ping timeout: 252 seconds)
06:41:14  * duch_kazatelquit
06:41:21  * subhojit777joined
06:41:33  * monk_king_kongquit (Ping timeout: 240 seconds)
06:41:42  * tesrtyjoined
06:41:48  * armyriadjoined
06:42:01  * bonifacequit (Remote host closed the connection)
06:42:12  * armyriadquit (Client Quit)
06:42:25  * mylordjoined
06:42:36  * Jidoorquit (Ping timeout: 250 seconds)
06:42:37  * Xitiquit (Quit: Xiti)
06:43:13  * thomas_25quit (Read error: Connection reset by peer)
06:44:05  * ibashquit (Remote host closed the connection)
06:44:30  * silencedjoined
06:45:55  * thomas_25joined
06:46:22  * muracquit (Read error: Connection reset by peer)
06:46:22  * tesrtyquit (Client Quit)
06:48:15  * thomas_25quit (Read error: Connection reset by peer)
06:48:37  * sumobobquit (Ping timeout: 250 seconds)
06:49:03  * ebiquit (Ping timeout: 250 seconds)
06:49:03  * beckyconning_quit (Ping timeout: 250 seconds)
06:49:04  * tfennellyjoined
06:49:29  * bpierrequit (Ping timeout: 250 seconds)
06:49:30  * Joykillerjoined
06:49:55  * jennmoneydollarsquit (Ping timeout: 250 seconds)
06:49:55  * bovequit (Ping timeout: 250 seconds)
06:49:55  * dulaxquit (Ping timeout: 250 seconds)
06:49:55  * tobiequit (Ping timeout: 250 seconds)
06:49:55  * janxquit (Ping timeout: 250 seconds)
06:49:55  * cspotcodequit (Ping timeout: 250 seconds)
06:50:06  * tvwjoined
06:50:10  * thomas_25joined
06:50:21  * lucasemquit (Ping timeout: 250 seconds)
06:50:21  * Sorellaquit (Ping timeout: 250 seconds)
06:50:21  * HeNquit (Ping timeout: 250 seconds)
06:50:34  * mschquit (Ping timeout: 240 seconds)
06:50:47  * seungha_____quit (Ping timeout: 250 seconds)
06:50:47  * wizonesolutionsquit (Ping timeout: 250 seconds)
06:50:47  * solexiousquit (Ping timeout: 250 seconds)
06:50:50  * star_pronequit (Remote host closed the connection)
06:51:12  * kawa2014joined
06:51:39  * beawesomeinsteadquit (Ping timeout: 250 seconds)
06:51:40  * thomas_25quit (Read error: Connection reset by peer)
06:51:49  * jackhumquit (Read error: Connection reset by peer)
06:51:49  * solexiousjoined
06:51:50  * tobiejoined
06:51:51  * lmatteisquit (Read error: Connection reset by peer)
06:51:55  * ebijoined
06:51:56  * bovejoined
06:52:08  * bpierrejoined
06:52:08  * mschjoined
06:52:10  * jennmoneydollarsjoined
06:52:10  * lucasemjoined
06:52:10  * HeNjoined
06:52:14  * seungha_____joined
06:52:15  * cspotcodejoined
06:52:20  * Sorellajoined
06:52:21  * janxjoined
06:52:25  * dulaxjoined
06:52:28  * Hyukjoined
06:52:29  * beckyconning_joined
06:52:35  * sillysluxjoined
06:52:54  * wizonesolutionsjoined
06:52:54  * ibashjoined
06:53:36  * jackhumjoined
06:53:45  * beawesomeinsteadjoined
06:53:46  * SwiftMattjoined
06:53:48  * lmatteisjoined
06:54:27  * tfennell_joined
06:55:06  * the_antjoined
06:56:11  * thomas_25joined
06:56:11  * ibashquit (Client Quit)
06:56:20  * eyyaquit (Quit: Leaving...)
06:56:20  * tfennellyquit (Ping timeout: 244 seconds)
06:56:52  * Finnoloidquit (Quit: Connection closed for inactivity)
06:57:18  * Literphorjoined
06:57:22  * BeerLoverquit (Quit: My Mac has gone to sleep. ZZZzzz…)
06:57:29  * Flynnnjoined
06:58:09  * hyeonuquit (Remote host closed the connection)
06:58:58  * nschoejoined
06:59:33  * sagerdeariaquit (Quit: Leaving)
07:00:03  * Mamutjoined
07:00:14  * Joykillerquit (Remote host closed the connection)
07:00:48  * hyeonujoined
07:01:31  * soeequit (Quit: Konversation terminated!)
07:02:47  <ChALkeR>Mega: not sure why not just add properties to the prototype.
07:03:15  * BeerLoverjoined
07:04:25  * Deeewaynequit (Ping timeout: 240 seconds)
07:05:11  * Jidoorjoined
07:05:16  * DragonPunchquit (Ping timeout: 264 seconds)
07:05:25  * soeejoined
07:06:02  * bumbleheadjoined
07:06:47  * fo0zlejoined
07:07:41  * nnykquit (Ping timeout: 250 seconds)
07:08:49  * phil23quit (Quit: WeeChat 1.4)
07:10:02  * quattro_joined
07:10:17  * bumbleheadquit (Ping timeout: 250 seconds)
07:11:52  * kakashiALquit (Ping timeout: 264 seconds)
07:12:09  * kmsivquit (Read error: Connection reset by peer)
07:12:33  * kmsivjoined
07:12:41  * doodadjsjoined
07:12:51  * FriedZombiequit (Ping timeout: 244 seconds)
07:12:51  * ZeBaguettejoined
07:14:47  * DragonPunchjoined
07:15:17  * rxmthjoined
07:15:36  * Totem|Awaychanged nick to TotempaaltJ
07:15:49  * bitnode3quit (Quit: WeeChat 0.4.2)
07:16:19  * p4trixjoined
07:17:05  * monk_king_kongjoined
07:17:14  * Deeewaynejoined
07:17:31  * Lomexjoined
07:20:18  * iyogeshjoshiquit (Remote host closed the connection)
07:20:28  * Silenced_v2joined
07:20:55  * Cranitequit (Read error: Connection reset by peer)
07:21:22  * TotempaaltJchanged nick to Totem|Away
07:22:25  * tanepiperquit (Ping timeout: 250 seconds)
07:22:33  * ljharbquit (Ping timeout: 240 seconds)
07:22:49  * ShrewdSpirit_joined
07:22:53  * tanepiperjoined
07:23:08  * laurensclaessenjoined
07:23:09  <Jidoor>i'm trying to use server-sent events and i'm storing the response object every time the client initiates this, when i write to the response objects the client receives the data but how can i know from the response object when the client has closed the browser and can't receive any more data?
07:23:16  * rxmthquit (Ping timeout: 258 seconds)
07:23:19  * star_pronejoined
07:23:48  <Jidoor>was looking at response.setTimeout() but not sure if that's what i want?
07:24:14  * ljharbjoined
07:27:49  * neoncontrailsquit (Remote host closed the connection)
07:30:14  * Booster2ooojoined
07:32:38  * dopesongquit (Remote host closed the connection)
07:33:29  * Razerglassquit (Read error: Connection reset by peer)
07:33:40  * busticatedquit (Read error: Connection reset by peer)
07:34:04  * _xorquit (Read error: Connection reset by peer)
07:34:16  * kevireilly__quit (Read error: Connection reset by peer)
07:34:17  * busticatedjoined
07:34:25  * jeffreylevesque_quit (Read error: Connection reset by peer)
07:34:31  * _xorjoined
07:34:32  * kevireilly_joined
07:34:40  * inhwjsjoined
07:34:49  <inhwjs>in koa, why do you do `yield next;` at the very top of the middleware
07:34:55  <inhwjs>instead of the bottom
07:35:02  <inhwjs>shouldn't middleware do its own stuff first before calling the next
07:35:10  * jeffreylevesquejoined
07:35:20  * kmsivquit (Read error: Connection reset by peer)
07:35:33  * turtlehatquit (Ping timeout: 240 seconds)
07:35:58  * Literphorquit (Quit: Literphor)
07:36:00  * Johnny-quit (Ping timeout: 276 seconds)
07:36:05  * SDrquit (Read error: Connection reset by peer)
07:36:07  * kmsivjoined
07:36:33  * pcfreak30quit (Ping timeout: 250 seconds)
07:36:34  * eyiquit (Ping timeout: 240 seconds)
07:36:47  * SDrjoined
07:36:53  * lmatteisquit (Read error: Connection reset by peer)
07:36:55  * mich-cook1quit (Quit: Leaving.)
07:37:03  * sbellinaquit (Ping timeout: 240 seconds)
07:37:03  * chovyquit (Ping timeout: 240 seconds)
07:37:04  * psmolenquit (Ping timeout: 264 seconds)
07:37:18  * eyijoined
07:37:26  * lmatteisjoined
07:37:34  * kanzurequit (Ping timeout: 240 seconds)
07:37:34  * sehropequit (Ping timeout: 240 seconds)
07:37:34  * ninseiquit (Ping timeout: 240 seconds)
07:37:34  * __main__quit (Ping timeout: 240 seconds)
07:37:49  * david1983joined
07:38:04  * h12oquit (Ping timeout: 240 seconds)
07:38:38  * kanzurejoined
07:38:46  * turtlehatjoined
07:39:04  * psmolenjoined
07:39:05  <xenon21>inhwjs: Are you referring to the main page example?
07:39:07  * Razerglassjoined
07:39:07  * sbellinajoined
07:39:25  * unitechquit (Read error: Permission denied)
07:39:25  * unitechjoined
07:39:25  * unitechquit (Max SendQ exceeded)
07:39:25  * unitechjoined
07:39:25  * robertkowalskiquit (Ping timeout: 250 seconds)
07:39:25  * chovy_joined
07:39:25  * mertimorquit (Ping timeout: 250 seconds)
07:39:27  * pcfreak30joined
07:39:31  * sehropejoined
07:39:34  * robertkowalskijoined
07:39:34  * mertimor-joined
07:39:40  * Totem|Awaychanged nick to TotempaaltJ
07:39:57  * thomas_25quit (Read error: Connection reset by peer)
07:39:59  * omequit (Quit: Connection closed for inactivity)
07:40:00  * Silenced_v2quit (Changing host)
07:40:00  * Silenced_v2joined
07:40:00  <xenon21>that shows how to use x-response-time, logging, and hello world middlewares?
07:40:03  * timoxley_quit (Ping timeout: 240 seconds)
07:40:22  * peb`joined
07:40:26  * __main__joined
07:40:31  * thomas_25joined
07:40:39  * timoxleyjoined
07:40:43  * h12ojoined
07:40:51  <inhwjs>xenon21: i just noticed it in a few places
07:40:53  * codelahomaquit (Ping timeout: 250 seconds)
07:40:58  * Johnny-joined
07:41:10  * ahmedelgabrijoined
07:41:21  <xenon21>If so it makes sense to pass (yield) from x-response-time to logging and then logging to hello world then it will be back at logging when hello world done
07:41:41  <inhwjs>what about in a situation like the 404 example
07:41:43  <xenon21>and then back to x-response-time which will set X-Response-Time correctly
07:41:43  <inhwjs>https://github.com/koajs/examples/blob/master/404/app.js
07:41:47  * silencedquit (Quit: My Mac has gone to sleep. ZZZzzz…)
07:41:51  * vuotoquit (Remote host closed the connection)
07:42:08  * thomas_25quit (Read error: Connection reset by peer)
07:42:34  * bonifacejoined
07:42:41  <xenon21>It tests first whether or not the next middlewares (if any) already set the response status to something
07:42:52  * wtrockijoined
07:42:58  <xenon21>If not set then it's obviously should be 404
07:43:27  * codelahomajoined
07:43:29  <inhwjs>hmm i see
07:43:39  * ninseijoined
07:43:39  * Mamutquit (Ping timeout: 265 seconds)
07:43:41  <inhwjs>but why wouldn't you just put the 404 middleware at the very bottom then?
07:43:56  <xenon21>that would be the case with express
07:44:04  <xenon21>that works too with koa
07:44:34  <xenon21>it's up to you how you will design how the middlewares should work together
07:44:37  <danneu>inhwjs: you `yield next` before your code if you want to do something to the response
07:44:59  <danneu> /* request is going downstream */ yield next; /* response is coming upstream */
07:45:29  * cocoadaemonjoined
07:46:20  * nd__joined
07:47:07  * tubuliferousjoined
07:47:29  * bonifacequit (Ping timeout: 244 seconds)
07:48:00  * plutoniixjoined
07:48:20  <danneu>you only put 404 middleware in express at the bottom because you don't have a choice
07:49:05  * FuzzySocketsquit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
07:49:19  * david1983quit (Quit: Leaving)
07:50:36  * iyogeshjoshijoined
07:51:58  * tubuliferousquit (Ping timeout: 258 seconds)
07:52:36  * texinwien_joined
07:54:38  * star_pronequit (Remote host closed the connection)
07:55:32  * kedarejoined
07:57:23  * Tragedyjoined
07:58:57  * Megaquit (Ping timeout: 260 seconds)
07:59:16  * dopesongjoined
07:59:50  * tesrtyjoined
08:00:12  * inhwjsquit (Quit: Page closed)
08:00:38  * dongustonjoined
08:01:05  * Swizecjoined
08:02:17  * unitechquit (Ping timeout: 250 seconds)
08:03:19  * Mamutjoined
08:04:26  * Razerglassquit (Read error: Connection reset by peer)
08:05:19  * bat_coderjoined
08:05:40  * csd_joined
08:06:03  * thomas_25joined
08:06:13  * silencedjoined
08:06:29  * mvenquit (Read error: Connection reset by peer)
08:06:47  * bumbleheadjoined
08:07:16  * mvenjoined
08:07:36  * chargenjoined
08:07:51  * ahmedelgabriquit (Ping timeout: 276 seconds)
08:08:03  * cotkojoined
08:08:37  * laurensc_joined
08:08:45  * Dimikquit (Ping timeout: 240 seconds)
08:09:55  * csd_quit (Ping timeout: 250 seconds)
08:10:03  * kanzurequit (Ping timeout: 240 seconds)
08:10:03  * Fuslquit (Ping timeout: 240 seconds)
08:10:46  * Razerglassjoined
08:11:03  * Kingdutchquit (Ping timeout: 240 seconds)
08:11:04  * L_starquit (Ping timeout: 240 seconds)
08:11:10  * kanzurejoined
08:11:11  * NeverDiequit (Quit: http://radiux.io/)
08:11:11  * chll_joined
08:11:14  * bumbleheadquit (Ping timeout: 244 seconds)
08:11:41  * Kingdutchjoined
08:12:04  * L_starjoined
08:12:28  * laurensclaessenquit (Ping timeout: 264 seconds)
08:13:03  * dodobrainjoined
08:13:07  * baudehloquit (Ping timeout: 250 seconds)
08:13:07  * zkatquit (Ping timeout: 250 seconds)
08:13:36  * zkatjoined
08:13:41  * baudehlojoined
08:14:07  * Fusljoined
08:15:15  * sillysluxquit (Read error: Connection reset by peer)
08:15:17  * BeerLoverquit (Ping timeout: 260 seconds)
08:16:00  * Flynnnquit (Read error: Connection reset by peer)
08:17:43  * oxhakquit (Remote host closed the connection)
08:20:32  * gliquit (Ping timeout: 260 seconds)
08:21:31  * rendarjoined
08:21:58  * stennoworkjoined
08:22:25  * vassagusjoined
08:22:54  * Narigojoined
08:22:58  * alilezajoined
08:23:01  * LeBlaaancquit (Quit: My Mac has gone to sleep. ZZZzzz…)
08:23:05  * benijoined
08:24:07  * oxhakjoined
08:24:24  * subhojit777quit (Ping timeout: 260 seconds)
08:24:44  * Cagelinpart
08:25:23  * bat_coderquit (Remote host closed the connection)
08:25:54  * hyeonuquit (Remote host closed the connection)
08:26:35  * p4trickjoined
08:26:47  * apparition47quit (Quit: Bye)
08:26:54  * vassagusquit (Ping timeout: 258 seconds)
08:27:05  * kawa2014quit (Ping timeout: 240 seconds)
08:27:25  * Mantas7776quit (Ping timeout: 250 seconds)
08:27:37  * alilezaquit (Ping timeout: 252 seconds)
08:27:38  * kevireilly_quit (Quit: kevireilly_)
08:29:37  * bongjovijoined
08:30:32  * p4trixquit (Ping timeout: 265 seconds)
08:31:27  * Ergojoined
08:32:23  * hyeonujoined
08:32:23  * kawa2014joined
08:34:03  * visceraljoined
08:34:39  * Cohedrinquit (Quit: My Mac has gone to sleep. ZZZzzz…)
08:36:59  * glijoined
08:38:35  * moneylotionjoined
08:38:40  * sankhaquit (Remote host closed the connection)
08:39:46  * Hyukquit (Quit: Textual IRC Client: www.textualapp.com)
08:40:02  * kakashiALjoined
08:40:17  * senayarjoined
08:40:33  * silencedquit (Ping timeout: 240 seconds)
08:41:11  * sagerdeariajoined
08:43:05  <JustAnotherIdiot>how do I do incrby by in node redis?
08:43:41  * bonifacejoined
08:44:51  <JustAnotherIdiot>nvm
08:48:19  * bonifacequit (Ping timeout: 260 seconds)
08:48:30  * subhojit777joined
08:49:16  * targosjoined
08:49:23  * JPTquit (Remote host closed the connection)
08:49:50  * serardjoined
08:52:58  * JPTjoined
08:53:27  * lohfuquit (Quit: WeeChat 1.2)
08:55:15  * b0xjoined
08:56:46  * silencedjoined
08:57:47  * ahmedelgabrijoined
08:58:48  * saghul_joined
08:59:14  * dodobrainquit (Quit: Leaving)
09:00:26  * dodobrainjoined
09:01:39  * lucasemquit (Quit: Connection closed for inactivity)
09:01:55  * oxhakquit (Ping timeout: 250 seconds)
09:02:56  * TyrfingMjolnirquit (Quit: leaving)
09:03:06  * thomas_25quit (Read error: Connection reset by peer)
09:03:57  * FarceLemmajoined
09:04:03  * TyrfingMjolnirjoined
09:04:04  * TyrfingMjolnirquit (Client Quit)
09:04:20  * dltmd6262joined
09:04:23  * jdelersjoined
09:04:40  * dltmd6262quit (Client Quit)
09:05:00  * ahmedelgabriquit (Ping timeout: 244 seconds)
09:05:54  * ToApolytoXaosjoined
09:06:07  * TyrfingMjolnirjoined
09:07:35  * bumbleheadjoined
09:07:45  * silencedquit (Quit: My Mac has gone to sleep. ZZZzzz…)
09:07:46  * Jidoorquit (Ping timeout: 250 seconds)
09:08:05  * nnykjoined
09:09:00  * sankhajoined
09:09:10  * NordiQjoined
09:09:58  * dongustonquit (Ping timeout: 252 seconds)
09:10:11  <TyrfingMjolnir>How can I read a file byte by byte?
09:10:46  * poseidquit (Quit: Page closed)
09:11:41  * bumbleheadquit (Ping timeout: 244 seconds)
09:12:29  * FarceLemmaquit (Ping timeout: 250 seconds)
09:13:54  * greves_changed nick to greves
09:14:00  * Condorquit (Ping timeout: 258 seconds)
09:14:13  * NordiQquit (Ping timeout: 250 seconds)
09:14:40  * ahmedelgabrijoined
09:15:29  * sankhaquit (Ping timeout: 265 seconds)
09:18:04  * timetocodejoined
09:18:55  * SwiftMattquit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
09:19:39  <TyrfingMjolnir>I'm here: http://termbin.com/wwd6
09:19:54  <TyrfingMjolnir>How can I extract byte by byte in an if?
09:20:34  <LetoThe2nd>TyrfingMjolnir: readSync with length = 1?
09:20:58  * _yoy_quit (Ping timeout: 252 seconds)
09:20:58  * YoYquit (Ping timeout: 252 seconds)
09:22:09  * MrP[Home]joined
09:23:54  * kakashiALquit (Ping timeout: 276 seconds)
09:27:01  * star_pronejoined
09:27:52  * Condorjoined
09:28:25  * lohfujoined
09:29:06  * Moonlight-Angelquit (Ping timeout: 276 seconds)
09:29:23  * JustAnotherIdiotquit (Ping timeout: 250 seconds)
09:30:46  * golemgargjoined
09:31:03  * sbellinaquit (Ping timeout: 276 seconds)
09:31:50  * T-2000quit (Quit: Leaving)
09:31:59  * star_pronequit (Ping timeout: 250 seconds)
09:32:09  * sibaquit (Quit: My Mac has gone to sleep. ZZZzzz…)
09:32:40  * iyogeshjoshiquit (Remote host closed the connection)
09:34:57  * dopesongquit (Remote host closed the connection)
09:35:35  * dopesongjoined
09:36:33  * Gatesunderjoined
09:36:39  * iyogeshjoshijoined
09:39:31  * dopesongquit (Remote host closed the connection)
09:39:49  * dopesongjoined
09:40:27  * tfennell_quit (Read error: Connection reset by peer)
09:42:16  * Moonlight-Angeljoined
09:43:22  * dongustonjoined
09:45:47  * tfennellyjoined
09:47:45  * BulleTTimejoined
09:47:52  * tubuliferousjoined
09:48:47  * stelarcfjoined
09:52:43  * tubuliferousquit (Ping timeout: 258 seconds)
09:52:50  * YoYjoined
09:53:39  * YoY_joined
09:54:35  * smccarthyjoined
09:54:55  * plutoniixquit (Read error: Connection reset by peer)
09:54:56  * gliquit (Ping timeout: 244 seconds)
09:55:14  * golemgargquit (Quit: Page closed)
09:55:40  * Golem-Gargjoined
09:56:07  * kingarmadilloquit (Ping timeout: 244 seconds)
09:57:58  * visiongatequit (Read error: Connection reset by peer)
09:58:31  * andre_joined
09:58:44  * smccarthyquit (Ping timeout: 244 seconds)
09:58:55  * andre_changed nick to Guest50628
10:00:41  * RLaquit (Quit: Leaving)
10:00:51  * plutoniixjoined
10:01:11  * Megajoined
10:01:35  * Megaquit (Client Quit)
10:01:53  * Megajoined
10:03:30  * Golem-Garg_joined
10:03:45  * Golem-Gargquit (Quit: Page closed)
10:04:26  * Golem-Garg_part
10:04:30  * Guest50628quit (Read error: Connection reset by peer)
10:04:41  * Tennisjoined
10:04:49  * monk_king_kongquit (Quit: leaving)
10:04:52  * nschoequit (Quit: Program. Terminated.)
10:05:47  * GolemGargjoined
10:05:59  * dopesongquit (Remote host closed the connection)
10:06:05  * samiswellcooljoined
10:06:35  * dopesongjoined
10:06:37  * tesrtyquit (Quit: -)
10:06:39  * hwcomcnjoined
10:06:46  * tfennellyquit (Read error: Connection reset by peer)
10:08:20  * bumbleheadjoined
10:09:05  * Sharaalquit (Ping timeout: 250 seconds)
10:09:07  <GolemGarg>Hi
10:09:10  * glijoined
10:09:24  * afusionquit (Ping timeout: 276 seconds)
10:09:30  * gliquit (Read error: Connection reset by peer)
10:09:32  <GolemGarg>I am new to the community and want to contribute to Node
10:10:01  * tfennellyjoined
10:10:26  <GolemGarg>Please guide
10:11:22  * dopesongquit (Ping timeout: 260 seconds)
10:11:27  * Sharaal1joined
10:11:32  * Sharaal1quit (Read error: Connection reset by peer)
10:12:18  * sankhajoined
10:12:30  * bumbleheadquit (Ping timeout: 244 seconds)
10:13:16  * Sharaaljoined
10:14:09  * Sharaalquit (Read error: Connection reset by peer)
10:14:40  <stennowork>GolemGarg, have you read https://nodejs.org/en/get-involved/ ?
10:14:52  * scippioquit (Ping timeout: 252 seconds)
10:14:52  * Sharaaljoined
10:16:38  * sankhaquit (Ping timeout: 244 seconds)
10:17:03  * joshonthewebquit (Quit: Computer has gone to sleep.)
10:18:35  * Sharaal1joined
10:18:35  * Sharaal1quit (Client Quit)
10:18:55  * Sharaal1joined
10:19:04  * Sharaalquit (Ping timeout: 240 seconds)
10:19:12  * nishu-tryinghardjoined
10:19:20  * blip-quit (Quit: Leaving)
10:19:25  * Sharaal1quit (Client Quit)
10:19:43  * Sharaaljoined
10:20:00  * ed209quit (Remote host closed the connection)
10:20:06  * ed209joined
10:20:43  * f5joined
10:20:46  * tesrtyjoined
10:20:49  * elfuegojoined
10:21:42  * Cranitejoined
10:22:08  * tesrtyquit (Client Quit)
10:23:08  * vassagusjoined
10:23:54  * tfennellyquit (Read error: Connection reset by peer)
10:23:59  * tesrtyjoined
10:24:52  * f5quit (Quit: Leaving.)
10:24:55  * tesrtyquit (Client Quit)
10:25:15  * openstructjoined
10:25:16  * fish1joined
10:25:19  * tfennellyjoined
10:25:25  * elfuegoquit (Ping timeout: 244 seconds)
10:25:25  <GolemGarg>@stennowork, I have gone through that document.
10:25:35  * fish1quit (Max SendQ exceeded)
10:25:45  <GolemGarg>I need further guidance
10:26:27  * fish1joined
10:26:42  * fish1quit (Max SendQ exceeded)
10:27:27  * fish8joined
10:27:33  * NomadJimquit (Read error: Connection reset by peer)
10:27:42  * fish8quit (Max SendQ exceeded)
10:27:52  * NomadJim_joined
10:27:53  * vassagusquit (Ping timeout: 250 seconds)
10:29:05  * tesrtyjoined
10:29:12  * fish86546joined
10:29:13  * Mamutquit (Quit: I cna ytpe 300 wrods pre mniuet!!!)
10:29:27  * fish86546quit (Max SendQ exceeded)
10:30:03  * fish86546joined
10:30:18  * fish86546quit (Max SendQ exceeded)
10:30:37  * dopesongjoined
10:30:51  * scippiojoined
10:31:23  * timetocodequit (Quit: Leaving)
10:31:36  * fish86546joined
10:31:45  * thealphanerdquit (Quit: farewell for now)
10:31:51  * fish86546quit (Max SendQ exceeded)
10:31:52  * ArchNoobquit (Ping timeout: 258 seconds)
10:32:01  * temmi_hooquit (Quit: Connection closed for inactivity)
10:32:15  * thealphanerdjoined
10:34:38  * wazjoined
10:37:42  * Megaquit (Quit: Leaving)
10:40:16  * SundayJunejoined
10:42:17  * mihokjoined
10:43:32  * kingarmadillojoined
10:44:40  * bat_coderjoined
10:44:45  * Dark_Aaronjoined
10:46:07  * greydawgquit (Remote host closed the connection)
10:46:13  * ThePendulumjoined
10:47:11  * devcjoined
10:49:14  * devc`joined
10:49:44  * Hyukjoined
10:50:33  * BeerLoverjoined
10:50:41  * Ergoquit (Ping timeout: 250 seconds)
10:51:19  <BeerLover> Hi people. I am having problem turning my code (highlighted) to async.... My code: https://dpaste.de/qjSy#L10,11,12,14,15,16,18,19,65,66,67,68,69,70,71
10:51:22  * Mamutjoined
10:52:42  * tesrtyquit (Quit: -)
10:53:36  * devcquit (Ping timeout: 276 seconds)
10:53:40  * Mamutquit (Client Quit)
10:55:15  * dopesongquit (Remote host closed the connection)
10:55:52  * dopesongjoined
10:57:19  * Ergojoined
10:57:21  * qbitquit (Quit: WeeChat 1.4)
10:58:07  * texinwien_quit (Ping timeout: 244 seconds)
10:58:32  * texinwien_joined
10:58:46  * iyogeshjoshiquit (Remote host closed the connection)
10:59:18  * iyogeshjoshijoined
10:59:30  * sagerdeariaquit (Quit: Leaving)
11:00:09  * dopesongquit (Ping timeout: 260 seconds)
11:00:37  * qbitjoined
11:01:32  * tesrtyjoined
11:02:14  * p3rrorjoined
11:03:28  * cobquit (Ping timeout: 264 seconds)
11:04:14  * earendelchanged nick to oolooloo
11:04:26  * visceralquit (Quit: visceral)
11:04:30  * DeltaHeavyjoined
11:04:34  * Cranitechanged nick to Cranite[Away]
11:04:46  * Cranite[Away]quit (Quit: My Mac has gone to sleep. ZZZzzz…)
11:04:54  * Lomexquit (Remote host closed the connection)
11:05:20  * Cranitejoined
11:05:33  * BeerLoverquit (Ping timeout: 240 seconds)
11:06:26  * BeerLoverjoined
11:06:30  * devc`changed nick to devc`zzz
11:06:34  <BeerLover> Hi people. I am having problem turning my code (highlighted) to async.... My code: https://dpaste.de/qjSy#L10,11,12,14,15,16,18,19,65,66,67,68,69,70,71
11:07:22  * devc`zzzquit (Quit: zzz...)
11:07:54  * tesrtyquit (Quit: -)
11:08:14  * ooloolooquit (Disconnected by services)
11:09:06  * bumbleheadjoined
11:09:45  * devcjoined
11:09:56  * tesrtyjoined
11:11:03  * oolooloo2joined
11:11:23  * GustavoLapastaquit (Quit: Leaving)
11:13:30  * SundayJunequit
11:13:36  * bumbleheadquit (Ping timeout: 258 seconds)
11:14:14  * Lomexjoined
11:14:16  * Aljone_1quit (Ping timeout: 252 seconds)
11:14:21  * devcquit (Client Quit)
11:14:38  * devcjoined
11:14:50  * quakephiljoined
11:16:21  * dopesongjoined
11:17:52  * Aljonejoined
11:18:25  * oolooloo2part
11:18:48  * earendeljoined
11:18:49  * openstructquit (Remote host closed the connection)
11:19:36  * Lomexquit (Ping timeout: 276 seconds)
11:20:15  * Cranitequit (Quit: Textual IRC Client: www.textualapp.com)
11:20:52  <reynir>BeerLover: can you describe your problem
11:21:55  * HoierMjoined
11:22:09  * phajijoined
11:23:06  * b0xquit (Quit: b0x)
11:23:16  * laurensc_quit (Remote host closed the connection)
11:26:31  * alanszlosekjoined
11:28:09  * Keanu73joined
11:29:42  * Gatesunderquit (Quit: WeeChat 1.0.1)
11:30:21  * plutoniixquit (Quit: จรลี จรลา)
11:33:29  * Fohlen-joined
11:34:49  * bat_coderquit (Remote host closed the connection)
11:35:04  * Fohlenquit (Ping timeout: 240 seconds)
11:35:09  * laurensclaessenjoined
11:36:06  * Mamutjoined
11:36:09  * lhdcquit (Remote host closed the connection)
11:36:59  * BeerLoverquit (Ping timeout: 258 seconds)
11:37:07  * samsshjoined
11:40:41  * openstructjoined
11:41:12  * alanszlosekquit (Remote host closed the connection)
11:43:17  * TechnoCrunchquit (Read error: Connection reset by peer)
11:44:20  * lhdcjoined
11:45:56  * Ice_Strikepart
11:46:03  * doodadjsquit (Quit: Leaving)
11:46:13  * michaelvbjoined
11:48:36  * tubuliferousjoined
11:49:05  * laurensclaessenquit (Remote host closed the connection)
11:49:46  * uniacid_pcquit (Read error: Connection reset by peer)
11:50:16  * GolemGargquit (Ping timeout: 250 seconds)
11:50:18  * pwnsdxjoined
11:50:28  * uniacid_pcjoined
11:50:49  * ChALkeRquit (Quit: Konversation terminated!)
11:51:01  * ChALkeRjoined
11:52:04  * OnkelTemquit (Ping timeout: 264 seconds)
11:53:28  * tubuliferousquit (Ping timeout: 258 seconds)
11:57:11  <joepie91>in yet another case of "this is why you use existing implementations of things, instead of trying to roll your own": https://labs.detectify.com/2016/07/27/how-i-made-lastpass-give-me-all-your-passwords/
11:57:22  * lhdcquit (Remote host closed the connection)
11:57:44  * thebisquickmanjoined
11:57:58  * lhdcjoined
11:58:37  <stennowork>oww thats painful
11:59:33  * Miajoined
12:00:00  * chxanequit (Read error: Connection reset by peer)
12:00:27  * iyogeshjoshiquit (Remote host closed the connection)
12:00:34  * iyogeshjoshijoined
12:01:02  * krauqjoined
12:01:34  * DeltaHeavyquit (Ping timeout: 252 seconds)
12:01:49  * laurensclaessenjoined
12:01:53  <shoky>yikes
12:03:09  * lhdcquit (Ping timeout: 276 seconds)
12:03:40  * Lee1092quit (Quit: Connection closed for inactivity)
12:04:37  * jeffreylevesquequit (Ping timeout: 244 seconds)
12:05:09  * andre_joined
12:05:30  <joepie91>seriously though, I've seen people here try to roll their own URL parsing more than once
12:05:33  * andre_changed nick to Guest47517
12:05:37  <joepie91>this is the kind of thing that can happen when you do that :P
12:05:45  * kedare_joined
12:05:58  * csd_joined
12:06:18  * gregf_joined
12:06:23  <joepie91>but it applies more widely - if there's a module that does the thing you need, chances are these kind of errors have already been resolved...
12:06:45  * hadifarnoudjoined
12:06:48  <maret>Hi everyone, I have folder for node.js library and everything is under lib foder under root so project/lib/... there is also sample with sample app in it so project/sample/sampleApp/index.js I am running this index.js from which I am pointing to files under lib folder (so i can try library while I am developing it). question is if I run node inspector for index.js it doesn't see lib folder so how should I run it so it has access to lib folder out
12:06:48  <maret>side of it in the project root?
12:07:04  * Fohlen-quit (Ping timeout: 264 seconds)
12:07:04  * lhdcjoined
12:07:18  * polydo_sjoined
12:07:43  * Hyukquit (Quit: Textual IRC Client: www.textualapp.com)
12:08:20  <joepie91>hmm...
12:08:47  * lhdcquit (Remote host closed the connection)
12:08:56  <joepie91>maret: can you screenshot the file tree you see in the inspector? because I *thought* that it just displayed whatever files were loaded
12:08:59  * kedarequit (Ping timeout: 260 seconds)
12:09:21  * lhdcjoined
12:09:40  <maret>jiangplus, seems like they are not but let me double check
12:09:50  * bumbleheadjoined
12:09:57  * Lomexjoined
12:10:02  * alfiechanged nick to Alfie
12:10:18  * csd_quit (Ping timeout: 244 seconds)
12:11:17  <michaelvb>hey joepie91 long time no see :)
12:11:42  * lhdc_joined
12:12:22  <joepie91>michaelvb: ohai
12:12:24  * Fohlenjoined
12:13:03  * lhdc_quit (Remote host closed the connection)
12:13:30  * sankhajoined
12:13:34  * lhdcquit (Ping timeout: 240 seconds)
12:13:37  * lhdc_joined
12:14:16  * bumbleheadquit (Ping timeout: 264 seconds)
12:14:45  * mrkmgjoined
12:15:10  * bongjoviquit (Quit: My Mac has gone to sleep. ZZZzzz…)
12:15:12  * setun-90joined
12:15:55  <michaelvb>got a job as node.js junior 3 months ago :)
12:16:04  <setun-90>Hello, where do node's core .js files get installed to on Win10?
12:17:00  * alilezajoined
12:17:09  <michaelvb>nice to see you're still here helping people out
12:17:28  * sibajoined
12:17:44  * sankhaquit (Remote host closed the connection)
12:17:50  * sankhajoined
12:18:19  * lhdc_quit (Ping timeout: 260 seconds)
12:18:23  <joepie91>michaelvb: good to hear :)
12:18:38  <joepie91>setun-90: you mean modules like 'path' and 'url'?
12:19:09  * alanszlosekjoined
12:19:11  * iyogeshjoshiquit (Remote host closed the connection)
12:19:20  * Hyukjoined
12:19:28  * Hyukquit (Client Quit)
12:19:35  * Guest47517quit (Read error: Connection reset by peer)
12:19:36  * crazyhorse18quit (Ping timeout: 244 seconds)
12:19:40  * iyogeshjoshijoined
12:19:47  * bongjovijoined
12:20:12  * andre_joined
12:20:36  * andre_changed nick to Guest52176
12:21:28  * alilezaquit (Ping timeout: 264 seconds)
12:23:57  * vassagusjoined
12:24:08  * iyogeshjoshiquit (Ping timeout: 258 seconds)
12:24:23  * pyonjoined
12:24:47  <setun-90>joepie91: yes
12:25:04  * hwcomcnquit (Ping timeout: 264 seconds)
12:25:33  * serardquit (Quit: Leaving)
12:25:43  * lol-iconquit (Killed (weber.freenode.net (Nickname regained by services)))
12:25:43  * pyonchanged nick to lol-icon
12:27:20  * lhdcjoined
12:27:21  * oxhakjoined
12:27:38  * Palssonjoined
12:27:44  * MrP[Home]quit (Read error: Connection reset by peer)
12:27:47  * Palssonchanged nick to MrP[Home]
12:28:20  * lhdcquit (Remote host closed the connection)
12:28:33  * vassagusquit (Ping timeout: 240 seconds)
12:28:55  * lhdcjoined
12:29:06  <joepie91>setun-90: those are not separately installed anywhere - they are compiled into the Node binary
12:29:15  <joepie91>setun-90: any particular reason you're asking?
12:30:06  * lemonsparrowjoined
12:30:26  <lemonsparrow>how to pass a result of a promise to another promise ? can anyone give any sample code ?
12:30:39  * ArchNoobjoined
12:30:58  <joepie91>lemonsparrow: your question isn't entirely clear - can you gist the code you're working with?
12:31:07  * BulleTTimequit (Ping timeout: 244 seconds)
12:31:14  <joepie91>probably the easiest way to clear it up :)
12:31:38  <joepie91>( http://gist.github.com/ )
12:32:32  * crazyhorse18joined
12:32:45  * Ergoquit (Ping timeout: 240 seconds)
12:32:58  * MrP[Home]quit (Read error: No route to host)
12:33:04  * Palssonjoined
12:33:28  * lhdcquit (Ping timeout: 264 seconds)
12:34:34  * star_pronejoined
12:35:15  * Ergojoined
12:35:36  <lemonsparrow>joepie91: sure.. 1 minute
12:37:10  * chargenquit (Ping timeout: 244 seconds)
12:38:05  <lemonsparrow>joepie91: just neeed a simple example.. like if I have a promise to begin with, I need to pass the result of it to another promise.. how to do it ?
12:38:17  <setun-90>joepie91: So it's different from a Linux installation?
12:39:36  <setun-90>joepie91: I needed to see the errors an API function passes to its callback
12:39:55  <joepie91>lemonsparrow: but that question doesn't make any sense. you don't "pass results to other promises", that's not how promises work
12:40:08  <joepie91>lemonsparrow: that's why I'm asking for some sample code, to understand what the actual problem is that you're trying to solve
12:40:23  <michaelvb>guessing he wants to resolve a result
12:40:28  <joepie91>setun-90: it works the same on Linux, the core lib is *always* compiled into the binary afaik
12:40:28  * jdelersquit (Quit: Connection closed for inactivity)
12:40:45  <joepie91>setun-90: and what do you mean? you need to see the code that *defines* those errors?
12:40:47  <joepie91>or?
12:40:53  <lemonsparrow>joepie91: why cant I pass results to another promise ?
12:41:02  <michaelvb>lemonsparrow google promises resolve
12:41:07  <michaelvb>see if that is what you're after
12:41:11  <joepie91>lemonsparrow: this entire line of questioning doesn't make sense, and it's impossible for me to answer any of this
12:41:26  <joepie91>lemonsparrow: there's no useful answer I can give you until I see a concrete example of what you're trying to do
12:41:32  * chargenjoined
12:41:54  <joepie91>michaelvb: I'd recommend against giving people generic terms like that because chances are they're going to be using Promise.resolve unnecessarily or incorrectly...
12:41:59  * BeerLoverjoined
12:42:02  <lemonsparrow>joepie91: pass result of a promise to a then clause
12:42:04  <joepie91>(given that a lot of the documentation on this is wrong/bad/etc)
12:42:07  <lemonsparrow>http://stackoverflow.com/questions/28250680/how-do-i-access-previous-promise-results-in-a-then-chain
12:42:10  <BeerLover> Hi people. I am having problem turning my code (highlighted) to async.... My code: https://dpaste.de/qjSy#L10,11,12,14,15,16,18,19,65,66,67,68,69,70,71
12:42:21  <michaelvb>didn't you write an article on promises joep?
12:42:26  <michaelvb>or was that somebody else
12:42:26  <joepie91>michaelvb: several
12:42:45  <BeerLover>joepie91 maybe you can help me
12:42:46  <joepie91>lemonsparrow: in the specific example in that stackoverflow post, the solution is to nest the promises - sec, let me make an example
12:43:09  <lemonsparrow>joepie91: thank
12:43:11  <lemonsparrow>ss
12:43:38  * chargenquit (Read error: Connection reset by peer)
12:44:20  <joepie91>lemonsparrow: https://gist.github.com/joepie91/87d9270e5aed19ffee1897f8c47f734e (also using arrow functions and Promise.try, which you definitely should be using)
12:44:26  <joepie91>for more about Promise.try....
12:44:29  <joepie91>!Promise.try @ lemonsparrow
12:44:29  <ecmabot>lemonsparrow: What is Promise.try, and why does it matter? http://cryto.net/~joepie91/blog/2016/05/11/what-is-promise-try-and-why-does-it-matter/
12:44:39  <setun-90>joepie91: Huh, on a previous Linux installation, I found files like 'http.js' under '/usr/local/bin'
12:44:48  <joepie91>setun-90: those definitely should not be there
12:45:12  <lemonsparrow>joepie91: thanks
12:45:47  <joepie91>BeerLover: what do you mean with "turning to async"?
12:46:00  <setun-90>joepie91: Well, not directly under there, but under '/usr/local/bin/nodejs/$somepath'
12:46:12  <joepie91>setun-90: ahh, hold on. Debian or Ubuntu?
12:46:40  <joepie91>with Node installed via apt?
12:46:40  <setun-90>joepie91: Lubuntu
12:46:48  * kmsivquit (Ping timeout: 258 seconds)
12:46:53  <BeerLover>joepie91 right now i'm using sync version of jsonwebtoken.... i want to make it async... which can be done by passing a callback... But how will the code in routes and auth.js change if i wanna do that?
12:47:01  <joepie91>setun-90: if it was installed via apt, it's probably the distro packagers doing nonstandard stuff
12:47:11  <joepie91>BeerLover: there's not really an async jsonwebtoken
12:47:23  <joepie91>BeerLover: thread about that is here: https://github.com/auth0/node-jsonwebtoken/issues/111
12:47:37  <joepie91>so you can just leave it sync
12:47:43  <joepie91>it's kinda sorta pretending to be async but isn't really
12:48:05  <setun-90>joepie91: Well I downloaded the package manually AFAIR
12:48:05  <BeerLover>joepie91 Verify currently offers a synchronous operation or an optional callback (which simply defers evaluation to a future turn of the event loop). It's unclear to me why the callback version exists. I also think it's an antipattern to overload the same method to behave both synchronously and asynchronously depending on the arguments.
12:48:22  <joepie91>BeerLover: yeah, that entire thread is about how the callback API should be removed because it isn't *actually* async
12:48:23  * munch_quit (Remote host closed the connection)
12:48:49  <BeerLover>if i keep it the way it is, will it affect performance?
12:48:52  <joepie91>so frankly it's probably best to just pretend the callback API isn't there and stick with sync
12:48:57  <joepie91>Probably Not(tm)
12:48:57  <BeerLover>if too many requests are there
12:49:13  <joepie91>the one case where their fake-async can help, is if you do like thousands of signatures *for the same request*
12:49:16  <joepie91>but you probably don't
12:49:22  <joepie91>and even then it'd only help with latency of other requests
12:49:24  <joepie91>not with performance
12:49:25  <BeerLover>and one more thing.... do i require passport at all?
12:49:25  <lemonsparrow>joepie91: thanks
12:49:27  <joepie91>otherwise
12:49:38  * jeffreylevesquejoined
12:49:41  * lemonsparrowquit (Quit: Page closed)
12:49:44  <joepie91>BeerLover: if you intend to support multiple auth mechanisms, in particular openid or oauth: yes
12:49:46  <joepie91>otherwise: no
12:49:47  <BeerLover>i duuno what passport is for really
12:49:59  * thinkt4nkjoined
12:50:19  <joepie91>BeerLover: abstracting multiple auth methods into one API
12:50:24  <BeerLover>i want local auth (username and password) upon which i give 2 tokens: refresh and access_token
12:50:26  <joepie91>can be useful if you have a million "sign in with X" links
12:50:28  <joepie91>uh oh
12:50:37  <joepie91>BeerLover: read this, please: http://cryto.net/~joepie91/blog/2016/06/13/stop-using-jwt-for-sessions/
12:50:48  <joepie91>sounds like you're trying to reimplement sessions with JWT and that's a bad idea
12:51:04  <joepie91>(yes, including with refresh tokens, see also the flowchart in the followup post)
12:51:19  <BeerLover>joepie91 no
12:51:27  <BeerLover>its a rest api server for an app
12:51:42  * DeltaHeavyjoined
12:51:42  <BeerLover>the tokens have expiry of 24h
12:51:57  <BeerLover>then they'll request for new token using refresh tokens
12:52:13  <BeerLover>every call will have auth token
12:52:30  * star_pronequit (Remote host closed the connection)
12:52:35  * wtrockiquit (Quit: Bye Bye ^^)
12:52:46  <joepie91>BeerLover: this is a browser-based thing, correct?
12:52:51  <BeerLover>nope
12:52:57  * kakashiALjoined
12:53:00  <joepie91>okay, then can you describe it a bit more?
12:53:02  <BeerLover>android app
12:53:07  * iyogeshjoshijoined
12:53:08  <BeerLover>ios app
12:53:12  <joepie91>and the user auths with username/password?
12:53:18  <BeerLover>yes
12:53:22  <joepie91>then you can still just use sessions
12:53:30  * EyePulpjoined
12:54:02  <joepie91>they're essentially still sessions, just not in a browser
12:54:13  * thinkt4n_joined
12:54:27  <BeerLover>joepie91 everywhere i only find jwt usage with rest api
12:54:32  <BeerLover>is that wrong?
12:54:41  <joepie91>BeerLover: yes, because that's what the hype is about, largely thanks to Auth0's nonsense
12:54:45  * DragonPunchquit (Ping timeout: 240 seconds)
12:54:48  <joepie91>doesn't make it the correct solution
12:54:54  <joepie91>reasons for which are described in the article I linked :p
12:55:04  * p3rrorquit (Ping timeout: 260 seconds)
12:55:16  * Guest41651quit (Quit: Konversation terminated!)
12:55:20  <joepie91>JWT is a very specialized solution for a fairly narrow set of usecases
12:55:31  <BeerLover>what use cases?
12:55:33  <joepie91>'sessions' is not one of those, and it's unreasonably complex and hard to get right for that
12:55:43  * bberryquit (Quit: Connection closed for inactivity)
12:55:48  <joepie91>BeerLover: inter-server claims, for example. one example is described at the bottom of my article
12:56:07  <joepie91>I really recommend just reading it :)
12:56:20  * blahfoojoined
12:56:31  * Tragedyquit (Read error: Connection reset by peer)
12:56:33  <BeerLover>it's too late i think to implement sessions
12:56:39  <joepie91>why would it be?
12:56:42  <BeerLover>can you point me to a resource?
12:56:59  * thinkt4nkquit (Ping timeout: 244 seconds)
12:57:05  * krauqquit (Ping timeout: 240 seconds)
12:57:07  <BeerLover>i don't know much about using sessions
12:57:21  * chargenjoined
12:57:23  <joepie91>BeerLover: app.use https://github.com/expressjs/session server-side, enable cookie retention / cookie jars client-side, you're done
12:57:35  <joepie91>(assuming you use Express)
12:57:48  <joepie91>that's essentially it
12:58:23  <BeerLover>joepie91 but doesn't that violate statelessness?
12:58:31  <joepie91>you can select whatever session store fits your current (database) stack
12:58:43  <joepie91>BeerLover: that assumes that you need or want 'statelessness' to begin with and you probably don't
12:58:44  * Abhishek_joined
12:58:49  <joepie91>it's not some kind of technically superior thing
12:58:51  * ironfroggyjoined
12:58:52  <joepie91>it's a tradeoff
12:59:04  <joepie91>a tradeoff that is almost never worth it
12:59:05  <commma>you store your sessions in a database
12:59:17  <commma>by that we could say that having a database violates statelelessness
12:59:28  <commma>... statelessness
12:59:35  <joepie91>unless you are quite literally running Reddit or a similarly-sized operation, 'statelessness' for session data shouldn't even be on your radar
12:59:45  * zxc_joined
12:59:46  * BulleTTimejoined
12:59:49  * visceraljoined
12:59:57  <commma>just try to keep to the tenants of the twelve-factor app
12:59:57  <joepie91>and hell, even Reddit uses sessions
13:00:02  <commma>no need to go full "stateless"
13:00:42  <stennowork>a colleague of mine was stateless for a while
13:00:43  <BeerLover>how long do the sessions last?
13:00:54  <stennowork>he could choose between german, russian and israel i think
13:00:54  * zxc_quit (Client Quit)
13:00:59  <stennowork>chose german in the end
13:01:01  <commma>obv.
13:01:06  * visceralpart
13:01:17  <commma>BeerLover: as long as you want
13:02:00  <joepie91>stennowork: hah
13:02:57  * munch_joined
13:03:02  * rhojoined
13:03:13  <setun-90>joepie91: Any resource you could link me to on the errors passed to callbacks?
13:03:44  <joepie91>setun-90: do you mean the error types?
13:03:53  <joepie91>so that you can detect specific kinds of errors?
13:04:39  <setun-90>joepie91: Well, if it's the error types, then yes
13:04:45  * tzeroquit (Ping timeout: 240 seconds)
13:05:18  <BeerLover>joepie91 you just made my day miserable
13:05:22  <BeerLover>thanks
13:05:33  <BeerLover>:'(
13:05:46  <joepie91>setun-90: you can find the source of the core libs here;https://github.com/nodejs/node/tree/master/lib - there's a git tag for each Node release
13:05:48  * ConspiratorXjoined
13:05:50  <joepie91>so ideally pick the release you are on
13:05:51  * afusionjoined
13:06:13  <joepie91>C++ extensions live in https://github.com/nodejs/node/tree/master/src
13:06:27  * bottazzinijoined
13:06:32  <joepie91>setun-90: unfortunately the error types are not particularly well-documented yet
13:06:56  <setun-90>joepie91: Yeah I guess that'll have to do
13:07:04  <setun-90>Thanks anyway :)
13:08:09  * dongustonquit (Read error: Connection reset by peer)
13:08:16  * nnykquit (Ping timeout: 264 seconds)
13:08:48  <joepie91>BeerLover: bright side: sessions are much simpler to work with than JWT :P
13:08:50  * nnykjoined
13:08:54  * nnykquit (Changing host)
13:08:54  * nnykjoined
13:09:01  <BeerLover>joepie91 i'll try that
13:09:20  <BeerLover>anyone knows how to scroll the overflow scroll bars in webpages
13:09:25  <BeerLover>with 2 fingers on mac
13:09:45  <BeerLover>the content inside divs doesn't move, the webpage moves
13:10:05  * setun-90part ("Leaving")
13:10:36  * bumbleheadjoined
13:11:20  * mcmillhjjoined
13:11:50  * afusionquit (Ping timeout: 265 seconds)
13:14:55  * dongustonjoined
13:15:09  * bumbleheadquit (Ping timeout: 250 seconds)
13:15:42  * lohfuquit (Quit: WeeChat 1.2)
13:15:59  * lohfujoined
13:16:13  * waz-joined
13:16:23  * lohfuquit (Client Quit)
13:16:39  * lohfujoined
13:17:03  * lohfuquit (Client Quit)
13:18:01  * wazquit (Ping timeout: 250 seconds)
13:18:32  <xenon21>joepie91: I like the example for what JWT is good for in your example, thanks
13:18:43  * kedare_quit (Quit: Leaving)
13:21:18  * star_pronejoined
13:21:38  * Xitijoined
13:21:47  * haensquit (Quit: Connection closed for inactivity)
13:22:41  <xenon21>* in your article
13:22:51  * elfuegojoined
13:24:50  * bonifacejoined
13:24:56  * lohfujoined
13:27:05  * elfuegoquit (Ping timeout: 240 seconds)
13:31:25  * timmywiljoined
13:31:31  * timmywilquit (Client Quit)
13:31:36  * BeerLoverquit (Quit: My Mac has gone to sleep. ZZZzzz…)
13:35:27  * neriumjoined
13:35:31  * hadifarnoudquit (Remote host closed the connection)
13:36:10  * sibaquit (Quit: My Mac has gone to sleep. ZZZzzz…)
13:36:21  <nerium>What would be a good data structure / package for getting keys from an object and fail with an error if the key doesn’t exist?
13:36:43  * dodobrainquit (Ping timeout: 252 seconds)
13:36:46  <nerium>I.e obj.get(”nonExistingKey”) // => fail Anything build in?
13:40:14  * dommeljoined
13:41:23  * smokeojoined
13:43:53  * altcatalinjoined
13:44:37  * de_hennejoined
13:44:45  * bonifacequit (Remote host closed the connection)
13:45:23  * bgeorgesquit (Remote host closed the connection)
13:47:09  * de_henne_quit (Ping timeout: 276 seconds)
13:47:28  * grilljoined
13:48:57  * marthinalquit (Ping timeout: 260 seconds)
13:49:21  * tubuliferousjoined
13:49:42  * thunfischjoined
13:51:29  * marthinaljoined
13:52:02  * alilezajoined
13:52:18  * Limixjoined
13:52:51  * subhojit777quit (Ping timeout: 250 seconds)
13:53:24  * mizu_no_oto_workjoined
13:53:48  * alilezaquit (Remote host closed the connection)
13:53:59  * alilezajoined
13:54:09  * tubuliferousquit (Ping timeout: 250 seconds)
13:54:59  * nd__quit (Ping timeout: 258 seconds)
13:55:16  * phil23joined
13:56:55  * TheSimonatorjoined
13:57:23  * elfuegojoined
13:57:36  * bgeorgesjoined
13:57:40  * rjnienaberjoined
13:57:52  * optikalmousejoined
13:58:29  * alilezaquit (Ping timeout: 250 seconds)
13:58:42  <michaelvb>joepie91, at my new work they basically wrote their own authentication framework, send help
13:58:54  * bonifacejoined
14:00:12  <rjnienaber>hey, i seem to be seeing a difference in behaviour between node v4.4.7 and v6.0.0 when connecting to an https server and specifying a certificate
14:00:17  <rjnienaber>https://gist.github.com/rjnienaber/87a1427e5084c5bb277084de70e8d2ac
14:00:27  * bdunavantjoined
14:00:34  <rjnienaber>it works in v6.0.0 and fails in v4.4.7
14:00:42  <rjnienaber>and i would expect it to work in both
14:01:02  <rjnienaber>should i be instantiating it differently in v4.4.7?
14:02:42  * phil23quit (Ping timeout: 258 seconds)
14:02:51  * iyogeshjoshiquit (Remote host closed the connection)
14:03:40  * marrenarrejoined
14:04:13  * DeltaHea_joined
14:04:49  * DeltaHeavyquit (Ping timeout: 250 seconds)
14:04:59  * Hesulanjoined
14:05:17  * kedarejoined
14:05:55  * calamityjoined
14:06:01  <calamity>is there an electron channel?
14:06:08  * husqarquit (Quit: ZNC - http://znc.in)
14:06:32  * grillquit (Quit: GRILL OUT)
14:06:34  * DeltaHea_changed nick to DeltaHeavy
14:06:40  <marrenarre>Not sure in which of the more specific channels I would otherwise ask this, so I'll ask here: What is the recommended way to combine Express and a build system such as Gulp? For example, let's say I want to use Babel for server scripts and Babel and Sass for client content. And what if I want to use views and I want to minify the HTML as well? Should I minify my templates in the build process?
14:06:54  * husqarjoined
14:07:09  <marrenarre>One of the things I'm wondering about is the recommended directory structure.
14:07:16  * csd_joined
14:07:42  * wtrockijoined
14:07:44  * rihbynequit (Remote host closed the connection)
14:08:23  * mrkmgquit (Remote host closed the connection)
14:08:43  * mrkmgjoined
14:09:07  * timmywiljoined
14:09:51  * timmywilquit (Client Quit)
14:10:03  * smccarthyjoined
14:10:09  * phil23joined
14:10:28  * macabrejoined
14:11:11  <nerium>Seams really dificult to find a key value store, like the Object, that fails when the key doesn’t exist
14:11:14  * mrkmgquit (Remote host closed the connection)
14:11:20  * bumbleheadjoined
14:11:26  <nerium>Isn’t this pattern common in javascript?
14:11:30  * mrkmgjoined
14:11:36  <stennowork>you mean like localstorage?
14:11:48  * tesrtyquit (Quit: -)
14:12:08  * eric2929292920joined
14:12:35  * waz-changed nick to waz
14:12:36  <nerium>No, a hash map which fails when fetching non existing keys
14:12:47  <nerium>obj.get(”nonExistingKey”) // => fail
14:13:29  * Limixquit (Quit: Limix)
14:14:01  * Tragedyjoined
14:14:08  * barajasfabjoined
14:14:22  * neovestajoined
14:14:48  <nerium>Waisting a lot of time 1. having to check that a value exist. 2. debugging code where undefined has been passed around when ’key’ in ’obj’ isn’t set
14:15:33  <nerium>Ruby has a obj.fetch(key) for hash maps which fails with a proper error message if the key isn’t found
14:15:39  * bumbleheadquit (Ping timeout: 250 seconds)
14:15:49  * gmuropjoined
14:16:03  * Alex`joined
14:16:38  <optikalmouse>so is anyone taking a look at the Node.js certification? does anyone know how much $$$ it will cost?
14:16:42  * rxmthjoined
14:17:58  * Alex`part ("Textual IRC Client: www.textualapp.com")
14:18:25  * timmywiljoined
14:18:36  * Mamutquit (Quit: I cna ytpe 300 wrods pre mniuet!!!)
14:19:36  * judjoined
14:20:18  * geirhaquit (Ping timeout: 276 seconds)
14:20:24  * tesrtyjoined
14:20:36  * kftzgjoined
14:20:45  * lsyoyomjoined
14:21:26  * _2E0PGSjoined
14:22:22  * mvenquit (Ping timeout: 252 seconds)
14:22:25  <joepie91>michaelvb: uh-oh. why?
14:22:46  <joepie91>optikalmouse: the what?
14:23:10  * elfuegoquit (Quit: elfuego)
14:23:34  <optikalmouse>joepie91: don't know it was advertised on twitter? by the node.js foundation?
14:23:40  <commma>there's no such thing
14:23:46  * felixjetquit (Quit: Leaving)
14:23:57  <commma>oh wow, there actually is going to be
14:24:04  <joepie91>wtf
14:24:09  <joepie91>reading through https://github.com/nodejs/education/blob/master/ROADMAP.md#certification now
14:24:10  <commma>https://github.com/nodejs/education/blob/master/ROADMAP.md#certification
14:24:11  * elfuegojoined
14:24:15  <commma>efb
14:24:15  <joepie91>and my first response is "wtf do you need that for"
14:24:21  <joepie91>:|
14:24:27  <nerium>Hmm, doesn’t look like lodash has support for this eather
14:24:38  * vassagusjoined
14:24:43  <commma>i wonder how related it is to strongloops old bullshit certification
14:24:48  <joepie91>nerium: what's your usecase
14:24:50  <joepie91>?*
14:24:52  <commma>seeing as their page now redirects to this
14:24:56  * phil23quit (Quit: WeeChat 1.4)
14:25:06  * mrogne_afkchanged nick to mrogne
14:25:10  <optikalmouse>I'm on the fence about it, but mainly glad. it's nice to have private certifications
14:25:22  <optikalmouse>but at the same time, I just know some employers will use that to hire *only* people with the cert.
14:25:24  <nerium>joepie91: I’m trying to prevent having undefined values floating around in my application
14:25:25  * felixjetjoined
14:25:25  * d0nkeyBOBjoined
14:25:30  <optikalmouse>just like they do with university degrees :/
14:25:38  <nerium>As they introduce unexpected behaviour
14:26:05  <joepie91>optikalmouse: I'm not sure I see any positive properties in this...
14:26:46  * Limixjoined
14:26:52  * veggie_joined
14:27:09  <optikalmouse>joepie91: I do; it's too easy to slap some js code together and call yourself a developer. all those code schools are churning out super jr devs, the cert could help make it easier to find the people who are actually interested in coding. go to a code school, get a node.js cert is a better indicator of developer performance imo
14:27:13  <joepie91>nerium: it's definitely not something you want on every object/property everywhere (there are very valid reasons for allowing `undefined` to be passed around) but I guess I can see the usecase for specific key/value maps or specific properties
14:27:22  * elfuegoquit (Client Quit)
14:27:25  <joepie91>optikalmouse: I don't find that to be true, at all.
14:27:30  <optikalmouse>or a good indicator that the person is a certification hunter.
14:27:32  <optikalmouse>:P
14:27:33  <joepie91>the certificate just becomes another checklist item
14:27:39  <joepie91>and loses its value automatically
14:27:59  <michaelvb>Well managers like checklists :p
14:28:01  <joepie91>it might work for the first few months or so
14:28:05  <joepie91>and then it doesn't anymore
14:28:07  * Limixquit (Client Quit)
14:28:10  <joepie91>and now everybody is stuck with bullshit cert requirements
14:28:15  * phalethjoined
14:28:23  <optikalmouse>I see, so the lemon companies will rely on it too much and we'll all get screwed over
14:28:27  <joepie91>that quite possibly will cost money as well
14:28:30  * elfuegojoined
14:28:34  <nerium>joepie91: Just to be clear; I’m not talking about *just* having a get method that fails, but as complement to one that doesn’t
14:28:38  <joepie91>increasing the barrier of entry to new devs who might not have a lot to spend
14:28:39  <optikalmouse>guess it's time for developers to have thier own companies where certs are nice but not required ;p
14:28:53  <joepie91>and those very same bullshit-bootcamps are going to add the cert stuff to their list of stuff to do anyway
14:29:39  * vassagusquit (Ping timeout: 265 seconds)
14:29:40  <joepie91>nerium: yeah. I'm not aware of anything built in like that, but it'd not be too difficult to implement yourself and there's probably a module (or twenty...) for this already
14:29:51  <joepie91>actually...
14:29:52  <joepie91>moment
14:30:01  * marrenarrepart
14:30:10  * ironfroggyquit (Remote host closed the connection)
14:30:21  <nerium>joepie91: The pattern is common so I would expect there to be a ”js way” to solve the problkem
14:30:22  <joepie91>hm, no, dotty doesn't have that.
14:30:26  * mvenjoined
14:30:36  * TorvusBugjoined
14:30:39  * ironfroggyjoined
14:31:05  <joepie91>nerium: generally when undefined appears somewhere it's not hard at all to track down the source from the stacktrace (because eventually something is going to try and call a non-existent property on it) so this is not something that developers will frequently be looking for
14:31:21  * dopesongquit (Remote host closed the connection)
14:31:33  <joepie91>that's not to say that there are *no* cases where you get weird errors
14:31:51  * AvianFlujoined
14:31:59  * dopesongjoined
14:32:06  <joepie91>but I'm not convinced that, as a general rule of thumb, it's worth the effort to explicitly use fail-if-non-existent getters everywhere just for the few edge cases where you have a hard-to-track-down bug
14:32:14  <joepie91>and I'd imagine that that's why it's not a common practice
14:32:16  <nerium>joepie91: It’s a bug that can be prevented by not allowing undefined values
14:32:34  <joepie91>it's quite a bit more complicated than that
14:32:44  <joepie91>JS as a language is designed around the possibility of having undefined values
14:32:57  <nerium>Yes, as most language.
14:33:07  <nerium>Just like most language, some parts shouldn’t be used
14:33:26  * Silenced_v2quit (Quit: ZNC 1.6.2 - http://znc.in)
14:33:27  <joepie91>and with the property access model it has, it's not trivial to say "do the same thing but fail when nonexistent" without introducing a wildly different syntax... which many likely will not be interested in using for the reason I've already described
14:33:28  <nerium>null values are mostly avoided as they are to general, just like undefined
14:33:52  <joepie91>nerium: "too general"?
14:34:01  <nerium>So how would you tackle an undefined behaviour?
14:34:19  <nerium>(an honest question)
14:34:27  <nerium>(as I’m interested)
14:34:33  <xenon21>nerium: Is explicit validation useful?
14:34:40  <xenon21>like always assert something
14:34:42  * vassagusjoined
14:34:49  <xenon21>in the critical part of code
14:34:50  <nerium>xenon21: That would be the same as failing, so yes
14:34:57  <joepie91>nerium: in most cases, an unexpected 'undefined' will blow up quickly because something tries to call a property on it
14:34:58  * ironfroggyquit (Ping timeout: 244 seconds)
14:35:03  <joepie91>before anything is actually done with it
14:35:16  <joepie91>in some cases, you want to explicitly validate
14:35:30  <optikalmouse>joepie91: you make some good points about the certs. like I said, I'm on the fence but kinda glad about it but now...not so happy heh
14:35:34  * Taylorquit (Ping timeout: 252 seconds)
14:35:48  <joepie91>can be as part of general input validation using something like checkit, joi, etc
14:35:58  <joepie91>or more simply if(whatever == null)
14:36:06  <xenon21>I saw something like `if (typeof obj.a === 'undefined') { throw new Error('this should never happen') }
14:36:06  <joepie91>depends on the case really
14:36:07  <nerium>Okay, so you hope that the code called with a undefined state/value will solve the problem for your instead of implicity handle the problem when it occurs?
14:36:11  * eric2929292920quit (Quit: Leaving.)
14:36:12  <xenon21>ahahaa
14:36:31  <joepie91>nerium: I don't expect it to 'solve the problem'. I expect it to blow up.
14:36:36  <nerium>Again, no bashing – just interesting in how this can be solved
14:36:38  * lsyoyomquit (Quit: WeeChat 1.5)
14:36:40  <joepie91>in internal code, that is
14:36:44  <michaelvb>just handle the blowing up part :D
14:36:49  <joepie91>generally externally-facing code (eg. module API) needs to have explicit validation
14:37:00  * digiskyjoined
14:37:05  <joepie91>you *can* do more paranoid validation and check input parameters on everything internally, but it's usually not worth the effort
14:37:11  <joepie91>assuming you test your code properly, ofc
14:37:25  * FergusLjoined
14:37:37  <nerium>Why not force a ’blow’ when the undefined state is introduced so it can be fixed instead of hoping that someone else (the code being passed the value) will solve it?
14:37:38  <michaelvb>we usually have a row of asserts in a function, just so we know the internals aren't going accept goofy stuff
14:37:39  * roddy_joined
14:37:47  <joepie91>nerium: because that takes work.
14:37:52  <joepie91>and creates more code
14:38:03  <joepie91>it's a risk assessment.
14:38:35  <nerium>No it doesn’t. Just return a known state which can be handled or fail
14:38:36  <joepie91>if I expect something to blow up anyway when something invalid occurs (because of a bug somewhere), then it's not worth it to me to add additional validation code
14:38:36  * eric2929292920joined
14:38:44  <xenon21>so, the good public API should validate inputs and throw the appropriate error with the useful error message to the user?
14:38:48  <joepie91>of course that assessment changes on the purpose of the code as well - eg. security-critical code will be more paranoid
14:38:50  * jishankaiquit (Ping timeout: 265 seconds)
14:39:02  <joepie91>nerium: not sure what you mean.
14:39:09  * maretquit (Ping timeout: 276 seconds)
14:39:21  <joepie91>"forcing a blow" means you need to validate something somewhere, which is work you need to do and code you have to write.
14:39:24  * ironfroggyjoined
14:39:38  <nerium>You should not add validation, the method asking for the value should.
14:39:56  <joepie91>regardless of whether that's a function call or (in a hypothetical language) some kind of annotation or property, in *any* language that doesn't fail on this input by default, it will take work
14:40:07  <joepie91>what?
14:40:48  * smccarthyquit (Remote host closed the connection)
14:41:50  <michaelvb>Think writing validation code for your function parameters is well worth the effort though
14:41:55  * solf1rejoined
14:41:55  <nerium>let value = obj.fetch(key, defaultValue) // returns ’defaultValue’ if key isn’t set. Here defaultValue is a predefined value which can be handled by code using ’value’
14:41:56  <nerium>let value = obj.fetch(key) // Fails if key isn’t as the code using value expect it to always be defined
14:41:58  <michaelvb>especially if you throw usefull messages, helps development
14:42:24  <nerium>I’m talking about using ’obj.fetch’ instead of ’obj[]'
14:42:48  <xenon21>nerium: in that case underscore or just `value = obj.key || 'default_value_here'` should work
14:42:48  <nerium>Exactly. ’obj.fetch’ would say. ’extected key in object, but nothing was found'
14:42:57  <joepie91>nerium: and now you have to write obj.fetch("foo").fetch("bar").fetch("baz") instead of obj.foo.bar.baz
14:43:01  <xenon21>assuming the value should not be boolean
14:43:13  * chxanejoined
14:43:15  <joepie91>xenon21: || is wrong
14:43:15  <nerium>No you don’t
14:43:22  * OnkelTemjoined
14:43:34  <nerium>If the chain fails, it should raise an error with a proper error message
14:43:35  <joepie91>xenon21: that's checking falsiness, not existence
14:43:37  * mven_joined
14:43:45  <joepie91>nerium: that doesn't contradict what I said.
14:43:52  * csd_quit (Ping timeout: 240 seconds)
14:43:57  <nerium>Aha, sorry
14:43:58  * duckpuppyjoined
14:44:00  <nerium>Missread your post
14:44:04  <xenon21>joepie91: ah yes, so I said assuming the value should never be boolean
14:44:19  <nerium>Yes, it does. But also saves be X hours a year having to debug code
14:44:29  <joepie91>xenon21: that's also wrong.
14:44:38  <joepie91>>> 0 || 1
14:44:38  <ecmabot>joepie91: (number) 1
14:45:00  <joepie91>tl;dr don't use ||, you want to weakly check for `null` instead.
14:45:10  <joepie91>nerium: but this is what I meant.
14:45:17  <joepie91>nerium: the tradeoff doesn't make sense in most cases.
14:45:32  * _Penguin_joined
14:45:39  * _Penguinquit (Ping timeout: 276 seconds)
14:45:42  <joepie91>because cases where - because of blowing up implicitly - it's unclear where the bug originates, are very rare
14:45:42  <xenon21>in my code since the codebase already depended on underscorejs, so I just use `_.defaults(obj, defaults)`
14:45:57  <joepie91>so the tradeoff here is "save time writing simpler code" vs "save time preventing a few uncommon bug edge cases"
14:46:00  <joepie91>and usually the former wins
14:46:06  <joepie91>you may want to choose the latter instead
14:46:13  <joepie91>but I'm just explaining here that most people choose the former
14:46:16  <xenon21>joepie91: yeah right, I encountered this problem before with my rate limit implementation, forgot the case again
14:46:26  <michaelvb>true, depends on the software you're writing aswell
14:46:29  <joepie91>xenon21: precisely the problem :)
14:46:32  * DrMabusejoined
14:46:33  <nerium>joepie91: Hehe, ’a few’. Every line using an object
14:46:36  <AvianFlu>and the deadlines, for that matter!
14:46:37  <joepie91>xenon21: too many footguns
14:46:50  <joepie91>as for _.defaults
14:46:51  * mvenquit (Ping timeout: 244 seconds)
14:46:55  <joepie91>not needed
14:47:00  <joepie91>Object.assign(defaults, data)
14:47:01  <joepie91>done
14:47:11  * mizu_no_oto_workquit (Quit: My Mac has gone to sleep. ZZZzzz…)
14:47:15  <joepie91>or if you need to default for a single value, I wrote `default-value` for precisely that purpose...
14:47:18  <xenon21>then I think relying on validation libraries should be ok?
14:47:49  <joepie91>xenon21: for what?
14:47:58  * iyogeshjoshijoined
14:48:05  <joepie91>nerium: not sure what you're talking about...
14:48:13  * TorvusBugquit (Ping timeout: 252 seconds)
14:48:18  * kftzgquit (Remote host closed the connection)
14:48:21  <joepie91>nerium: can you share some of these hard-to-debug cases? because in typical JS, they really are very rare
14:48:24  <xenon21>in my older codebase i write `a || 'default_here'` for almost everything as I keep this idiom from my ruby days
14:48:25  * csd_joined
14:48:42  <joepie91>xenon21: I'm sad that ES6 didn't adopt ?...
14:48:52  <nerium>joepie91: Missquoted your post. ”few uncommon bug edge cases” – every line using an object
14:48:52  <joepie91>that's the one thing that I -really- wanted to see being added
14:49:07  <joepie91>(which does what you intend)
14:49:10  * elfuegoquit (Quit: elfuego)
14:49:14  <joepie91>nerium: still not following
14:49:16  * timmywilquit (Quit: O.o)
14:49:38  <nerium>joepie91: Never mind :) Still now sure how you would handle undefined states in your application
14:50:01  * leehambleyjoined
14:50:08  * dunpealquit (Ping timeout: 244 seconds)
14:50:09  <joepie91>that's a very generic question and I don't really have an answer for you unless you can provide a more concrete example
14:50:10  <nerium>Or do you allways expect every value passed to a function to be undefined?
14:50:10  <joepie91>:p
14:50:36  <nerium>*that it could be undefined
14:51:20  <nerium>A state ==> a set of arguments passed to a pure function
14:52:15  <nerium>f(a) // => Given that you invoked ’f’ how to you know that ’f’ has been defined for ’a’?=
14:52:17  * elfuegojoined
14:53:43  * fyutylequit (Remote host closed the connection)
14:54:01  <joepie91>nerium: I still have no idea what you're asking, this is all far too theoretical
14:54:45  <nerium>joepie91: No worries. I’m blaming my professor in models of computation :)
14:54:49  * dmzquit (Ping timeout: 252 seconds)
14:55:07  <xenon21>I'm not sure if I understand correctly, but isn't that the thing strong typed language solved cleanly?
14:55:43  <nerium>xenon21: Mostly. You can still passa null value
14:56:10  * acrusselljoined
14:56:14  <xenon21>nvm, I use TypeScript, I parsed JSON and got undefined property
14:56:17  <xenon21>:(
14:56:20  * kftzgjoined
14:56:22  <nerium>Null are usually to generic so they shoule avoided as welll
14:56:24  <ChALkeR>joepie91: btw, regarding that checklist
14:57:10  <ChALkeR>joepie91: perhaps a good idea would be to make the exact opposite thing
14:57:23  <ChALkeR>i.e. a list of things one shouldn't be using or doing
14:57:54  <ChALkeR>Noting that following that list alone doesn't make the user safe, of course
14:58:40  <nerium>joepie91: Thanks for your input. It’s fun being forced to reflect on your ideas :)
14:58:41  <ChALkeR>I will try to make something like that in a week or so.
14:58:43  * eric2929292920quit (Quit: Leaving.)
14:58:46  * jpw68060joined
14:59:00  <nerium>’your’ as in ’mine’
14:59:16  * eric2929292920joined
14:59:19  <joepie91>nerium: ack :P
14:59:24  * mizu_no_oto_workjoined
14:59:26  * eric2929292920quit (Client Quit)
14:59:32  * TheSimonatorquit (Remote host closed the connection)
15:00:00  <nerium>ack?
15:00:10  <joepie91>nerium: acknowledged :P
15:00:20  <nerium>aha
15:00:59  * soeequit (Quit: Konversation terminated!)
15:01:23  * zwaragjoined
15:01:37  * zwaragquit (Client Quit)
15:01:37  * Ergoquit (Quit: WeeChat 1.4)
15:01:47  * soeejoined
15:02:38  * diamondsjoined
15:03:33  * lol-iconquit (Read error: Connection reset by peer)
15:04:14  * timmywiljoined
15:04:22  * mmmveggiesjoined
15:04:43  * HoierMquit (Ping timeout: 252 seconds)
15:05:06  * tubuliferousjoined
15:05:43  * dopesong_joined
15:06:11  * pyonjoined
15:06:30  * plutoniixjoined
15:07:01  * tvwquit (Remote host closed the connection)
15:07:04  * dmzjoined
15:07:35  * dopeson__joined
15:07:43  * rebootdjoined
15:08:05  * pyonchanged nick to lol-icon
15:08:19  * niemaljoined
15:09:00  * rxmthquit (Quit: leaving)
15:09:03  * Mamutjoined
15:09:13  * dopesongquit (Ping timeout: 244 seconds)
15:09:35  * rjnienaberquit (Quit: Page closed)
15:09:46  * burtonsjoined
15:10:04  * tubuliferousquit (Ping timeout: 264 seconds)
15:11:13  * dopesong_quit (Ping timeout: 265 seconds)
15:11:16  * veggie_quit (Ping timeout: 264 seconds)
15:12:07  * bumbleheadjoined
15:12:42  * iyogeshjoshiquit (Remote host closed the connection)
15:12:55  * one_zerojoined
15:13:08  * iyogeshjoshijoined
15:16:41  * bumbleheadquit (Ping timeout: 258 seconds)
15:17:05  * Mamutquit (Read error: Connection reset by peer)
15:17:48  * star_pronequit (Remote host closed the connection)
15:17:49  * Mamutjoined
15:18:33  * p4trickquit (Ping timeout: 258 seconds)
15:18:47  * iyogeshjoshiquit (Ping timeout: 260 seconds)
15:18:48  * mrognechanged nick to mrogne_afk
15:19:16  * diosneyjoined
15:19:45  * Abhishek_quit (Quit: Connection closed for inactivity)
15:20:22  * krish203joined
15:20:53  * KieronWiltshirejoined
15:20:54  * dmtojoined
15:21:18  * openstructquit
15:21:19  * FunnyLookinHatjoined
15:22:03  * subhojit777joined
15:22:13  * Steve_B_29joined
15:22:45  * DigitalSpeedjoined
15:24:13  * bgeorges_joined
15:25:11  * bgeorges_quit (Remote host closed the connection)
15:25:54  * bgeorges_joined
15:26:39  * kernalogsjoined
15:26:43  * kernalogsquit (Remote host closed the connection)
15:26:55  * TheSimonatorjoined
15:26:56  * Lightswordjoined
15:27:02  * bgeorgesquit (Ping timeout: 258 seconds)
15:27:45  * someone235quit (Quit: Leaving)
15:28:01  * beniquit (Quit: KVIrc 4.2.0 Equilibrium http://www.kvirc.net/)
15:28:29  * wraithgarjoined
15:29:28  * bendmanjoined
15:29:33  <Lightsword>hi, would anyone know why this return doesn't seem to work? https://gist.github.com/jameshilliard/385de9d6b029dacd72a8248ecbdcd5c6#file-ckdb-js-L43 console.log on line 42 prints something but not the one on line 47
15:29:41  * Lomexquit (Remote host closed the connection)
15:29:56  * bendmanquit (Client Quit)
15:30:11  * bgeorges_quit (Ping timeout: 250 seconds)
15:30:37  * roddy__joined
15:31:47  * dzmienpart ("WeeChat 1.5")
15:31:50  * Mamutquit (Read error: Connection reset by peer)
15:32:07  * the_antquit (Quit: the_ant)
15:32:09  * nishu-tryinghardquit (Quit: Leaving)
15:32:32  <commma>!async @Lightsword
15:32:32  <ecmabot>Lightsword: JavaScript doesn't have a concept of "sleep" or "wait". Most environments provide setTimeout and ES6 has Promises which are available natively in the latest Firefox, Chrome, io.js or usable via a library such as https://github.com/petkaantonov/bluebird. Also check out caolan/async. For more info: !timeout, !promises
15:32:33  * Mamutjoined
15:32:43  * ningujoined
15:33:08  <Sorella>!cps
15:33:08  <ecmabot>Sorella: Continuation-Passing style is the formal term for the "callback-based" approach to programming. CPS is a heavily used idiom in JavaScript to deal with asynchronous programming. See http://matt.might.net/articles/by-example-continuation-passing-style/
15:33:15  <Sorella>commma: that?
15:33:19  <shoky>Lightsword: that's returning from the sock.on('data', function.. callback, not from the outer `send` function. you can't return async results. you need to add a callback argument to `send`, or return a promise
15:33:38  <commma>Sorella: aha, that's the one
15:33:38  <ningu>is gyp still the thing used for C++ bindings in node?
15:33:49  * roddy_quit (Ping timeout: 250 seconds)
15:34:47  * neovestapart
15:35:08  * neovestajoined
15:36:54  <Lightsword>shoky, which way would you recommend doing it?
15:37:06  <Lightsword>basically this is supposed to be a database adapter
15:37:16  <Lightsword>that I’ll be calling from my application
15:37:56  * Lee1092joined
15:38:08  * michaelvbquit (Quit: Page closed)
15:38:52  <shoky>Lightsword: i'd recommend using promises
15:39:01  * solf1requit (Quit: Leaving)
15:39:14  * lsyoyomjoined
15:39:37  * veggie_joined
15:40:32  * neovestapart
15:40:40  * dommelquit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client)
15:40:51  * neovestajoined
15:41:10  * Lomexjoined
15:41:17  * sumobobjoined
15:41:38  <Lightsword>shoky, ok, thanks, will look into how to do that, is a promise kind of like a yield in python async frameworks?
15:42:07  * ghotiquit (Ping timeout: 260 seconds)
15:42:47  * ghotijoined
15:44:06  * diogogmtjoined
15:44:24  * dommeljoined
15:44:25  <ljharb>!promises @ Lightsword
15:44:25  <ecmabot>Lightsword: Promises are placeholders for values that'll be provided in the future. They allow composing asynchronous operations like synchronous ones. See http://robotlolita.me/2015/11/15/how-do-promises-work.html and https://blog.domenic.me/youre-missing-the-point-of-promises/. Contrast with !cps & see https://bevacqua.github.io/promisees/
15:44:26  <shoky>Lightsword: i donno but probably not, that sounds more like generator functions. promises are just a nicer way to work with callback-based code
15:44:28  <ljharb>no, not like a yield at all
15:44:50  * mizu_no_oto_workquit (Quit: My Mac has gone to sleep. ZZZzzz…)
15:45:02  * lsyoyomquit (Remote host closed the connection)
15:45:13  <AvianFlu>ahahahah I'm really glad there's a !promises
15:45:15  <AvianFlu>that's great
15:45:36  * Mamutquit (Quit: I cna ytpe 300 wrods pre mniuet!!!)
15:45:39  * lsyoyomjoined
15:46:45  * Lomexquit (Ping timeout: 276 seconds)
15:47:17  <ljharb>!point of promises
15:47:17  <ecmabot>ljharb: You're missing the point of promises: "The point of promises is to give us back functional composition and error bubbling in the async world." https://blog.domenic.me/youre-missing-the-point-of-promises/
15:47:21  <Sorella>Lightsword: Python's generators give you suspensible functions, and you can write a runtime to handle async stuff with that if you want. JS also has generators, in the same vein as Python. Promises are a separate thing, which just give you a way of representing values that haven't been computed yet. You can combine generators and promises (things like the co
15:47:22  <Sorella>library do just that), and JS also (will) support the async/await idiom from C#.
15:47:22  <ljharb>also that ^ but that's in !promises too
15:48:25  <Sorella>Is "suspensible" even a word? I mean "functions you can suspend and restart later"
15:48:35  <Lightsword>what do most database adapters use?
15:49:49  * FriedZombiejoined
15:49:53  <Sorella>Lightsword: I'd recommend avoiding "design by popularity" :) Choose the best solution for the particular problem. In this case, the best solution is promises.
15:50:14  <Sorella>(Promises also have cons, ofc. You should be aware of those too)
15:50:18  * InfoTestjoined
15:50:44  * dunpealjoined
15:51:16  <Lightsword>I’m a little confused about what the point of “representing values that haven't been computed yet” is, I’m familiar with python’s generators somewhat since I’ve worked on a project that uses tornado and twisted frameworks with redis pubsub
15:51:57  * ahmedelgabriquit (Ping timeout: 276 seconds)
15:52:07  * Lomexjoined
15:52:08  * ironfroggy_joined
15:52:25  * grilljoined
15:52:37  * FuzzySocketsjoined
15:52:43  * FuzzySocketsquit (Max SendQ exceeded)
15:53:02  * mizu_no_oto_workjoined
15:53:40  * ChALkeRquit (Ping timeout: 252 seconds)
15:53:42  * stennoworkquit (Quit: Time to go home Kreygasm)
15:54:06  * terminalreclusejoined
15:54:51  * smccarthyjoined
15:55:14  * dunpealquit (Ping timeout: 244 seconds)
15:55:31  * ironfroggy_quit (Read error: No route to host)
15:55:42  * ironfroggy_joined
15:56:05  * calamityquit (Ping timeout: 244 seconds)
15:56:07  * tmquit (Ping timeout: 258 seconds)
15:56:10  * fear0fmusicjoined
15:56:16  * ironfroggyquit (Ping timeout: 264 seconds)
15:56:44  * ironfroggy_quit (Remote host closed the connection)
15:57:14  * ironfroggyjoined
15:57:22  * iyogeshjoshijoined
15:57:44  * kevireilly_joined
15:58:44  * ironfroggy_joined
15:59:07  * ironfroggyquit (Read error: Connection reset by peer)
15:59:20  * jasnelljoined
15:59:22  * smccarthyquit (Ping timeout: 244 seconds)
15:59:42  * cocoadaemonquit (Quit: Quitte)
16:00:13  * DeltaHeavyquit (Ping timeout: 244 seconds)
16:00:36  * DrMabusequit (Remote host closed the connection)
16:00:40  <shoky>Lightsword: a better way to put it that was mentioned is "placeholders for values that'll be provided in the future". read the linked articles, take a look here too https://gist.github.com/joepie91/791640557e3e5fd80861
16:02:21  * iyogeshjoshiquit (Ping timeout: 276 seconds)
16:02:33  * subhojit777quit (Ping timeout: 240 seconds)
16:03:16  * Booster2oooquit (Remote host closed the connection)
16:03:59  * mcmillhjquit (Ping timeout: 244 seconds)
16:04:08  * TheSimonatorquit (Remote host closed the connection)
16:04:32  * kedarequit (Quit: Leaving)
16:04:39  * ironfroggy_quit (Remote host closed the connection)
16:05:11  * ironfroggyjoined
16:05:33  * senayarquit
16:06:26  * kawa2014quit (Quit: Leaving)
16:06:52  * Abhishek_joined
16:07:02  * buttminer_joined
16:07:10  * dommelquit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client)
16:07:21  * roddy__quit (Remote host closed the connection)
16:07:56  * roddy_joined
16:08:02  * csd_quit (Quit: Lost terminal)
16:08:10  * buttminer_quit (Client Quit)
16:08:20  * nhahnjoined
16:08:56  * neoncontrailsjoined
16:09:27  * ironfroggyquit (Remote host closed the connection)
16:09:36  * ironfroggyjoined
16:09:54  * unitechjoined
16:09:59  * dommeljoined
16:10:26  * leehambleyquit (Quit: My Mac has gone to sleep. ZZZzzz…)
16:10:42  * TotempaaltJchanged nick to Totem|Away
16:10:43  * subhojit777joined
16:11:03  * czeraszjoined
16:11:17  * TheSimonatorjoined
16:11:25  <Lightsword>also….does anyone know if node has an equivalent to twisted’s IntNStringReceiver protocol wrapper?
16:11:32  <Lightsword>for use with unix sockets
16:12:49  * bumbleheadjoined
16:13:05  <Lightsword>basically something for cleanly handling length prefixed reads and writes
16:14:25  * hextileXjoined
16:14:25  * TheSimonatorquit (Remote host closed the connection)
16:14:33  <Lightsword>right now I’m kinda doing it manually with writeUInt32LE and readUInt32LE https://gist.github.com/jameshilliard/385de9d6b029dacd72a8248ecbdcd5c6
16:14:52  * FriedZombiequit (Ping timeout: 244 seconds)
16:15:30  * ZeBaguettepart
16:15:54  <inflames>ugh, dependency injection makes me want to blow my head off ;/
16:16:13  * jasnellquit (Remote host closed the connection)
16:16:46  * TheSimonatorjoined
16:17:04  * bumbleheadquit (Ping timeout: 240 seconds)
16:17:26  * kevireilly_quit (Quit: kevireilly_)
16:18:42  * FriedZombiejoined
16:18:47  * NeverDiejoined
16:20:19  * vuotojoined
16:21:04  * tzerojoined
16:21:08  * sunoanojoined
16:21:08  * sunoanoquit (Changing host)
16:21:08  * sunoanojoined
16:21:59  * elfuegoquit (Quit: elfuego)
16:22:33  * sunoano1quit (Ping timeout: 240 seconds)
16:22:38  * burtonsquit (Quit: My Mac has gone to sleep. ZZZzzz…)
16:23:03  * cotkoquit (Ping timeout: 250 seconds)
16:23:24  * smccarthyjoined
16:23:55  * niemalquit (Ping timeout: 252 seconds)
16:24:31  * unitechquit (Ping timeout: 250 seconds)
16:24:47  * ShrewdSpirit_part
16:24:49  * sillysluxjoined
16:25:12  * AKPWDquit (Quit: じゃね。)
16:25:19  * elfuegojoined
16:25:31  * niemaljoined
16:26:08  * ericwooleyjoined
16:26:47  * dommelquit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client)
16:26:51  * elfuegoquit (Client Quit)
16:27:08  * rebootdquit
16:27:50  * elfuegojoined
16:27:56  * star_pronejoined
16:28:00  * dommeljoined
16:28:10  * sbellinajoined
16:28:38  * czeraszquit (Ping timeout: 244 seconds)
16:28:42  * burtonsjoined
16:29:40  * ericwool_joined
16:29:48  * burtonsquit (Max SendQ exceeded)
16:30:32  * dommelquit (Client Quit)
16:31:36  * nhahn_joined
16:31:47  * dopeson__quit (Remote host closed the connection)
16:31:51  * nhahn_quit (Read error: Connection reset by peer)
16:31:52  * star_pronequit (Ping timeout: 240 seconds)
16:31:57  * ividyonjoined
16:32:09  * vuotoquit (Remote host closed the connection)
16:32:25  * vuotojoined
16:32:28  * dopesongjoined
16:32:30  * neovestaquit (Quit: neovesta)
16:32:52  * ericwooleyquit (Ping timeout: 260 seconds)
16:32:53  * BeerLoverjoined
16:33:10  * iyogeshjoshijoined
16:33:39  * nhahn_joined
16:34:12  * nhahnquit (Ping timeout: 276 seconds)
16:34:16  * vuotoquit (Remote host closed the connection)
16:34:18  * ahmedelgabrijoined
16:34:32  * vuotojoined
16:34:47  * Guest52176quit (Read error: Connection reset by peer)
16:34:48  * HoierMjoined
16:35:53  * optikalmousequit (Quit: optikalmouse)
16:36:02  * leehambleyjoined
16:37:10  * mablaejoined
16:38:28  * ironfroggyquit (Remote host closed the connection)
16:38:40  * ahmedelgabriquit (Ping timeout: 258 seconds)
16:40:01  * wtrockiquit (Quit: Bye Bye ^^)
16:40:14  * BeerLoverquit (Quit: My Mac has gone to sleep. ZZZzzz…)
16:40:35  * acrussellquit (Ping timeout: 258 seconds)
16:40:40  * wtrockijoined
16:40:40  * oxhakquit (Ping timeout: 244 seconds)
16:40:41  * Steve_B_29quit (Quit: Leaving)
16:40:47  * opiatesjoined
16:40:51  * wtrockiquit (Remote host closed the connection)
16:41:36  <opiates>So I'm trying to use the Facebook oEmbed API Endpoints in my Node.js/Express server but somehow it's returning an entire page. https://developers.facebook.com/docs/plugins/oembed-endpoints
16:42:25  * alilezajoined
16:43:34  * thinkt4n_quit (Quit: My Mac has gone to sleep. ZZZzzz…)
16:43:46  * quattro_quit (Quit: quattro_)
16:44:40  * Miachanged nick to Axy
16:45:23  * robertmaxreesjoined
16:45:41  * BeerLoverjoined
16:45:54  * cagedwisdomjoined
16:46:34  * mcmillhjjoined
16:46:36  * oxhakjoined
16:46:45  * tfennellyquit (Read error: Connection reset by peer)
16:46:47  * thinkt4nkjoined
16:46:49  * opiatesquit (Quit: brb tornado)
16:46:51  * BeerLoverquit (Client Quit)
16:47:08  * tvwjoined
16:47:20  * BeerLoverjoined
16:47:37  * dommeljoined
16:48:21  * Cohedrinjoined
16:48:47  * thinkt4n_joined
16:48:56  * chll_quit (Quit: quit)
16:49:14  * ironfroggyjoined
16:49:37  * ironfroggyquit (Remote host closed the connection)
16:49:50  * thinkt4n_quit (Client Quit)
16:50:02  * tfennellyjoined
16:50:06  * ironfroggyjoined
16:50:27  * flyBoijoined
16:50:27  * driverajoined
16:50:43  * driverachanged nick to localdose
16:50:53  * tubuliferousjoined
16:50:58  * vuotoquit (Remote host closed the connection)
16:51:06  * samsshchanged nick to samssh_away
16:51:17  * vuotojoined
16:51:23  * thinkt4nkquit (Ping timeout: 250 seconds)
16:51:38  * vuotoquit (Remote host closed the connection)
16:51:57  * vuotojoined
16:52:29  * vuotoquit (Remote host closed the connection)
16:52:44  * vuotojoined
16:52:57  * nnykquit (Ping timeout: 250 seconds)
16:53:50  * vuotoquit (Remote host closed the connection)
16:54:09  * tesrtyquit (Quit: -)
16:55:24  * BeerLoverquit (Ping timeout: 260 seconds)
16:55:32  * tubuliferousquit (Ping timeout: 258 seconds)
16:55:40  * poiuiopjoined
16:55:50  * Lomexquit (Remote host closed the connection)
16:55:54  * mylordquit (Quit: mylord)
16:56:15  * oxhakquit (Quit: leaving)
16:56:21  <poiuiop>hello! is there a way to remove the trailing newline when running node with the -p flag? for example, echo has a -n flag to suppress it
16:56:26  * oxhakjoined
16:57:09  * diamondsquit (Ping timeout: 260 seconds)
16:57:24  * Milos|Workjoined
16:58:23  * lucasbjoined
16:58:27  * osum4estquit (Quit: Lost terminal)
16:58:44  * robertmaxreesquit
16:58:55  * saghul_quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
16:59:04  * Mamutjoined
16:59:05  <localdose>Socket validation question here. Can someone link me to an article/tutorial on how socket security works? I'm concerned with how to validate a user on a specific socket. "I'm not sure which user is which, and I feel that I can't trust the user to tell me who they are."
16:59:10  <localdose>Socket.io *
16:59:19  * ibashjoined
16:59:22  * TorvusBugjoined
17:00:30  * vavovijoined
17:00:55  * wtrockijoined
17:01:08  * zipzapzoomjoined
17:01:24  * DrMabusejoined
17:01:30  * Swizecquit (Ping timeout: 276 seconds)
17:02:56  * quattro_joined
17:03:00  * ahmedelgabrijoined
17:03:05  * DigitalSpeedquit (Ping timeout: 250 seconds)
17:05:21  * DeltaHeavyjoined
17:05:57  * DrMabusequit (Ping timeout: 250 seconds)
17:06:01  * Lomexjoined
17:06:21  * diamondsjoined
17:06:55  * texinwien_quit (Read error: Connection reset by peer)
17:07:29  * jdelersjoined
17:08:06  * texinwien_joined
17:08:20  * Swizecjoined
17:09:10  * ShekharReddyjoined
17:10:01  * eric2929292920joined
17:10:51  * Literphorjoined
17:10:52  * Lomexquit (Ping timeout: 240 seconds)
17:10:55  * polydo_squit (Ping timeout: 258 seconds)
17:11:23  * ibashquit (Remote host closed the connection)
17:12:17  * Narigoquit (Quit: This computer has gone to sleep)
17:12:20  * optikalmousejoined
17:12:56  * ibashjoined
17:13:12  * sputnik13joined
17:13:15  * oxhakquit (Remote host closed the connection)
17:13:36  * bumbleheadjoined
17:13:46  * zipzapzoomquit
17:14:16  * dopesongquit (Remote host closed the connection)
17:14:36  * tfennellyquit (Read error: Connection reset by peer)
17:14:54  * dopesongjoined
17:16:01  * oxhakjoined
17:17:15  * sillysluxquit (Read error: Connection reset by peer)
17:18:09  * bumbleheadquit (Ping timeout: 258 seconds)
17:18:59  * tfennellyjoined
17:19:32  * dopesongquit (Ping timeout: 260 seconds)
17:19:37  * subhojit_joined
17:19:41  * alilezaquit (Ping timeout: 258 seconds)
17:19:47  * subhojit777quit (Ping timeout: 265 seconds)
17:20:36  * LeBlaaancjoined
17:20:44  * alilezajoined
17:21:12  * Limixjoined
17:21:47  * LeBlaaancquit (Client Quit)
17:21:59  * vuotojoined
17:22:57  * LeBlaaancjoined
17:23:33  * samssh_awaychanged nick to samssh
17:23:39  * vuotoquit (Client Quit)
17:23:53  * hextileXquit (Ping timeout: 250 seconds)
17:24:44  * vuotojoined
17:26:23  * SwiftMattjoined
17:26:27  * chargenquit (Read error: Connection reset by peer)
17:26:35  * tahjjoined
17:26:46  <nerium>localdose: Let the user pass a signed user_id (or whatvery you use to uniquely indentify your users)
17:27:05  * VarunAgwjoined
17:27:11  * bgeorgesjoined
17:27:12  * tesrtyjoined
17:28:04  <VarunAgw>I am trying to convert a font file to base64. I am trying new Buffer(file_content).toString('base64'). But it is giving wrong output
17:28:06  * TheSimonatorquit (Remote host closed the connection)
17:28:22  * vuotoquit (Remote host closed the connection)
17:28:45  <VarunAgw>There are so many slashes (/) in output compared to the output I get through linux base64 program
17:29:23  <VarunAgw>Unix bash command sample output: AAgUwIgSIJjzQREAqBpESBjUIBNgIkA4ZsE70QC4M8AAQgBYIyB4QoDIIJG8
17:29:38  <VarunAgw>nodejs sample output: AA/UwI/SIJ/TQREAr9/UT9/UIBNgIkA/1sE/0QC/08AAQgBf0yB/0oDP0JG/13
17:29:59  <nerium>localdose: I.e
17:30:00  <nerium>Server side (psudo code): cookies[sid] = [user.id, md5(user.id, key)].join(”:”)
17:30:00  <nerium>Client side: (——||——): io.send(”it’s me”, cookies[sid])
17:30:30  <nerium>Then just verify ’sid’
17:30:32  * sergeyjoined
17:30:48  * _sjsjoined
17:30:52  * dommelquit (Quit: http://www.kiwiirc.com/ - A hand crafted IRC client)
17:31:19  * Mamutquit (Quit: I cna ytpe 300 wrods pre mniuet!!!)
17:31:30  <nerium>valthonis: There should be a ”url safe” base64 encoder
17:31:42  <nerium>Which handles / and other stuff
17:32:07  <VarunAgw>ok. I will try to google it
17:32:11  * altcatalinquit
17:33:21  * bgeorgesquit (Ping timeout: 276 seconds)
17:33:23  * evil_dan2wikchanged nick to dan2wik
17:33:57  * JoeOlliffjoined
17:34:24  * Peppi^joined
17:35:00  <danneu>localdose: the websocket connects by sending a regular http request (can touch it with regular express middleware) and then upgrades into a websocket connection, so that's one opportunity to authenticate
17:35:37  * sankhaquit (Remote host closed the connection)
17:35:47  * Peppiquit (Ping timeout: 258 seconds)
17:35:47  <danneu>localdose: another way is to bake it into your websocket layer. for example, after connecting, the client might send an `auth` event with some token
17:36:45  * ben__joined
17:37:24  * mizu_no_oto_workquit (Quit: My Mac has gone to sleep. ZZZzzz…)
17:39:18  <nerium>danneu: I think the easiest way would be to just verify the cookies pass by socket io
17:39:39  * sankhajoined
17:40:04  * huypn12joined
17:40:15  <danneu>just depends what you want. for example the first just works with the middleware you're prob already using
17:40:22  * phil23joined
17:40:48  * eric2929292920quit (Quit: Leaving.)
17:40:51  <nerium>danneu: How would the first one autenthicate the user you mean?
17:41:16  * ibashquit
17:42:24  * eric2929292920joined
17:43:09  * cotalinuxjoined
17:43:11  <VarunAgw>nerium: Still same problem
17:43:43  <danneu>you can short-circuit the request before the upgrade. if they are authenticated, you can reach into request on connect. socket.req.user or something
17:43:45  <VarunAgw>URLSafeBase64.encode(content) returns binary code
17:44:06  * alilezaquit (Read error: Connection reset by peer)
17:44:14  <VarunAgw>URLSafeBase64.encode(new Buffer(content)) returns ascii but still it is different
17:44:24  * ben__quit (Ping timeout: 276 seconds)
17:44:34  * nitricjoined
17:45:03  * apparitionjoined
17:45:26  <nerium>danneu: Wasn’t the problem that he wanted to authenticated to user?
17:45:27  * alilezajoined
17:45:52  * poiuiopquit (Quit: Page closed)
17:45:54  <JoeOlliff>I'm trying to figure out the correct approach to creating a sort of master server that points to many sub-apps without having to manually add each new sub-app's routing to the master server. Anyone interested/able to point me in the right direction?
17:46:01  <danneu>nerium: yeah
17:46:06  <nerium>VarunAgw: Verify that they (bash/node) is following the same spec
17:46:32  * chargenjoined
17:46:32  * alilezaquit (Remote host closed the connection)
17:46:55  <nerium>danneu: Then I guess your suggestion would be the next step as you wrote ”if they are authenticated” :)
17:47:14  * wtrockiquit (Quit: Bye Bye ^^)
17:47:25  <VarunAgw>nerium: I am trying to use it in chrome as "data:base64...". Only bash encoded content works
17:47:35  <danneu>no, i'm saying they can reuse their authentication middleware that they already use for, say, express
17:47:40  <nerium>VarunAgw: run ”man” before you command and scroll to the bottom. That’s usually where it’s defined in *nix
17:47:49  * sankhaquit (Remote host closed the connection)
17:48:04  * star_pronejoined
17:48:11  <nerium>danneu: Aha, sorry. Then we’re talking about the same thing
17:48:28  <nerium>I assumed he didnt have any authentication
17:48:34  <nerium>at all
17:48:36  <VarunAgw>My bash version is 4.3. NodeJS version is 5
17:48:39  <VarunAgw>.7.0
17:49:04  <localdose>I do have middleware for authentication. Using the stormpath service.
17:49:06  * Limes_joined
17:49:14  <nerium>VarunAgw: You should look at the base64 specific implementation for node and bash
17:49:22  * silencedjoined
17:49:58  <nerium>localdose: Same subdomain/domain site?
17:50:17  * abernixquit (Quit: Bye)
17:50:20  <JoeOlliff>I'm trying to figure out the correct approach to creating a sort of master server that points to many sub-apps without having to manually add each new sub-app's routing to the master server. Anyone interested/able to point me in the right direction?
17:50:53  * Dimikjoined
17:51:04  * dunpealjoined
17:51:13  <danneu>JoeOlliff: is it dynamic or something?
17:51:18  * phil23quit (Quit: WeeChat 1.4)
17:51:39  * mizu_no_oto_workjoined
17:51:39  * phil23joined
17:52:03  * huypn12quit (Quit: Konversation terminated!)
17:52:11  <JoeOlliff>danneu: I would like it be. I haven't built it yet i'm trying to design it first and doing research. I've tried a few packages but none of them seem to do quite what i'm trying to do
17:52:13  <nerium>danneu: Thanks for the parsimmon link btw. I manage to reduce my previous solution with 80% and remove all edge cases
17:52:22  * [_huypn12_]joined
17:52:28  * TorvusBugquit (Ping timeout: 252 seconds)
17:52:58  <danneu>nerium: yeah, parser combinators were the best thing to happen to my attempts at parsing
17:53:48  * daivykjoined
17:54:10  <localdose>nerium: yes.
17:54:50  * MrP[Home]joined
17:54:52  * Palssonquit (Read error: Connection reset by peer)
17:54:53  <nerium>localdose: Then you could just access the cookies from the server side in a middleware as danneu suggested
17:55:00  * phil23quit (Client Quit)
17:55:43  <danneu>the other thing i've used in js for parsing is http://pegjs.org/online
17:55:52  * dunpealquit (Ping timeout: 240 seconds)
17:56:22  <danneu>but peg is imo a lot harder to reason about
17:56:23  <JoeOlliff>danneu: my ultimate goal is to make a "master server" that all it does is point to various sub apps based off of what it finds in the routes folder. Being able to add new sub-apps as needed without having to hard-code their names into the "Master Server" just add a new route file to the routes folder
17:56:26  * robertmaxreesjoined
17:56:30  * GustavoLapastajoined
17:57:24  * cedvanjoined
17:57:31  * AvianFluquit (Ping timeout: 250 seconds)
17:57:41  <danneu>JoeOlliff: couldn't you do this with basic `fs` module stuff? like read all the folders in `/routes` and `app.use(require(path))` of each one assuming each has an index.js file?
17:57:47  * deanjoined
17:57:56  * plutoniixquit (Read error: Connection reset by peer)
17:58:01  * phil23joined
17:58:03  <nerium>danneu: I’ll have a look
17:58:14  * alilezajoined
17:58:19  * AvianFlujoined
17:58:33  * jvolkmanquit (Ping timeout: 250 seconds)
17:59:15  <nerium>JoeOlliff: Rails has something called mountable engines which does exactly this. See if express has somethign similuar
17:59:28  * ben__joined
17:59:55  <JoeOlliff>danneu: Yes but then wouldn't the prefix have to be listed in every established route in the index.js of each route? Wouldn't it be preferable to do that at the app level when reading the files? (or folders)
18:00:11  * Tennisquit (Read error: Connection reset by peer)
18:00:17  <JoeOlliff>nerium: hmm mountable engines? noted, will google that shortly. Thanks!
18:00:22  * Ir0nYjoined
18:00:54  * vassagusquit (Read error: Connection reset by peer)
18:00:55  * hyeonuquit (Quit: Leaving)
18:01:04  * ibashjoined
18:01:06  * ibashquit (Client Quit)
18:01:20  <nerium>JoeOlliff: If you did this:
18:01:21  <nerium>mount Abcd::Engine => ”/abcd”
18:01:21  <nerium>rails would point /abcd to the app Abcd
18:01:28  * tubuliferousjoined
18:01:29  * vassagusjoined
18:01:34  <danneu>JoeOlliff: not sure what you mean. but modules can communicate with the parent (import site) by just exporting more data. `module.exports = { router, prefix }`
18:01:48  <nerium>mount <app>::Engine => ”<route>”
18:02:09  * DrMabusejoined
18:02:19  * veggie_quit (Ping timeout: 265 seconds)
18:02:30  <nerium>JoeOlliff: Would something that solve your problem?
18:02:46  * krstfjoined
18:03:15  * alilezaquit (Ping timeout: 276 seconds)
18:03:16  <danneu>JoeOlliff: for example. for (router in routers) app.use(router.prefix, router.routes()).
18:03:16  * jvolkmanjoined
18:03:33  * InfoTestquit (Quit: InfoTest)
18:03:34  * calamityjoined
18:03:53  <JoeOlliff>nerium: Though I appreciate the effort, danneu: just solved my problem by making me feel quite stupid... I've been fighting with this since yesterday morning, why didn't I think of just appending the desired prefix to the exports.....
18:03:54  * IronYquit (Ping timeout: 276 seconds)
18:03:54  * Ir0nYchanged nick to IronY
18:04:03  * abijeetjoined
18:04:05  * MrP[Home]quit (Read error: Connection reset by peer)
18:04:15  <danneu>JoeOlliff: another idea is to just derive prefix from the folder name
18:04:23  * mcmillhjquit (Ping timeout: 244 seconds)
18:04:30  * vassagus_joined
18:04:44  * oxhakquit (Remote host closed the connection)
18:04:53  * polydo_sjoined
18:04:58  <JoeOlliff>Thanks again, the both of you for helping me out. Still going to look into what you mentioned nerium:
18:05:34  <danneu>for (folder in fs.readdirs('routes')) app.use(folder, require(__dirname + '/' + folder) might be cool to use folder name as prefix
18:05:36  * jr3joined
18:05:45  * Damn3dquit (Ping timeout: 250 seconds)
18:05:50  <JoeOlliff>danneu: does that work better than deriving from the file name? I tried that and when I would require the file, setting it to a variable and then pass that variable to app.use() it complained about it not being a function...
18:06:17  * tubuliferousquit (Ping timeout: 244 seconds)
18:06:28  * [_huypn12_]quit (Quit: Konversation terminated!)
18:06:32  * subhojit_quit (Quit: Leaving)
18:06:37  * DrMabusequit (Ping timeout: 250 seconds)
18:06:47  * [huypn12]joined
18:07:24  <danneu>nice thing about requiring a folder is that it implicitly loads `folder/index.js`
18:07:43  * Tragedyquit (Read error: Connection reset by peer)
18:07:49  * tesrtyquit (Quit: -)
18:07:50  * calamityquit (Ping timeout: 244 seconds)
18:07:55  <danneu>and if folder name is the prefix, then the app code itself never needs to know its own prefix which is prob ideal
18:08:02  * vassagusquit (Ping timeout: 258 seconds)
18:08:03  * dopesongjoined
18:08:21  * optikalmousequit (Quit: optikalmouse)
18:08:24  * brainpro1joined
18:08:46  <JoeOlliff>hmmm ok... sounds like that's the way to go then. Thanks for the help! taking note.
18:08:56  * vassagusjoined
18:10:04  * brainproxyquit (Ping timeout: 264 seconds)
18:10:06  * ironfroggyquit (Remote host closed the connection)
18:10:35  * ironfroggyjoined
18:11:10  * alilezajoined
18:11:22  * ningupart
18:11:23  * Damn3djoined
18:11:42  * kingarmadilloquit (Ping timeout: 276 seconds)
18:11:43  * vassagus_quit (Ping timeout: 252 seconds)
18:11:54  * MrP[Home]joined
18:12:13  * Tragedyjoined
18:12:29  * optikalmousejoined
18:12:33  <danneu>if you have an issue with app.use() again, you'll need to post some code
18:12:35  * dopesongquit (Ping timeout: 258 seconds)
18:13:18  * dopesongjoined
18:13:24  <JoeOlliff>danneu: definitely
18:14:00  * iyogeshjoshiquit (Remote host closed the connection)
18:14:22  * bumbleheadjoined
18:15:19  * ironfroggyquit (Ping timeout: 260 seconds)
18:15:41  * kingarmadillojoined
18:17:01  * p4trixjoined
18:17:01  * TheSimonatorjoined
18:17:59  * noobsjoined
18:18:22  * smogjoined
18:18:34  * bumbleheadquit (Ping timeout: 240 seconds)
18:18:49  * GustavoLapastaquit (Ping timeout: 260 seconds)
18:19:11  * itaipujoined
18:19:48  * MrP[Home]quit (Read error: Connection reset by peer)
18:19:59  * alilezaquit (Remote host closed the connection)
18:20:49  <JoeOlliff>danneu: I should be able to pass parameters in that call correct? i.e. app.use(folder, require(__dirname + '/' + folder)(app, db, express));
18:21:20  * bongjoviquit (Quit: My Mac has gone to sleep. ZZZzzz…)
18:23:07  * Xiti`joined
18:23:30  * uniacid_pcquit (Read error: Connection reset by peer)
18:23:32  * uni`pcjoined
18:24:01  * mich-cookjoined
18:24:09  * GustavoLapastajoined
18:24:28  * mcmillhjjoined
18:25:02  * Xiti`quit (Client Quit)
18:25:03  * plutoniixjoined
18:25:49  * flappynerdjoined
18:26:04  * Xitiquit (Ping timeout: 244 seconds)
18:26:20  * eric29292929201joined
18:26:32  * daivykquit (Quit: Quit)
18:28:21  * eric2929292920quit (Ping timeout: 258 seconds)
18:28:30  * MrP[Home]joined
18:30:19  * laurensclaessenquit
18:32:44  <danneu>JoeOlliff: yes, if your subapp's index.js defines `module.exports = function (app, db, express) { ... return subapp )`
18:33:59  * KLVTZjoined
18:34:06  * lpinquit (Quit: Textual IRC Client: www.textualapp.com)
18:34:13  * Narigojoined
18:34:34  * scippioquit (Ping timeout: 240 seconds)
18:34:41  * [huypn12]quit (Quit: Konversation terminated!)
18:34:53  * [huypn12]joined
18:35:00  * LeBlaaancquit (Quit: My Mac has gone to sleep. ZZZzzz…)
18:35:23  * manu__quit (Ping timeout: 250 seconds)
18:35:41  * [huypn12]quit (Client Quit)
18:35:58  * [huypn12]joined
18:36:07  * [huypn12]quit (Client Quit)
18:36:28  * [huypn12]joined
18:37:12  * tesrtyjoined
18:38:19  * phil23quit (Ping timeout: 244 seconds)
18:38:25  * Totem|Awaychanged nick to TotempaaltJ
18:39:26  * ironfroggyjoined
18:39:32  * unitechjoined
18:39:40  * unitechquit (Max SendQ exceeded)
18:39:54  * lennymquit (Quit: Connection closed for inactivity)
18:40:18  * ahhhndijoined
18:40:30  <JoeOlliff>danneu: So I have it running with no explicit errors however the routes are not being loaded.
18:40:43  <JoeOlliff>danneu: I have console.log(fs.readdir(__dirname + '/routers')); for (folder in fs.readdir(__dirname + '/routers')) { app.use(folder, require(__dirname + '/routers/' + folder)(app, db, express)); }
18:40:43  * localdosepart ("WeeChat 0.4.2")
18:40:43  * star_pronequit (Remote host closed the connection)
18:41:24  <JoeOlliff>I'm noting that the console.log is returning undefined even though I'm giving it an absolute path...
18:42:17  <JoeOlliff>and the file within the folder called 'test' is called index.js .... it's finding the folder (else I would get an error) but it's not loading the contents...
18:42:20  * acrusselljoined
18:42:59  * sankhajoined
18:43:04  * mich-cookquit (Quit: Leaving.)
18:43:48  * airdisajoined
18:43:48  * mizu_no_oto_workquit (Quit: My Mac has gone to sleep. ZZZzzz…)
18:43:49  * elseverojoined
18:44:17  * ToApolytoXaosquit (Quit: I'm off folks. Drop by at http://alifealgorithm.blogspot.com)
18:44:51  * texinwien_quit (Ping timeout: 276 seconds)
18:46:14  * p4trixquit (Read error: Connection reset by peer)
18:46:18  * ArchNoobquit (Ping timeout: 265 seconds)
18:46:22  * sbellinaquit (Read error: Connection reset by peer)
18:48:15  * TotempaaltJchanged nick to Totem|Away
18:48:17  * Drojoined
18:48:19  * smokeoquit (Remote host closed the connection)
18:48:33  * mizu_no_oto_workjoined
18:50:01  * sillysluxjoined
18:50:04  * leehambleyquit (Quit: My Mac has gone to sleep. ZZZzzz…)
18:52:22  * noobsquit (Quit: Page closed)
18:53:02  * stelarcfquit (Quit: stelarcf)
18:53:16  * stelarcfjoined
18:53:44  * clintarquit (Quit: Leaving)
18:53:53  * clintarjoined
18:54:21  * manu__joined
18:56:32  <xenon21>JoeOlliff: Try redadirSync instead of readdir?
18:56:38  <xenon21>* readdirSync
18:57:47  <polydo_s>I am having a hard time using the new way to import module introduced in es6
18:58:22  <ljharb>polydo_s: you have to use babel
18:58:25  <ljharb>!es6 modules @ polydo_s
18:58:25  <ecmabot>polydo_s: While ES6 provides syntax for import/export, it currently *does nothing*, anywhere, because the loader spec is not finished ( https://github.com/whatwg/loader ). ES6 Modules are not yet a thing; they do not yet exist. !babel simply transpiles import/export to `require`, which is not guaranteed to work once the loader is finished. Use CommonJS modules for now.
18:58:29  * veggie_joined
18:59:10  <polydo_s>Yes I should have been more precise I am using babelify+browserify with gulp.
18:59:11  <myndzi>JoeOlliff: you need to either use a callback or readdirSync, yeah. also 'for in' is not really what you want to use; if new enough node you could use 'for of', or use array.forEach on the result
18:59:19  * whathappensquit (Remote host closed the connection)
18:59:26  * ironfroggy_joined
18:59:37  <polydo_s>I created an "abstract" class named Object. And I am trying to do a default export. But then, I am not able to import it somewhere else...K
18:59:41  <polydo_s>-K
19:00:08  <myndzi>paste code and error
19:00:19  * NomadJim_changed nick to NomadJim
19:00:51  * jasnelljoined
19:01:53  <polydo_s>https://gist.github.com/soueuls/0668806a8808a7218deacf33c7ce5143
19:02:47  * star_pronejoined
19:02:48  * ironfroggyquit (Ping timeout: 258 seconds)
19:02:49  * scippiojoined
19:02:52  * DrMabusejoined
19:03:49  * ironfroggy_quit (Ping timeout: 244 seconds)
19:04:33  * steverandyquit (Quit: Connection closed for inactivity)
19:04:34  * veggie_quit (Ping timeout: 240 seconds)
19:04:41  * krstfquit (Quit: WeeChat 1.5)
19:05:06  <JoeOlliff>myndzi: thanks, making progress now. probably going to rearrange to callback to try and keep things as async as possible
19:05:11  * flappynerdquit (Quit: = "bye")
19:05:18  <myndzi>JoeOlliff: promises might be your friend here too
19:05:29  * ahmedelgabriquit (Ping timeout: 258 seconds)
19:05:33  * smokeojoined
19:05:43  <myndzi>polydo_s: Object is already a thing in javascript, you don't want to use that name
19:05:45  <myndzi>that may be your problem
19:05:45  <cjohnson>polydo_s: http://www.2ality.com/2014/09/es6-modules-final.html
19:06:22  * sillysluxquit (Ping timeout: 244 seconds)
19:06:57  <myndzi>also, i think default exports need to match the module name? not 100% sure
19:06:58  * liuwenhaojoined
19:07:03  <myndzi>(you have a case difference: Object vs object)
19:07:12  <myndzi>the above link looks useful
19:07:36  * DrMabusequit (Ping timeout: 276 seconds)
19:07:56  <xenon21>it doesn't need to match
19:08:17  * optikalmousequit (Quit: optikalmouse)
19:08:20  <polydo_s>myndzi, Yeah, I feel stupid right now. It seems that the Object naming clash was the bug.
19:09:08  * luldajoined
19:09:27  * NomadJim_joined
19:10:05  <myndzi>how is the import determined for a default?
19:10:28  * jdelersquit (Quit: Connection closed for inactivity)
19:10:59  <polydo_s>myndzi, If you specify import {foo, bar} from 'foo' then you import foo and bar
19:11:06  <myndzi>if you have export default { foo: 'bar' }; and you use `import foo from 'whatever'`, do you get { foo: 'bar' } or 'bar'? how do you distinguish?
19:11:20  <polydo_s>myndzi, If you do import foo from 'bar' then foo is going to point on the default
19:11:36  <myndzi>and if there's no default you must use the destructuring syntax?
19:11:38  * optikalmousejoined
19:11:49  * optikalmousequit (Client Quit)
19:11:56  <polydo_s>myndzi, I think yes, I am not a expert with export/import yet, but I do think yes
19:12:01  <xenon21>myndzi: default exporting right now AFAIK will be transpired to `module.exports.default = Somename`
19:12:12  <lulda>is there anyway to have the client download a file from another domain that doesnt have Allow-Control-Allow-Origin without requiring the server to download it first?
19:12:14  <KLVTZ>export default Event / import Event from './event'
19:12:28  <myndzi>yeah, i was just trying to determine how it knows what the default import is since it doesn't have a name
19:12:35  <myndzi>i guess it knows by the syntax (not using destructuring syntax)?
19:12:48  <xenon21>So default importing is just `var canBeDifferentName = require('somename_module').default`
19:13:03  <myndzi>lulda: i don't believe CORS applies to GET requests?
19:13:19  <lulda>it does, but not when the server that hosts the file doesnt have that flag set to true
19:13:23  <myndzi>or maybe it was POST requests that it didn't apply to, i am not sure. but you can certainly click a link that is offsite and download a file
19:13:27  * NomadJimquit (Ping timeout: 276 seconds)
19:13:31  * moseKjoined
19:13:49  <lulda>well, i dont need the user to download it. i need to store it into an arraybuffer in js
19:13:56  <lulda>and then parse it
19:14:01  * oxhakjoined
19:14:38  * BulleTTimequit (Ping timeout: 244 seconds)
19:14:43  <myndzi>there are a couple workarounds that depend on different things, i assume if you can't set the header you may not have access to the server to do anything to change it on that end?
19:15:02  <lulda>no, i want to download a replay file from valve servers
19:15:05  * NordiQjoined
19:15:06  * bumbleheadjoined
19:15:33  * NomadJim_changed nick to NomadJim
19:15:56  * nitricpart ("Textual IRC Client: www.textualapp.com")
19:17:00  * ahmedelgabrijoined
19:17:02  * duckpuppyquit (Ping timeout: 258 seconds)
19:17:08  <myndzi>proxy seems to be your best bet
19:17:21  <myndzi>iirc the three main options are CORS headers, JSONP, proxy
19:17:33  <myndzi>there might be some hackery possible with iframes and stuff too
19:17:35  * LeBlaaancjoined
19:17:42  * emilknieveljoined
19:17:49  <lulda>then the download speed would still be constrainted to what my server allows right?
19:17:55  <lulda>anyway thanks
19:17:56  <myndzi>yep
19:17:59  * emilknievelquit (Client Quit)
19:18:22  * Narigoquit (Quit: This computer has gone to sleep)
19:18:41  * FuzzySocketsjoined
19:19:12  * bumbleheadquit (Ping timeout: 240 seconds)
19:19:16  * JustAnotherIdiotjoined
19:19:57  * phalethquit (Quit: Download IceChat at www.icechat.net)
19:20:17  * NordiQquit (Ping timeout: 260 seconds)
19:20:41  * luldaquit (Quit: Page closed)
19:20:54  * tesrtyquit (Quit: -)
19:21:18  * tesrtyjoined
19:21:19  <joepie91>myndzi: the problem with cross-domain is that you can -make- the request but not programmatically read its response
19:21:21  * junexjoined
19:21:28  <joepie91>(this goes for all request types)
19:21:29  * jasnellquit (Remote host closed the connection)
19:21:30  * dunpealjoined
19:21:45  <joepie91>(even if sometimes a workaround may be needed)
19:22:33  * ironfroggyjoined
19:22:35  * jasnelljoined
19:24:06  * ChALkeRjoined
19:24:19  * duckpuppyjoined
19:24:55  * flappynerdjoined
19:26:06  * veggie_joined
19:26:17  * chargenquit (Read error: No route to host)
19:26:47  * d0nkeyBOBquit (Read error: Connection reset by peer)
19:27:06  * d0nkeyBOBjoined
19:28:09  * KieronWiltshirequit (Read error: Connection reset by peer)
19:28:22  * andrew9183joined
19:29:24  * samsshquit (Quit: Leaving)
19:29:53  * star_pronequit (Remote host closed the connection)
19:30:29  * Sixmsjjoined
19:30:35  * star_pronejoined
19:30:59  * NordiQjoined
19:31:33  * optikalmousejoined
19:32:15  <myndzi>joepie91: yeah, i guess that makes sense. though i seem to recall at least one special case (possibly for legacy reasons) and i thought that was post or something
19:32:21  * andresrosveljoined
19:33:03  * TheTank111quit (Quit: Page closed)
19:33:09  * andresrosvelpart
19:33:22  * shawndomnitijoined
19:33:53  * munch_quit (Remote host closed the connection)
19:33:53  * jasnellquit (Remote host closed the connection)
19:34:07  * marthinalquit (Ping timeout: 244 seconds)
19:34:07  * jasnelljoined
19:35:09  * polydo_squit (Ping timeout: 244 seconds)
19:35:43  * munch_joined
19:35:47  * RLajoined
19:35:58  * allanmacgregorjoined
19:36:17  * chargenjoined
19:36:20  <JoeOlliff>so I'm attempting to require a .js file by reading the name of the directory it is in and then using app.use(), however the require only seems to become anything other than undefined when I have the module.exports = function() return something. But 'this' returns a global not the function it should be returning...
19:36:33  <JoeOlliff>I'm missing something simple somewhere I know it...
19:36:55  * nicknightjoined
19:38:01  <RLa>"the require only seems to become anything other than undefine" <- needs more specific description
19:38:33  <KLVTZ>Can you gist the example?
19:38:48  <RLa>oh, you mean object returned by the require call?
19:39:44  * junexquit (Read error: Connection reset by peer)
19:41:17  * brainproxyjoined
19:41:34  <JoeOlliff>RLa: sorry for the delay, yes when i test what is being returned by doing the require() call within console.log() it only shows as something other than undefined when I tell the module.exports = function() in the index.js file to return something
19:42:07  <myndzi>well of course
19:42:10  <myndzi>you're calling the function
19:42:12  * ejbjoined
19:42:18  <myndzi>if the function doesn't return anything, the return value is undefined
19:42:32  <myndzi>require(folder)(app, db, express) is what you're doing
19:42:35  * dopesongquit (Remote host closed the connection)
19:42:37  <myndzi>so you need to return a middleware function
19:42:42  <JoeOlliff>myndzi: so what should I tell it to return? 'this' doesn't seem to work
19:42:43  <myndzi>from the function you export
19:42:56  <JoeOlliff>ah
19:42:58  <myndzi>if you're exporting the middleware function, don't call it
19:42:59  <JoeOlliff>ok
19:43:08  * leehambleyjoined
19:43:12  <myndzi>you seem to be doing a parametric thing, so you need a function that returns a function if you want the other things (db, etc.) to be in scope
19:43:21  * brainpro1quit (Ping timeout: 276 seconds)
19:43:28  <myndzi>the outer function may not do anything other than provide scope for the inner function
19:43:34  <myndzi>so you could wind up with
19:43:52  <myndzi>module.exports = function (app, db, express) { return function (req, res) { ... }; };
19:44:30  <JoeOlliff>gotcha, that makes sense... thanks again
19:44:32  * a-109-107quit (Read error: Connection reset by peer)
19:44:54  * silencedquit (Quit: My Mac has gone to sleep. ZZZzzz…)
19:45:29  * nicknightquit (Quit: WeeChat 1.4)
19:46:27  * vuotojoined
19:46:50  * tfennellyquit (Read error: Connection reset by peer)
19:47:09  * mnemonicjquit (Ping timeout: 250 seconds)
19:47:20  * EGregjoined
19:47:46  * ningujoined
19:48:19  <ningu>anyone here familiar with node addons? I have a question about global state basically... trying to keep an object around for the lifetime of the module
19:48:23  * mnemonicjjoined
19:48:45  * duckpuppyquit (Read error: Connection reset by peer)
19:48:51  * sbellinajoined
19:49:50  * mrogne_afkchanged nick to mrogne
19:49:56  * mihokquit (Remote host closed the connection)
19:50:07  * tfennellyjoined
19:50:21  * acrussellquit (Ping timeout: 250 seconds)
19:50:35  * yhpark_talk_____quit (Ping timeout: 265 seconds)
19:51:05  * moseKquit (Quit: Lost terminal)
19:51:26  * mrognechanged nick to it
19:51:33  * itchanged nick to mrogne
19:51:54  * yhpark_talk_____joined
19:52:30  * moseKjoined
19:53:29  * krish203quit (Quit: Leaving.)
19:54:18  * BetaSouljoined
19:54:23  * sagerdeariajoined
19:55:31  * abijeetquit (Remote host closed the connection)
19:55:40  <JoeOlliff>myndzi: Ok so that got it "working" but only if it is handling one single route. so <site>/test/ could only ever accept <site>/test/ maybe I should declare a Router object, set all my routes to it and then return the Router?
19:56:44  * munch_quit (Remote host closed the connection)
19:56:51  * tahjquit
19:57:54  * phrearchjoined
19:59:36  * buzulijoined
20:00:02  * whathappensjoined
20:00:59  * Limixquit (Quit: Limix)
20:02:53  * star_pronequit (Remote host closed the connection)
20:03:30  * tvwquit (Remote host closed the connection)
20:03:37  * AvianFluquit (Remote host closed the connection)
20:03:42  * DrMabusejoined
20:03:52  * star_pronejoined
20:03:57  * andrew9183quit (Quit: andrew9183)
20:04:09  * HoierMquit (Ping timeout: 276 seconds)
20:04:37  * andrew9183joined
20:05:02  * roddy__joined
20:05:15  * BetaSoulquit (Quit: My Mac has gone to sleep. ZZZzzz…)
20:05:25  * DrMabuse_joined
20:05:26  * DrMabusequit (Read error: Connection reset by peer)
20:05:34  * whathappensquit (Ping timeout: 260 seconds)
20:07:20  * roddy__quit (Remote host closed the connection)
20:07:57  * roddy__joined
20:08:02  * BetaSouljoined
20:08:19  * roddy_quit (Ping timeout: 252 seconds)
20:08:32  * sbellina_joined
20:08:32  * sbellinaquit (Read error: Connection reset by peer)
20:09:15  * d0nkeyBOBquit (Read error: Connection reset by peer)
20:09:24  <flappynerd>!ask @ ningu
20:09:24  <ecmabot>ningu: Don't ask to ask, nor if anyone is here or alive or uses something. Just ask your question. http://www.mikeash.com/getting_answers.html http://www.catb.org/esr/faqs/smart-questions.html
20:09:49  * silencedjoined
20:10:14  * DrMabuse_quit (Ping timeout: 260 seconds)
20:10:33  <ningu>I am trying to store a pointer to a C++ class object that will be loaded every time the module is initialized
20:10:57  <ningu>I need to store it and be able to retrieve it later from a function on the module's exports object
20:11:23  <ningu>so far I am trying to store it on the exports object itself as External
20:11:29  <ningu>but I can't figure out yet how to retrieve it
20:11:48  <ningu>I guess I could just make it all internal to C++
20:12:23  * krish203joined
20:12:25  * TheTank111joined
20:12:52  * mcmillhjquit (Ping timeout: 240 seconds)
20:13:11  * tfennellyquit (Read error: Connection reset by peer)
20:13:12  * josdeha_rtjoined
20:14:03  * wazquit (Quit: Textual IRC Client: www.textualapp.com)
20:14:22  * kingarmadilloquit (Ping timeout: 252 seconds)
20:15:50  * bumbleheadjoined
20:19:10  * mcmillhjjoined
20:19:11  <nerium>ningu: Are you sure that’s the way to go? I doesn’t sound very thread safe to have a global mutable object
20:19:25  * oxhak_joined
20:19:26  <ningu>it is not mutable
20:19:42  <ningu>anyway this is single-threaded
20:19:52  * tfennellyjoined
20:20:01  * ed209quit (Remote host closed the connection)
20:20:07  * ed209joined
20:20:15  * bumbleheadquit (Ping timeout: 250 seconds)
20:20:20  * rendar_joined
20:20:55  * lucasemjoined
20:21:16  <nerium>ningu: Maybe if two processes invoved it
20:21:17  * liuwenhaoquit (Quit: Leaving)
20:21:25  * rendarquit (Disconnected by services)
20:21:30  <ningu>then they would get two separate instances of the module
20:21:38  * neoncontrailsquit (Remote host closed the connection)
20:21:45  <nerium>ningu: Aha, okay.
20:21:50  * rendar_quit (Client Quit)
20:21:55  <ningu>that's just how it works, nothing I did to make it that way
20:21:59  * phrearchquit (Quit: Konversation terminated!)
20:22:05  * rendarjoined
20:22:16  * JoeOlliffquit (Quit: Page closed)
20:22:35  <ningu>cool, this seems to be working so far
20:22:38  <ningu>not quite sure how I did it :P
20:22:40  * MrP[Home]quit (Read error: No route to host)
20:22:52  * MrP[Home]joined
20:23:04  <ningu>it takes 5 min to load in the graph so I will have to wait
20:23:32  * hextileXjoined
20:23:33  * oxhak_quit (Ping timeout: 240 seconds)
20:23:43  * mcmillhjquit (Ping timeout: 244 seconds)
20:23:58  * EGregquit (Remote host closed the connection)
20:24:54  <joepie91>heh. http://deviq.com/shiny-toy/
20:25:15  * ArchNoobjoined
20:25:51  * ejbquit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
20:25:55  * FVjoined
20:26:15  * Johnny-quit (Ping timeout: 276 seconds)
20:26:38  * calamityjoined
20:28:11  * Literphorquit (Quit: Literphor)
20:28:26  * FVquit (Remote host closed the connection)
20:28:32  * TyrfingMjolnirquit (Ping timeout: 260 seconds)
20:28:58  * smogquit (Ping timeout: 250 seconds)
20:29:21  * Dark_Aaronquit (Ping timeout: 250 seconds)
20:31:11  * dopesongjoined
20:31:14  * calamityquit (Ping timeout: 260 seconds)
20:31:25  * tfennellyquit (Remote host closed the connection)
20:31:43  * FuzzySocketsquit (Read error: Connection reset by peer)
20:31:44  * ahhhndiquit (Quit: Verlassend)
20:33:07  * Gatesunderjoined
20:33:19  * soeequit (Quit: Konversation terminated!)
20:33:37  * devcquit (Quit: zzz...)
20:33:38  * neriumquit (Quit: nerium)
20:33:43  * Johnny-joined
20:34:33  * neriumjoined
20:34:34  * sankhaquit (Read error: Connection reset by peer)
20:35:13  * sankhajoined
20:35:27  * wazjoined
20:36:00  * Narigojoined
20:36:15  * whathappensjoined
20:36:47  * star_pronequit (Remote host closed the connection)
20:37:17  * sankha_joined
20:37:44  * danmulveyjoined
20:38:08  * silencedquit (Quit: My Mac has gone to sleep. ZZZzzz…)
20:38:18  * maretjoined
20:38:30  * roddy_joined
20:38:45  * nd__joined
20:39:04  * mcmillhjjoined
20:39:50  * Johnny-quit (Ping timeout: 258 seconds)
20:39:59  * sankhaquit (Ping timeout: 260 seconds)
20:41:19  * jeffreylevesquequit (Ping timeout: 258 seconds)
20:41:33  * marthinaljoined
20:42:29  * roddy__quit (Ping timeout: 244 seconds)
20:43:07  * roddy_quit (Ping timeout: 260 seconds)
20:43:30  * mcmillhjquit (Ping timeout: 244 seconds)
20:44:16  * tfennellyjoined
20:44:26  * neriumquit (Quit: nerium)
20:45:11  * sbellina_quit (Read error: Connection reset by peer)
20:45:14  * tfennellyquit (Remote host closed the connection)
20:45:16  * neriumjoined
20:45:35  * AvianFlujoined
20:45:35  * neanderslobjoined
20:45:41  * flappynerdquit (Quit: = "bye")
20:45:47  * tfennellyjoined
20:45:53  * tfennellyquit (Remote host closed the connection)
20:46:05  * tfennellyjoined
20:46:12  * marthinalquit (Ping timeout: 240 seconds)
20:46:14  * Johnny-joined
20:46:53  * HoierMjoined
20:47:22  * tfennellyquit (Remote host closed the connection)
20:47:24  * mcmillhjjoined
20:47:46  * neanderslobquit (Disconnected by services)
20:47:46  * neanderslob_joined
20:47:50  * sankha_quit (Ping timeout: 258 seconds)
20:48:51  * silencedjoined
20:49:04  * neanderslobjoined
20:51:46  * BetaSoulquit (Ping timeout: 244 seconds)
20:52:41  * TheSimonatorquit (Remote host closed the connection)
20:53:16  * TheSimonatorjoined
20:53:23  * odigityjoined
20:53:26  * sillysluxjoined
20:54:38  * mizu_no_oto_workquit (Quit: My Mac has gone to sleep. ZZZzzz…)
20:55:20  * TheSimonator_joined
20:55:53  * TheSimonatorquit (Read error: Connection reset by peer)
20:56:36  * mihokjoined
20:56:48  * graffixquit (Ping timeout: 276 seconds)
20:56:48  * graffix_changed nick to graffix
20:57:18  * alanszlosekquit (Remote host closed the connection)
20:57:45  * Hesulanquit (Remote host closed the connection)
20:58:09  <nerium>joepie91: In regards to what we talked about before (accessing data using aa.bb.cc.dd) http://programmers.stackexchange.com/questions/157526/explanation-on-how-tell-dont-ask-is-considered-good-oo
20:58:12  * iffraff1quit (Remote host closed the connection)
20:58:48  <nerium>TL;DR Your example would break ’tell dont ask’
21:00:11  * maretquit (Ping timeout: 265 seconds)
21:00:57  * mrkmgquit (Quit: mrkmg)
21:02:10  * sankhajoined
21:02:31  * marthinaljoined
21:03:33  * blindboxquit (Ping timeout: 240 seconds)
21:04:04  * oxhakquit (Ping timeout: 240 seconds)
21:04:45  * Finnoloidjoined
21:04:55  * blindboxjoined
21:05:09  * Literphorjoined
21:05:17  * DeltaHeavyquit (Quit: Textual IRC Client: www.textualapp.com)
21:05:39  * thebisquickmanquit (Ping timeout: 260 seconds)
21:06:09  * DrMabusejoined
21:06:32  * sankhaquit (Ping timeout: 240 seconds)
21:06:59  * LeBlaaancquit (Quit: My Mac has gone to sleep. ZZZzzz…)
21:07:10  * elfuegoquit (Quit: elfuego)
21:07:34  * marthinalquit (Ping timeout: 240 seconds)
21:08:31  * LeBlaaancjoined
21:10:58  * leehambleyquit (Quit: My Mac has gone to sleep. ZZZzzz…)
21:11:06  * DrMabusequit (Ping timeout: 276 seconds)
21:11:22  * jasnellquit (Remote host closed the connection)
21:12:15  * neanderslob_quit (Ping timeout: 250 seconds)
21:12:26  * neanderslobquit (Ping timeout: 244 seconds)
21:12:52  * kingarmadillojoined
21:13:29  * neanderslobjoined
21:13:44  * neanderslob_joined
21:13:44  * neanderslobquit (Disconnected by services)
21:14:50  * Galvusjoined
21:14:58  * SwiftMattquit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
21:15:15  * neanderslobjoined
21:15:30  * Narigoquit (Quit: This computer has gone to sleep)
21:16:28  * dodobrainjoined
21:16:34  * bumbleheadjoined
21:16:44  * mcmillhjquit (Ping timeout: 260 seconds)
21:16:46  * cotkojoined
21:17:18  * cotalinuxquit (Quit: "Gotta catch them all..")
21:18:13  * tvwjoined
21:18:22  * Log1xjoined
21:18:22  * Log1xquit (Changing host)
21:18:22  * Log1xjoined
21:18:31  * sergeyquit
21:18:38  * euphoria-joined
21:18:56  * NickEUjoined
21:19:34  * itaipuquit (Ping timeout: 240 seconds)
21:19:41  * leehambleyjoined
21:19:55  * odigityquit (Quit: Leaving)
21:20:07  * leehambleyquit (Client Quit)
21:20:14  * ToApolytoXaosjoined
21:20:44  * bumbleheadquit (Ping timeout: 244 seconds)
21:21:08  * jeffreylevesquejoined
21:22:05  <joepie91>nerium: the answer described there is rather... not quite correct, in that it doesn't cover a good many cases, and works with a different definition of 'object' than what is commonly used in JS
21:23:35  * neanderslobquit (Read error: Connection reset by peer)
21:25:11  * marthinaljoined
21:25:27  * pingupingujoined
21:25:27  * pingupinguquit (Changing host)
21:25:27  * pingupingujoined
21:26:19  * graffix222joined
21:27:11  * Tragedyquit (Read error: Connection reset by peer)
21:28:06  * smokeoquit (Remote host closed the connection)
21:28:38  * FunnyLookinHatquit (Remote host closed the connection)
21:28:58  * ^esc_quit (Ping timeout: 244 seconds)
21:29:14  * FunnyLookinHatjoined
21:31:29  * vuotoquit (Read error: Connection reset by peer)
21:31:32  * vuoto_joined
21:32:52  * flappynerdjoined
21:33:00  * FunnyLookinHatquit (Remote host closed the connection)
21:33:15  * FunnyLookinHatjoined
21:33:47  * Narigojoined
21:34:00  * optikalmousequit (Quit: optikalmouse)
21:34:13  * Narigoquit (Remote host closed the connection)
21:34:18  * Galvusquit (Quit: Page closed)
21:35:34  * iyogeshjoshijoined
21:36:12  * sbellinajoined
21:36:47  * neanderslob_quit (Ping timeout: 260 seconds)
21:39:19  * SquadGoalsjoined
21:39:37  * Narigojoined
21:39:41  * SwiftMattjoined
21:39:52  * iyogeshjoshiquit (Ping timeout: 240 seconds)
21:39:55  <SquadGoals>if i have a json array. and i call splice on that array to remove one element, will it delete that element + its children? or just the reference to that element? the goal here is to avoid memory leak errors
21:40:12  * FuzzySocketsjoined
21:40:49  <SquadGoals>by 'remove' i mean make it so that the gc can come later and actually remove it
21:41:16  * bottazziniquit (Quit: Disappears in a puff of smoke)
21:41:37  * GustavoLapastaquit (Quit: Leaving)
21:41:40  * ChALkeRquit (Remote host closed the connection)
21:42:05  * ChALkeRjoined
21:42:19  * nd__quit (Ping timeout: 258 seconds)
21:42:26  * mcmillhjjoined
21:42:47  * neoncontrailsjoined
21:43:26  * geirhajoined
21:45:23  * Narigoquit (Ping timeout: 258 seconds)
21:46:31  * grillquit (Quit: Goodnight)
21:46:47  * neanderslobjoined
21:46:54  * neanderslobquit (Disconnected by services)
21:46:55  * jasnelljoined
21:46:56  * neanderslob_joined
21:47:00  * zerowaitstatejoined
21:47:07  <zerowaitstate>does anyone here use node-mysql?
21:47:11  * mcmillhjquit (Ping timeout: 250 seconds)
21:47:26  <zerowaitstate>or to put it a different way, does anyone use node-mysql with connection pooling?
21:47:40  <zerowaitstate>because this performance is terrible
21:47:46  * stelarcfquit (Quit: stelarcf)
21:47:56  <flappynerd>SquadGoals, https://developer.mozilla.org/en-US/docs/Web/JavaScript/Memory_Management
21:48:00  * stelarcfjoined
21:48:25  * DragonPunchjoined
21:48:31  <flappynerd>SquadGoals, I think it's going to be nearly identical in node.js
21:48:33  <zerowaitstate>doing a query once you have a connection from the pool: 160 ms
21:48:49  <zerowaitstate>actually getting a connection from the pool when a connection is already established, 250 ms
21:49:00  <flappynerd>zerowaitstate, I use postgres
21:49:08  <flappynerd>so, no idea, connection pools with pg are fine
21:49:23  <zerowaitstate>yeah, it appears to be an issue with this library
21:49:25  <flappynerd>zerowaitstate, where is the app, where is the db (i.e. same box?)
21:49:29  * dunpealquit (Ping timeout: 244 seconds)
21:49:36  <zerowaitstate>app and db are on separate boxes.
21:49:39  * krish203part
21:49:47  * diosneyquit (Quit: Konversation terminated!)
21:49:49  <flappynerd>could be network latency then
21:49:54  <zerowaitstate>I'm sure the cause of the delay is that it is doing a mysql ping before each connection fetch from the pool
21:49:55  * diosneyjoined
21:50:02  * josdeha_rtquit (Quit: josdeha_rt)
21:50:09  <zerowaitstate>which practically defeats the purpose of pooling
21:50:23  * Mamutjoined
21:50:28  * roflmyeggojoined
21:51:14  * plexigrasjoined
21:51:14  <AvianFlu>the code could probably make that pretty clear zerowaitstate
21:51:19  <AvianFlu>that seems like an easy thing to notice it doing
21:51:27  <AvianFlu>referring to the lib, not yours per se
21:52:11  <AvianFlu>it also looks like it hasn't been released in 2 years?
21:52:23  * neanderslob_quit (Ping timeout: 250 seconds)
21:52:44  * ahtikquit (Ping timeout: 244 seconds)
21:52:45  <zerowaitstate>version 2.11.1 was released Jun 7
21:52:54  * neanderslobjoined
21:52:58  <AvianFlu>must just be the npm search output then, nm on that part
21:53:04  * marthinalquit (Ping timeout: 240 seconds)
21:53:37  * Narigojoined
21:53:54  <zerowaitstate>it's this one: https://github.com/mysqljs/mysql
21:54:31  <zerowaitstate>"When a previous connection is retrieved from the pool, a ping packet is sent to the server to check if the connection is still good."
21:55:03  <SquadGoals>flappynerd, i understand. can u point to the part that lets me know if a splice commands removes the json + all its children? i could extrapolate from the fact that a spliced variable is not being referenced ever again anywhere. its gone. and therefore infer that a spliced item is eligible for gc pickup. buuut, there will be a global array i'll be using in nodejs. and this array will be referenced throughout its lifetime. so i dont know
21:55:03  <SquadGoals>if that spliced json object and its cihldren will be picked up by its children
21:55:14  * cobjoined
21:55:46  * neriumquit (Quit: nerium)
21:55:59  <AvianFlu>zerowaitstate, okay, lol, I was looking at a different module
21:56:19  * InverseRhombusjoined
21:56:40  * andrew9183quit (Quit: andrew9183)
21:56:40  * neriumjoined
21:56:53  * dopesongquit (Remote host closed the connection)
21:57:03  <SquadGoals>by the garbage collector*
21:57:30  * dopesongjoined
21:57:36  <zerowaitstate>AvianFlu: yeah, the query times themselves (once you get a connection from the pool) are pretty much in line with what I'm seeing via JDBC from the same machine
21:58:03  <zerowaitstate>AvianFlu: it's the part where the connection is fetched from the pool which is basically doubling/tripling the total database query time
21:58:09  * Limes_quit (Ping timeout: 260 seconds)
21:58:22  <AvianFlu>yeah, that seems super wrong for sure
21:58:52  * plexigrasquit (Ping timeout: 252 seconds)
21:59:04  * Xitijoined
21:59:11  * InverseRhombusquit (Client Quit)
21:59:16  * lsyoyomquit (Ping timeout: 264 seconds)
21:59:28  * rendarquit (Quit: std::lower_bound + std::less_equal *works* with a vector without duplicates!)
22:00:18  * mcmillhjjoined
22:00:30  * flappynerdquit (Quit: Leaving)
22:00:32  * TheSimonator_quit (Remote host closed the connection)
22:00:52  <AvianFlu>zerowaitstate, if you feel like some mad science, try tweaking this maybe https://github.com/mysqljs/mysql/blob/master/lib/Pool.js#L117
22:01:02  <AvianFlu>and just call the CB instead of doing the ping
22:01:09  * TheSimonatorjoined
22:01:13  <AvianFlu>if that solves your problem open an issue
22:01:16  <AvianFlu>(or just open an issue anyway)
22:01:24  * alanszlosekjoined
22:01:33  * dopesongquit (Ping timeout: 244 seconds)
22:02:15  * andrew9183joined
22:02:27  * ConspiratorXquit (Quit: My Mac has gone to sleep. ZZZzzz…)
22:02:31  * dopesongjoined
22:02:57  * alanszlosekquit (Remote host closed the connection)
22:03:30  <zerowaitstate>AvianFlu: I've done web services on Erlang before, and the way it was handled there was that the erlang driver that managed the pool proactively sent keepalives to connections which were not in use so that mysql server wouldn't harvest them. By allowing them to timeout organically you have to introduce a sanity check each time you pull a connection to verify it hasn't gone away.
22:03:40  * Lee1092quit (Quit: Connection closed for inactivity)
22:03:59  * TheSimonatorquit (Read error: Connection reset by peer)
22:04:09  * TheSimonatorjoined
22:04:22  * scippio1joined
22:04:33  * ConspiratorXjoined
22:04:56  * mcmillhjquit (Ping timeout: 250 seconds)
22:04:58  <zerowaitstate>so avoiding the ping check isn't a total solution, because they are relying on the ping check to avoid having to implement keep alives
22:05:05  * TyrfingMjolnirjoined
22:05:09  * TyrfingMjolnirquit (Client Quit)
22:05:58  * TyrfingMjolnirjoined
22:06:52  <AvianFlu>yeah, that makes sense
22:06:53  * DrMabusejoined
22:07:25  <AvianFlu>so fixing it properly would be a lot more complicated
22:07:36  * ConspiratorXquit (Client Quit)
22:07:43  <AvianFlu>the keepalive approach sounds saner to me, but that's not news to you lol
22:08:17  * scippioquit (Ping timeout: 260 seconds)
22:08:33  * mvenjoined
22:08:49  * vuoto_quit (Remote host closed the connection)
22:09:06  * ShekharReddyquit (Quit: Connection closed for inactivity)
22:09:34  * sillysluxquit (Ping timeout: 240 seconds)
22:11:05  * DeckTone`joined
22:11:10  <zerowaitstate>how reliable is the Timer facility in Node? If you set a Timer to execute within 3000 ms, are there guarantees that it will execute near that time, or is it dependent on what else is waiting on the event loop?
22:11:29  <zerowaitstate>ah, nvm, answered my own question
22:11:36  * neanderslobquit (Disconnected by services)
22:11:43  * DrMabusequit (Ping timeout: 265 seconds)
22:11:58  * robertmaxreesquit
22:12:12  * mven_quit (Ping timeout: 276 seconds)
22:12:24  * iyogeshjoshijoined
22:12:31  * mcmillhjjoined
22:12:33  * digiskyquit (Quit: Leaving.)
22:12:40  * neanderslobjoined
22:12:41  * TheSimonatorquit (Remote host closed the connection)
22:12:57  * DeckTonequit (Ping timeout: 260 seconds)
22:13:13  <AvianFlu>yeah, it's part of the event loop, as you realized :)
22:13:18  * TheSimonatorjoined
22:13:21  * kingarmadilloquit (Ping timeout: 250 seconds)
22:15:02  * ningupart
22:17:01  * mcmillhjquit (Ping timeout: 252 seconds)
22:17:01  * neanderslobquit (Ping timeout: 244 seconds)
22:17:20  * bumbleheadjoined
22:17:24  * iyogeshjoshiquit (Ping timeout: 276 seconds)
22:17:34  * TheSimonatorquit (Ping timeout: 244 seconds)
22:17:42  * quattro_quit (Quit: quattro_)
22:20:15  * Tennisjoined
22:20:57  * jasnellquit (Remote host closed the connection)
22:21:39  * bdunavantquit (Remote host closed the connection)
22:22:04  * bumbleheadquit (Ping timeout: 264 seconds)
22:22:31  * Sixmsjquit (Ping timeout: 258 seconds)
22:22:34  * ConspiratorXjoined
22:23:24  * ConspiratorXquit (Client Quit)
22:23:30  * Sixmsjjoined
22:23:47  * ggreerpart
22:23:56  * ThePendulumquit (Quit: leaving)
22:24:27  * ConspiratorXjoined
22:25:35  * uniacid_pcjoined
22:26:22  * glebihan__quit (Ping timeout: 252 seconds)
22:26:29  * dodobrainquit (Quit: Leaving)
22:26:37  * mcmillhjjoined
22:27:04  * dodobrainjoined
22:27:53  * iyogeshjoshijoined
22:28:34  * uni`pcquit (Ping timeout: 252 seconds)
22:28:40  * moseKquit (Quit: leaving)
22:29:40  * Sixmsj_joined
22:29:50  * shiro_samajoined
22:29:56  * timmywilquit (Ping timeout: 244 seconds)
22:30:13  * jkridnerquit (Read error: Connection reset by peer)
22:30:17  <diamonds>How
22:30:17  <diamonds>To
22:30:22  * fodchanged nick to ElmerFUD
22:30:23  * Sixmsjquit (Read error: Connection reset by peer)
22:30:23  * Sixmsj_changed nick to Sixmsj
22:30:24  <diamonds>close a readable stream manually
22:30:27  <diamonds>??
22:30:33  <diamonds>I think I asked the other day but I'm not sure
22:30:37  * SquadGoalsquit (Quit: SquadGoals)
22:30:39  * shawndomnitiquit (Quit: My Mac has gone to sleep. ZZZzzz…)
22:30:57  * jkridnerjoined
22:31:03  * Gatesunderquit (Quit: WeeChat 1.0.1)
22:31:10  * shiro_samaquit (Client Quit)
22:31:37  * mvenquit (Ping timeout: 260 seconds)
22:31:40  * mcmillhjquit (Ping timeout: 264 seconds)
22:31:43  <diamonds>My understanding is: you call `.end()` on the stream it's flowing TO, and that will stop the readable from emitting anymore
22:32:09  <diamonds>but I have no idea how to confirm this without adding another .on('data listener or piping, either of which will probably PREVENT it from closing ???
22:32:16  * amdi_joined
22:32:22  <diamonds>this aspect of the streams api is really fucky tbh
22:32:30  * iyogeshjoshiquit (Ping timeout: 265 seconds)
22:33:28  * MrP[Home]quit (Ping timeout: 264 seconds)
22:33:29  * diogogmt_joined
22:34:02  * Palssonjoined
22:34:02  * eric29292929201quit (Quit: Leaving.)
22:34:24  * diogogmtquit (Ping timeout: 258 seconds)
22:34:24  * diogogmt_changed nick to diogogmt
22:35:12  * tesrtyquit (Ping timeout: 240 seconds)
22:35:31  * bgeorgesjoined
22:35:42  * ShekharReddyjoined
22:36:37  * tesrtyjoined
22:37:16  * nhahn_quit (Remote host closed the connection)
22:37:41  * polydo_sjoined
22:38:44  * nhahnjoined
22:39:05  * neanderslobjoined
22:39:21  * safejoined
22:39:30  * neanderslobquit (Read error: Connection reset by peer)
22:39:41  * mcmillhjjoined
22:39:46  * bgeorgesquit (Ping timeout: 250 seconds)
22:40:23  * h0x00ajoined
22:40:31  <joepie91>diamonds: it's dependent on what is providing the stream, I believe.
22:40:45  <diamonds>joepie91, in this case it's S3
22:41:01  * cobquit (Remote host closed the connection)
22:41:05  <joepie91>dependent on the library you're using :P
22:41:09  <diamonds>but that's discouraging, to hear that there's no standard interface provided :(
22:41:16  <AvianFlu>what are you streaming that you want to close the readable end before it hits some kind of EOF?
22:41:18  <diamonds>? joepie91 aws-sdk::S3
22:41:39  * lucasemquit (Quit: Connection closed for inactivity)
22:41:53  <diamonds>AvianFlu, I have a large CSV, like 1gb, on S3. I need to stream it to postgres (that works) but I first need to check line 1: the header
22:41:54  * dopesongquit (Remote host closed the connection)
22:42:27  * Palssonquit (Quit: My Mac has gone to sleep. ZZZzzz…)
22:42:29  * dopesongjoined
22:42:29  <diamonds>so I open stream 1: pipe to split & check line one, then immediately call .end() on that "checkCSVHeader" writeStream
22:42:33  <AvianFlu>oh, so you're trying to say "check first data chunk and then abort if it's the wrong thing"
22:42:54  * tubuliferousjoined
22:43:15  <diamonds>I open stream 2 (same file as I can't pipe it two places & I don't want to pipe every-single-chunk thru the split+header-checker): pipe THAT to postgres
22:43:30  * iyogeshjoshijoined
22:43:33  <diamonds>exiting on error is easy, just queue and error from the stream & listen elsewhere
22:43:33  * KieronWiltshirejoined
22:43:36  <diamonds>then exit process
22:43:37  * TyrfingM1olnirjoined
22:43:41  * TyrfingM1olnirquit (Client Quit)
22:43:49  <diamonds>the hard bit is "stop reading but don't throw an error"
22:44:08  * neanderslobjoined
22:44:15  <diamonds>so I'm calling .end() in the WritableStream and... I guess crossing my fingers that it closes the upstream readable?
22:44:23  * mcmillhjquit (Ping timeout: 250 seconds)
22:44:30  <AvianFlu>yeah, streams are definitely built with "read a whole file" or "read until connection is closed" in mind
22:44:31  <diamonds>it appears to all be very AutoMagical
22:44:33  * TyrfingMjolnirquit (Quit: leaving)
22:44:50  <AvianFlu>I feel like using a stream for the header check isn't really the right approach, and is causing a bunch of your trouble
22:44:52  * zerowaitstatequit (Quit: leaving)
22:44:57  <diamonds>mm. well I don't want to read the whole file into mem to check the first line if I can help it
22:44:58  <AvianFlu>but, you don't want to download the whole gig, either
22:45:00  <AvianFlu>right
22:45:03  <diamonds>yeah
22:45:06  <diamonds>that's my quandry
22:45:12  <AvianFlu>where are these csvs sourced from that you have no idea what's in them at this point?
22:45:14  <diamonds>if it were local FS I could use built-in head utils
22:45:17  * TyrfingMjolnirjoined
22:45:21  <AvianFlu>yeah, I see your problem now
22:45:30  <diamonds>AvianFlu, they are from a data vendor
22:45:34  <AvianFlu>aha
22:45:44  <AvianFlu>woof
22:45:52  <diamonds>AvianFlu, the check is primarily for safety. make sure we know what's going in there before sending it to PG
22:45:54  * tubuliferous_joined
22:46:00  * Narigoquit (Quit: This computer has gone to sleep)
22:46:09  * tubuliferousquit (Read error: Connection reset by peer)
22:46:11  <diamonds>it's public real estate records fwiw, not ad-spy data ;)
22:46:20  <AvianFlu>yeah, this makes sense
22:46:32  * dopesongquit (Ping timeout: 240 seconds)
22:46:36  * cobjoined
22:46:50  * TyrfingMjolnirquit (Client Quit)
22:46:54  <AvianFlu>you could always try something relatively simple, like using a var as a flag
22:46:55  <diamonds>I just can't believe there's NO INTERFACE for this in the readablestream api :(
22:47:00  <AvianFlu>and then use it to short-circuit the checking in the stream
22:47:04  <diamonds>AvianFlu, then passing thru?
22:47:05  <diamonds>yeah
22:47:17  <diamonds>tbh that'd be much simpler
22:47:24  <AvianFlu>that way you at least save the 100,000 split calls or whatever it is
22:47:36  * amdi_quit (Quit: amdi_)
22:47:59  * dopesongjoined
22:48:00  * iyogeshjoshiquit (Ping timeout: 250 seconds)
22:48:23  <diamonds>yeah that's the hard part... now do I avoid all those splits
22:48:25  <AvianFlu>I feel like closing the write stream like you were will also close the read end though
22:48:35  * Literphorquit (Quit: Literphor)
22:48:37  <AvianFlu>but, the idea is, you just have like
22:48:39  <diamonds>AvianFlu, how are you suggesting to avoid the split? unpipe that one?
22:48:47  * mihokquit (Remote host closed the connection)
22:48:58  <AvianFlu>if (!alreadyChecked) { doTheCheck(); alreadyChecked = true }
22:48:59  * Literphorjoined
22:49:12  * nnykjoined
22:49:15  <AvianFlu>and then have var alreadyChecked = false outside the stream handler
22:49:21  * TyrfingMjolnirjoined
22:49:41  <AvianFlu>but yeah unpipe or close the writable, and things should just stop for you
22:49:49  * tfennellyjoined
22:49:53  <AvianFlu>this is definitely a bit of a stream edge case though
22:50:42  <diamonds>I mean, if someone goes to upload a file to your server
22:50:45  * tubuliferous_quit (Read error: Connection reset by peer)
22:50:49  <diamonds>& that opens a readablestream on the server
22:50:55  * tubuliferousjoined
22:50:55  * ConspiratorXquit (Quit: My Mac has gone to sleep. ZZZzzz…)
22:51:09  <diamonds>you may wish to shut that connection off programatically, no?
22:51:21  <diamonds>"file too big, halt"
22:51:49  * lyyjoined
22:51:55  * cedvanquit (Remote host closed the connection)
22:51:56  <diamonds>where the hell is this getting destroy from https://github.com/nodejs/node/blob/master/lib/stream.js#L67
22:52:05  <diamonds>it's not in events.js, not in writable_stream... :(
22:52:08  * whathappensquit (Remote host closed the connection)
22:52:12  <diamonds>oh well. ~~magic~~
22:52:27  <diamonds>it's galling that I can't even figure out a way to CHECK if the stream is closed or not
22:52:41  * texinwien_joined
22:52:45  <diamonds>maybe I have to use some sorta reverse proxy to see what's open to AWS? argh
22:53:21  * ggreerjoined
22:54:05  * ironfroggy_joined
22:54:18  <AvianFlu>https://nodejs.org/dist/latest-v6.x/docs/api/stream.html#stream_buffering
22:54:44  * tfennellyquit (Ping timeout: 265 seconds)
22:54:54  <lyy>trying to learn nodejs. first project is to write a script that reads arguments from command line and do a system call to 'dir ' the item passed:var p = require('process');var s = require('child_process');process.argv.forEach(function fileName){shell.exec('dir ' + fileName);});
22:55:12  <lyy>but it's not doing it
22:55:15  * ironfroggyquit (Read error: Connection reset by peer)
22:55:21  <AvianFlu>there's also states you can try checking diamonds https://nodejs.org/dist/latest-v6.x/docs/api/stream.html#stream_three_states
22:55:45  * diogogmtquit (Ping timeout: 276 seconds)
22:56:07  <AvianFlu>I have to run but I'd check whether or not any of those properties match what you're trying to watch for
22:56:18  * AvianFluquit (Remote host closed the connection)
22:56:30  * diogogmtjoined
22:56:40  <joepie91>diamonds: https://github.com/nodejs/node-v0.x-archive/commit/44b308b1f7beaa3398d869f1626f01ae6526bc0b#diff-9a205ef7ee967ee32efee02e58b3482dR1515
22:56:42  <joepie91>node 0.12
22:56:51  * plutoniixquit (Read error: Connection reset by peer)
22:56:52  * NickEUquit (Read error: Connection reset by peer)
22:57:00  <joepie91>diamonds: in fs.js
22:57:09  <joepie91>so it seems that destroy is expected to be implemented on a per-stream-provider basis
22:57:15  * mrognechanged nick to mrogne_afk
22:57:18  * NickEUjoined
22:57:19  <joepie91>hm
22:57:19  * tubuliferousquit (Ping timeout: 244 seconds)
22:57:21  * tfennellyjoined
22:57:24  <joepie91>"Note that the destroy (and the close) functions are specific to fs.ReadStream. There are not part of the generic stream.readable "interface"."
22:57:36  * nhahnquit (Remote host closed the connection)
22:57:38  <dmarr>what ORMs do people prefer with Node+postgres? What i've found so far: knex, bookshelf, sequelize
22:57:43  <joepie91>odd
22:57:46  <joepie91>dmarr: one sec
22:57:47  <joepie91>er
22:57:49  <joepie91>diamonds: one sec *
22:57:52  <diamonds>joepie91, is this current?
22:57:55  * nhahnjoined
22:57:57  * dongustonquit (Read error: No route to host)
22:57:58  <diamonds>4.2.+?
22:58:01  <joepie91>diamonds: node 0.12 era, but I have a lead
22:58:02  <joepie91>sec
22:58:08  * diamondsnods
22:58:15  <diamonds>yeah they went 1->2 on streams
22:58:21  <joepie91>0.12 was 2
22:58:23  <joepie91>we're at 3 now
22:58:25  <joepie91>:p
22:58:52  * andrew9183quit (Quit: andrew9183)
22:59:06  * LeBlaaancquit (Quit: My Mac has gone to sleep. ZZZzzz…)
22:59:20  * tfennellyquit (Remote host closed the connection)
22:59:45  * earendelquit (Ping timeout: 258 seconds)
22:59:55  * hextileX1joined
23:00:32  * hextileXquit (Ping timeout: 265 seconds)
23:00:32  * hextileX1changed nick to hextileX
23:00:34  * tfennellyjoined
23:01:15  <joepie91>diamonds: found it
23:01:16  <joepie91>https://nodejs.org/docs/v0.8.9/api/stream.html#stream_stream_destroy
23:01:22  <joepie91>destroy was apparently a streams 1 thing
23:01:25  * TyrfingM1olnirjoined
23:01:26  * diamondsnods
23:01:28  * tubuliferousjoined
23:01:41  * tfennellyquit (Remote host closed the connection)
23:01:49  * Aljonequit (Ping timeout: 244 seconds)
23:01:52  <diamonds>https://github.com/aws/aws-sdk-js/blob/eb5a124d973a8542b556dac14a7b8191482d6571/lib/request.js#L532-L548
23:01:53  <joepie91>diamonds: so this is almost certainly intended to interop with streams1 streams
23:01:55  <joepie91>when piping to them
23:02:01  <diamonds>this makes it look like it's an HTTP stream
23:02:05  <joepie91>though I guess implementations can add a .destroy anyway to offer that same functionality