Closed ggoodale closed 12 years ago
Strange. the 0.2.5 version of the adapter works fine, so something about 0.3.0 is incompatible with hubot 2.2.0 maybe?
Yeah, it seems that most recent commit in master changes the style of requiring Hubot to be compatible with 2.3.x: SHA: 31174734e8168f5c0ec163f04c63a2b75575bd89
This means that the adapter version 0.3.0 is not anymore compatible with the older 2.2.x versions of Hubot. I'll document this to the adapter README to avoid confusion. :)
This still doesn't work for me. Not only that, but hubot-flowdock doesn't seem to be listening to my environment variables...
♬ echo $HUBOT_FLOWDOCK_LOGIN_EMAIL
my@email.address.com
♬ ./bin/hubot -a flowdock
ERROR: No credentials in environment variables HUBOT_FLOWDOCK_LOGIN_EMAIL and HUBOT_FLOWDOCK_LOGIN_PASSWORD
Error: Uncaught, unspecified 'error' event.
at Flowdock.emit (events.js:50:15)
at Flowdock.run (/Users/tom/Code/fubot/node_modules/hubot-flowdock/src/flowdock.coffee:77:14)
at Robot.run (/Users/tom/Code/fubot/node_modules/hubot/src/robot.coffee:338:27)
at Object.<anonymous> (/Users/tom/Code/fubot/node_modules/hubot/bin/hubot:106:11)
at Object.<anonymous> (/Users/tom/Code/fubot/node_modules/hubot/bin/hubot:109:4)
at Module._compile (module.js:432:26)
at Object.run (/Users/tom/Code/fubot/node_modules/hubot/node_modules/coffee-script/lib/coffee-script/coffee-script.js:79:25)
at /Users/tom/Code/fubot/node_modules/hubot/node_modules/coffee-script/lib/coffee-script/command.js:175:29
at /Users/tom/Code/fubot/node_modules/hubot/node_modules/coffee-script/lib/coffee-script/command.js:150:18
at [object Object].<anonymous> (fs.js:115:5)
When I pass those values in through the command line, I get:
♬ HUBOT_FLOWDOCK_LOGIN_EMAIL=email@address.com HUBOT_FLOWDOCK_LOGIN_PASSWORD=something ./bin/hubot -a flowdock
The "sys" module is now called "util". It should have a similar interface.
events.js:50
throw new Error("Uncaught, unspecified 'error' event.");
^
Error: Uncaught, unspecified 'error' event.
at Session.emit (events.js:50:15)
at Request._callback (/Users/tom/Code/fubot/node_modules/hubot-flowdock/node_modules/flowdock/lib/flowdock.js:48:17)
at Request.callback (/Users/tom/Code/fubot/node_modules/hubot-flowdock/node_modules/flowdock/node_modules/request/main.js:118:22)
at Request.<anonymous> (/Users/tom/Code/fubot/node_modules/hubot-flowdock/node_modules/flowdock/node_modules/request/main.js:459:16)
at Request.emit (events.js:67:17)
at IncomingMessage.<anonymous> (/Users/tom/Code/fubot/node_modules/hubot-flowdock/node_modules/flowdock/node_modules/request/main.js:418:14)
at IncomingMessage.emit (events.js:88:20)
at HTTPParser.onMessageComplete (http.js:137:23)
at CleartextStream.ondata (http.js:1137:24)
at CleartextStream._push (tls.js:367:27)
Sorry for the delay in answering to this. I can reproduce this error if I give wrong credentials for the environment variables. Are you sure you don't have a typo there or some special characters in password that could be mangled in the command line input?
There should probably be a better handling for invalid credentials anyway, this error message is pretty confusing.
It works if I export
the variables, but yeah it would be cool if it at least checked for these variables.
I was using an ancient version of Node (I think v0.6?), and when I updated to 8 everything worked. So maybe just instruct people to update if they see this bug again. :)
Thanks for debugging this! I'll add a note to the README about using a recent Node version. :)
node: 0.6.x, 0.8.x npm: 1.0.x, 1.1.x hubot: 2.2.0
Error:
No mods to the flowdock adapter or hubot. API change maybe?