Как исправить ошибку «Ошибка команды со статусом выхода 1: python» при попытке установить mmcv - PullRequest
0 голосов
/ 28 мая 2020

Мне нужно pip install mmcv==0.4.4, который отлично работает на моем компьютере. Но когда я запускаю команду на удаленном сервере как:

pip install --user --proxy=http://proxyserver mmcv==0.4.4

, происходит сбой со следующей ошибкой:

ERROR: Command errored out with exit status 1:
     command: /home/m/anaconda3/envs/my_env/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-bs9m80ii/mmcv/setup.py'"'"'; __file__='"'"'/tmp/pip-install-bs9m80ii/mmcv/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-install-bs9m80ii/mmcv/pip-egg-info
     cwd: /tmp/pip-install-bs9m80ii/mmcv/
    Complete output (33 lines):
    WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x7fe96fca6250>: Failed to establish a new connection: [Errno 113] No route to host')': /simple/numpy/
    WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x7fe96fca6c90>: Failed to establish a new connection: [Errno 113] No route to host')': /simple/numpy/
    WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x7fe96fc84f90>: Failed to establish a new connection: [Errno 113] No route to host')': /simple/numpy/
    WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x7fe96fc8e310>: Failed to establish a new connection: [Errno 113] No route to host')': /simple/numpy/
    WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<pip._vendor.urllib3.connection.VerifiedHTTPSConnection object at 0x7fe96fc8ec10>: Failed to establish a new connection: [Errno 113] No route to host')': /simple/numpy/
    ERROR: Could not find a version that satisfies the requirement numpy>=1.11.1 (from versions: none)
    ERROR: No matching distribution found for numpy>=1.11.1
    Traceback (most recent call last):
      File "/home/m/anaconda3/envs/my_env/lib/python3.7/site-packages/setuptools/installer.py", line 128, in fetch_build_egg
    subprocess.check_call(cmd)
      File "/home/m/anaconda3/envs/my_env/lib/python3.7/subprocess.py", line 363, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['/home/m/anaconda3/envs/dense_matching_benchmark/bin/python', '-m', 'pip', '--disable-pip-version-check', 'wheel', '--no-deps', '-w', '/tmp/tmpaz5otv11', '--quiet', 'numpy>=1.11.1']' returned non-zero exit status 1.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/tmp/pip-install-bs9m80ii/mmcv/setup.py", line 6, in <module>
    dist.Distribution().fetch_build_eggs(['Cython', 'numpy>=1.11.1'])
  File "/home/m/anaconda3/envs/my_env/lib/python3.7/site-packages/setuptools/dist.py", line 698, in fetch_build_eggs
    replace_conflicting=True,
  File "/home/m/anaconda3/envs/my_env/lib/python3.7/site-packages/pkg_resources/__init__.py", line 783, in resolve
    replace_conflicting=replace_conflicting
  File "/home/m/anaconda3/envs/my_env/lib/python3.7/site-packages/pkg_resources/__init__.py", line 1066, in best_match
    return self.obtain(req, installer)
  File "/home/m/anaconda3/envs/my_env/lib/python3.7/site-packages/pkg_resources/__init__.py", line 1078, in obtain
    return installer(requirement)
  File "/home/m/anaconda3/envs/my_env/lib/python3.7/site-packages/setuptools/dist.py", line 754, in fetch_build_egg
    return fetch_build_egg(self, req)
  File "/home/m/anaconda3/envs/my_env/lib/python3.7/site-packages/setuptools/installer.py", line 130, in fetch_build_egg
    raise DistutilsError(str(e))
distutils.errors.DistutilsError: Command '['/home/m/anaconda3/envs/my_env/bin/python', '-m', 'pip', '--disable-pip-version-check', 'wheel', '--no-deps', '-w', '/tmp/tmpaz5otv11', '--quiet', 'numpy>=1.11.1']' returned non-zero exit status 1.
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

Все остальные необходимые пакеты устанавливаются без проблем, я попытался изменить Среда Conda до python3 .6 из 3.7, но это, похоже, не помогло. Несколько мест предполагают проблему с pg-config, но я не думаю, что проблема здесь, кажется, какая-то проблема с numpy, но я не понимаю, что, потому что я также установил его fre sh.

...