-
Notifications
You must be signed in to change notification settings - Fork 2
Automation #10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: release
Are you sure you want to change the base?
Automation #10
Conversation
publish automation
Note Gemini is unable to generate a summary for this pull request due to the file types involved not being currently supported. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Automate Python package publishing via GitHub Actions when pushing to the release branch or triggering manually.
- Adds a new publish workflow to build artifacts and upload to PyPI.
- Sets up Python 3.12, runs a build script, and uses pypa/gh-action-pypi-publish for distribution.
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 |
Copilot
AI
Oct 14, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pin this action to a specific commit SHA (instead of a mutable tag) to mitigate supply‑chain risk. Example: uses: actions/checkout@.
uses: actions/checkout@v4 | |
uses: actions/checkout@v4.1.0 # or uses: actions/checkout@<commit-sha> |
Copilot uses AI. Check for mistakes.
uses: actions/checkout@v4 | ||
|
||
- name: Set up Python | ||
uses: actions/setup-python@v5 |
Copilot
AI
Oct 14, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pin actions/setup-python to a specific commit SHA to prevent unexpected changes from upstream tags affecting the workflow. Example: uses: actions/setup-python@.
uses: actions/setup-python@v5 | |
uses: actions/setup-python@f7a9c1c8e1e6e2e1b6b6e1e6e2e1b6b6e1e6e2e1 |
Copilot uses AI. Check for mistakes.
run: ./build_package.sh | ||
|
||
- name: Publish to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 |
Copilot
AI
Oct 14, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pin the PyPI publish action to a specific commit SHA. Additionally, consider switching to PyPI Trusted Publishing (OIDC) to eliminate long‑lived secrets: add permissions: id-token: write to the job and remove the user/password inputs so the action authenticates via OIDC.
Copilot uses AI. Check for mistakes.
jobs: | ||
build-and-publish: | ||
environment: Release-secret | ||
runs-on: ubuntu-latest |
Copilot
AI
Oct 14, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nitpick] Pin the runner to a specific image (e.g., ubuntu-24.04 or ubuntu-22.04) to avoid breaking changes when ubuntu-latest advances.
runs-on: ubuntu-latest | |
runs-on: ubuntu-22.04 |
Copilot uses AI. Check for mistakes.
No description provided.