2013-01-04 29 views
0

我試了一個小時沒有任何進展。
Jython解釋器配置在PyDev中失敗

我正在使用Eclipse Juno和最新的PyDev。 Win 7.我在E磁盤上安裝了Jython。當我試圖配置PyDev的Jython解釋路線(偏好 - >的PyDev - >解釋器的Jython - >添加),我得到以下錯誤(在一個巨大的彈出窗口):

Error: Python stdlib not found or stdlib found without .py files. It seems that the Python /lib folder (which contains the standard library) was not found/selected during the install process or the stdlib does not contain the required .py files (i.e.: only has .pyc files). This folder (which contains files such as threading.py and traceback.py) is required for PyDev to function properly, and it must contain the actual source files, not only .pyc files. if you don't have the .py files in your install, please use an install from python.org or grab the standard library for your install from there. If this is a virtualenv install, the /Lib folder from the base install needs to be selected (unlike the site-packages which is optional). What do you want to do? Note: if you choose to proceed, the /Lib with the standard library .py source files must be added later on, otherwise PyDev may not function properly.

他們」重三種方案可供選擇:

  1. 重新選擇文件夾:剛剛試,並再次給出了錯誤。
  2. 取消:沒有令人印象深刻的有幫助
  3. 繼續反正:此選項特別怪異。我點擊它並沒有任何反應。 Jython解釋不能鏈接到的PyDev

回答

0

我不知道Jython的Windows上如何表現,所以這只是胡亂猜測:

運行Jython的第一次,它通常做一些基本的庫配置。嘗試在將其添加到PyDev之前自行運行Jython.jar。

4

官方的安裝說明也不太工作對我來說:http://www.jython.org/jythonbook/en/1.0/JythonIDE.html

這裏是我的發現如何使的Jython在Eclipse中運行(我使用開普勒4.3.1.M20130911-1000的PyDev 2.7。 5.2013052819):

  • 下載的Jython 獨立罐子(如版本2.5.3 2.7 -B1

    • http://jython.org/downloads.html

    • 暗示:在Eclipse的PyDev分佈式的PyDev-jython.jar似乎不是一個有效的jython發行 (例如eclipse/plugins/org.python.pydev.jython_2.7.5.2013052819/pydev-jython.jar

      • 它會拋出一些:NoClassDefFoundError: org/python/pydev/core/ObjectsPool$ObjectsPoolMap(這實際上是包含在例如eclipse/plugins/org.python.pydev_2.7.5.2013052819/core.jar

...

  • 窗口 - >首選項 - > PyDev->解釋Jython->新建 - >選擇jython-standalone-xxx.jar

    • 取消所有建議的文件夾(如果需要的話,你可以稍後添加它們)

    • 忽略警告(上面提到的問題)和select 請繼續反正

      • /Lib文件夾不能被發現,因爲它是獨立的jar(jython-standalone-xxx.jar!/Lib),這可能是確定以後

...

內包裝
  • 調整新創建的或現有的項目中使用這個解釋:

    • - >屬性 - > PyDev的 - 翻譯/ Grammar->的Jython

      • 語法:(例如2.5)
      • 解釋:(例如Jython的獨立-2.5.3.jar)(通常應> =語法版本)
0

之前用於配置解釋jython,請確保在新項目文件夾中選擇語言類型爲python/jython「。

相關問題