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

1:1 works well, but not room. #246

Open
hueidou opened this issue May 19, 2015 · 15 comments
Open

1:1 works well, but not room. #246

hueidou opened this issue May 19, 2015 · 15 comments

Comments

@hueidou
Copy link

hueidou commented May 19, 2015

Robot have sent message, but room not received. 1:1 works well.

command:

@hubot time
hubot time

message:

[Tue May 19 2015 12:36:12 GMT+0800 (China Standard Time)] DEBUG  OUT > 
<message to="[email protected]" type="chat" from="[email protected]
.com/hubot-hipchat"><inactive xmlns="http://jabber/protocol/chatstates"/><body>S
erver time is: Tue May 19 2015 12:36:12 GMT+0800 (China Standard Time)</body>
</message>

env(Windows):

set [email protected]
set HUBOT_HIPCHAT_PASSWORD=mysecret
set [email protected]

set HUBOT_HIPCHAT_HOST=chat.hipchat.com
set HUBOT_HIPCHAT_XMPP_DOMAIN=conf.hipchat.com

set HUBOT_LOG_LEVEL=debug
set PORT=8081
@ghost
Copy link

ghost commented May 30, 2015

I'm having the same issue, it seems. Did you ever figure it out, @hueidou?

@VvanGemert
Copy link

I've had the same issue and got it working with the following ENV variables:

export HUBOT_HIPCHAT_JID="[email protected]"
export HUBOT_HIPCHAT_PASSWORD="password"
export HUBOT_LOG_LEVEL="debug"
export HUBOT_HIPCHAT_ROOMS="[email protected]"
export HUBOT_HIPCHAT_NAME="botname"
export HUBOT_HIPCHAT_HOST="chat.hipchat.com"
# export HUBOT_HIPCHAT_XMPP_DOMAIN="btf.hipchat.com"

Notice I'm not setting the XMPP domain.

@hueidou
Copy link
Author

hueidou commented Jun 3, 2015

Thanks, @VvanGemert, but not worked for my bot. Maybe I need rebuild my bot in a new environment.

@hueidou
Copy link
Author

hueidou commented Jun 3, 2015

@MyriadTruths, no idea, I will rebuild it.

@VvanGemert
Copy link

I've installed hubot with the yo generator. Here's my package.json file, maybe you'll find it useful:

{
  "name": "hubot",
  "version": "0.0.0",
  "private": true,
  "author": "Test <[email protected]>",
  "description": "A simple helpful robot for your Company",
  "dependencies": {
    "hubot": "^2.12.0",
    "hubot-diagnostics": "0.0.1",
    "hubot-google-images": "^0.1.4",
    "hubot-google-translate": "^0.1.0",
    "hubot-help": "^0.1.1",
    "hubot-hipchat": "^2.12.0-5",
    "hubot-maps": "0.0.2",
    "hubot-pugme": "^0.1.0",
    "hubot-redis-brain": "0.0.2",
    "hubot-rules": "^0.1.0",
    "hubot-scripts": "^2.5.16",
    "hubot-shipit": "^0.2.0",
    "hubot-youtube": "^0.1.2"
  },
  "engines": {
    "node": "0.10.x"
  }
}

@mspiegle
Copy link

If you have a private/corporate installation of HipChat, the following may work for you:

export HUBOT_HIPCHAT_JID='[email protected]'
export HUBOT_HIPCHAT_PASSWORD='password'
export HUBOT_HIPCHAT_ROOMS='#[email protected]'
export HUBOT_HIPCHAT_JOIN_PUBLIC_ROOMS='false'
export HUBOT_HIPCHAT_HOST='your.hipchat.server'
export HUBOT_HIPCHAT_XMPP_DOMAIN='btf.hipchat.com'

@mnapoleon
Copy link

anyone get past this issue? I've got the same thing where the bot answers in 1-1room but ignores me in a room. The log indicates the message was received but nothing ever gets to the room.

@alandwarinasia
Copy link

I got mine working, but I'm not 100% certain what I did to fix it -- I believe it was to do with the config variables. Here are mine:

BUILDPACK_URL=https://github.com/heroku/heroku-buildpack-nodejs
HEROKU_URL=http://botaddress.heroku.com
HUBOT_HEROKU_KEEPALIVE_URL=http://botaddress.heroku.com
HUBOT_HIPCHAT_JID=#####@chat.hipchat.com
HUBOT_HIPCHAT_JOIN_PUBLIC_ROOMS=true
HUBOT_HIPCHAT_JOIN_ROOMS_ON_INVITE=true
HUBOT_HIPCHAT_PASSWORD=botshipchatpassword
HUBOT_HIPCHAT_RECONNECT=true
[email protected],[email protected]
HUBOT_LOG_LEVEL=debug

@udl
Copy link

udl commented Sep 4, 2015

also worked for me on heroku when unsetting HUBOT_HIPCHAT_XMPP_DOMAIN

@alessandro-aglietti
Copy link

also worked for me outside heroku when unsetting HUBOT_HIPCHAT_XMPP_DOMAIN

@cheddarwhizzy
Copy link

I'm also having this same issue. I've tried unsetting HUBOT_HIPCHAT_XMPP_DOMAIN, setting all the vars, and trying the package.json file above. No luck :-\

@cheddarwhizzy
Copy link

Okay, my issue was that I was using a personal account to log in. After creating a 'hubot' Hipchat account, he started responding to my @hubot mentions. Maybe this should be a feature request.. To be able to do '@anyBotName ping' and have it work.

@fenneh
Copy link

fenneh commented Dec 24, 2015

Just to add to this, I've experienced the same issues. Running hubot internally with an internal hipchat instance.

1:1's worked, channels didn't

That's until saying "ship it" in a channel and then suddenly Hubot came to life and started responding to channel commands.

@blaskovicz
Copy link

I was able to get hubot to respond to public rooms! I was having the same symptom others reported of only 1-on-1 responses working.

The big things that worked for me were:

  • Unsetting HUBOT_HIPCHAT_XMPP_DOMAIN
  • Setting HUBOT_HIPCHAT_ROOMS to @All
  • Setting HUBOT_HIPCHAT_RECONNECT to true
  • Setting HUBOT_HIPCHAT_PASSWORD to the hubot user's password
  • Setting HUBOT_HIPCHAT_JID to the hubot user's JID
  • Setting HUBOT_HIPCHAT_JOIN_ROOMS_ON_INVITE to true
  • Setting HUBOT_HIPCHAT_JOIN_PUBLIC_ROOMS to true
  • (for debugging) Setting HUBOT_LOG_LEVEL to debug
  • The following in package.jsona
    • "hubot": "2.9.3"
    • "hubot-hipchat": "^2.12.0-6"
    • "hubot-scripts": "2.5.13"
  • In hubot-scripts.json
    • (among other things) redis-brain.coffee

Looking at the code, most of the variables that @alandwarinasia set to true are enabled by default.
From the hubot-hipchat node module version I have, here are some of the defaults:

      jid: process.env.HUBOT_HIPCHAT_JID
      password: process.env.HUBOT_HIPCHAT_PASSWORD
      token: process.env.HUBOT_HIPCHAT_TOKEN or null
      rooms: process.env.HUBOT_HIPCHAT_ROOMS or "All"
      rooms_blacklist: process.env.HUBOT_HIPCHAT_ROOMS_BLACKLIST or ""
      rooms_join_public: process.env.HUBOT_HIPCHAT_JOIN_PUBLIC_ROOMS isnt "false"
      host: process.env.HUBOT_HIPCHAT_HOST or null
      bosh: { url: process.env.HUBOT_HIPCHAT_BOSH_URL or null }
      autojoin: process.env.HUBOT_HIPCHAT_JOIN_ROOMS_ON_INVITE isnt "false"
      xmppDomain: process.env.HUBOT_HIPCHAT_XMPP_DOMAIN or null
      reconnect: process.env.HUBOT_HIPCHAT_RECONNECT isnt "false"

@digrich
Copy link

digrich commented Feb 22, 2017

I am also experiencing the same issue, hubot is answering, but room is not receiving any message. 1-1 chat is working fine. I tried almost all solutions suggested in this thread but none of them seems to be working. Did anyone try something different to make this work?

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