Search code examples
pythonwxpythonwxwidgets

Wx not importing


So I'm using python 3.3 and recently I have tried to install wxpython and wxwidgets. Synaptic package manager shows that wxversion, wxtools and wxgtk2.8 are all installed. When I use the python idle I get an import error however when I use iPython (command line with auto complete etc...) it happily runs the code.

What's going on?

Error Message:

Traceback (most recent call last):
    File "<pyshell#0>", line 1, in <module> import wx
ImportError: No module named 'wx'

Solution

  • IPython must be running Python 2.x because wxPython 2.8.x ONLY works with Python 2.x. If you want to use wxPython in Python 3, you have to use wxPython 2.9-Phoenix. Please note the Phoenix is kind of alpha in that ONLY the core widgets are currently available in it.

    You can read more about it and download it from here: