Do not backport PRs closed ("merged") because of other PRs getting merged
- Dominant language
- Python
- Stars
- 10
- Forks
- 9
- PR merge metrics
- No merged PRs in 30d
Description
https://github.com/cupy/cupy/pull/8460#issuecomment-2273294843
> It seems that the backport tool does not cover this case: two PRs with `to-be-backported` label exist and one closed because of another one getting merged.
https://github.com/cupy/cupy/pull/8221 automatically closed as "merged" because https://github.com/cupy/cupy/pull/8412 got merged, which includes all commits from 8221.
This case can be detected by checking `merged_by` field from the pull-request API response. If it is `null` (like 8221), it indicates the PR was not merged but all commits in the PR got merged in another PR.
Contributor guide
No contributing guide indexed for this repository
Research direction
Start by tracing how the backport tool processes closed pull requests and reads the pull-request API response. Compare the `merged_by` value for PRs like 8221 and 8412, then verify that a closed PR with a null `merged_by` is not backported while a genuinely merged PR remains eligible.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100