我试图上传一个软件包(https://github.com/chembl/standardiser)到PyPI,我做了很多次,没有任何问题。
我使用conda环境,安装了Python2.7.13。
1.第一次尝试:
python setup.py sdist upload错误:
Submitting dist/standardiser-0.1.9.tar.gz to https://pypi.python.org/pypi
Upload failed (410): Gone (This API has been deprecated and removed from legacy PyPI in favor of using the APIs available in the new PyPI.org implementation of PyPI (located at https://pypi.org/). For more information about migrating your use of this API to PyPI.org, please see https://packaging.python.org/guides/migrating-to-pypi-org/#uploading. For more information about the sunsetting of this API, please see https://mail.python.org/pipermail/distutils-sig/2017-June/030766.html)
error: Upload failed (410): Gone (This API has been deprecated and removed from legacy PyPI in favor of using the APIs available in the new PyPI.org implementation of PyPI (located at https://pypi.org/). For more information about migrating your use of this API to PyPI.org, please see https://packaging.python.org/guides/migrating-to-pypi-org/#uploading. For more information about the sunsetting of this API, please see https://mail.python.org/pipermail/distutils-sig/2017-June/030766.html)2.第二次尝试:
python setup.py sdist upload -r https://www.python.org.pypi错误:
error: <urlopen error [Errno 8] nodename nor servname provided, or not known>3.第三次尝试全系统Python2.7.3:
python setup.py sdist upload
Error:
Creating tar archive
removing 'standardiser-0.1.9' (and everything under it)
running upload
Submitting dist/stardiser-0.1.9.tar.gz to https://upload.pypi.org/legacy
error: None这个包还没有在PyPI中
4.第四次尝试
在~/.pypirc中创建https://packaging.python.org/guides/migrating-to-pypi-org/#uploading文件
[distutils]
index-servers =
pypi
[pypi]
repository:https://pypi.python.org/pypi
username:MY_ACTUAL_USERNAME
password:MY_ACTUAL_PASSWORD和跑步:
python setup.py sdist upload错误:与1相同。
5.第五次尝试
从repository:https://pypi.python.org/pypi中删除~/.pypirc行
和跑步:
python setup.py sdist upload错误:与1相同。
6.第六次尝试
遗留~/.pypirc
[distutils]
index-servers =
pypi
[pypi]
repository: https://upload.pypi.org/legacy/
username: MY_ACTUAL_USERNAME
password: MY_ACTUAL_PASSWORD和跑步:
python setup.py sdist upload错误:与1相同。
还有任何其他提示,我如何上传我的包到PyPI?
发布于 2017-08-22 12:59:49
似乎Pypi不再支持上传命令.
如果你想把你的项目上传到Pypi,请使用T电平。这些文档可以在这里获得,https://pypi.python.org/pypi/twine
https://stackoverflow.com/questions/45818291
复制相似问题