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

Already on GitHub? Sign in to your account

Hubot entering infinite loop on issue search in FlowDock #422

Merged
merged 1 commit into from May 17, 2012

Conversation

Projects
None yet
4 participants
Contributor

christianmarth commented May 17, 2012

Had issues with hubot entering an infinite loop when responding to an issue search, even when setting HUBOT_JIRA_IGNOREUSERS and HUBOT_JIRA_ISSUEDELAY

Issue search changed from robot.hear to robot.respond
Had issues with hubot entering an infinite loop when responding to an issue search

tombell added a commit that referenced this pull request May 17, 2012

Merge pull request #422 from cloudgroup/master
Hubot entering infinite loop on issue search in FlowDock

@tombell tombell merged commit 44c598d into github:master May 17, 2012

Contributor

gregmac commented on 4c82425 Jun 19, 2012

This is 98% of the reason I use this plugin. Let's fix the issue with the loop, not cripple the bot. This commit needs to be reverted.

Can you reliably repo the problem? I am guessing if msg.message.user.id is robot.name return is supposed to prevent that, but I am pretty sure that condition will never be true (maybe it depends on the adapter?)

Contributor

tombell replied Jun 19, 2012

user.id is not always the same as robot.name. Hence why it can go into infinite loops. For example our hubot is called Sir Hubot in Campfire, and his robot.name is hubot.

Contributor

gregmac replied Jun 19, 2012

I added ignoredusers support and that just uses msg.message.user.name .. so:

  1. workaround is to add the robot's name to HUBOT_JIRA_IGNOREUSERS env variable
  2. changing that line to if msg.message.user.name is robot.name will likely fix the original issue, unless that acts differently with different adapters.. anyone know?
Contributor

christianmarth replied Jun 20, 2012

Have tested changing to if msg.message.user.name is robot.name and change back to robot.hear and this is working fine now on the Flowdock adapter,

Sometimes i get hu responding with the same issue twice but this is not a deal breaker and is much better than an infinite loop

Contributor

tombell replied Jun 20, 2012

You cannot reliably use robot.name to check against the name of the user who sends the message. Because they're not always the same for hubot.

Mange replied Sep 9, 2013

This should still be reverted; or have the documentation changed. I tried to get it to work, all in vain. The "recent issues" code should also fix this problem; it will not respond to issues mentioned the last 30 seconds again.

amaltson pushed a commit to amaltson/hubot-scripts that referenced this pull request Jan 7, 2013

Merge pull request #422 from cloudgroup/master
Hubot entering infinite loop on issue search in FlowDock
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment