questions about py2exe and wax

I

iclinux

Using py2exe, I can convert a GUI Application with PythonCard to a
standalone windows program, and it works.
Then I try another GUI Toolkit named Wax, implement a GUI App, it
works. And I convert that app by py2exe. But this time, when run, it
show a messagebox that says:

"""
This application requires a version of wxPython greater than or equal
to 2.6, but a matching version was not found.

You currently have these version(s) installed:

Would you like to download a new version of wxPython?
"""
any suggestion?

the follows are the code of setup.py and the GUI App test.py.
///////////////////////////////////////////////////////////////////////////////////////////////
#setup.py

from distutils.core import setup

# py2exe stuff
import py2exe, os

setup(name='test',
version='0.1',
url='about:none',
author='anonymous',
author_email='[email protected]',
package_dir={'test':'.'},
packages=['test'],
windows=['test.py'],
)

///////////////////////////////////////////////////////////////////////////////////////////////
# test.py

import sys
sys.path.append("../..")

from wax import *

WaxConfig.default_font = ("Verdana", 9)

class MainFrame(Frame):
def Body(self):
self.AddComponent(Button(self, "one", event=self.OnClick))
self.Pack()
def OnClick(self, event=None):
# show an empty dialog... ugly, but it should work
dlg = Dialog(self, "JUst some dialog")
print dlg.OnCharHook
print dlg.ShowModal()
dlg.Destroy()

app = Application(MainFrame)
app.MainLoop()
///////////////////////////////////////////////////////////////////////////////////////////////
 
H

Hans Nowak

iclinux said:
Using py2exe, I can convert a GUI Application with PythonCard to a
standalone windows program, and it works.
Then I try another GUI Toolkit named Wax, implement a GUI App, it
works. And I convert that app by py2exe. But this time, when run, it
show a messagebox that says:

"""
This application requires a version of wxPython greater than or equal
to 2.6, but a matching version was not found.

You currently have these version(s) installed:

Would you like to download a new version of wxPython?
"""
any suggestion?

I got the same problem. Apparently the wxversion-related code in
wax/core.py that doesn't work well with py2exe. Try commenting out the
try..except clause in core.py; this worked for me. (Of course, I'll
have to think of a better solution for future releases of Wax...)

Feel free to contact me by private mail if you need more help.

Cheers,
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,009
Latest member
GidgetGamb

Latest Threads

Top