Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(pip_parse): support referencing dependencies to packages via hub #1856

Merged
merged 5 commits into from
Apr 30, 2024

Conversation

aignas
Copy link
Collaborator

@aignas aignas commented Apr 17, 2024

With this change we can in theory have multi-platform libraries in the
dependency cycle and use the pip hub repo for the dependencies. With
this we can also make the contents of whl_library not depend on what
platform the actual dependencies are. This allows us to support the
following topologies:

  • A platform-specific wheel depends on cross-platform wheel.
  • A cross-platform wheel depends on cross-platform wheel.
  • A whl_library can have select dependencies based on the interpreter
    version, e.g. pull in a tomli dependency only when the Python
    interpreter is less than 3.11.

Relates to #1663.
Work towards #735.

With this change we can in theory have multi-platform libraries in the
dependency cycle and use the pip hub repo for the dependencies. With
this we can also make the contents of `whl_library` not depend on what
platform the actual dependencies are. This allows us to support the
following topologies:

* A platform-specific wheel depends on cross-platform wheel.
* A cross-platform wheel depends on cross-platform wheel.
* A whl_library can have `select` dependencies based on the interpreter
  version, e.g. pull in a `tomli` dependency only when the Python
  interpreter is less than 3.11.

Relates to bazelbuild#1663.
Work towards bazelbuild#735.
@arrdem
Copy link
Contributor

arrdem commented Apr 17, 2024

Hmmm gave this a scan and don't have any immediate complaints. While any-any wheels are absolutely my majority use case, I'm a bit concerned about how to model their participation in cycles with platform-dependent artifacts but you've already got that called out as TBD so seems fine.

Copy link
Contributor

@philsc philsc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks reasonable. I am admittedly not at all familiar with the existing group_library code, which most of the PR seems concerned with.

@aignas aignas added this pull request to the merge queue Apr 29, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to a conflict with the base branch Apr 29, 2024
@aignas aignas enabled auto-merge April 30, 2024 01:21
@aignas aignas added this pull request to the merge queue Apr 30, 2024
Merged via the queue into bazelbuild:main with commit d3cec48 Apr 30, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants