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

ci: Only trigger pypi push on release tag #433

Merged
merged 1 commit into from
Jul 2, 2024
Merged

Conversation

ewuerger
Copy link
Member

@ewuerger ewuerger commented Jul 1, 2024

The pipeline on master is unsuccessful because only non-dev versions can be uploaded to PyPI. This fixes the situation by only triggering the pypi stage when a release tag was created.

@ewuerger ewuerger self-assigned this Jul 1, 2024
@Wuestengecko
Copy link
Member

The pipeline on master is unsuccessful because I force pushed to fix the commit message of the latest merge, and PyPI doesn't let you reupload the same version twice. :)

ERROR    HTTPError: 400 Bad Request from https://upload.pypi.org/legacy/
         File already exists. See https://pypi.org/help/#file-name-reuse for
         more information.

Regardless, it might not be necessary to upload all dev versions to PyPI after all. Space there is limited, and I'm not sure anymore why we did that in the first place (probably something to do with misconfigured firewalls or something). Do you have any idea? If not, I'd maybe actually merge this and see what breaks 🙃

@ewuerger
Copy link
Member Author

ewuerger commented Jul 2, 2024

Do you have any idea? If not, I'd maybe actually merge this and see what breaks 🙃

No idea why we allowed to run the pypi upload on any push to main or tag creation. Maybe an and (&&?) is correct here? It isn't breaking anythin. This is the version of the workflow we use in the capella2polarion, rest-api and context-diagrams now. It works :)

@Wuestengecko
Copy link
Member

Maybe an and (&&?) is correct here?

Definitely not, because the ref either is refs/heads/master or starts with refs/tags/v, but never both at the same time ;)

Publishing pre-releases was a deliberate choice (81cccd8), but the commit doesn't have a reason either. Let's just go through with this PR. The way to install pre-releases henceforth shall be to just use the git master directly like for any other repo.

But first we'll have to somehow deal with the Sphinx failure.

@Wuestengecko Wuestengecko force-pushed the fix-pypi-ci branch 2 times, most recently from 2d8b35b to 7e250c7 Compare July 2, 2024 16:01
Wuestengecko pushed a commit that referenced this pull request Jul 2, 2024
Publishing pre-releases has been deemed to not be necessary (anymore?).
They can still be installed by using the Git repository directly.

This reverts 81cccd8 and
a1d7410.
Publishing pre-releases has been deemed to not be necessary (anymore?).
They can still be installed by using the Git repository directly.

This reverts 81cccd8 and
a1d7410.
@Wuestengecko Wuestengecko merged commit 7567e50 into master Jul 2, 2024
7 of 8 checks passed
@Wuestengecko Wuestengecko deleted the fix-pypi-ci branch July 2, 2024 16:05
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