Skip to content

Conversation

@kevinbackhouse
Copy link
Collaborator

https://test.pypi.org/ is a testing version of https://pypi.org. I'll try to get this workflow working there first before I try to add the real PyPI. I've implemented it with a reusable workflow, so hopefully it will be easy to add PyPI when I've got this working.

Copilot AI review requested due to automatic review settings November 4, 2025 18:04
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces a reusable workflow pattern for publishing Python packages to PyPI/TestPyPI. It adds two new workflow files: a reusable workflow that handles the entire publish process (building, signing, uploading to PyPI, and creating GitHub releases), and a caller workflow configured for TestPyPI.

  • Adds a reusable workflow (publish-reusable.yml) that builds Python packages, publishes to PyPI/TestPyPI, signs with sigstore, and creates GitHub releases
  • Adds a caller workflow (publish-to-testpypi.yaml) that triggers the reusable workflow for TestPyPI deployments
  • Implements trusted publishing with OIDC for secure PyPI authentication

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.

File Description
.github/workflows/publish-to-testpypi.yaml Caller workflow that invokes the reusable workflow for TestPyPI publishing with manual trigger
.github/workflows/publish-reusable.yml Reusable workflow that handles building, publishing, signing, and release creation

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@kevinbackhouse kevinbackhouse force-pushed the publish-to-testpypi branch 3 times, most recently from 336ee26 to 3bcd8aa Compare November 4, 2025 18:25
uses: .github/workflows/publish-reusable.yml@main
with:
version: ${{ inputs.version }}
release_notes: ${{ github.head_ref }}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just for testing?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, because this whole workflow is just for testing. It pushes to TestPyPI, so my intention is that we can do it whenever we feel like it, rather than just when we have a new release.

I'm planning to add a separate workflow for pushing to PyPI, which is why I've put most of the logic in a reusable workflow.

JarLob
JarLob previously approved these changes Nov 5, 2025
@kevinbackhouse kevinbackhouse merged commit 9939558 into GitHubSecurityLab:main Nov 5, 2025
9 checks passed
@kevinbackhouse kevinbackhouse deleted the publish-to-testpypi branch November 5, 2025 09:44
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.

2 participants