Skip to content

Support {root:uri}-like workflow in build-system.requires #990

@LecrisUT

Description

@LecrisUT

Consider a project with multiple sub-packages that depend on each other through their cmake find_package. We want that during the build step with isolation the appropriate dependency is used:

  • when built from sdist: use the PyPI index
  • when built from local git checkout: use relative path pointer
  • when built from git url/archive: same as local checkout (if possible)

Borrowing hatch's {root:uri} the effective pyproject.toml would look like

[build-system]
requires = [ "foo >=1.0 @ {root:uri}/../bar" ]

Afaiu this is not possible because the pip/uv fronted would have to recognise that pattern and it would not be acceptable on PyPI.

But we have dynamically inserted build-system.requires, so wouldn't it be possible to expose that on a tool.scikit-build field and expand it with or without the @ qualifier?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions