The GUI event loop is already running in the pyzo kernel, and exec_()
does not block. In most cases your app should run fine without the need
for modifications. For clarity, this is what the pyzo kernel does:
- Prevent deletion of objects in the local scope of functions leading to exec_()
- Prevent system exit right after the exec_() call
QQQ
Not exactly smooth :-)
Summary
...there is lots of magic (behind-the-scenes complications) involved. Furthermore, pyzo renders graphics output in a popup Qt pane, which is too bad because Leo can't use the pyzo code as is.
pyzo puts the following warning in the IPython pane every time it produces graphics output: QQQ Note on using QApplication.exec_(): [snip] QQQ
It's time to create a Leo issue to track progress on [the Jupyter in Leo] project.
Edward. While perusing the jupyter sub-projects on Github, I came across https://github.com/jupyter/qtconsole