[Distutils] Python module for use in ‘setup.py’ but not to install

Ben Finney ben+python at benfinney.id.au
Sun Jan 18 21:35:29 CET 2015


Donald Stufft <donald at stufft.io> writes:

> > On Jan 17, 2015, at 7:47 PM, Ben Finney <ben+python at benfinney.id.au> wrote:
> > As it stands (‘python-daemon’ [0] version 2.0.3), the ‘version.py’ file
> > is correctly included in the source distribution, correctly used by the
> > ‘egg_info.writers’ entry point; but then ends up incorrectly installed
> > to the run-time packages library. This causes problems for subsequent
> > import of unrelated modules that happen to share the same name.
> > 
> > How can I specify to Setuptools that the file is needed in the source
> > distribution, is needed by the entry points for Setuptools, but should
> > not be installed along with the binary distribution?
>
> setup_requires?

Did you want to say anything else about that, for instance, how it
applies to the question or what specifically you suggest I do?

As it stands, I can only quote the documentation:

    setup_requires

    A string or list of strings specifying what other distributions need
    to be present in order for the setup script to run. […]

    <URL:https://setuptools.pypa.io/en/latest/setuptools.html>

The module in question is part of the same code base, and is not an
“other distribution”. So I don't know why you suggest this option.

-- 
 \      “Every valuable human being must be a radical and a rebel, for |
  `\      what he must aim at is to make things better than they are.” |
_o__)                                                      —Niels Bohr |
Ben Finney



More information about the Distutils-SIG mailing list