[Distutils] The problem with Setuptools on Python 3.

P.J. Eby pje at telecommunity.com
Wed Apr 22 18:04:51 CEST 2009


At 04:52 PM 4/22/2009 +0200, Lennart Regebro wrote:
>On Wed, Apr 22, 2009 at 16:18, P.J. Eby <pje at telecommunity.com> wrote:
> > Er, no.  It only means that you need Python 2 to be installed 
> *while porting
> > a package* to Python 3.
>
>No. It means it needs to be installed when installing the package from
>a source distribution. Which is the normal way of distributing
>modules.

I don't understand you.  Here is what I understand:

1. Setuptools requires setuptools
2. Setuptools doesn't run on Python 3 (yet)
3. There needs to be a way to build a Py3 version of setuptools in 
order to fix #2

Therefore, adding a new setuptools comand to do #3, that runs under 
either Py2 or Py3, fixes #1 in the context of #2.

However, once setuptools *does* run on Python 3, then there is no 
longer a need for the build process to run exclusively under...

Aha!  Now I (finally) get what you're talking about!  In order for 
this to work, there'd have to be a separate Py3 source distro for 
setuptools, or else setup.py would need to have a (non-setuptools 
depending) way to build its own Python3 version.

Okay, now that I actually understand the problem, I will give it some 
more thought.  I see now that what I was proposing works only for the 
porting process and for non-self-dependent packages, but not for 
distribution of self-dependent packages like setuptools.  Either the 
sdist would need to ship with a Python3 version already included (or 
have a distinct Py3 sdist), or there'd need to be a 
non-setuptools-dependent bootstrap process.

I'll have to think about this one a bit more.



More information about the Distutils-SIG mailing list