[Distutils] Beyond wheels 1.0: helping downstream, FHS and more

Chris Barker chris.barker at noaa.gov
Tue Apr 14 23:02:14 CEST 2015

On Tue, Apr 14, 2015 at 9:46 AM, Paul Moore <p.f.moore at gmail.com> wrote:

> > Could an "extension" be -- "run this arbitrary Python script" ?
> The main point (as I see it) of an "extension" is that it's
> distributed independently of the packages that use it. So you get to
> decide to use an extension (and by inference audit it if you want)
> *before* it gets run as part of an installation.

OK, I think this is getting clearer to me now -- an Extension is (I suppose
arbitrary) block of python code, but what goes into the wheel is not the
code, but rather a declarative configuration for the extension. then at
install-time, the actual code that runs is separate from the wheel, which
gives the end user greater control, plus these nifty features....

> Extensions get peer
> review by the community, and bad ones get weeded out,

>  the independent review and quality control

>  there's also portability. And code quality. And
> consistency.

And I'll add that this would promote code re-use and DRY.

I'd be much happier installing a project that used a well-known "start
> menu manager extension"

So where would that code live? and how would it be managed? I'm thinking:
 - In package on PyPi like anything else
 - a specification in install_requires
 - pip auto-installs it (if not already there) when the user goes to
install the wheel.

Is that the idea?

Of course, if the project I want to install makes using the extension
> mandatory for the install to work, I still don't have a real choice -
> I accept the extension or I can't use the code I want -

well, you can't easily auto-install it anyway -- you could still do a
source install, presumably.

but there's an
> extra level of transparency involved. And hopefully most extensions
> will be optional, in practice.

There's a bit to think about in the API/UI here. If an
installation_extension is used by a package, and it's specified in
install_requires, then it's going to get auto-magically installed an used
with a regular old "pip install". If we are worried about code review and
users being in control of what extensions they use, then how to we make it
obvious that a given extension is in use, but optional, and how to turn it
off if you  want?



Christopher Barker, Ph.D.

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

Chris.Barker at noaa.gov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/distutils-sig/attachments/20150414/4bf3bee2/attachment.html>

More information about the Distutils-SIG mailing list