Add --skip-existing
to publish command
#831
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
While working on #759 I noticed that we didn't offer support for dispatching
--skip-existing
from Twine.Edit: This PR adds
--skip-existing
to the publish command.This PR adds--force
(-f
) which covers dispatch of--skip-existing
. I landed on "force" because I felt it was more generic.--skip-existing
to me falls under the category of forcing behavior. So I decided to start with something more generic to approach this feature.I'm kind of curious in general of--skip-existing
, since, to me (IIUC), it's effectively a swap of an already published package -- which just feels odd to be able to do.I tested this manually against upload.pypi.org. I was pretty sure that test.pypi.org implemented the same rejection, but I couldn't get it to trigger.
Other than the manual testing, I've held off on adding anything since I've already added a bunch of testing in #759.