uv-distribution-types 0.0.1

This is a component crate of uv
Documentation

Type hierarchy

When we receive the requirements from pip sync, we check which requirements already fulfilled in the users environment ([InstalledDist]), whether the matching package is in our wheel cache ([CachedDist]) or whether we need to download, (potentially build) and install it ([Dist]). These three variants make up [BuiltDist].

Dist

A [Dist] is either a built distribution (a wheel), or a source distribution that exists at some location. We translate every PEP 508 requirement e.g. from requirements.txt or from pyproject.toml's [project] dependencies into a [Dist] by checking each index.

  • [BuiltDist]: A wheel, with its three possible origins:
    • [RegistryBuiltDist]
    • [DirectUrlBuiltDist]
    • [PathBuiltDist]
  • [SourceDist]: A source distribution, with its four possible origins:
    • [RegistrySourceDist]
    • [DirectUrlSourceDist]
    • [GitSourceDist]
    • [PathSourceDist]

CachedDist

A [CachedDist] is a built distribution (wheel) that exists in the local cache, with the two possible origins we currently track:

  • [CachedRegistryDist]
  • [CachedDirectUrlDist]

InstalledDist

An [InstalledDist] is built distribution (wheel) that is installed in a virtual environment, with the two possible origins we currently track:

  • [InstalledRegistryDist]
  • [InstalledDirectUrlDist]

Since we read this information from direct_url.json, it doesn't match the information [Dist] exactly.