ceph-pr-pipeline: fail conflicted PRs with a clear status - #2693
Open
djgalloway wants to merge 1 commit into
Open
ceph-pr-pipeline: fail conflicted PRs with a clear status#2693djgalloway wants to merge 1 commit into
djgalloway wants to merge 1 commit into
Conversation
GitHub does not publish refs/pull/N/merge for a PR with merge conflicts, so every leg's checkout died with "Couldn't find any revision to build" and left five cryptic red statuses (seen on build 45 for ceph/ceph#70703; the old GHPRB jobs had the same rough edge). prepare now checks pr_data.mergeable (retrying while GitHub computes it lazily, since a fetch right after a push usually returns null) and, for a conflicted PR, posts one plain-language error status on each applicable context -- "PR has merge conflicts; resolve and push to run CI" -- then stops before any leg runs. The post{failure} sweep stays quiet because no run flags were set yet. Signed-off-by: David Galloway <david.galloway@ibm.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up from live triage: build 45 (ceph/ceph#70703) failed all five legs with "Couldn't find any revision to build" because conflicted PRs have no refs/pull/N/merge on GitHub. prepare now checks .mergeable (with retries while GitHub computes it lazily) and posts a single clear error status per applicable context instead of letting every checkout crash. Takes effect on merge (Jenkinsfile is fetched from main per build).