简体   繁体   English

Visual Studio PyTools创建虚拟环境失败

[英]Visual Studio PyTools Create Virtual Environment Fail

I am trying to create a Virtual Environment using PyTools for Visual Studio 2013. I've manually installed Python before installing Visual Studio 2013 and PyTools, and it functions correctly. 我正在尝试使用PyTools for Visual Studio 2013创建虚拟环境。在安装Visual Studio 2013和PyTools之前,我已经手动安装了Python,并且它可以正常运行。

When I try to create a virtual environment through PyTools I get the following error: 当我尝试通过PyTools创建虚拟环境时,出现以下错误:

AssertionError: Filename c:\\Python27\\Lib\\os.py does not start with any of these prefixes: ['C:\\Python27'] AssertionError:文件名c:\\ Python27 \\ Lib \\ os.py不以以下任何前缀开头:['C:\\ Python27']

C:\\Python27 and C:\\Python27\\Lib are in my PYTHONPATH. C:\\ Python27和C:\\ Python27 \\ Lib在我的PYTHONPATH中。

The assert error was caused because maybe you don't have a PYTHONPATH environment variable setup. 断言错误是由于您可能没有PYTHONPATH环境变量设置而引起的。

The socket error was caused because there is no included the PythonXX\\DLLs folder. 套接字错误是由于没有包含PythonXX \\ DLLs文件夹而引起的。

The full PYTHONPATH environment variable should look follows: 完整的PYTHONPATH环境变量应如下所示:

PYTHONPATH=C:\\Python27;C:\\Python27\\Lib;C:\\Python27\\DLLs PYTHONPATH = C:\\ Python27; C:\\ Python27 \\库; C:\\ Python27 \\的DLL

Here is a full post of that topic StackOverflow link 这是该主题StackOverflow链接的完整文章

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM