[Distutils] patches: ez_setup.py: don't import setuptools into your current address space in order to learn its version number
Phillip J. Eby
pje at telecommunity.com
Thu Oct 4 01:20:35 CEST 2007
At 01:51 PM 10/3/2007 -0600, zooko wrote:
>Okay, this still uses subprocess but doesn't duplicate parse_version
>() from pkg_resources. Unlike the previous one that I posted, this
>one works because it does "import subprocess" at the top...
...which is why it won't work with Python 2.3. The subprocess module
wasn't added until 2.4.
Luckily, the subprocess is unnecessary; it's sufficient to:
del sys.modules['pkg_resources']
after upgrading setuptools, as long as it wasn't there to start with.
More information about the Distutils-SIG
mailing list