Skip to content

Fix PyPI package upload #1128

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

Merged
merged 3 commits into from
Apr 17, 2025
Merged

Fix PyPI package upload #1128

merged 3 commits into from
Apr 17, 2025

Conversation

qubvel
Copy link
Collaborator

@qubvel qubvel commented Apr 17, 2025

No description provided.

@qubvel qubvel merged commit ccbf7e6 into main Apr 17, 2025
16 checks passed
Copy link

codecov bot commented Apr 17, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@adamjstewart
Copy link
Collaborator

From https://github.com/pypa/gh-action-pypi-publish:

try to separate building from publishing — this makes sure that any scripts maliciously injected into the build or test environment won't be able to elevate privileges while flying under the radar.

This is also how https://packaging.python.org/en/latest/guides/publishing-package-distribution-releases-using-github-actions-ci-cd-workflows/ works.

I think we should have separate steps for:

  1. Building and uploading artifacts
  2. Downloading and publishing artifacts

See https://github.com/microsoft/torchgeo/blob/main/.github/workflows/deploy.yaml for an example.

Also see ultralytics/ultralytics#18027 for some motivation.

@qubvel
Copy link
Collaborator Author

qubvel commented Apr 17, 2025

@adamjstewart thanks for bringing this up! I heard about ultrlytics case, 💯 it's better to avoid such situations 😅 would like to make a PR?

@qubvel qubvel deleted the pypi-debug branch April 18, 2025 12:31
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