Content-Type: multipart/mixed; boundary="Apple-Mail-7--657540573" --Apple-Mail-7--657540573 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset="us-ascii" hey = py2exe people,

when using the zipfile=3DNone option = to generate one .exe including everything I get import problems = recently.

running text.exe does nothing but = writing this error message to = my_stderr,log
 
Traceback (most recent call = last):
  File "test.py", line 7, in = <module>
ImportError: No module named = os

I am using Python 2.6.5 = and the latest py2exe from the SVN trunk (although I guess there are not = so much changes)

If I comment the zipfile = option a library.zip is created and test.py runs = fine.

thanks a lot for your = help!
michael

= --Apple-Mail-7--657540573 Content-Disposition: attachment; filename="setup.py" Content-Type: text/x-python-script; name="setup.py" Content-Transfer-Encoding: 7bit from setuptools import setup import shutil import os import sys main_script = 'test.py' # delete target folder before execution of py2app for path in ['dist', 'build']: if os.path.isdir(path): shutil.rmtree(path) APP = [main_script] INCLUDES = ['sip',] EXCLUDES = [ #'PyQt4.QtDesigner', 'PyQt4.QtNetwork', # 'PyQt4.QtOpenGL', 'PyQt4.QtScript', # 'PyQt4.QtSql', 'PyQt4.QtTest', # 'PyQt4.QtWebKit', 'PyQt4.QtXml', # 'PyQt4.phonon', 'scipy', 'rpy', 'Tkconstants', 'Tkinter', 'tcl', ] if sys.platform == 'darwin': OPTIONS = {'app' : APP} SYSTEM = 'py2app' DATA_FILES = [] EXTRA_OPTIONS = {'argv_emulation': True, 'includes': INCLUDES, 'excludes': EXCLUDES, 'dylib_excludes': [], 'resources': [], 'optimize': 2, 'compressed': True, } elif sys.platform == 'win32': import py2exe OPTIONS = {'windows': [{'script': main_script, }], 'zipfile' : None, } SYSTEM = 'py2exe' DATA_FILES = [] EXTRA_OPTIONS = {'includes': INCLUDES, 'excludes': EXCLUDES, 'optimize': 2, 'compressed': True, 'bundle_files': 1, #'ascii': True, #'xref': True, } setup( data_files=DATA_FILES, options={SYSTEM: EXTRA_OPTIONS}, setup_requires=[SYSTEM], **OPTIONS ) --Apple-Mail-7--657540573 Content-Transfer-Encoding: 7bit Content-Type: text/html; charset="us-ascii"
--Apple-Mail-7--657540573 Content-Disposition: attachment; filename="test.py" Content-Type: text/x-python-script; name="test.py" Content-Transfer-Encoding: 7bit import sys sys.stdout = open("my_stdout.log", "w") sys.stderr = open("my_stderr.log", "w") # just to show the general import problem import os, shutil, time from PyQt4.QtGui import * from PyQt4.QtCore import * from PyQt4.Qt import * class MainWindow(QMainWindow): def __init__(self): QMainWindow.__init__(self) self.show() self.raise_() if __name__ == "__main__": app = QApplication(sys.argv) main = MainWindow() main.raise_() sys.exit(app.exec_()) --Apple-Mail-7--657540573 Content-Transfer-Encoding: 7bit Content-Type: text/html; charset="us-ascii"
--Apple-Mail-7--657540573--