-
Notifications
You must be signed in to change notification settings - Fork 12k
build: exclude redundant cherry-picked commits when generating changelog #17050
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
Conversation
If generating a changelog between tags that are on different branches (e.g., 9.0.3 on 9.0.x and 9.1.0-next.0 on master), commits that were cherry-picked and present in the previous version would also show in the newer version's changelog. This update analyzes the commits and excludes any that fit this scenario. Any commits that had conflicts will not be able to be matched authoritatively. Manual review of the generated changelog may still be needed for attempted cherry-pick commits that had conflicts.
Typically when I cherry-pick commits I include the Assuming caretakers always add Could we compare these "authoritative" hashes to identify the new commits and generate a changelog from that set? |
The |
Not true, I just had this happen while merging #17040. I did a I would imagine there's a way to put a restriction on release branches that they must contain the |
The documentation for the option says it doesn't (https://git-scm.com/docs/git-cherry-pick) so I'm not sure we should rely on the behavior. But we could augment the check to also try to find the text and analyze the referenced commit if no initial match is found. This doesn't cover the case where separate PRs are created due to the conflicts though. From my manual review of 9.1.0-next.0, this was the more common case. |
Interesting that |
Yes. I agree, I was hoping it would be more useful especially since I noticed you started using it when cherry-picking. |
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
If generating a changelog between tags that are on different branches (e.g., 9.0.3 on 9.0.x and 9.1.0-next.0 on master), commits that were cherry-picked and present in the previous version would also show in the newer version's changelog. This update analyzes the commits and excludes any that fit this scenario. Any commits that had conflicts will not be able to be matched authoritatively. Manual review of the generated changelog may still be needed for attempted cherry-pick commits that had conflicts.