[Distutils] PEP for specifying build dependencies
Robert Collins
robertc at robertcollins.net
Tue May 10 21:27:18 EDT 2016
On 11 May 2016 at 12:39, Brett Cannon <brett at python.org> wrote:
> Donald, Nathaniel, and I have finished our proposed PEP for specifying a
> projects' build dependencies. The PEP is being kept at
> https://github.com/brettcannon/build-deps-pep, so if you find spelling
> mistakes and grammatical errors please feel free to send a PR to fix them.
>
> The only open issue in the PEP at the moment is the bikeshedding topic of
> what to name the sub-section containing the requirements: `[package.build]`
> or `[package.build-system]` (we couldn't reach consensus among the three of
> us on this). Otherwise the three of us are rather happy with the way the PEP
> has turned out and look forward to this being the first step towards
> allowing projects to customize their build process better!
I find calling this build dependencies confusing, but perhaps thats just me.
Right now the work flow is this:
unpack tarball
run setup.py egg-info
introspect that for dependencies
download and install such dependencies (recursively) [ in future, it
would resolve ]
run setup.py install || setup.py wheel
install
1) What would pip do when it encounters one of these files?
unpack tarball
introspect and prepare an isolated environment with the specified dependencies
run setup.py egg_info
download and install such runtime dependencies (recursively) [ in
future, it would resolve ]
run setup.py install || setup.py wheel
install
?
Right now setup.py dependencies are turing complete, and its a useful
escape valve - this design seems to have no provision for that
(previous designs we've had here have had that). If the declared
dependencies are merely those needed to be able to invoke the build
system, rather than those needed to be able to successfully build, it
would preserve that escape valve.
2) what do we expect setuptools to do here? Is it reasonable to
introspect this file and union it with setup_requires?
3) Why does this specify ' what dependencies are required to go from
source checkout to built wheel' ? - build systems also run tests,
generate docs and man pages, produce other artifacts. Perhaps making
either the target more specific (wheel_requires = ...) or the
description less specific ('dependencies required to invoke the build
system') would be good.
I am not suggesting that we model all the things a build system might
do: thats YAGNI at best, scope creep at worst.
-Rob
--
Robert Collins <rbtcollins at hpe.com>
Distinguished Technologist
HP Converged Cloud
More information about the Distutils-SIG
mailing list