PythonAnywhere`python3.6 -m venv test`导致错误

时间:2017-04-07 12:39:55

标签: pythonanywhere

我正在尝试直接在PythonAnywhere中使用python3.6 -m venv test来创建virtualenv。我想使用这种方法,因为我认为它更容易移植到可能无法设置virtualenvwrapper的其他环境。

当我运行命令时(在已升级为使用Python 3.6的PA环境中),我收到以下错误。

12:34 ~ $ python3.6 -m venv test
Error: Command '['/home/dpottsagilisys/test/bin/python3.6', '-Im', 'ensurepip', 
'--upgrade', '--default-pip']' returned non-zero exit status 1.

2 个答案:

答案 0 :(得分:25)

PythonAnywhere dev here:这似乎是Ubuntu 14.04(显然是15.04)中的一个错误,我们是在最初询问这个问题的基础上的。

This Ask Ubuntu question提出了各种建议;这是我在PythonAnywhere上100%确定的作品:

class Container
{
    vector<Foo> objects;

[2018年6月28日更新:巧合的是,转换为16.04图像,我们现在正在努力。]

[2018年9月30日更新:16.04图片现已上线用于新的PythonAnywhere帐户]

答案 1 :(得分:3)

Not having the package python3.6-venv导致此问题。安装方式:
 sudo apt-get install python3.6-venv应该解决。