pydev安装后找不到python库 [英] pydev doesn't find python library after installation

查看:393
本文介绍了pydev安装后找不到python库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用Django和PyDev / Eclipse。我刚刚安装了带有 setup.py install 的django-treebeard,它已经安装在我的site-packages目录 C:\Python26\Lib\站点包。我可以使用 import treebeard 在python shell中成功导入它。但是PyDev抱怨当我尝试导入它时无法解决它。



不幸的是,我没有PyDev的经验,我认为它会自动接收site-packages目录中的所有内容,但显然没有。我缺少什么?



谢谢

解决方案

Pydev不自动重新扫描site-packages文件夹。你需要去 Preferences->口译 - > Python ,然后单击应用以使其再次扫描。


I'm using Django and PyDev/Eclipse. I just installed django-treebeard with setup.py install and it got installed in my site-packages directory C:\Python26\Lib\site-packages. I can successfully import it in the python shell with import treebeard. However PyDev complains that it cannot resolve it when I try to import it.

Unfortunately I have no experience with PyDev and I assumed that it would automatically pick up everything in the site-packages directory but apparently it does not. What am I missing?

thanks

解决方案

Pydev doesn't automatically rescan the site-packages folder. You need to go to Preferences-> Interpreter -> Python and click apply to make it scan again.

这篇关于pydev安装后找不到python库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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