I am new to python and to py2exe so I hope you’ll bear with me.
Here is my problem. I am able to run my python scripts python using just the interpreter. However, when my bundle everything together using py2exe and try to run my exe, I get the following error:
<some other code that is just trying to import ctypes>
File "zipextimporter.pyo", line 82, in load_module
File "ctypes\__init__.pyo", line 20, in <module>
Exception: ('Version number mismatch', '1.0.2', '1.0.3')
I am using Python 2.5 which I believe has ctypes included in it. The following code from the ctypes file is where the exception is thrown:
__version__ = "1.0.3"
… some code…
from _ctypes import __version__ as _ctypes_version
…some other code…
if __version__ != _ctypes_version:
raise Exception, ("Version number mismatch", __version__, _ctypes_version)
My question is:
Does py2exe automatically include an older version _ctypes? (note the underscore) Or is there something else wrong?
If anyone can help, I would appreciate it.