Add --skip-existing option to poetry publish
See original GitHub issue- I have searched the issues of this repo and believe that this is not a duplicate.
- I have searched the documentation and believe that my question is not covered.
Feature Request
The twine tool for publishing to PyPi style repos has a very useful option --skip-existing
for the twine upload
command. This option basically says “don’t error out if a file already exists on PyPi, continue to the next”.
This is super useful in a number of cases, including with CI/CD pipelines where, on branching, the pipeline will trigger a build for the new branch, but of course that first build will already have a corresponding package in PyPi as the commit it’s being built from has already been built on the branch that the new branch was created from. In that case, it’s fine for the pipeline to fail to upload the file as it already exists.
There are various other use cases for this flag. Could we have an equivalent flag for poetry publish
?
Issue Analytics
- State:
- Created 3 years ago
- Reactions:16
- Comments:7 (3 by maintainers)
i would probably do something similar to twine (heuristics for a few package index implementations that try to detect this particular error)
i explicitly don’t want to ignore all errors, only “this file already exists”
I agree that this feature would be great. The PR looks good too me (although I did not check all possible responses 😃 ).