How to make PyDev Debug Console Interactive?

喜夏-厌秋 提交于 2019-12-08 07:18:55

问题


PyDev offers both a debug console as well as an interactive console. However, I am still not able to execute interactive commands such as %timeit in the debug console.

How can I make the debug console interactive?


回答1:


You can't currently make the debug console an IPython interactive console -- you can have a "regular" interactive console by right-clicking a stack-frame in the Debug view > PyDev > Debug Console, but it's not really an interactive console with IPython support.

Starting an IPython session in the context of a breakpoint could end up having side effects that could break your debug session, so, it wasn't implemented -- although in practice, there's probably nothing stopping anyone from implementing it (the only thing is that there should probably be a preference so that users could opt out of it and the time and willingness to actually implement it).

Another option is turn things the other way around. Start an interactive console and have a debugger attached to it -- go to window > preferences > PyDev > Interactive Console and check Connect console to Debug Session?

See: http://www.pydev.org/manual_adv_interactive_console.html#full-debug-support-in-interactive-console for more details.



来源:https://stackoverflow.com/questions/41532818/how-to-make-pydev-debug-console-interactive

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!