Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-6484

ircbot sends command output to wrong irc user

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: ircbot-plugin
    • Labels:
      None
    • Environment:
      rhel 5.3 64-bit
      hudson 1.351
      im plugin 1.7
      irc plugin 2.3
    • Similar Issues:

      Description

      Sometimes the irc bot sends command output to the wrong irc user.

      For example, if I send the hudson bot the command "!help" (with ! being the command prefix), sometimes I get the output.

      But then, if another irc user sends the hudson bot the command "!help", then that other user might get the output, or I might get the output (incorrectly). I haven't been able to identify a pattern to when hudson gets it correct, versus incorrect.

        Attachments

          Activity

          Hide
          kutzi kutzi added a comment -

          Do you and the other user send the command at the same time?
          Otherwise, I couldn't imagine how this could happen.

          Show
          kutzi kutzi added a comment - Do you and the other user send the command at the same time? Otherwise, I couldn't imagine how this could happen.
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in hudson
          User: : kutzi
          Path:
          trunk/hudson/plugins/ircbot/src/main/java/hudson/plugins/ircbot/v2/PircConnection.java
          http://jenkins-ci.org/commit/30884
          Log:
          destroy input- and output-thread on disconnect. This could possibly fix JENKINS-6484

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in hudson User: : kutzi Path: trunk/hudson/plugins/ircbot/src/main/java/hudson/plugins/ircbot/v2/PircConnection.java http://jenkins-ci.org/commit/30884 Log: destroy input- and output-thread on disconnect. This could possibly fix JENKINS-6484
          Hide
          philsttr philsttr added a comment -

          No, usually it's not at the same time. Sometimes 30 mins will pass.

          For example, I will have issued a command, received my output, and closed my message window. Then 30 mins later, somebody else would message hudson, and then my message window will pop back up containing his output.

          Show
          philsttr philsttr added a comment - No, usually it's not at the same time. Sometimes 30 mins will pass. For example, I will have issued a command, received my output, and closed my message window. Then 30 mins later, somebody else would message hudson, and then my message window will pop back up containing his output.
          Hide
          kutzi kutzi added a comment -

          Where do you issue the command to the bot? In a chatroom or as a private message?

          When you get the output from the other user, does the other user also get the ouptut - i.e. is is duplicated - or do only you get the
          output?

          Show
          kutzi kutzi added a comment - Where do you issue the command to the bot? In a chatroom or as a private message? When you get the output from the other user, does the other user also get the ouptut - i.e. is is duplicated - or do only you get the output?
          Hide
          philsttr philsttr added a comment -

          Both people initiated the commands in a private message to the bot.

          The output is not duplicated. It only goes to one person.

          Show
          philsttr philsttr added a comment - Both people initiated the commands in a private message to the bot. The output is not duplicated. It only goes to one person.
          Hide
          kutzi kutzi added a comment -

          Can you try to issue some invalid commands - e.g. !status invalidjobname - and see what the bot sends as reply in case the output goes to the wrong user.
          It should ouptut:
          "<sender>: unknown job 'invalidjobname'"

          Show
          kutzi kutzi added a comment - Can you try to issue some invalid commands - e.g. !status invalidjobname - and see what the bot sends as reply in case the output goes to the wrong user. It should ouptut: "<sender>: unknown job 'invalidjobname'"
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in hudson
          User: : kutzi
          Path:
          trunk/hudson/plugins/ircbot/src/main/java/hudson/plugins/ircbot/v2/IRCConnection.java
          trunk/hudson/plugins/ircbot/src/main/java/hudson/plugins/ircbot/v2/IRCPrivateChat.java
          trunk/hudson/plugins/ircbot/src/main/java/hudson/plugins/ircbot/v2/PircConnection.java
          http://jenkins-ci.org/commit/30950
          Log:
          [FIXED JENKINS-6484] ircbot command output send to wrong user

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in hudson User: : kutzi Path: trunk/hudson/plugins/ircbot/src/main/java/hudson/plugins/ircbot/v2/IRCConnection.java trunk/hudson/plugins/ircbot/src/main/java/hudson/plugins/ircbot/v2/IRCPrivateChat.java trunk/hudson/plugins/ircbot/src/main/java/hudson/plugins/ircbot/v2/PircConnection.java http://jenkins-ci.org/commit/30950 Log: [FIXED JENKINS-6484] ircbot command output send to wrong user
          Hide
          kutzi kutzi added a comment -

          Yeah, I think I've found the bug. Seems that this was broken from the beginning, so thanks for pointing this out.

          It would be great if you could test that the attached snapshot build fixes your problem.

          Show
          kutzi kutzi added a comment - Yeah, I think I've found the bug. Seems that this was broken from the beginning, so thanks for pointing this out. It would be great if you could test that the attached snapshot build fixes your problem.
          Hide
          philsttr philsttr added a comment -

          Finally got a chance to try this. It looks like build you provided is working now. Thanks!

          Show
          philsttr philsttr added a comment - Finally got a chance to try this. It looks like build you provided is working now. Thanks!

            People

            • Assignee:
              kutzi kutzi
              Reporter:
              philsttr philsttr
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: