nic*_*kik 44 python pip gunicorn
我不太了解python.我想开始研究项目,设置说明说:
pip install -r requirements-dev.txt
Run Code Online (Sandbox Code Playgroud)
简单的enougth.问题是我得到了这个:
Downloading/unpacking gunicorn==0.13.4 (from -r requirements.txt (line 7))
Running setup.py egg_info for package gunicorn
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "/tmp/pip-build-root/gunicorn/setup.py", line 18, in <module>
long_description = file(
NameError: name 'file' is not defined
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 16, in <module>
File "/tmp/pip-build-root/gunicorn/setup.py", line 18, in <module>
long_description = file(
NameError: name 'file' is not defined
Run Code Online (Sandbox Code Playgroud)
我不明白这个问题.也许有人可以帮忙吗?
我在Arch Linux上运行它,python默认为python 3,项目不是python 3但是我不确定是不是这样.
谢谢.
显然您正在使用的Python3中未定义文件。您要安装的软件包不适用于Python 3,而是应该安装Python 2.7,然后重试。
请参阅:http : //docs.python.org/release/3.0/whatsnew/3.0.html#builtins