-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi Phillip, thanks for the response. On Dec 25, 2007, at 11:58 PM, Phillip J. Eby wrote:
At 05:51 PM 12/23/2007 -0500, Barry Warsaw wrote:
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
setuptools is causing me pain lately. Something's clearly broken, but setuptools is not helping me understand what, or how to fix it.
% /opt/local/bin/python2.5 setup.py develop -d staging running develop running egg_info creating mailman.egg-info writing requirements to mailman.egg-info/requires.txt writing mailman.egg-info/PKG-INFO writing top-level names to mailman.egg-info/top_level.txt writing dependency_links to mailman.egg-info/dependency_links.txt writing entry points to mailman.egg-info/entry_points.txt writing manifest file 'mailman.egg-info/SOURCES.txt' reading manifest template 'MANIFEST.in' writing manifest file 'mailman.egg-info/SOURCES.txt' running build_ext error: /opt/local/lib/python2.5/site-packages/site.py: No such file or directory
You have a broken setuptools installation in /opt, which is missing site.py. I'm afraid that setuptools isn't designed to gracefully handle the situation where random files are simply missing from the installation.
Would it be possible to just print the traceback? I haven't looked at the code, but a traceback at least would have helped me narrow down where setuptools was unhappy. The above error message really gives me no clue about where to go next, what to look for, or how to debug and fix the problem. Even a simple "Hey, your setuptools installation is broken, better reinstall it!" would have been very helpful.
I'm going to guess that it's missing because it was installed using an RPM or some other package put together by someone who had the hubris to assume that I would actually include files in setuptools that aren't *necessary* for its operation, and that it would therefore be "better" for them to remove it. If this is the case, please educate them regarding the error of their ways -- it will be taken more seriously from an actual user bitten by it, than from me.
This is the MacPorts version of Python, so I guess I have to shame them for busting setuptools. I ended up re-installing it manually to make it happy again. Your explanation about the root problem was helpful in understanding that this was probably the right course of action. :) Maybe I'll try to figure out why the MacPorts version broke.
% rm -rf mailman.egg-info % /usr/local/bin/python2.5 setup.py develop -d staging
I notice here you're using /usr instead of opt, and this worked, so it appears you have two setuptools installations: one working and one not. Be sure to praise the originator of your working installation as much as you shame the culprit responsible for your broken one. :)
Yes, /usr/local/bin/python2.5 is the one I built and installed from source, so I thank me for a working setuptools installation there! Way to go Barry! :) The other thing I didn't understand is why I got a different error message after the first "setup.py develop" and why it took deleting mailman.egg-info to get the original error message back. Maybe I should look at the setuptools code more carefully. <wink> Thanks, - -Barry -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (Darwin) iQCVAwUBR3VFR3EjvBPtnXfVAQJCTAP/esAOA4eigORGEdZghj45sVa5gprBCWaG 6g5O7X3gtp+lHPwc43fI1h3xqeXIZN7WB0I2hlRVRsVKaUfmUHJOTIBcX0suf+5v E9YaZAIywvGAQuuxMrh7qu7uB3QfvxFMRbxZdv7dtLE/a+XGLJ3P3ZezdgLLHkk/ 5uvrJvJnWnE= =YMI4 -----END PGP SIGNATURE-----