I have a python package (xyz) that was on python.pypi.org. I am trying to release a new version and I am using twine for upload. I fixed everything in the ~/.pypirc file as explained on tutorials. When I run the following command:
twine upload dist/*
I got the following output:
Uploading distributions to https://upload.pypi.org/legacy/
Uploading xyz-1.9.1.tar.gz
HTTPError: 400 Client Error: provides: Invalid requirement: 'xyz (1.9.1)' for url: https://upload.pypi.org/legacy/
I was not sure why this is happening but I am guessing it could be my setup.py file but here are the block in my setup() part.
setup(
name='xyz',
version=__version__,
author='xyz',
author_email='xyz',
description='xyz package for xyz',
long_description=long_description,
url='xyz',
packages=PACKAGES,
package_dir=PACKAGE_DIR,
package_data=PACKAGE_DATA,
ext_modules=EXTENSIONS,
license='MIT License',
keywords=('xyz'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Intended Audience :: Education',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: MIT License',
'Operating System :: MacOS',
'Operating System :: Microsoft :: Windows',
'Operating System :: POSIX',
'Programming Language :: Python',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 3',
'Topic :: Scientific/Engineering :: xyz',
'Topic :: Scientific/Engineering :: xyz',
],
scripts=SCRIPTS,
requires=['NumPy (>=1.7)', ],
provides=['xyz'.format(__version__)]
)
Could anyone help me on this? Thanks.
Note: "xyz" is the replacement name for the package. There will be no duplicate packages.