Publish to PyPI on real releases - #476
Merged
Merged
Conversation
The upload step is gated on "!needs.release.outputs.dry_run". Job outputs are strings, so on a real release that value is the string "false", which is truthy: the negation is false and the upload is skipped. Only an empty string would ever run it. Skipping a step is not a failure, so the publish job stayed green while 1.0.1 through 1.0.5 were tagged and released on GitHub without ever reaching PyPI. Compare against "true" instead, which is what octave_kernel's release workflow already does.
blink1073
marked this pull request as ready for review
August 17, 2026 02:11
blink1073
enabled auto-merge (squash)
August 17, 2026 02:11
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #476 +/- ##
=======================================
Coverage 93.55% 93.55%
=======================================
Files 51 51
Lines 2981 2981
Branches 414 414
=======================================
Hits 2789 2789
Misses 129 129
Partials 63 63 🚀 New features to boost your workflow:
|
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.
References
No issue filed. Noticed while checking whether the 1.0.5 release carried #475.
Description
Nothing has reached PyPI since 1.0.0. Releases 1.0.1 through 1.0.5 all have tags and GitHub releases, and every
publishjob reported success, but the upload step inside it was skipped every time:The step is gated on
if: ${{ !needs.release.outputs.dry_run }}. Job outputs are always strings, so on a real release that output is the string"false", which is truthy, making!"false"false and skipping the upload. The only value that would ever run it is an empty string. Because the skip is not a failure, the job stays green and the missing upload goes unnoticed.octave_kernelalready uses the string comparison this changes to, andoct2pyavoids the problem by testinginputs.dry_rundirectly, where it is a real boolean.Changes
needs.release.outputs.dry_run != 'true', so real releases publish and dry runs and the nightly scheduled run still do not.Backwards-incompatible changes
None
Testing
actionlintpasses and the workflow parses. The condition itself cannot be exercised without running a release: withdry_run: falsethe expression now evaluates"false" != 'true'to true, and for the scheduled run and explicit dry runs the output is"true", so it stays false.Note that 1.0.5 is tagged but was never published, so it will need a roll forward to 1.0.6 after this merges.
AI usage