bug(mirror): if: cut gate fires on non-cut push:main events (post-#319 empirical) #322
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
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
frankenbit/release-toolkit#322
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
Empirical anchor
After #319 merged (introducing the
mirrorjob in.forgejo/workflows/release.ymlgated on${{ needs.release.outputs.mode == 'cut' }}), the Forgejo Actions history shows 2×mirror: failureruns onsha=31970151e0a7332fc005ad6cd86fdc95ced9e997— the merge commit of #319 to main, which was a mode=update event (rolling PR update, not a cut).The mirror job should have been SKIPPED via the
if: needs.release.outputs.mode == 'cut'gate. Instead it fired + failed. The cut path itself worked cleanly (v0.25.0 shipped fine + Codeberg auto-mirror on the REAL cut commit97bb8076showsmirror: success), so the failure is dispatch-scope noise, not substrate-of-record corruption.Hypothesis
if:expressions differently on job-level workflow_call gating vs GitHub Actions equivalentsneeds.release.outputs.modemay resolve to empty string OR the literal${{ ... }}unevaluated on some evaluation paths, making the== 'cut'compare unexpectedlycontinue-on-error: truemay cause "failure" display even onskippedstate (unlikely — skipped ≠ failed in Actions)Investigation surface
sha=31970151— what did theif:evaluation see? What step failed?sha=97bb8076— how does the evaluation path differ?if:withneeds.<job>.outputsreferenceFix direction (post-diagnosis)
if:to something less ambiguouscontinue-on-error: true; but noise floor is a real cost)Priority
priority/lowsize/S— the substrate is behaviorally correct (real cut fires mirror clean; non-cut fires get warned but don't propagate). This is quality-of-workflow-status polish, not correctness. Don't gate v1.0.0 on it.Related
mirrorjob (this tracker's follow-up scope)2e68bus-catch (2026-07-03 12:46) — dispatcher surfaced the pre-cut noisebef7bus-flag (2026-07-03 12:42) — first-observation flagAnchor
Set I close, post-v0.25.0 first-live-exercise. Noise observed but doesn't gate the cut path.
Sharper diagnosis (Surveyor
c778, 2026-07-03)Original filing had two hypothesis gaps that Surveyor's Actions-task-list dive resolved:
The
2×is not a double-fire — it's the reusable-call representation. Auses:job in Forgejo Actions shows as caller-job "mirror" + the reusable's internal job "mirror" = 2 rows per invocation.Real finding: mirror runs on EVERY push:main; the
if: mode == 'cut'gate isn't filtering. Evidence: mirror ran on31970151(#319 merge, non-cut → FAILURE from empty TAG_NAME → Forgejo-fetch-fail) AND on97bb8076(rolling-PR push, non-cut → SUCCESS from idempotency-or-empty-PAT path).Hypothesis (unverified pending run-log): Forgejo Actions likely doesn't honor
needs.<reusable-call-job>.outputsin a job-levelif:the way GitHub does — soneeds.release.outputs.mode == 'cut'doesn't skip non-cuts.Fail-safe holds — this is noisy not dangerous. The tag-guard + Forgejo-fetch-fail path catch the empty-TAG case exactly as designed. Wrong-commit class stays closed; symptom is spurious workflow failures cluttering Actions on non-cut pushes.
Immediate mitigation (filed as follow-up PR): empty-TAG_NAME guard as FIRST check in the reusable workflow — Forgejo-agnostic script-level gate. Sidesteps the outputs-based gating question by not depending on it.
Broader question this tracker stays open on: does Forgejo Actions populate reusable-call outputs at all? If not, the outputs-based gating pattern needs revisiting repo-wide — but that's post-v1.0 investigation, not immediate.
Refs: Surveyor
c778Actions-task-list evidence (2026-07-03 12:49 post-v0.25.0-cut analysis), QMbef7first-flag, Bosun2e68dispatch to me for this filing.