如何在IDE上激活VirtualEnv [英] How to activate VirtualEnv on IDE

查看:73
本文介绍了如何在IDE上激活VirtualEnv的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要使用IDE调试项目,但是它需要在 virtualenv 上运行.我已经使用此

I need to Debug my Project using IDE but It requires to be run on a virtualenv. I have created a virtualenv on the IDE Clion using this documentation:

但是我无法激活它.当我运行项目时,它会自动激活吗?我也尝试过,但是没有运行.当我从终端运行它时,一切正常,但由于我对gdb不太熟悉,调试变得很困难.如何在IDE上激活我的 virtualenv ?

But I am not able to activate it. Will it get automatically activated, when I run the project? I have tried that also but it is not running. when I am running it from terminal everything works fine but debugging becomes difficult as I am not much familiar with gdb. How do I activate my virtualenv on IDE??

任何帮助将不胜感激.

谢谢灰烬

推荐答案

我找到了解决此问题的方法.基本上,您只需要使用源TargetDir/bin/activate从终端激活virtualenv,然后从那里启动IDE.在那之后一切正常.

I found a way to solve this problem. Basically you just have to activate the virtualenv from terminal, using source TargetDir/bin/activate and launch your IDE from there. It is working fine after that.

谢谢灰烬

这篇关于如何在IDE上激活VirtualEnv的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆