[wxpython-users] AttributeError, wxPython, py2exe
Mike Driscoll
mike at pythonlibrary.org
Wed Sep 3 07:19:52 PDT 2008
Hi Robert,
> Hi,
>
> I'd like to create an executable from my python project that uses
> wxPython with py2exe.
> I have
> Python 2.5.2
> wxPython 2.8-win32-unicode
> py2exe 0.6.8-win32-py25
> installed and I have the following problem when I try to run the
> resulting executable:
>
> Traceback (most recent call last):
> File "morinus.py", line 4, in <module>
> File "wx\__init__.pyc", line 45, in <module>
> File "wx\_core.pyc", line 14713, in <module>
> File "wx\_controls.pyc", line 7458, in <module>
> AttributeError: 'module' object has no attribute
> '_AxBaseWindow_swigregister'
>
> The problem is that it worked fine with ansi wxPython but not with
> unicode.
> I have already reinstalled everything but did't help.
>
> I am using "import wx" everywhere in my code.
>
> I'd really appreciate if somebody helped me.
>
> Robert
You could try GUI2Exe and see if it generates a different setup.py file
than the one you have created. You can get that cool tool here:
http://xoomer.alice.it/infinity77/main/GUI2Exe.html
It has a quick tutorial on that page, but you can also take a look at my
more in-depth tutorial here: http://www.blog.pythonlibrary.org/?p=68
Finally, can you send show us your setup.py? Posting to the py2exe
user's group might prove helpful too:
https://lists.sourceforge.net/lists/listinfo/py2exe-users
-------------------
Mike Driscoll
Blog: http://blog.pythonlibrary.org
Python Extension Building Network: http://www.pythonlibrary.org
More information about the wxpython-users
mailing list