Broken IPython example #1

Open
GaelVaroquaux opened this Issue May 2, 2011 · 1 comment

Comments

Projects
None yet
2 participants
Collaborator

GaelVaroquaux commented May 2, 2011

It seems like the IPython widget is implemented in neither backends. Or is this because I have the wrong version of IPython? In which case the error message is not terribly informative.

parietal ~/dev/enthought/ets/pyface/examples $ python ipython_shell.py
Traceback (most recent call last):
  File "ipython_shell.py", line 51, in 
    window.open()
  File "/home/varoquau/dev/enthought/ets/pyface/pyface/i_window.py", line 145, in open
    self._create()
  File "/home/varoquau/dev/enthought/ets/pyface/pyface/ui/wx/application_window.py", line 150, in _create
    contents = self._create_contents(body)
  File "ipython_shell.py", line 39, in _create_contents
    self._shell = IPythonWidget(parent)
  File "/home/varoquau/dev/enthought/ets/pyface/pyface/toolkit.py", line 92, in __init__
    raise NotImplementedError("the %s pyface backend doesn't implement %s" % (ETSConfig.toolkit, oname))
NotImplementedError: the wx pyface backend doesn't implement IPythonWidget
parietal ~/dev/enthought/ets/pyface/examples $ export ETS_TOOLKIT=qt4
parietal ~/dev/enthought/ets/pyface/examples $ python ipython_shell.py
Traceback (most recent call last):
  File "ipython_shell.py", line 51, in 
    window.open()
  File "/home/varoquau/dev/enthought/ets/pyface/pyface/i_window.py", line 145, in open
    self._create()
  File "/home/varoquau/dev/enthought/ets/pyface/pyface/ui/qt4/application_window.py", line 123, in _create
    contents = self._create_contents(self.control)
  File "ipython_shell.py", line 39, in _create_contents
    self._shell = IPythonWidget(parent)
  File "/home/varoquau/dev/enthought/ets/pyface/pyface/toolkit.py", line 92, in __init__
    raise NotImplementedError("the %s pyface backend doesn't implement %s" % (ETSConfig.toolkit, oname))
NotImplementedError: the qt4 pyface backend doesn't implement IPythonWidget
Contributor

epatters commented May 2, 2011

If any exception occurs when importing a backend implementation, Pyface simply says that it isn't implemented. This is extremely annoying and maybe one day I or someone else will fix it. In the meantime, you can comment out the appropriate lines in toolkit.py to see what is actually the problem.

But I wouldn't be surprised if this code has become broken. Unfortunately, I don't have time to investigate right now.

corranwebster pushed a commit that referenced this issue Jul 9, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment