[wxPython-users] error while importing all from wx

Christopher Barker Chris.Barker at noaa.gov
Wed Jul 26 23:34:24 PDT 2006


Hameed U. Khan wrote:
> Hi,
>  I'm having problems while importing all from wx on Ubuntu Dapper 6.06 
> with python 2.4.3 installed.

> Following is the error I'm getting while executin "from wx import *"

Well, you shouldn't get that error, but you shouldn't use "import * " 
anyway. see:

http://wiki.wxpython.org/index.cgi/wxPython_Style_Guide

When you do import *, a bunch of name mangling has to go on to add the 
"wx" back at the beginning of all the identifiers. This is done to keep 
backward compatibility, but it may be broken.

Does it work if you just use "import wx" ?

-Chris



-- 
Christopher Barker, Ph.D.
Oceanographer
                                      		
NOAA/OR&R/HAZMAT         (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

Chris.Barker at noaa.gov




More information about the wxpython-users mailing list