setup.py containing an external url: platform specific failure (Windows & Linux)

心不动则不痛 提交于 2021-02-17 03:45:36

问题


This is in my setup.py:

setup(...,
      install_requires=[
           'fons @ git+https://github.com/binares/fons.git',
       ],
)

Installing the package on Windows (pip 19.3.1, python 3.6.5) works just fine, but on Ubuntu 18.04 (pip 9.0.1, python 3.6.9) I get :

requests.exceptions.HTTPError: 404 Client Error: Not found for url: https://pypi.org/simple/fons

(I used commands: pip install wsclient-0.1.0.tar.gz and pip3 install wsclient-0.1.0.tar.gz)

How to make it work on both platforms?


回答1:


https://setuptools.readthedocs.io/en/latest/setuptools.html#declaring-dependencies

Warning: Dependency links support has been dropped by pip starting with version 19.0 (released 2019-01-22).

The syntax

'fons @ git+https://github.com/binares/fons.git'

is from PEP 440 and is supported by pip 19.1+.

Upgrade pip at Ubuntu.



来源:https://stackoverflow.com/questions/59525593/setup-py-containing-an-external-url-platform-specific-failure-windows-linux

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!