Repository navigation
fix(sync): land a re-pin as the candidate its checks passed on - #185
Merged
Merged
Conversation
A re-pin rewrites the line, so no pull-request merge method can land it, and the sync force-pushed the line directly: the required checks never ran on the head that landed. The re-pin now pushes its candidate to sync/<date>-<pin>, whose push runs the line's suites, and opens a pull request against the line; a separate land dispatch pushes exactly that head once run-tests and govulncheck passed on it, onto the line head it was replayed from, and closes the pull request. A line input runs the same flow for a maintenance line.
The pin lookup dropped every tag with a hyphen, so on a line pinned to an upstream prerelease it found no pin and every run failed. Take the nearest reachable upstream tag by commit distance instead of the highest by version.
2 tasks
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.
Problem
The re-pin of the line landed on the default branch as a force-push of its head (#119), so the required checks never ran on the commit that landed. A re-pin rewrites the line: the old line head is not an ancestor of the re-pinned one, so a pull request cannot land it with any merge method. A rebase merge replays upstream's commits onto the old line and conflicts at the second one.
Change
sync-upstreamre-pin: pushes the candidate tosync/<date>-<pin>. That push runspr-workflow(run-tests),helm-e2eandgovulncheckon its head. The run then opens a pull request against the line listing the replayed patches and recording the line head it was replayed from. A conflicting replay still yields a hand-over candidate, finished by hand on the same branch.sync-upstreamland: refuses a candidate whoserun-testsorgovulncheckdid not pass on its head, or whose recorded line head is no longer the line's. Otherwise it pushes exactly that head to the line (lease on the line head) and closes the pull request. No merge and nodevctl pr mergefor a re-pin.lineinput: the same flow for a maintenance line (release-1.3).The branch protection that refuses a push to the line whose head has not passed the required checks, for every actor, is a separate change to the repository's declared rulesets (part of #163).
Proof
A
dry_rundispatch of the workflow from this branch, recorded on #163.Written by an agent.