-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Closed
Labels
type: bugDEPRECATED: replace with the "bug" issue typeDEPRECATED: replace with the "bug" issue type
Description
Problem
I am trying to use io.js in my production.
I got a following error in a sequelize module.
TypeError: undefined is not a function
at Promise.addListener (events.js:154:18)
at Promise.on (/Users/yosuke/go/src/github.com/yosuke-furukawa/Hexi/node_modules/sequelize/lib/promise.js:118:31)
at Promise.<anonymous> (/Users/yosuke/go/src/github.com/yosuke-furukawa/Hexi/node_modules/sequelize/lib/promise.js:268:10)
at Array.forEach (native)
at Promise.proxy (/Users/yosuke/go/src/github.com/yosuke-furukawa/Hexi/node_modules/sequelize/lib/promise.js:267:18)
at Promise.proxySql (/Users/yosuke/go/src/github.com/yosuke-furukawa/Hexi/node_modules/sequelize/lib/promise.js:278:15)
at Promise._then (/Users/yosuke/go/src/github.com/yosuke-furukawa/Hexi/node_modules/sequelize/lib/promise.js:57:10)
at Promise$then [as then] (/Users/yosuke/go/src/github.com/yosuke-furukawa/Hexi/node_modules/sequelize/node_modules/bluebird/js/main/promise.js:153:17)
at Promise.error.Promise.failure.Promise.fail (/Users/yosuke/go/src/github.com/yosuke-furukawa/Hexi/node_modules/sequelize/lib/promise.js:200:15)
cause
Sequelize/Promise calls EventEmitter.prototype.addEventListener directly.
https://github.com/sequelize/sequelize/blob/master/lib/promise.js#L127
io.js has new method, getMaxListeners and the method is called in EventEmitter.prototype.addEventListener.
https://github.com/iojs/io.js/blob/v1.x/lib/events.js#L154
solution
Sequelize/Promise need to inherit EventEmitter methods.
Metadata
Metadata
Assignees
Labels
type: bugDEPRECATED: replace with the "bug" issue typeDEPRECATED: replace with the "bug" issue type