[Distutils] (How) do setuptools/distribute/pip handle circular dependencies?

Daniel Holth dholth at gmail.com
Tue Nov 13 04:44:00 CET 2012


On Mon, Nov 12, 2012 at 8:11 PM, Vinay Sajip <vinay_sajip at yahoo.co.uk>wrote:

> Daniel Holth <dholth <at> gmail.com> writes:
>
> >
> > I think it's necessary, but you would never hunt for "providing"
> packages as
> > part of dependency resolution. You would have to install those manually
> first.
>
> What makes you say that? I agree that, given a requirement "A", it doesn't
> make
> sense to search the entire index metadata to see what provides "A". But as
> for
> installing anything first - my distro package manager doesn't insist on
> downloading and installing anything first; it tells me what will need to be
> downloaded, installed and upgraded and lets me decide whether to go ahead.
> Why
> should it be different for Python packages with interdependencies?
>
> You haven't answered the question of *why* multi-valued Provides fields are
> needed as a matter of practicality, nor how one would tackle the practical
> issues
> of dependency/conflict resolution I mentioned if multi-valued Provides
> fields are
> used completely freely.


David, did you mention a paper about advanced dependency resolution
algorithms?

I don't know how dependency resolution should work. I only claim that the
very popular distribute needs to provide setuptools to work; right now it
does that with a hack by including a setuptools .egg-info directory. I
don't expect provides-dist to be a very widely used feature at all.

As for Provides-Dist you should just index that field locally and the
remote package index should let you search by provides instead of by the
package name (in that index the package name is one of the provides
values). You are searching the entire metadata, it's just already indexed
so it's efficient. Yum/apt cache all the available package metadata locally
too.

In Python/pypi, which is mostly libraries and not applications like in
Debian, a fork would be the normal use case for provides-dist. If the
plugin systems were more widely used then you might have more non-fork
provides-dist lines, for example if trac required at least one revision
control backend.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/distutils-sig/attachments/20121112/1dbb39a6/attachment-0001.html>


More information about the Distutils-SIG mailing list