Skip to content

Conversation

@tiran
Copy link
Collaborator

@tiran tiran commented Jan 5, 2026

Introduce new configuration for source resolver and downloads. The new
system uses profiles for common tasks:

  • pypi-sdist: resolve versions of sdists from PyPI, download sdist
  • pypi-prebuilt: resolve versions of platform wheels from PyPI,
    download pre-built wheel from PyPI.
  • pypi-download: resolve versions of any package from PyPI, download
    from external URL (with {version} variable)
  • pypi-git: resolve versions for any package from PyPI, git clone
    (with {version} variable)
  • gitlab: resolve and download from Gitlab (tarball or git clone)
  • github: resolve and download from Github (tarball or git clone)

The new settings will eventually replace download_source,
resolver_dist, and git_options top-level options as well as
wheel_server_url and pre_built flags for variants.

Extend the resolver API with alternative download URLs. Resolvers can
now return download links to alternative locations or retrieval methods.

The `PyPIProvider` now accepts a `override_download_url` parameter. The
value overwrites the default PyPI download link. The string can contain
a `{version}` format variable.

The GitHub and Gitlab tag providers can return git clone URLs for
`https` and `ssh` transport. The URLs uses pip's VCS syntax like
`git+https://host/repo.git@tag`.

The new enum `RetrieveMethod` has a `from_url()` constructor that parses
an URL and splits it into method, url, and git ref.

Signed-off-by: Christian Heimes <cheimes@redhat.com>
@mergify mergify bot added the ci label Jan 5, 2026
@tiran tiran force-pushed the source-resolve-api branch from e200ace to f402870 Compare January 5, 2026 14:33
Introduce new configuration for source resolver and downloads. The new
system uses profiles for common tasks:

- `pypi-sdist`: resolve versions of sdists from PyPI, download sdist
- `pypi-prebuilt`: resolve versions of platform wheels from PyPI,
  download pre-built wheel from PyPI.
- `pypi-download`: resolve versions of any package from PyPI, download
  from external URL (with `{version}` variable)
- `pypi-git`: resolve versions for any package from PyPI, git clone
  (with `{version}` variable)
- `gitlab`: resolve and download from Gitlab (tarball or git clone)
- `github`: resolve and download from Github (tarball or git clone)

The new settings will eventually replace `download_source`,
`resolver_dist`, and `git_options` top-level options as well as
`wheel_server_url` and `pre_built` flags for variants.

Signed-off-by: Christian Heimes <cheimes@redhat.com>
@LalatenduMohanty
Copy link
Member

Not specific to this PR but have we considered adding Local File Provider — For air-gapped environments with local tarballs in the past.

@tiran tiran force-pushed the source-resolve-api branch from f402870 to d1523d9 Compare January 6, 2026 07:14
@tiran
Copy link
Collaborator Author

tiran commented Jan 6, 2026

The PR depends on #871

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants