简体   繁体   English

虚拟环境建立在Sublime Text 3 for Windows上

[英]Virtual environment build on Sublime Text 3 for Windows

I seem to be unable to run my Sublime Text 3 build with any virtual environment. 我似乎无法在任何虚拟环境中运行我的Sublime Text 3构建。 My latest attempt has been to use the Virtualenv package in sublime text and use the following project settings: 我最近的尝试是在sublime文本中使用Virtualenv包并使用以下项目设置:

{
 "folders":
 [
  {
   "path": "."
  }
 ],

    "virutalenv": "C:\\Users\\alexa\\Envs\\test5",
    "settings": "C:\\Users\\alexa\\Envs\\test5\\Scripts\\python" 
}

My desired venv has pandas installed: 我想要的venv安装了pandas

C:\Users\alexa\Envs\test5\Scripts>activate
(test5) C:\Users\alexa\Envs\test5\Scripts>pip install pandas
Requirement already satisfied: pandas in c:\users\alexa\envs\test5\lib\site-packages
Requirement already satisfied: python-dateutil>=2 in c:\users\alexa\envs\test5\lib\site-packages (from pandas)
Requirement already satisfied: numpy>=1.7.0 in c:\users\alexa\envs\test5\lib\site-packages (from pandas)
Requirement already satisfied: pytz>=2011k in c:\users\alexa\envs\test5\lib\site-packages (from pandas)
Requirement already satisfied: six>=1.5 in c:\users\alexa\envs\test5\lib\site-packages (from python-dateutil>=2->pandas)

(test5) C:\Users\alexa\Envs\test5\Scripts>

But when I run my build, which is set to Python + Virtualenv , I get the following: 但是,当我运行我的构建,设置为Python + Virtualenv ,我得到以下内容:

Traceback (most recent call last):
  File "C:\Users\alexa\Desktop\SBP\first.py", line 2, in <module>
    import pandas 
ModuleNotFoundError: No module named 'pandas'
[Finished in 0.4s with exit code 1]
[shell_cmd: python -u "C:\Users\alexa\Desktop\SBP\first.py"]
[dir: C:\Users\alexa\Desktop\SBP]
[path: C:\Program Files\Dell\DW WLAN Card;;C:\Program Files (x86)\Intel\iCLS Client\;C:\Program Files\Intel\iCLS Client\;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\WIDCOMM\Bluetooth Software\;C:\Program Files\WIDCOMM\Bluetooth Software\syswow64;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;%SYSTEMROOT%\System32\WindowsPowerShell\v1.0\;C:\Python35-32;C:\Python35-32\Lib\site-packages\;C:\Python35-32\Scripts\;%USERPROFILE%\AppData\Local\Microsoft\WindowsApps;]

Have you checked out this question? 你看过这个问题吗? It seems pretty similar, and has some helpful responses. 它似乎很相似,并有一些有用的回应。 Also, try pip freeze within your virtual environment to see if pandas is installed in your virtual environment. 此外,在虚拟环境中尝试pip冻结,以查看是否在您的虚拟环境中安装了pandas。

Python modules not found in virtualenv 在virtualenv中找不到Python模块

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

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