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

no-local-version on release branches #462

Closed
pmeier opened this issue Jul 10, 2020 · 2 comments
Closed

no-local-version on release branches #462

pmeier opened this issue Jul 10, 2020 · 2 comments

Comments

@pmeier
Copy link

pmeier commented Jul 10, 2020

I'm using releases/* branches to check if my package is publishable on PyPI or not. Amongst others, I try to upload to TestPyPI.

The problem I'm facing is that even with version_scheme="release-branch-semver" all commits up to a tag are marked as development commit. Since they include a local identifier the upload is rejected. This is resolved after I create the tag, but I can't know beforehand if the upload will be rejected for another reason than the version.

My current workaround is to pre-install setuptools_scm and use get_version(version_scheme="release-branch-semver", local_scheme="no-local-version") to set SETUPTOOLS_SCM_PRETEND_VERSION.

Would it be possible to add a local_scheme that uses no-local-version while on a release/* branch and otherwise behaves as the default?

@RonnyPfannschmidt
Copy link
Contributor

It would be possible, my proposal however would be to have a env var which generally allows informed release pipelines to opt out of dev/local version tags to allow test artifact upload

@RonnyPfannschmidt
Copy link
Contributor

closing as duplicate of #455 given the proposal will add a general env var for config overrides

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

No branches or pull requests

2 participants