fix(check): distinguish missing local build-ref tags #1291
No reviewers
Labels
No labels
bump
major
bump
minor
bump
patch
kind/bug
kind/chore
kind/docs
kind/feature
priority/critical
priority/high
priority/low
priority/medium
size/L
size/M
size/S
size/XL
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
frankenbit/release-toolkit!1291
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "i/1273-build-ref-diagnostic"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Scope
Refs #1273. This change only improves
rt build-ref-check's cannot-grade diagnostic when the requested tag is not present in the local clone.Contract
refs/tags/<ref>^{commit}before scanning canonical files.git fetch --tagsremedy.Evidence
Base:
c91e3bf1c5fc6f02abff5d2c195788842af00757Head:
3b2199c66d62902e44a7839d3c426c9140708f6eThe missing-tag control creates a real temporary Git repository with a commit and no tag. It exits 2 and asserts both
tag v0.59.0 is absent from this local cloneandgit fetch --tags; the resolvedv0.1.0control reportstag resolved locallybefore the zero-marker refusal.Mutation evidence: bypassing local-tag resolution makes the missing-tag control fail by entering the resolved-tree path; removing the fetch remedy makes the same control fail. Both mutations were applied and observed, then reverted.
Verification:
go test -count=1 ./...,go vet ./...,go build ./..., uncappedgolangci-lint, Bats165/165, ShellCheck,rt fragment-check changelog.d, andrt gitea-twin --check(11/11) all pass. The fragment check also reports its existing non-blocking warning onchangelog.d/1177.added.md.APPROVED at exact head
3b2199c66d.The resolver checks the explicit refs/tags namespace before scanning canonical files, so a missing local tag is a clear rc=2 cannot-grade result naming
git fetch --tags, rather than being reported as an old tagged tree with absent files. A resolved old tag retains its local-resolution diagnostic and existing zero-marker cannot-grade path. The real temporary-repository test asserts rc=2 plus both state and remedy text, including the CLI error; resolver-bypass and remedy-removal mutations were reported red. Full Go tests, focused tests, vet/build, Bats 165/165, and diff-check pass; Forgejo CI is terminal 28/28 green.