我需要对一些脚本使用python-2.7,setuptools==39.1.0,我不能安装dm-十四行诗,在setuptools中应该有find_namespace_packages吗?它不在这个setuptools(或v44)错误消息中:
ERROR: Command errored out with exit status 1:
command: /home/russo/anaconda3/envs/russo2/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-9l072x/dm-sonnet/setup.py'"'"'; __file__='"'"'/tmp/pip-install-9l072x/dm-sonnet/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-9l072x/dm-sonnet/pip-egg-info
cwd: /tmp/pip-install-9l072x/dm-sonnet/
Complete output (5 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-9l072x/dm-sonnet/setup.py", line 7, in <module>
from setuptools import find_namespace_packages
ImportError: cannot import name find_namespace_packages
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.发布于 2020-04-08 14:54:09
需要Python 3。您不能在Python 2中使用它。
在提交00612中,setup.py使用find_packages。您可以使用Python2.7尝试这个版本。它可能是发布1.36或更早版本。试一试
pip2 install dm-sonnet==1.36或
pip2 install 'dm-sonnet<2'https://stackoverflow.com/questions/61101722
复制相似问题