Repository navigation
ci(release): publish stable Python wheels directly to PyPI - #5157
Merged
Merged
Conversation
Signed-off-by: Piotr Mlocek <pmlocek@nvidia.com>
pimlock
requested review from
a team,
derekwaynecarr,
mrunalp and
sjenning
as code owners
November 2, 2026 20:40
|
🌿 Preview your docs: https://nvidia-preview-pr-5157.docs.buildwithfern.com/openshell |
Signed-off-by: Piotr Mlocek <pmlocek@nvidia.com>
pimlock
commented
Nov 3, 2026
pimlock
commented
Nov 3, 2026
SDAChess
previously approved these changes
Nov 3, 2026
Download the wheel and checksums from the stable GitHub Release instead of the run's build artifact. A new Release run for the same tag rebuilds a wheel whose bytes differ from the released asset, so publishing the run artifact could not finish a failed PyPI upload after the artifact expired. Signed-off-by: Piotr Mlocek <pmlocek@nvidia.com>
Collaborator
Author
|
a1cadbc changes Why:
The release is published before this job runs: This differs from the other publishers (snap and GHCR use run artifacts; npm rebuilds from the source commit). Those can be corrected or rebuilt from a fixed commit; a PyPI file cannot. |
SDAChess
approved these changes
Nov 3, 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.
Summary
Stable releases currently trigger Kitmaker through GitLab to publish Python wheels. Publish directly from
release.ymlto PyPI using Trusted Publishing and thepypiGitHub environment. Development and prerelease wheels remain GitHub Release assets without PyPI uploads.Related Issue
Closes #5156
Changes
release.yml, with job-scopedid-token: writeand a pinned PyPA publishing action. Check the stable tag's source commit, wheel name/version, and release checksum before uploading. Skip existing uploads on release retries.wheel-publish.ymlworkflow, and GitLab trigger credential references.flowchart LR B[Build stable artifacts] --> R[Publish release assets and other packages] R --> P[Verify wheel and publish to PyPI] P --> D[Publish stable docs]The configured PyPI publisher trusts
NVIDIA/OpenShell, workflowrelease.yml, and environmentpypi. The GitHub environment currently allowsmainand has no required reviewers. Support release branches must be explicitly allowed before dispatching Release. No stored PyPI API token is required.Release Notes
Testing
git diff --checkpasses.concurrency.queuesyntax errors inrelease.ymlandrelease-prerelease.yml. The unchanged versions produce the same errors; no new findings were reported. ShellCheck and Pyflakes were disabled for this check.Checklist