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/gopherbot: ignore versions in other paragraphs of backport requests #27489

Open
bcmills opened this issue Sep 4, 2018 · 6 comments
Open

Comments

@bcmills
Copy link
Member

@bcmills bcmills commented Sep 4, 2018

In #27486 (comment), I attempted to set up a backport issue for Go 1.11. However, apparently because I mentioned “from 1.9 or 1.10” in the justification, gopherbot constructed a backport issue for 1.10 too.

I think we should make gopherbot ignore versions that are separated from the first version in the comment by any punctuation other than a comma. (However, we should be careful not to stop after a period that appears as part of a version string.)

So, for example:
@gopherbot, p—— backport to Go 1.11: this is a regression from 1.9. should backport to 1.11 only.
@gopherbot, p—— backport to Go 1.11, and possibly 1.10: this is a bad runtime bug. should backport to both 1.11, 1.10.

(CC @FiloSottile )

@dmitshur
Copy link
Contributor

@dmitshur dmitshur commented Mar 4, 2020

As a simplification of this, it may be worth considering limiting the scope where gopherbot looks for requests to the paragraph where the 3 keywords are mentioned (@gopherbot, ple​ase, backport).

A comment can be split into separate paragraphs by looking for the sequence "\n\n". As an example, this comment has three paragraphs (not counting the edits at the bottom).

This would've been sufficient to help with #34878 (comment).

Edit: Another occurrence in #38122 (comment). The suggestion above would've also worked there.
Edit: One more occurrence in #39635 (comment). /cc @ianlancetaylor
Edit: Another in #44463.
Edit: Also would've worked for #44884.

@dmitshur
Copy link
Contributor

@dmitshur dmitshur commented Aug 24, 2020

See issue #41012 for another occurrence. /cc @toothrot @cagedmantis @andybons

Until this issue is resolved, one possible workaround is to embed a zero-width space (​) in Go versions that need to be mentioned but should not be considered for backport.

@bcmills
Copy link
Member Author

@bcmills bcmills commented Aug 24, 2020

one possible workaround is to insert a zero-width space

The difficult part of that is remembering to do it. 😉

@bcmills
Copy link
Member Author

@bcmills bcmills commented Mar 9, 2021

Tripped over this again in #44884.

@dmitshur
Copy link
Contributor

@dmitshur dmitshur commented Mar 9, 2021

The difficult part of that is remembering

separated from the first version in the comment by any punctuation other than a comma. (However, we should be careful not to stop after a period that appears as part of a version string.)

All that seems hard to remember. It looks like the suggestion in #27489 (comment) to split by paragraphs is easier to remember and works for almost all instances of this issue. I'll retitle the issue to be about that.

@dmitshur dmitshur changed the title x/build/cmd/gopherbot: ignore versions after hard punctuation in backport requests x/build/cmd/gopherbot: ignore versions in other paragraphs of backport requests Mar 9, 2021
@dmitshur dmitshur added this to Planned in Go Release Team Mar 9, 2021
@bcmills
Copy link
Member Author

@bcmills bcmills commented May 18, 2021

Another occurrence in #45332 (comment) (@jayconrod):

… Please backport to 1.16. We plan to revert to the 1.15 behavior.

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

Successfully merging a pull request may close this issue.

None yet
3 participants