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

Raise exception if attempting upload to deprecated legacy PyPI URLs #322

Merged
merged 2 commits into from
Mar 18, 2018

Conversation

brainwane
Copy link
Contributor

Now that legacy (deprecated) URLs give a 410 Gone, Twine should just watch for those URLs and give an actionable error rather than transmit the upload request.

Fixes #307.

@codecov
Copy link

codecov bot commented Mar 18, 2018

Codecov Report

Merging #322 into master will increase coverage by 1.02%.
The diff coverage is 71.42%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #322      +/-   ##
==========================================
+ Coverage   68.51%   69.53%   +1.02%     
==========================================
  Files          12       12              
  Lines         578      581       +3     
  Branches       91       91              
==========================================
+ Hits          396      404       +8     
+ Misses        156      149       -7     
- Partials       26       28       +2
Impacted Files Coverage Δ
twine/utils.py 87.12% <0%> (+1.98%) ⬆️
twine/repository.py 60.57% <100%> (+0.38%) ⬆️
twine/exceptions.py 100% <100%> (ø) ⬆️
twine/commands/upload.py 65.47% <66.66%> (+3.57%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5199edb...ecff890. Read the comment docs.

@brainwane brainwane force-pushed the deprecated-URL-exception branch 2 times, most recently from cf16b33 to 5c864af Compare March 18, 2018 13:08
Now that legacy (deprecated) URLs give a 410 Gone,
Twine should just watch for those URLs and give
an actionable error rather than transmit the upload
request.

Fixes #307.
@brainwane
Copy link
Contributor Author

@jonparrott I've revised the exception handling; take another look?

@brainwane brainwane merged commit 4a8c3d4 into master Mar 18, 2018
@brainwane brainwane deleted the deprecated-URL-exception branch March 18, 2018 15:13
@brainwane brainwane mentioned this pull request Mar 19, 2018
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.

3 participants