Skip to content

Add --skip-existing option to poetry publish #2254

@jonathanunderwood

Description

@jonathanunderwood
  • 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 ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/publishingRelated to PyPI/PEP 503 publishingkind/featureFeature requests/implementations

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions