Python向PYPI上传代码时无法命令行注册和上传
我在看《head first python》,向PYPI发布代码时遇到问题。
背景:我已经把函数的代码放到一个模块中,用来创建发布;并且安装在python本地副本中。
过程:输入 ..\python.exe setup.py register,按照提示输入帐号名称和密码,提示如下:
Registering nester to https://upload.pypi.org/legacy/
Server response (410): Project pre-registration is no longer required or support
ed, so continue directly to uploading files.
之后,输入 ..\python.exe setup.py sdist upload,提示如下错误:
Submitting dist\nester-1.0.0.tar.gz to https://upload.pypi.org/legacy/
Upload failed (403): Invalid or non-existent authentication information.
error: Upload failed (403): Invalid or non-existent authentication information.
这要如何解决?和我的预期不一样。