Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No response from Hubot #35

Closed
bilke opened this issue Feb 21, 2014 · 34 comments
Closed

No response from Hubot #35

bilke opened this issue Feb 21, 2014 · 34 comments

Comments

@bilke
Copy link

bilke commented Feb 21, 2014

I successfully deployed Hubot to Heroku and from the logs it seems fine but I get no response when I ping Hubot @hubot: help although the message arrives on Hubots side:

$ heroku logs
...
2014-02-21T15:41:07.797660+00:00 app[web.1]: Incoming message received

Do you have any idea how I can debug this further?

@weilu
Copy link

weilu commented Feb 21, 2014

+1 same problem here

@chayner
Copy link
Contributor

chayner commented Feb 21, 2014

Have you confirmed that "@hubot" is the appropriate way to get Hubot's attention? For example, we have configured it so we can type "!" as the prefix on a statement. Ex: "!img Winter Olympics"

@weilu
Copy link

weilu commented Feb 21, 2014

I have "slackbot" configured as the name for the Hubot. So I expect "@slackbot" will get Hubot's attention. No?

@weilu
Copy link

weilu commented Feb 21, 2014

ah! it's just slackbot: help, without @

@evansolomon
Copy link
Contributor

For whatever it's worth, "@[hubot's name]" works just fine.

I'm not sure if naming it the same as slackbot has any impact.

@bilke
Copy link
Author

bilke commented Feb 22, 2014

Never mind it works. I thought my bot is named hubot but in fact it is called slackbot.

@bilke bilke closed this as completed Feb 22, 2014
@trg
Copy link

trg commented Mar 5, 2014

I'm seeing the same issue. All my config vars are set, my Heroku server receives the webhook and prints "Incoming message received", but no response is provided to Slack that I am aware of.

Config:
HEROKU_URL:             http://<my app name>.herokuapp.com
HUBOT_SLACK_BOTNAME:    slackbot
HUBOT_SLACK_LINK_NAMES: 1
HUBOT_SLACK_TEAM:      <my team name>
HUBOT_SLACK_TOKEN:     <slack provided token>
REDISTOGO_URL:          <my redis url>
Procfile:
web: bin/hubot --adapter slack
Logs:
2014-03-05T14:50:43.185966+00:00 heroku[web.1]: Starting process with command `bin/hubot --adapter slack`
2014-03-05T14:50:44.948559+00:00 app[web.1]:   team: '<my team>',
2014-03-05T14:50:44.948559+00:00 app[web.1]:   name: 'slackbot',
2014-03-05T14:50:44.948559+00:00 app[web.1]:   mode: 'blacklist',
2014-03-05T14:50:44.948559+00:00 app[web.1]: Slack adapter options: { token: '<my token>',
2014-03-05T14:50:44.948559+00:00 app[web.1]:   channels: [],
2014-03-05T14:50:44.949373+00:00 app[web.1]: Successfully 'connected' as slackbot
2014-03-05T14:50:44.948559+00:00 app[web.1]:   link_names: '1' }

@Jacke
Copy link

Jacke commented Mar 8, 2014

Same thing,

2014-03-08T11:20:07.988965+00:00 app[web.1]: Incoming message received
2014-03-08T11:20:19.621164+00:00 heroku[router]: at=info method=POST path=/hubot/slack-webhook host=hidden-eyrie-5462.herokuapp.com request_id=80ea5890-7f0f-46ca-9813-bcfa75d34836 fwd="54.227.128.195" dyno=web.1 connect=2ms service=5ms status=200 bytes=135
2014-03-08T11:20:19.620222+00:00 app[web.1]: Incoming message received

And nothing, without reply. Name is correct, because he is getting message.

@evansolomon
Copy link
Contributor

What is the message you're sending? What Hubot scripts do you have running? Hubot doesn't just reply to every message (well, it could if you wanted...) so it would be helpful to get some more details.

@rajiv
Copy link

rajiv commented Apr 28, 2014

we're having a similar issue. the bot gets messages, but sends no replies. even to scripts we know were working in the past. simple ones like:

  robot.respond /time$/i, (msg) ->
    msg.send "Server time is: #{new Date()}"

@olliebun
Copy link

olliebun commented May 6, 2014

I'm having the same issue - I can see "incoming message received" when I run hubot: help in slack, but there's no response in slack. Is there an easy way to debug this?

@dhoulb
Copy link

dhoulb commented May 14, 2014

I'm having the same issue!

Pretty confident I've done everything right, and I'm seeing Incoming message received messages in Heroku, but Hubot never responds to any messages no matter how he's addressed. I've tried hubot help, slackbot help etc.

@johnke
Copy link

johnke commented May 21, 2014

Seeing the same issue here. Fresh install of Hubot (2.7.5)

$ ./bin/hubot --name slackbot
slackbot> slackbot help
slackbot> Events:
debug - {user: <user object to send message to>}
slackbot <user> doesn't have <role> role - Removes a role from a user
slackbot <user> has <role> role - Assigns a role to a user
slackbot <user> is a badass guitarist - assign a role to a user
slackbot <user> is not a badass guitarist - remove a role from a user
...

But with --adapter slack

$ ./bin/hubot --adapter slack --name slackbot
Slack adapter options: { token: 'XXXXX',
  team: 'XXX',
  name: 'slackbot',
  mode: 'blacklist',
  channels: [],
  link_names: 0 }
Successfully 'connected' as slackbot
Incoming message received
Incoming message received
Incoming message received

The three 'incoming message received' were me trying out slackbot help, slackbot: help and @slackbot help

@JoeStanton
Copy link

👍

1 similar comment
@aethernet
Copy link

+1

@evansolomon
Copy link
Contributor

Is it safe to assume you're all running this on some server is publicly accessible from a URL that you've configured with Slack?

@aethernet
Copy link

i deployed on heroku and set the url to slackbot, i've the same symptoms than ppl above, logs shows that it got my message, but it doensn't respond.

@evansolomon
Copy link
Contributor

Do the logs show that it's trying to send a message?

@aethernet
Copy link

no, and things are getting worse as i try to solve the problem :

2014-06-16T20:02:05.278358+00:00 app[web.1]: Successfully 'connected' as slackbot
2014-06-16T20:02:05.770450+00:00 heroku[web.1]: State changed from starting to up
2014-06-16T20:02:05.657129+00:00 app[web.1]: [Mon Jun 16 2014 20:02:05 GMT+0000 (UTC)] INFO Data for brain retrieved from Redis
2014-06-16T20:02:05.651878+00:00 app[web.1]: [Mon Jun 16 2014 20:02:05 GMT+0000 (UTC)] INFO Successfully authenticated to Redis
2014-06-16T20:02:02.859678+00:00 heroku[web.1]: Starting process with command bin/hubot --adapter slack --name slackbot
2014-06-16T20:02:04.392962+00:00 heroku[web.1]: Stopping all processes with SIGTERM
2014-06-16T20:02:06.857923+00:00 heroku[web.1]: Process exited with status 0

@evansolomon
Copy link
Contributor

I don't know much about the specifics of Heroku, but from reading those logs it looks like something is explicitly choosing to kill the process. The line "Stopping all processes with SIGTERM" sounds like something is deciding to terminate the hubot process, which then exits successfully.

@aethernet
Copy link

ok got it it was a double http:// in the url in slack :(

thanks for your time !

@sgimeno
Copy link

sgimeno commented Jun 17, 2014

Note that HUBOT_SLACK_BOTNAME env var prevails uppon -n Hubot parameter when booting your hubot instance. Maybe the incoming messages are only due to hear scripts but you are not correctly invoking your bot?

@chandlervdw
Copy link

@chayner how did you set up hubot to respond to ! as a prefix?

@chayner
Copy link
Contributor

chayner commented Jul 17, 2014

@chandlervdw: the prefix is determined by the -l option to hubot when it's started up. When deployed on heroku, the startup command is in Procfile in the root of the repo.

Ours for example is bin/hubot -a slack -n MrMcFeely -l !

@chandlervdw
Copy link

@chayner thanks! Do you have any insight into the fact that hubot-slack won't properly run all hubot-scripts?

@chayner
Copy link
Contributor

chayner commented Jul 24, 2014

@chandlervdw I don't, unfortunately, without a deep dive of troubleshooting. Sorry!

@pl1ght
Copy link

pl1ght commented Jul 28, 2014

Also having this same issue with what seems to be a properly configured bot. Works locally but once on #slack it just receives incoming message and nothing ever posts to #slack

@drstevens
Copy link

It would appear that I'm having same issue as most of the folks here.

2014-08-29T19:31:41.209630+00:00 heroku[api]: Scale to web=1 by davexxxxxxxxx@gmail.com
2014-08-29T19:31:44.118808+00:00 heroku[web.1]: Starting process with command `bin/hubot --adapter slack --name hubot`
2014-08-29T19:31:46.989352+00:00 app[web.1]: Slack adapter options: { token: 'xxxxxxxxxxxxxxx',
2014-08-29T19:31:46.989372+00:00 app[web.1]:   team: 'yyyyyyyyyyy',
2014-08-29T19:31:46.989374+00:00 app[web.1]:   name: 'hubot',
2014-08-29T19:31:46.989376+00:00 app[web.1]:   mode: 'blacklist',
2014-08-29T19:31:46.989377+00:00 app[web.1]:   channels: [],
2014-08-29T19:31:46.989379+00:00 app[web.1]:   link_names: 0 }
2014-08-29T19:31:46.994458+00:00 app[web.1]: Successfully 'connected' as hubot
2014-08-29T19:31:47.583068+00:00 heroku[web.1]: State changed from starting to up
2014-08-29T19:31:52.236043+00:00 heroku[router]: at=info method=POST path="/hubot/slack-webhook" host=intense-blahblah-12345 request_id=b411e3bb-fd7b-4d30-be9e-1d481ea289b7 fwd="184.73.118.141" dyno=web.1 connect=1ms service=14ms status=200 bytes=700
2014-08-29T19:31:52.229915+00:00 app[web.1]: Incoming message received
2014-08-29T19:32:00.609149+00:00 heroku[router]: at=info method=POST path="/hubot/slack-webhook" host=intense-blahblah-12345 request_id=c681ea90-86de-499c-98ef-a15b2d755444 fwd="54.89.68.28" dyno=web.1 connect=1ms service=4ms status=200 bytes=700
2014-08-29T19:32:00.607589+00:00 app[web.1]: Incoming message received
2014-08-29T19:32:06.565672+00:00 heroku[router]: at=info method=POST path="/hubot/slack-webhook" host=intense-blahblah-12345 request_id=e8cf1b45-4630-48a2-bff2-96447404ab70 fwd="54.80.201.34" dyno=web.1 connect=1ms service=13ms status=200 bytes=701
2014-08-29T19:32:06.551687+00:00 app[web.1]: Incoming message received

Messages are hubot help, hubot: help, @hubot help respectively. Team name and token in log above have been changed but I have triple checked that they are correct. I do get Successfully 'connected' as hubot in the log.

Dependencies from package.json, pretty barebones.

"dependencies": {
  "hubot":         "2.8.1",
  "coffee-script": "1.6.3",
  "express": "3.3.4",
  "hubot-slack": "2.1.1",
  "log": "1.4.0",
  "optparse": "1.0.4",
  "scoped-http-client": "0.9.8",
  "hubot-slack": "2.1.1"
}, 

I have also tried getting it to respond to slackbot to no avail using

heroku config:add HUBOT_SLACK_BOTNAME=slackbot

@pl1ght
Copy link

pl1ght commented Aug 29, 2014

FYI. I resolved my issue by following the direction exactly like they are in the README here on hubot-slack. I did not use a pre-installed hubot or anything. Start from a blank slate. Installing with the following is what fixed my issue with the no response to the channel from my hubot.
That being said, ive moved onto lita.io ruby based bot.

"npm install -g hubot coffee-script
hubot --create [path_name]
cd [path_name]
npm install hubot-slack --save"

@drstevens
Copy link

Cleaned my directory and started over and works now. Thanks.

@epinault
Copy link

Same issue for me.. Start from blank slate, I see "Incoming message received" but no response.

This use to work back in January when I first tried to set it up. Now it is somewhat broken...

I tried different Slackbot NAme also and the incoming Message always works with the correct name but I never get a response , even for the simple help... Any solutions?

I am using the following

  "name": "hosted-hubot",
  "version": "2.7.1",
  "private": true,
  "author": "GitHub Inc.",
  "keywords": [
    "github",
    "hubot",
    "campfire",
    "bot"
  ],
  "description": "A simple helpful robot for your Company",
  "licenses": [
    {
      "type": "MIT",
      "url": "https://github.com/github/hubot/raw/master/LICENSE"
    }
  ],
  "repository": {
    "type": "git",
    "url": "https://github.com/github/hubot.git"
  },
  "dependencies": {
    "hubot": ">= 2.6.0 < 3.0.0",
    "hubot-scripts": ">= 2.5.0 < 3.0.0",
    "hubot-slack": "^2.2.0"
  },
  "engines": {
    "node": ">= 0.8.x",
    "npm": ">= 1.1.x"
  }

and node 0.10.36

@epinault
Copy link

So I have been debugging for a while and found my token to be incorrect. now that I fixed it and it matches... (which would be nice to log for debugging purpose)... I still get no response but the following code is being called

        # Pass to the robot
        self.log "hello"
        self.receive new TextMessage(author, "help")

      # Just send back an empty reply, since our actual reply,
      # if any, will be async above
      res.end ""

So My guess is that reply never comes back or is not going to your endpoint properly? In the shell everything works properly.

@epinault
Copy link

Also the fact that I cannot see the message "@log "Sending message"" ever, seems like something is broken either in the expectation or in hubot itself?

@realdanielbyrne
Copy link

hubot hello doesn't work by default anymore, try hubot pug me if you installed from yo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests