Make the workflow_dispatch publish path actually publish - #566
Merged
ChrisonSimtian merged 1 commit intoJul 26, 2026
Conversation
Every job downstream of test-and-pack was unreachable on a workflow_dispatch
run, so the manual path — the documented way to publish to nuget.org, and the
documented way to retry a partial publish — silently published nothing while
reporting success. Two independent causes:
validate-ref is skipped by design on workflow_dispatch (`if: event_name ==
'push'`), and a skipped job propagates through the dependency graph.
test-and-pack survives that with `always()`, but that rescues only itself: its
own dependents still saw a skipped ancestor and were skipped too. This hit all
three publish jobs, including the two that carry no condition of their own.
Separately, the nuget.org opt-in compared `inputs.publish-to-nugetorg == true`.
A `type: boolean` input is only a real boolean when the run starts from the
Actions UI; the REST API can only send strings, and `gh workflow run` rejects a
JSON boolean outright. Comparing a string to a boolean casts both to numbers
('true' → NaN, true → 1), so the opt-in never matched from the CLI — including
the exact invocation in docs/branching-and-release.md.
Both fixed: the publish jobs gate on `always() && needs.test-and-pack.result ==
'success'`, and the opt-in accepts the string as well as the boolean. Tag-push
behaviour is unchanged — validate-ref still gates it, and nuget.org still needs
both the flag and the environment approval.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This was referenced Jul 29, 2026
This was referenced Aug 7, 2026
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.
The
workflow_dispatchpath onpublish-packages-release.ymlcould never publish anything. It is the documented way to publish to nuget.org and the documented way to retry a partial publish — both silently did nothing while the run reported success.Found while publishing
v10.4.0-rc.4: run 30202826208 showstest + pack: successwith all three publish jobsskipped, and a green overall conclusion.Two independent causes
1. Skip propagation.
validate-refis skipped by design onworkflow_dispatch(if: github.event_name == 'push'), and a skipped job propagates through the dependency graph.test-and-packsurvives withalways()— but that rescues only itself; its dependents still saw a skipped ancestor. This is whypublish-github-packagesandpublish-github-releasesskipped despite carrying no condition at all, which is the part that makes the failure so quiet.2. The boolean compare. The opt-in was
inputs.publish-to-nugetorg == true. Atype: booleaninput is only a real boolean when the run starts from the Actions UI; the REST API can only send strings, andgh workflow runrejects a JSON boolean outright (cannot unmarshal bool into Go value of type string). Comparing a string to a boolean casts both to numbers —'true'→ NaN,true→ 1 — so the opt-in never matched from the CLI, including the exact invocation in docs/branching-and-release.md.Fix
All three publish jobs gate on
always() && needs.test-and-pack.result == 'success', and the opt-in accepts the string as well as the boolean.Tag-push behaviour is unchanged:
validate-refstill gates it, and nuget.org still requires both the flag and thenuget-orgenvironment approval. This also makes the runbook's "re-running a publish job is idempotent" claim true for the first time.Verification
Merging this and re-dispatching for
v10.4.0-rc.4is the test —publish → nuget.orgshould reach the approval gate instead of skipping. No code change, soTest/Packare unaffected.