Eclipse Oxygen 4.7.0中的PyDev 5.9.2运行时错误

时间:2017-08-25 15:30:31

标签: python eclipse pydev

我在Windows 7和WinPython 3.6.0.1上使用PyDev作为Eclipse扩展(通过更新站点)安装。即使语法检查器被破坏,我也可以运行代码,即标记为错误"未定义的变量:print"简单的行

print("hello") 

我认为问题与我在启动Eclipse时在错误日志中出现的错误有关:

Error creating python process - exited before creating sockets - exitValue = (1).

这是异常堆栈跟踪

java.lang.RuntimeException: Error creating python process - exited before creating sockets - exitValue = (1).
ProcessInfo:

 - Executed: C:\tools\winpython\3.6.0.1\python-3.6.0.amd64\python.exe -u C:\Portables\Eclipse\plugins\org.python.pydev_5.9.2.201708151115\pysrc\pycompletionserver.py 55270

 - Environment:
ALLUSERSPROFILE=C:\ProgramData
[... list of all the environment variables ...]

 - Working Dir:
C:\Portables\Eclipse\plugins\org.python.pydev_5.9.2.201708151115\pysrc

 - OS:
Windows 7

 - Std output:


 - Err output:
Traceback (most recent call last):

  File "C:\Portables\Eclipse\plugins\org.python.pydev_5.9.2.201708151115\pysrc\pycompletionserver.py", line 13, in <module>

    from _pydevd_bundle.pydevd_constants import IS_JYTHON

ModuleNotFoundError: No module named '_pydevd_bundle'



    at org.python.pydev.core.log.Log.log(Log.java:54)

    at org.python.pydev.editor.codecompletion.shell.AbstractShell.startIt(AbstractShell.java:290)

    at org.python.pydev.editor.codecompletion.shell.ShellsContainer.getServerShell(ShellsContainer.java:232)

    at org.python.pydev.editor.codecompletion.shell.ShellsContainer.getServerShell(ShellsContainer.java:165)

    at org.python.pydev.editor.codecompletion.shell.AbstractShell.getServerShell(AbstractShell.java:222)

    at org.python.pydev.editor.codecompletion.revisited.modules.CompiledModule.createTokensFromServer(CompiledModule.java:372)

    at org.python.pydev.editor.codecompletion.revisited.modules.CompiledModule.<init>(CompiledModule.java:176)

    at org.python.pydev.editor.codecompletion.revisited.SystemModulesManager.getBuiltinModule(SystemModulesManager.java:332)

    at org.python.pydev.editor.codecompletion.revisited.SystemModulesManager.getBuiltinModule(SystemModulesManager.java:1)

    at org.python.pydev.ui.interpreters.AbstractInterpreterManager.getBuiltinMod(AbstractInterpreterManager.java:146)

    at org.python.pydev.ui.interpreters.AbstractInterpreterManager.getBuiltinCompletions(AbstractInterpreterManager.java:118)

    at org.python.pydev.plugin.nature.PythonNature.getBuiltinCompletions(PythonNature.java:1126)

    at org.python.pydev.editor.codecompletion.revisited.AbstractASTManager.getBuiltinComps(AbstractASTManager.java:1801)

    at org.python.pydev.editor.codecompletion.revisited.AbstractASTManager.getBuiltinCompletions(AbstractASTManager.java:1787)

    at com.python.pydev.analysis.scopeanalysis.AbstractScopeAnalyzerVisitor.<init>(AbstractScopeAnalyzerVisitor.java:151)

    at com.python.pydev.analysis.visitors.OccurrencesVisitor.<init>(OccurrencesVisitor.java:105)

    at com.python.pydev.analysis.OccurrencesAnalyzer.analyzeDocument(OccurrencesAnalyzer.java:50)

    at com.python.pydev.analysis.builder.AnalysisBuilderRunnable.doAnalysis(AnalysisBuilderRunnable.java:271)

    at com.python.pydev.analysis.builder.AbstractAnalysisBuilderRunnable.run(AbstractAnalysisBuilderRunnable.java:162)

    at org.python.pydev.core.concurrency.RunnableAsJobsPoolThread$1.run(RunnableAsJobsPoolThread.java:140)

    at org.eclipse.core.internal.jobs.Worker.run(Worker.java:56)

所以,显然错误是这个

ModuleNotFoundError: No module named '_pydevd_bundle'

我尝试重新安装PyDev(看起来安装可能会被破坏),但无济于事。想法?

1 个答案:

答案 0 :(得分:0)

我可能真的发现了这个问题。我发现我安装的WinPython发行版是&#34; WinPython Zero&#34;,它没有附加软件包。我卸载了它并安装了&#34;默认&#34; WinPython;现在调试器正在按预期工作。我想那时需要一些库来启用调试。也许一个更具信息性的错误信息会对此有所帮助,因为我得到的这个并不是很多。

有趣的是,这正是PyCharm中发生的事情:https://youtrack.jetbrains.com/issue/PY-24198