{"action":"closed","issue":{"url":"https://api.github.com/repos/sequelize/sequelize/issues/2933","labels_url":"https://api.github.com/repos/sequelize/sequelize/issues/2933/labels{/name}","comments_url":"https://api.github.com/repos/sequelize/sequelize/issues/2933/comments","events_url":"https://api.github.com/repos/sequelize/sequelize/issues/2933/events","html_url":"https://github.com/sequelize/sequelize/issues/2933","id":54322426,"number":2933,"title":"events usage incompatible with io.js","user":{"login":"aldafu","id":133273,"avatar_url":"https://avatars.githubusercontent.com/u/133273?v=3","gravatar_id":"","url":"https://api.github.com/users/aldafu","html_url":"https://github.com/aldafu","followers_url":"https://api.github.com/users/aldafu/followers","following_url":"https://api.github.com/users/aldafu/following{/other_user}","gists_url":"https://api.github.com/users/aldafu/gists{/gist_id}","starred_url":"https://api.github.com/users/aldafu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aldafu/subscriptions","organizations_url":"https://api.github.com/users/aldafu/orgs","repos_url":"https://api.github.com/users/aldafu/repos","events_url":"https://api.github.com/users/aldafu/events{/privacy}","received_events_url":"https://api.github.com/users/aldafu/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-01-14T13:35:59Z","updated_at":"2015-01-20T10:31:17Z","closed_at":"2015-01-20T10:31:17Z","body":"io.js is the new Node.js fork by most of the active previous Node.js developers. They've just made their first release available, [changes here](https://github.com/iojs/io.js/blob/545959468fbc878e7f0a486264eebbdf06a57bea/CHANGELOG.md).\r\n\r\n[```Promise.prototype.on```](https://github.com/sequelize/sequelize/blob/c3f2603048ac9ffaea0886fd6c135d21bf094428/lib/promise.js#L118) in sequelize calls [```EventEmitter.prototype.addListener```](https://github.com/iojs/io.js/blob/3e1b1dd4a9ac048105a4dc4cd81578e26d39a1fc/lib/events.js#L154) which in turn calls ```this.getMaxListeners```. But ```this``` is now refering to Promise in sequelize, so it doesn't have ```getMaxListeners``` and results in \"undefined is not a function\" error.\r\n\r\nThis is the relevant part of a stack trace:\r\nTypeError: undefined is not a function\r\n    at Promise.addListener (events.js:154:18)\r\n    at Promise.on (project\\node_modules\\sequelize\\lib\\promise.js:116:31)\r\n    at Promise.<anonymous> (project\\node_modules\\sequelize\\lib\\promise.js:261:10)\r\n    at Array.forEach (native)\r\n    at Promise.proxy (project\\node_modules\\sequelize\\lib\\promise.js:260:18)\r\n    at Promise.proxySql (project\\node_modules\\sequelize\\lib\\promise.js:271:15)\r\n    at Promise._then (project\\node_modules\\sequelize\\lib\\promise.js:57:10)\r\n    at Promise$then [as then] (project\\node_modules\\sequelize\\node_modules\\bluebird\\js\\main\\promise.js:144:17)\r\n    at Promise.on (project\\node_modules\\sequelize\\lib\\promise.js:113:10)\r\n"}}