Repository navigation
ci(sync-mirror): detect mirrored tags from the remote, not local clone - #41
Merged
Bjordis Collaku (bjordiscollaku) merged 1 commit intoJul 15, 2026
Merged
Conversation
The --single-branch mirror clone only holds tags reachable from the branch tip, so a rebased or divergent upload that was already mirrored is invisible locally. The missing-upload check used that local view, re-listed such uploads, and the atomic push then failed with "tag already exists", halting the sync. Judge "already mirrored" against the mirror's actual tags via git ls-remote --tags origin, matching the check-version gate in fetch-source-pkg.yml. Also guarantee the branch ends at the newest upload after the loop: a backfilled older upload or a prior partial run could otherwise leave the mirror HEAD behind the latest tag. Signed-off-by: Bjordis Collaku <bcollaku@qti.qualcomm.com>
Keerthi Gowda (keerthi-go)
approved these changes
Jul 15, 2026
Bjordis Collaku (bjordiscollaku)
deleted the
ci/fix-sync-mirror-tag-detection
branch
July 17, 2026 03:30
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 manual sync (
fetch-source-pkg.yml→sync-mirror.sh) failed at the atomicpush with
! [rejected] Ubuntu-qcom-7.0.0-1004.5 (already exists), halting the run.sync-mirror.shdecided which uploads were un-mirrored by checking the localclone's tags. That clone is
--single-branch, so it only holds tags reachable fromthe branch tip; a rebased or divergent upload that was already mirrored is invisible
locally. The script re-listed such uploads, and the atomic push was rejected because
the tag already exists on the remote. The halt also left the mirror branch moved
backward onto an older upload.
Fix
git ls-remote --tags origin, matching thecheck-versiongate infetch-source-pkg.yml. Only genuinely un-mirrored uploads are attempted.backfilled older upload or a prior partial run cannot leave the mirror HEAD behind
the latest tag.
Validation
Dispatched from this branch against the real mirror
(run 29296302725):
Uploads to mirror (ascending): 7.0.0-1008.11— only the genuinely-missing upload(previously it wrongly re-listed
1003.3 / 1004.5 / 1005.7).Sync complete: 1 upload(s) mirrored; branch now at 7.0.0-1008.11— the branchadvanced
1003.3 → 1008.11, healing the backward slip.trigger-builddispatched a build of1008.11.bash -nandshellcheckclean. Scripts only; no workflow changes.