I have some troubles with py2app; for some reason I have always the same error for all scripts that I developed. At the moment I am using last MacPorts version and after two days of testing I cannot figure out what is wrong.
One of the setup.py file for py2app is:
from setuptools import setup
APP = ['main.py']
OPTIONS = {'argv_emulation': True, 'includes': ['sip', 'PyQt4._qt', 'PyQt4.QtCore', 'PyQt4.QtGui'],
'excludes': ['PyQt4.QtDesigner', 'PyQt4.QtNetwork', 'PyQt4.QtOpenGL', 'PyQt4.QtScript', 'PyQt4.QtSql', 'PyQt4.QtTest', 'PyQt4.QtWebKit', 'PyQt4.QtXml', 'PyQt4.phonon']}
setup(
app=APP,
options={'py2app': OPTIONS},
setup_requires=['py2app'],
)
And this is the log:
python setup.py py2app
running py2app
creating /Users/opensw/SkyDrive/SISSA/Kymograph/build/bdist.macosx-10.6-intel/python2.7-standalone/app
creating /Users/opensw/SkyDrive/SISSA/Kymograph/build/bdist.macosx-10.6-intel/python2.7-standalone/app/collect
creating /Users/opensw/SkyDrive/SISSA/Kymograph/build/bdist.macosx-10.6-intel/python2.7-standalone/app/temp
creating build/bdist.macosx-10.6-intel/python2.7-standalone/app/lib-dynload
creating build/bdist.macosx-10.6-intel/python2.7-standalone/app/Frameworks
*** using recipe: virtualenv ***
WARNING: ImportError in sip recipe ignored: No module named matplotlib-1
WARNING: ImportError in sip recipe ignored: No module named scipy-0
*** using recipe: sip ***
*** using recipe: matplotlib ***
*** using recipe: scipy ***
Traceback (most recent call last):
File "setup.py", line 10, in <module>
setup_requires=['py2app'],
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/core.py", line 152, in setup
dist.run_commands()
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py", line 953, in run_commands
self.run_command(cmd)
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/distutils/dist.py", line 972, in run_command
cmd_obj.run()
File "/Users/opensw/SkyDrive/SISSA/Kymograph/py2app-0.7.3-py2.7.egg/py2app/build_app.py", line 553, in run
self._run()
File "/Users/opensw/SkyDrive/SISSA/Kymograph/py2app-0.7.3-py2.7.egg/py2app/build_app.py", line 741, in _run
self.run_normal()
File "/Users/opensw/SkyDrive/SISSA/Kymograph/py2app-0.7.3-py2.7.egg/py2app/build_app.py", line 816, in run_normal
self.process_recipes(mf, filters, flatpackages, loader_files)
File "/Users/opensw/SkyDrive/SISSA/Kymograph/py2app-0.7.3-py2.7.egg/py2app/build_app.py", line 710, in process_recipes
find_needed_modules(mf, packages=rval['packages'])
File "build/bdist.macosx-10.6-intel/egg/modulegraph/find_modules.py", line 199, in find_needed_modules
TypeError: 'NoneType' object has no attribute '__getitem__'
Thanks for any help.