Wow. I think every single issue I've been having is because I used .pyc. It works fine with .py and .pyc.
On 9/08/2011 1:57 AM, Adam Estes wrote:Works for me. I've modified the "simple" py2exe sample included with py2exe. test.py has:
The problem has be reduced to a few lines of code. I can remove
everything and just have an application that tries to import something
thats not included with the .exe and it will cause this issue.
print "hello world"
In o:\temp I have a t.py which includes just one line:
print "hello from t.py!"
Creating the .exe from py2exe, I run it and get the expected:
hello worldFile "test.py", line 4, in <module>
Traceback (most recent call last):
ImportError: No module named t
But if I uncomment the sys.path.append and recreate it, I then get:
hello from t.py!
So sys.path modifications in py2exe works fine.