Skip to content

docs(release): winget fails differently now — record the v0.9.0 evidence - #146

Merged
AThraen merged 1 commit into
mainfrom
docs/winget-failure-modes
Oct 1, 2026
Merged

AThraen merged 1 commit into
mainfrom
docs/winget-failure-modes

Conversation

@AThraen

@AThraen AThraen commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

Why

The winget section documented one error shape and two causes. Both are now fixed, and v0.9.0 failed a third way — so the existing text would have sent the next person chasing a stale fork that wasn't stale, or a token scope that was already correct.

What happened on v0.9.0 (2026-09-30)

The workflow's sync step succeeded. Submit then failed with:

0: Ref cannot be created.
1: failed to create branch UmageAI.CodeShellManager-0.9.0-<hash>

No user named, no mention of permissions — a different string from the documented AThraen does not have the correct permissions to execute CreateRef.

At the moment of failure the fork was behind upstream by exactly 5 commits: everything winget-pkgs landed in the 34 seconds between the sync (18:51:46) and the submit error (18:52:23). komac resolves upstream HEAD at submit time and branches from it, so a commit arriving inside that gap is one the fork does not have yet, and the ref cannot be created.

A hand merge-upstream (clean fast-forward to 0/0) plus an immediate re-dispatch succeeded with no other change — which is the evidence for the race rather than a guess.

What this records

  • The new error text beside the old one, and a table keyed on both the error string and whether the sync step passed. That pair separates all three causes at a glance, and it is what was missing.
  • That making the sync step non-continue-on-error is what made this diagnosable at all — its passing is what ruled out the two historical causes immediately.
  • The compare-direction gotcha. compare/master...microsoft:winget-pkgs:master puts the fork in base position, so ahead_by is upstream's lead over the fork. Read the natural way round it reports "5 ahead" for a fork that is 5 behind, and sends you hunting a divergence that doesn't exist. I misread it once before catching it, which is why it's written down.
  • The personal-fork question re-tested rather than re-asserted: AThraen/winget-pkgs was 19,108 commits behind and untouched since 2026-08-19, yet v0.7.0 and v0.8.0 both published fine in that window — so komac isn't using it. Marked settled so it stops being re-opened.
  • A line on the post-tag checklist that winget has needed manual help on three consecutive releases, each for a different reason, while Chocolatey has been reliable throughout.

Not done

The underlying fix is unchanged and still open: have CI create the Release with a PAT instead of GITHUB_TOKEN. That removes the manual dispatch and the sync→submit gap together. Flagged in the doc as worth doing before v1.0.

Docs only — no code, no build impact.

🤖 Generated with Claude Code

https://claude.ai/code/session_01NDsEfog5kVkT5NmX1Ya5be

The winget section described one failure shape and two causes, both of which
are now fixed. v0.9.0 failed a third way and the old text would have sent the
next person after a stale fork that wasn't stale, or a token scope that was
already correct.

What actually happened (2026-09-30): the workflow's sync step SUCCEEDED, and
submit then failed with "Ref cannot be created." — no user named, no mention
of permissions, which is a different string from the documented one. The fork
was behind upstream by exactly the 5 commits winget-pkgs landed in the 34
seconds between the sync (18:51:46) and the submit error (18:52:23). komac
resolves upstream HEAD at submit time and branches from it, so a commit that
arrives inside that gap is one the fork does not have yet. A hand
merge-upstream (clean fast-forward to 0/0) plus an immediate re-dispatch
succeeded with no other change.

Recorded:

- The new error text, next to the old one, and a table keyed on BOTH the
  error string and whether the sync step passed — that pair separates all
  three causes in one glance, which is the thing that was missing.
- That the sync step not being continue-on-error is what made this
  diagnosable: its passing is what ruled out the two historical causes.
- The compare-direction gotcha. `compare/master...microsoft:winget-pkgs:master`
  puts the fork in base position, so `ahead_by` is upstream's lead over the
  fork. Read the natural way round it reports "5 ahead" for a fork that is 5
  behind, and sends you looking for a divergence that does not exist. I
  misread it once before catching it.
- The personal-fork question, re-tested rather than re-asserted: it was 19,108
  commits behind and untouched since 2026-08-19, yet v0.7.0 and v0.8.0 both
  published fine in that window, so komac is not using it. Marked settled.
- A note on the post-tag checklist that winget has now needed manual help on
  three consecutive releases, each for a different reason, while Chocolatey
  has been reliable throughout.

The underlying fix for all of it is unchanged and still not done: have CI
create the Release with a PAT instead of GITHUB_TOKEN. That removes the manual
dispatch and the sync-to-submit gap together.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01NDsEfog5kVkT5NmX1Ya5be
@AThraen
AThraen merged commit 9c50f5e into main Oct 1, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant