Skip to content

Publish to pypi#2

Merged
ofekby merged 7 commits intomainfrom
publish-to-pypi
Dec 2, 2025
Merged

Publish to pypi#2
ofekby merged 7 commits intomainfrom
publish-to-pypi

Conversation

@ofekby
Copy link
Collaborator

@ofekby ofekby commented Dec 2, 2025

This pull request introduces an automated PyPI release workflow and updates the project version for snaplint. The main changes are focused on improving the release process and preparing for a new version deployment.

Release workflow improvements:

  • Enabled the publish-release job in .github/workflows/ci.yml to automate publishing to PyPI, including setting the deployment environment to pypi-production and configuring trusted publishing permissions.

Version update:

  • Bumped the project version in pyproject.toml from 0.4.2 to 0.5.0 to reflect new changes and prepare for release.

Copilot AI review requested due to automatic review settings December 2, 2025 09:19
@ofekby ofekby merged commit 9e02ce1 into main Dec 2, 2025
8 checks passed
Copy link

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 enables automated PyPI publishing for the snaplint project by activating a previously commented-out workflow job and bumping the package version to 0.5.0. The workflow uses GitHub's trusted publishing mechanism with OIDC authentication, eliminating the need for API tokens while maintaining security through environment-based deployment controls.

Key Changes:

  • Activated the publish-release workflow job with trusted publishing configuration and pypi-production environment
  • Bumped version from 0.4.2 to 0.5.0 in preparation for release
  • Updated lock file to reflect the new version

Reviewed changes

Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.

File Description
.github/workflows/ci.yml Enabled the publish-release job to automate PyPI publishing using trusted publishing with appropriate OIDC permissions
pyproject.toml Updated project version from 0.4.2 to 0.5.0
uv.lock Updated lock file to reflect the new version in the package metadata

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

@@ -136,6 +136,7 @@ jobs:
publish-release:
needs: build-release
runs-on: ubuntu-latest
Copy link

Copilot AI Dec 2, 2025

Choose a reason for hiding this comment

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

The publish-release job will execute on every successful build, including pull requests, because it only depends on build-release without explicitly checking the trigger conditions. Although build-release depends on tag-release which has a condition for main branch, the dependency chain alone doesn't prevent the job from being triggered in other contexts.

Consider adding an explicit condition to ensure it only runs when intended:

publish-release:
  needs: build-release
  runs-on: ubuntu-latest
  if: needs.tag-release.outputs.tag_created == 'true'
  environment: pypi-production

This makes the intent clear and adds an extra safety layer to prevent accidental publishes.

Suggested change
runs-on: ubuntu-latest
runs-on: ubuntu-latest
if: needs.tag-release.outputs.tag_created == 'true'

Copilot uses AI. Check for mistakes.
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