I have created a package and tried to upload it to testpypi to test it, as suggested in the Python Packaging User Guide. I created a distribution, registered it, and uploaded it to testpypi:
me@machine$ cd mypackage
me@machine:~/mypackage$ python setup.py sdist bdist_wheel
me@machine:~/mypackage$ twine register dist/mypackage-1.0.0-py3-none-any.whl -r https://testpypi.python.org/pypi
me@machine:~/mypackage$ twine upload dist/* -r https://testpypi.python.org/pypi
This worked fine, but trying to install it
me@machine:~$ pip install -r https://testpypi.python.org/pypi mypackage
fails with the following error:
Invalid requirement: '<?xml version="1.0" encoding="utf-8"?>'
Traceback (most recent call last):
[...]
pip._vendor.pyparsing.ParseException: Expected W:(abcd...) (at char 0), (line:1, col:1)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/vol/home/me/miniconda3/envs/myenv/lib/python3.5/site-packages/pip/req/req_install.py", line 82, in __init__
req = Requirement(req)
File "/vol/home/me/miniconda3/envs/myenv/lib/python3.5/site-packages/pip/_vendor/packaging/requirements.py", line 96, in __init__
requirement_string[e.loc:e.loc + 8]))
pip._vendor.packaging.requirements.InvalidRequirement: Invalid requirement, parse error at "'<?xml ve'"