[Distutils] Q about best practices now (or near future)

Daniel Holth dholth at gmail.com
Thu Jul 18 02:40:26 CEST 2013


On Wed, Jul 17, 2013 at 8:16 PM, Vinay Sajip <vinay_sajip at yahoo.co.uk> wrote:
> Donald Stufft <donald <at> stufft.io> writes:
>
>> There was discussion around ``python -m getpip`` and the general thinking of
> that
>> thread was that expecting users to type in an explicit command was adding
> extra
>> steps into the process (and placing a dependency on the network connection
>> being available whenever they happen to want to install something) and that
> was
>
> Well, it's just one additional command to type in - it's really neither here
> nor there as long as it's well documented.
>
> And the network connection argument is a bit of a straw man. Even if pip is
> present already, a typical pip invocation will fail if there is no network
> connection - hardly a good user experience. No reasonable user is going to
> complain if the instructions about installing packages include having a
> working network connection as a precondition.
>
> Whatever the technical merits of approach A vs. approach B, remember that my
> initial post was about following the process.
>
> Regards,
>
> Vinay Sajip

I didn't realize the current option was about bundling pip itself
rather than including a simple bootstrap. I have favored the bootstrap
approach (being any intentionally limited installer that you would be
daft to use generally). The rationale is that we would want to avoid
bundling a soon outdated "good enough" tool that people use instead of
letting better pypi-hosted tools thrive.

Setuptools is an example of a project that has this problem. Projects
might use the [even more*] terrible distutils in preference,
admonishing others to do the same, often without understanding why
apart from "it's in the standard library".

I didn't believe in the pip command that installs itself because I
would have been irritated if pip was installed by surprise - maybe I
have a reason to install it a different way - perhaps from source or
from a system package.

A bundled get-pip that avoids also having to install setuptools first,
and that is secure, and easy to remember, would be super handy.

The normal way to get pip these days is to install virtualenv. After
you get it it's just one command to run and pretty convenient.

* for the haters


More information about the Distutils-SIG mailing list