How to upload new versions of project to PyPI with twine?

后端 未结 5 370
鱼传尺愫
鱼传尺愫 2021-02-03 18:27

I\'ve uploaded my Python package to PyPI. But now I made new version of my package and need to upload it. I tried to make same progress which I did when upload the package first

5条回答
  •  囚心锁ツ
    2021-02-03 19:00

    Can get that error for following reasons:

    • Didn't change your version in setup.py
    • didn't remove your previous dist file

    Solution:

    • Change the version number in setup.py.
    • Run setup file again. python setup.py bdist_wheel.
    • Upload only that dist file or run twine (if using). twine upload --skip-existing dist/*

    As mentioned by @dustin, dist file of same name cannot be uploaded again.

提交回复
热议问题