shadwickman 159 Posting Pro in Training

For some reason (this hasn't happened to me in the past), any wxPython scripts I package via py2exe crash on my other Windows computer (lacking a Python install). If I try running it on my other machine, I get an error message telling me to look at a log file that Windows has created. This is what it says (test.exe was my program):

Traceback (most recent call last):
  File "test.pyw", line 1, in <module>
  File "zipextimporter.pyc", line 82, in load_module
  File "wx\__init__.pyc", line 45, in <module>
  File "zipextimporter.pyc", line 82, in load_module
  File "wx\_core.pyc", line 4, in <module>
  File "zipextimporter.pyc", line 98, in load_module
ImportError: MemoryLoadLibrary failed loading wx\_core_.pyd

So it looks like there's a problem when trying to import something for the wxPython module. This happened on even the most basic of wxPython programs... this is the script I ran through py2exe:

import wx

app = wx.App()
frame = wx.Frame(None, -1, "Hello wxPython!", size=(300, 175))
frame.Centre()
frame.Show(True)
app.MainLoop()

And using this setup script for py2exe:

from distutils.core import setup
import py2exe

setup( name='test.exe', scripts=['test.pyw'] )

Does anyone have any clue as to what's messing up here? My guess is something with packaging wxPython as it says it's missing wx\_core_.py. I haven't had issues with this sort of thing in the past, but does anyone have any idea what I should try doing to fix it? Thanks in advance!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.