jenkinsci / jenkinsci/github-branch-source-plugin
[JENKINS-73811] Ignore draft PRs for branch detection
- Dominant language
- Java
- Stars
- 217
- Forks
- 398
- Avg merge
- 30m
- Merged PRs (30d)
- 1
Description
Our Jenkins configuration to discover branches and PRs is as follow:
- branches: Exclude branches that are also filed as PRs
- PRs: Merging the pull request with the current target branch revision
- Ignore pull requests marked as drafts
We had one branch that also had a draft PR attached to it. This caused
- the branch to be ignored, as it has a PR
- the PR to be ignored as it is a draft
- The branch is not meant to be merged soon and has conflicts, thus converting it to non-draft is not an option
We resolved it by closing the PR. However, it would be nice if either:
"Ignore PRs marked as drafts" caues the "Exclude branches that are also filed as PRs" to ignore draft PRs
or
There would be a setting for branches "Exclude branches that have a ready to review PR".
Also: The Scan Repository Log could be improved. It just says that it is checking that branch, but not why it is ignoring it -> say something like "ignoring due to PR 42".
---
Originally reported by xomex, imported from: Ignore draft PRs for branch detection
Raw content of original issue
Our Jenkins configuration to discover branches and PRs is as follow:
- branches: Exclude branches that are also filed as PRs
- PRs: Merging the pull request with the current target branch revision
- Ignore pull requests marked as drafts
We had one branch that also had a draft PR attached to it. This caused
- the branch to be ignored, as it has a PR
- the PR to be ignored as it is a draft
- The branch is not meant to be merged soon and has conflicts, thus converting it to non-draft is not an option
We resolved it by closing the PR. However, it would be nice if either:
"Ignore PRs marked as drafts" caues the "Exclude branches that are also filed as PRs" to ignore draft PRs
or
There would be a setting for branches "Exclude branches that have a ready to review PR".
Also: The Scan Repository Log could be improved. It just says that it is checking that branch, but not why it is ignoring it -> say something like "ignoring due to PR 42".
Contributor guide
Assessment
This issue has not been assessed yet.