Hi,
I can help a bit on this bug. I have already messed with py2app to generate .app packages and I have some code to automatically generate DMG images.
I first tried to add some basic options to py2app and ran it, to see if everything is ok. Unfortunately, it seems the latest version of modulegraph (necessary for py2app) is in conflict with the setuptools version that is used in the project (ImpLoader is part of pkg_resources).
running py2app
running build_py
copying src/allmydata/_version.py -> build/bdist.macosx-10.6-intel/lib/allmydata
creating /Users/geoffroycouprie/dev/python/tahoe-lafs/build/bdist.macosx-10.6-intel/python2.7-standalone/app
creating /Users/geoffroycouprie/dev/python/tahoe-lafs/build/bdist.macosx-10.6-intel/python2.7-standalone/app/collect
creating /Users/geoffroycouprie/dev/python/tahoe-lafs/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
Traceback (most recent call last):
File "setup.py", line 472, in <module>
**setup_args
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 "/Library/Python/2.7/site-packages/py2app/build_app.py", line 553, in run
self._run()
File "/Library/Python/2.7/site-packages/py2app/build_app.py", line 741, in _run
self.run_normal()
File "/Library/Python/2.7/site-packages/py2app/build_app.py", line 812, in run_normal
mf = self.get_modulefinder()
File "/Library/Python/2.7/site-packages/py2app/build_app.py", line 691, in get_modulefinder
debug=debug,
File "/Library/Python/2.7/site-packages/modulegraph/find_modules.py", line 274, in find_modules
find_needed_modules(mf, scripts, includes, packages)
File "/Library/Python/2.7/site-packages/modulegraph/find_modules.py", line 182, in find_needed_modules
mf.run_script(path)
File "/Library/Python/2.7/site-packages/modulegraph/modulegraph.py", line 673, in run_script
self.scan_code(co, m)
File "/Library/Python/2.7/site-packages/modulegraph/modulegraph.py", line 1015, in scan_code
imported_module = self._safe_import_hook(name, m, fromlist, level)[0]
File "/Library/Python/2.7/site-packages/modulegraph/modulegraph.py", line 917, in _safe_import_hook
mods = self.import_hook(name, caller, level=level)
File "/Library/Python/2.7/site-packages/modulegraph/modulegraph.py", line 684, in import_hook
q, tail = self.find_head_package(parent, name, level)
File "/Library/Python/2.7/site-packages/modulegraph/modulegraph.py", line 758, in find_head_package
q = self.import_module(head, qname, parent)
File "/Library/Python/2.7/site-packages/modulegraph/modulegraph.py", line 840, in import_module
searchpath, parent)
File "/Library/Python/2.7/site-packages/modulegraph/modulegraph.py", line 1119, in find_module
fp, buf, stuff = find_module(name, path)
File "/Library/Python/2.7/site-packages/modulegraph/modulegraph.py", line 248, in find_module
if loader.path.endswith('.py') or loader.path.endswith('.pyw'):
AttributeError: ImpLoader instance has no attribute 'path'
I could try to patch modulegraph to get it working, but I don't want to mess too much my current environment. Can tahoe be built under virtualenv?