-
Notifications
You must be signed in to change notification settings - Fork 326
Closed
Description
Is there an existing issue for this?
- I have searched the existing issues (open and closed), and could not find an existing issue
What keywords did you use to search existing issues?
twine_username
Please describe why your using this option
Someone reported that TWINE_USERNAME wasn't working, and we spent around an hour debugging it. Finally came across
Lines 34 to 39 in 94f810c
| if cast(str, self.config["repository"]).startswith( | |
| (utils.DEFAULT_REPOSITORY, utils.TEST_REPOSITORY) | |
| ): | |
| # As of 2024-01-01, PyPI requires API tokens for uploads, meaning | |
| # that the username is invariant. | |
| return "__token__" |
I think this could be improved, a few ideas:
- Expand the details of this in the changelog entry for 5.0.0
- Check to see if a username other than
__token__is set in this PyPI/TestPyPI branch, and issue a warning about requesting a username. - Maybe add a note in the CLI help for
-u.
Anything else you'd like to mention?
Someone ran into this in #1113
kratsg and woodruffw