deployed to Heroku, bot doesn't join Campfire room #352

Closed
andreivolt opened this Issue Sep 25, 2012 · 17 comments

Comments

Projects
None yet
6 participants
@andreivolt

I've followed the "Deploying Hubot onto Heroku" guide, and, despite no obvious errors in the logs, the bot doesn't show up in the configured Campfire room. Yes, I've set up all the required env vars.

How can I debug such an issue?

@drnic

This comment has been minimized.

Show comment
Hide comment
@drnic

drnic Sep 28, 2012

I have this same issue, though I deployed to a Unix machine. No errors appear in logs (they do if the credentials are wrong), but the bot doesn't appear in the room. I'm on a free Campfire account, which should allow 4 users.

drnic commented Sep 28, 2012

I have this same issue, though I deployed to a Unix machine. No errors appear in logs (they do if the credentials are wrong), but the bot doesn't appear in the room. I'm on a free Campfire account, which should allow 4 users.

@atmos

This comment has been minimized.

Show comment
Hide comment
@atmos

atmos Sep 28, 2012

Contributor

It can be kinda confusing if you're using the same user as yourself where you won't actually see any messages. Is this happening here or are you using a different user?

Contributor

atmos commented Sep 28, 2012

It can be kinda confusing if you're using the same user as yourself where you won't actually see any messages. Is this happening here or are you using a different user?

@drnic

This comment has been minimized.

Show comment
Hide comment
@drnic

drnic Sep 28, 2012

OOOOOhhh, I completely didn't think to create a new Campfire user and use
its token. I feel silly right now.

On Fri, Sep 28, 2012 at 2:55 PM, Corey Donohoe notifications@github.comwrote:

It can be kinda confusing if you're using the same user as yourself where
you won't actually see any messages. Is this happening here or are you
using a different user?


Reply to this email directly or view it on GitHubhttps://github.com/github/hubot/issues/352#issuecomment-8996473.

drnic commented Sep 28, 2012

OOOOOhhh, I completely didn't think to create a new Campfire user and use
its token. I feel silly right now.

On Fri, Sep 28, 2012 at 2:55 PM, Corey Donohoe notifications@github.comwrote:

It can be kinda confusing if you're using the same user as yourself where
you won't actually see any messages. Is this happening here or are you
using a different user?


Reply to this email directly or view it on GitHubhttps://github.com/github/hubot/issues/352#issuecomment-8996473.

@drnic

This comment has been minimized.

Show comment
Hide comment
@drnic

drnic Sep 29, 2012

Screenshot

Hubot is now pleasantly joining the room, but not responding to requests. Nothing mentioned in the logs. The hubot CLI works as expected.

Thoughts on how to debug?

drnic commented Sep 29, 2012

Screenshot

Hubot is now pleasantly joining the room, but not responding to requests. Nothing mentioned in the logs. The hubot CLI works as expected.

Thoughts on how to debug?

@drnic

This comment has been minimized.

Show comment
Hide comment
@drnic

drnic Sep 29, 2012

It's being run as follows:

node /var/vcap/packages/node08/bin/coffee /var/vcap/packages/hubot/bin/hubot --name hubot --adapter campfire --alias /

drnic commented Sep 29, 2012

It's being run as follows:

node /var/vcap/packages/node08/bin/coffee /var/vcap/packages/hubot/bin/hubot --name hubot --adapter campfire --alias /
@drnic

This comment has been minimized.

Show comment
Hide comment
@drnic

drnic Sep 29, 2012

Technically, its being run by monit as exec hubot --name $HUBOT_USER --adapter $HUBOT_ADAPTER --alias '/' but looks like it expands out as above.

Nonetheless, the bot runs. Yay. But it is a quiet bot. A less useful bot.

drnic commented Sep 29, 2012

Technically, its being run by monit as exec hubot --name $HUBOT_USER --adapter $HUBOT_ADAPTER --alias '/' but looks like it expands out as above.

Nonetheless, the bot runs. Yay. But it is a quiet bot. A less useful bot.

@drnic

This comment has been minimized.

Show comment
Hide comment
@drnic

drnic Sep 29, 2012

Oh, New Skitch, why do you hate so much.

drnic commented Sep 29, 2012

Oh, New Skitch, why do you hate so much.

@atmos

This comment has been minimized.

Show comment
Hide comment
@atmos

atmos Sep 29, 2012

Contributor

Yeah. The other gotcha is not specifying names correctly. /ping etc should work properly. I have two hubots online for different orgs, what version are you running in your package.json file?

Contributor

atmos commented Sep 29, 2012

Yeah. The other gotcha is not specifying names correctly. /ping etc should work properly. I have two hubots online for different orgs, what version are you running in your package.json file?

@laurentkempe

This comment has been minimized.

Show comment
Hide comment
@laurentkempe

laurentkempe Sep 29, 2012

I had the same issue using Jabbr adapater and it looks like the -a parameter is not correctly read when lauching hubot.

So I went into hubot/bin/hubot and change

Options =
adapter: "shell"

to

Options =
adapter: "jabbr"

And then hubot could connect to Jabbr again.

I had the same issue using Jabbr adapater and it looks like the -a parameter is not correctly read when lauching hubot.

So I went into hubot/bin/hubot and change

Options =
adapter: "shell"

to

Options =
adapter: "jabbr"

And then hubot could connect to Jabbr again.

@drnic

This comment has been minimized.

Show comment
Hide comment
@drnic

drnic Oct 1, 2012

@atmos

{
  "name":        "hubot",
  "version":     "2.3.4",
  "author":      "hubot",
  "keywords":    "github hubot campfire bot",
  "description": "A simple helpful Robot for your Company",
  "licenses":     [{
    "type":       "MIT",
    "url":        "http://github.com/github/hubot/raw/master/LICENSE"
  }],

  "repository" : {
    "type": "git",
    "url":  "https://github.com/github/hubot.git"
  },

  "dependencies": {
    "coffee-script": "1.3.3",
    "optparse": "1.0.3",
    "scoped-http-client": "0.9.7",
    "log": "1.3.0",
    "connect": "2.3.4",
    "connect_router": "1.8.6"
  },

  "main": "./index",

  "bin": {
    "hubot": "./bin/hubot"
  }
}

@laurentkempe a quick read of the code and I can't see why the -a/--adapter flag wouldn't be working; but I'll try hard coding it.

drnic commented Oct 1, 2012

@atmos

{
  "name":        "hubot",
  "version":     "2.3.4",
  "author":      "hubot",
  "keywords":    "github hubot campfire bot",
  "description": "A simple helpful Robot for your Company",
  "licenses":     [{
    "type":       "MIT",
    "url":        "http://github.com/github/hubot/raw/master/LICENSE"
  }],

  "repository" : {
    "type": "git",
    "url":  "https://github.com/github/hubot.git"
  },

  "dependencies": {
    "coffee-script": "1.3.3",
    "optparse": "1.0.3",
    "scoped-http-client": "0.9.7",
    "log": "1.3.0",
    "connect": "2.3.4",
    "connect_router": "1.8.6"
  },

  "main": "./index",

  "bin": {
    "hubot": "./bin/hubot"
  }
}

@laurentkempe a quick read of the code and I can't see why the -a/--adapter flag wouldn't be working; but I'll try hard coding it.

@drnic

This comment has been minimized.

Show comment
Hide comment
@drnic

drnic Oct 1, 2012

@laurentkempe forcing campfire do not change the behavior - Hubot still logs into campfire and isn't responding to commands.

I'll have to look at how to add some debugging into the source this week. Or can someone with a working hubot paste in their working set of npm packages?

drnic commented Oct 1, 2012

@laurentkempe forcing campfire do not change the behavior - Hubot still logs into campfire and isn't responding to commands.

I'll have to look at how to add some debugging into the source this week. Or can someone with a working hubot paste in their working set of npm packages?

@laurentkempe

This comment has been minimized.

Show comment
Hide comment
@laurentkempe

laurentkempe Oct 1, 2012

@drnic I couldn't find neither why the flag wasn't working. In my case the adapter wasn't considered even with the -a/--adapter.

My package.json is slightly different then yours but the dependencies are the same with same version.

{
  "name": "hubot",
  "version": "2.3.4",
  "author": {
    "name": "hubot"
  },
  "keywords": "github hubot campfire bot",
  "description": "A simple helpful Robot for your Company",
  "licenses": [
    {
      "type": "MIT",
      "url": "http://github.com/github/hubot/raw/master/LICENSE"
    }
  ],
  "repository": {
    "type": "git",
    "url": "https://github.com/github/hubot.git"
  },
  "dependencies": {
    "coffee-script": "1.3.3",
    "optparse": "1.0.3",
    "scoped-http-client": "0.9.7",
    "log": "1.3.0",
    "connect": "2.3.4",
    "connect_router": "1.8.6"
  },
  "main": "./index",
  "bin": {
    "hubot": "./bin/hubot"
  },
  "readme": "# Hubot\n\nThis is a version of ...",
  "_id": "hubot@2.3.4",
  "_from": "hubot"
}

I just cut down the readme part

@drnic I couldn't find neither why the flag wasn't working. In my case the adapter wasn't considered even with the -a/--adapter.

My package.json is slightly different then yours but the dependencies are the same with same version.

{
  "name": "hubot",
  "version": "2.3.4",
  "author": {
    "name": "hubot"
  },
  "keywords": "github hubot campfire bot",
  "description": "A simple helpful Robot for your Company",
  "licenses": [
    {
      "type": "MIT",
      "url": "http://github.com/github/hubot/raw/master/LICENSE"
    }
  ],
  "repository": {
    "type": "git",
    "url": "https://github.com/github/hubot.git"
  },
  "dependencies": {
    "coffee-script": "1.3.3",
    "optparse": "1.0.3",
    "scoped-http-client": "0.9.7",
    "log": "1.3.0",
    "connect": "2.3.4",
    "connect_router": "1.8.6"
  },
  "main": "./index",
  "bin": {
    "hubot": "./bin/hubot"
  },
  "readme": "# Hubot\n\nThis is a version of ...",
  "_id": "hubot@2.3.4",
  "_from": "hubot"
}

I just cut down the readme part

@atmos

This comment has been minimized.

Show comment
Hide comment
@atmos

atmos Oct 1, 2012

Contributor

Usually the hubot help command is beneficial to see if it's a campfire name clash that's messing things up.

Is your procfile specifying the name that matches up with the actual campfire username?

~/p/phes-hubot(master)$ cat Procfile app: bin/hubot -a campfire -n Hubot -l '/'

Fwiw I was able to upgrade my hubot from 2.1 to 2.3.4 without noticing anything other than coffee-script deprecation warnings.

Contributor

atmos commented Oct 1, 2012

Usually the hubot help command is beneficial to see if it's a campfire name clash that's messing things up.

Is your procfile specifying the name that matches up with the actual campfire username?

~/p/phes-hubot(master)$ cat Procfile app: bin/hubot -a campfire -n Hubot -l '/'

Fwiw I was able to upgrade my hubot from 2.1 to 2.3.4 without noticing anything other than coffee-script deprecation warnings.

@atmos

This comment has been minimized.

Show comment
Hide comment
@atmos

atmos Oct 1, 2012

Contributor

Using the script here, https://gist.github.com/3810246. You should be able to double check the name that's being used. I think you guys are probably using clones of this repo when you should be using the output of make package or a tagged version like https://github.com/downloads/github/hubot/hubot-2.2.0.tar.gz which sadly still points to 2.2.0. :P

Contributor

atmos commented Oct 1, 2012

Using the script here, https://gist.github.com/3810246. You should be able to double check the name that's being used. I think you guys are probably using clones of this repo when you should be using the output of make package or a tagged version like https://github.com/downloads/github/hubot/hubot-2.2.0.tar.gz which sadly still points to 2.2.0. :P

@parkr

This comment has been minimized.

Show comment
Hide comment
@parkr

parkr Dec 3, 2012

Contributor

I'm having a similar-ish issue over at #372.
What port is hubot using to communicate? Does heroku allow it?

Contributor

parkr commented Dec 3, 2012

I'm having a similar-ish issue over at #372.
What port is hubot using to communicate? Does heroku allow it?

@tombell

This comment has been minimized.

Show comment
Hide comment
@tombell

tombell Jan 10, 2013

Contributor

If you don't specify a hubot name it's Hubot by default and is case-sensitive.

Contributor

tombell commented Jan 10, 2013

If you don't specify a hubot name it's Hubot by default and is case-sensitive.

@tombell tombell closed this Jan 10, 2013

@tombell tombell reopened this Jan 10, 2013

@tombell

This comment has been minimized.

Show comment
Hide comment
@tombell

tombell Jan 10, 2013

Contributor

Also from looking at these package.json examples, you're running the hubot directly from the code in this repo. It might be easier to use bin/hubot --create ~/myhubot to create a deployable hubot.

Contributor

tombell commented Jan 10, 2013

Also from looking at these package.json examples, you're running the hubot directly from the code in this repo. It might be easier to use bin/hubot --create ~/myhubot to create a deployable hubot.

@tombell tombell closed this Jan 12, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment