NameError:未定义名称'execfile'在Python3上安装fandjango

时间:2017-01-07 18:48:57

标签: python django fandjango

我正在尝试使用以下方法安装fandjango:

pip install fandjango

然而我收到错误:

Collecting fandjango
  Using cached fandjango-4.2.1.tar.gz
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "C:\Users\Apaar\AppData\Local\Temp\pip-build-0j7g1eqn\fandjango\setup.py", line 5, in <module>
        execfile('fandjango/version.py')
    NameError: name 'execfile' is not defined

----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in C:\Users\Apaar\AppData\Local\Temp\pip-build-0j7g1eqn\fandjango\

非常感谢任何帮助

1 个答案:

答案 0 :(得分:2)

Fandjango仅根据其Pypi entry支持Python2,并且您使用的是Python3(Python3没有execfile内置函数。)