At 05:29 PM 7/12/2005 -1000, Bob Ippolito wrote:
Well, just do the second suggestion then. "Install" the eggs somewhere, unzipped, and make sure it's on sys.path during setup.py. Maybe you could crank the ez_setup wheels (or whatever module is appropriate, I haven't looked at eggs yet) at the top of your setup.py and automate this.
Well, if it just has to be on sys.path during setup.py, then it should be working now, shouldn't it? I mean, if he installed them to Python's site-packages. In the alternative, he could create a wrapper command that calls require("project==version") to find all the eggs and put them on sys.path.
So, I guess my suggestion to Kevin is to try installing to a directory on sys.path, using the new --always-unzip option to force the packages to be unzipped, and then try hacking py2app to do a require() before looking for dependencies (consulting the setuptools "test" command for an example).
I suspect this means that the packages will get merged into one another with no distinction at runtime, but whatever works, works.
One interesting thing that eggs do, however, in the problem of module-finding is that they potentially reduce the question to one of just identifying what portions of the standard library each egg uses, which in some ways is a significantly easier problem because import tricks (e.g. dynamic imports, exec's, etc.) involving the standard library occur far less often. It might be worth adding something modulegraph-ish to setuptools to support this, although it's not at the top of my list right now.