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

x/build/cmd/gerritbot: posts duplicate messages whenever Gerrit message IDs change #49467

Open
ianlancetaylor opened this issue Nov 8, 2021 · 1 comment
Labels
Builders NeedsInvestigation
Milestone

Comments

@ianlancetaylor
Copy link
Contributor

@ianlancetaylor ianlancetaylor commented Nov 8, 2021

Starting at about 08 Nov 2021 02:47:26 -0800 GerritBot sent a large number of duplicate comments. These were comments made in Gerrit on CLs imported into GitHub. Those comments has already been echoed back to the original GitHub pull requests. They were then duplicated on November 8. This affected more than 50 pull requests.

Some Sample GitHub pull requests showing the duplicate comments:

golang/debug#7 (the first one I found)
golang/sys#114
#44998
#29726
#44535 (the last one I found)

CC @golang/osp-team

@dmitshur
Copy link
Contributor

@dmitshur dmitshur commented Nov 8, 2021

From taking a brief look, a part of the cause seems to be originating from Gerrit: some change there caused message IDs on existing comments to become different, and that led to messages that gerritbot posted to be slightly different, and defeating it's de-duplication logic.

For example, these two GitHub comments:

  1. golang/build#37 (comment)
  2. golang/build#37 (comment)

Are both referring to Heschi's only comment in Gerrit on that CL, but the former's URL includes:

Visit [golang.org/cl/336511](https://go-review.googlesource.com/c/build/+/336511#message-212851e6ca26bb1c864f1e79ada86a8f8f5211c0).

While this morning's one has a different message ID:

Visit [golang.org/cl/336511](https://go-review.googlesource.com/c/build/+/336511#message-c61585b95b9aa13f9d1b62707afb294cee7a2119).

gerritbot's de-duplication algorithm can be improved, but this also means unless Gerrit IDs change again (hopefully not something that happens often) this type of issue shouldn't keep happening.

@dmitshur dmitshur changed the title GerritBot: many duplicate messages x/build/cmd/gerritbot: posts duplicate messages whenever Gerrit message IDs change Nov 8, 2021
@gopherbot gopherbot added the Builders label Nov 8, 2021
@gopherbot gopherbot added this to the Unreleased milestone Nov 8, 2021
@dmitshur dmitshur added the NeedsInvestigation label Nov 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Builders NeedsInvestigation
Projects
None yet
Development

No branches or pull requests

3 participants