Eclipse的Mercurial插件无法找到Python – 如何修复?

Mercurial plugin for Eclipse can't find Python--how to fix?

我在Mac OS X 10.7.1(Lion)上。我刚刚下载了一个新的Eclipse IDE副本,用于JavaEE开发人员,并安装了MyalAPI插件。我收到以下错误消息:

abort: couldn't find mercurial libraries in [...assorted Python directories...].

我确实安装了python 2.6.1和3.2.1。我还有一个目录System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7,它在它查找mercurial库的位置列表中。hg -y debuginstall给了我同样的信息。

这些库的名称是什么,Eclipse在安装插件时可能将它们放在哪里,以及如何告诉Eclipse它们在哪里(或者我应该将它们移到哪里)?

谢谢,戴夫

完整错误消息如下:

abort: couldn't find mercurial libraries in
[/usr/platlib/Library/Python/2.6/site-packages /usr/local/bin
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python27.zip
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plat-darwin
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plat-mac
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/plat-mac/lib-scriptpackages
/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-tk
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-old
/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/lib-dynload
/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/PyObjC
/Library/Python/2.7/site-packages] (check your install and PYTHONPATH)


没有人回答我,但我找到了答案。也许它能帮助别人。

我终于意识到,由于命令行的'hg-y debuginstal'给了我同样的错误消息,所以这根本不是Eclipse问题(duh)。重新安装新版Mercurial解决了这个问题。


我在Mac上安装了两个Mercurial。一个直接安装,另一个使用MacPort。移除直接安装解决了问题。

  • 移除直接安装,使用易于安装-M mercurial

  • 将"mercurial executable"路径更新为"/opt/local/bin/hg"eclipse->preference->team->mercurial->

  • 重新启动Eclipse