Skip to content
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

pypi upload workflow maintenance #5269

Merged
merged 3 commits into from
May 6, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/pypi-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ on:
types:
- published
push:
branches:
- master
tags:
- 'v*'
Comment on lines 4 to +8
Copy link
Member

Choose a reason for hiding this comment

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

I think this will result in duplicate runs i.e. one for the push event and the release event... Do we want this duplication?

Copy link
Collaborator Author

@keewis keewis May 6, 2021

Choose a reason for hiding this comment

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

I think that's okay (intentional even), as long as we only upload to PyPI on release and to TestPyPI on push (not sure if I got that right, though).


jobs:
build-artifacts:
Expand Down Expand Up @@ -63,7 +63,7 @@ jobs:
ls -ltrh
ls -ltrh dist
- name: Publish package to TestPyPI
if: github.event_name == 'push' || startsWith(github.event.ref, 'refs/tags/v')
if: github.event_name == 'push'
uses: pypa/gh-action-pypi-publish@v1.4.2
with:
user: __token__
Expand All @@ -72,7 +72,7 @@ jobs:
verbose: true

- name: Check uploaded package
if: github.event_name == 'push' || startsWith(github.event.ref, 'refs/tags/v')
if: github.event_name == 'push'
run: |
sleep 3
python -m pip install --upgrade pip
Expand Down