Repository navigation
fix(ci): a merge racing Conda Update's push leaves the run green (#1649) - #1669
Merged
Merged
Conversation
- Push Changes rebases onto the tip it fetched and judged, so a merge landing between that fetch and the push had the push refused as a non-fast-forward, and the step failed: a red run on main. A failed push now re-fetches main. Moved to a commit without the bump in its history, the step writes pushed=false, emits a notice and exits 0, as main moving before the fetch does. - Main still at the judged tip (a declined push), the bump in main's history (a push that landed though git reported failure), or a failed re-fetch still fail the step with the push's exit status. test_a_merge_landing_after_the_fetch_refuses_the_push now expects pushed=false, the notice and exit 0, and fails against the old step. Four new tests run the real step against throwaway repos: a pre-receive hook declining, the remote lost after the fetch, and a push that lands but reports failure, with and without a merge over it. Each fails when its check is dropped from the step. Closes #1649
Owner
Author
|
Verdict: GOOD TO GO at It merges cleanly with |
Contributor
|
Coverage: 89.68% (unit tier, Python 3.14,
Per-file detail: the |
3 of 13 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.
Please follow the guide below
You will be asked some questions, please read them carefully and answer honestly
Put an
xinto all the boxes [ ] relevant to your pull request (like that [x])Use Preview tab to see how your pull request will actually look like
Searched for similar pull requests
Followed the coding style (
make pylint,make mypy,make isort)make testpasses, and a test case covers the changeAdded a changelog entry under
docs/source/changelog/and regeneratedCHANGELOG.md, if the change is user-visible — N/A — centralised in docs(changelog): shared 1.5.0 changelog — long-lived, merges last (#610, #616, #617, #618, #620) #657What is the purpose of your pull request?
Tick the commit type your subject line carries.
fix— corrects a defectfeat— adds a featureperf— changes performance, not behaviourrefactor— changes neither behaviour nor performancetest— tests onlydocs— documentation onlyci— workflows or build toolingrelease— bumps the version or rolls up a distributionchore— anything elseDescription of your pull request and other information
#1649. Push Changes rebases onto the tip it fetched and judged, so a merge landing between that fetch and the push had the push refused as a non-fast-forward, and the run went red. A failed push now re-fetches main (
.github/workflows/cron-conda.yml:268). If main has moved to a commit without the bump in its history (:270), the step writespushed=false, emits a::notice(:275) and exits 0, the same way main moving before the fetch ends. The step still fails with the push's exit status in three cases: main is still at the judged tip (a declined push), the bump is already in main's history (git reported a failure but the push landed), or the re-fetch fails.test_a_merge_landing_after_the_fetch_refuses_the_pushnow expects that ending and fails against the old step. Four new tests run the real step against throwaway repos: apre-receivehook declining the push, the remote lost after the fetch, and a push that lands but reports failure, with and without a merge on top. Each one fails when its check is dropped from the step.tests/project/test_release_gates.pypasses in full on 3.14 and 3.11 (119 tests).The hunk is all inside the Push Changes
run:script. Nopcapkit/file changes, so no engine's output changes.Closes #1649