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: add whl_filegroup #1904

Merged
merged 10 commits into from
May 20, 2024
Merged

feat: add whl_filegroup #1904

merged 10 commits into from
May 20, 2024

Conversation

lalten
Copy link
Contributor

@lalten lalten commented May 16, 2024

This adds a whl_filegroup rule which can take a wheel as input and extract it, making the
output available to consumers. A pattern is allowed to better control what files
are extracted.

This is handy to, e.g. get the numpy headers from the numpy wheel so they can be
used in a cc_library. e.g.,

Closes #1903
Fixes #1311

@lalten lalten requested a review from rickeylev as a code owner May 16, 2024 11:22
@lalten lalten mentioned this pull request May 16, 2024
Copy link
Collaborator

@aignas aignas left a comment

Choose a reason for hiding this comment

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

Thanks for the PR, looking promising :)

python/pip.bzl Outdated Show resolved Hide resolved
python/pip.bzl Outdated Show resolved Hide resolved
python/pip_install/tools/wheel_installer/wheel.py Outdated Show resolved Hide resolved
tests/integration/whl_filegroup/BUILD.bazel Outdated Show resolved Hide resolved
@lalten lalten requested a review from aignas May 18, 2024 10:56
@rickeylev
Copy link
Contributor

Aside from the pending comments, this looks pretty good. Thanks!

python/private/whl_filegroup/whl_filegroup.bzl Outdated Show resolved Hide resolved
python/private/whl_filegroup/whl_filegroup.bzl Outdated Show resolved Hide resolved
python/private/whl_filegroup/BUILD.bazel Outdated Show resolved Hide resolved
python/private/whl_filegroup/whl_filegroup.bzl Outdated Show resolved Hide resolved
tests/integration/whl_filegroup/BUILD.bazel Outdated Show resolved Hide resolved
@lalten lalten requested a review from rickeylev May 20, 2024 09:46
@rickeylev rickeylev added this pull request to the merge queue May 20, 2024
Merged via the queue into bazelbuild:main with commit 730a2e3 May 20, 2024
4 checks passed
@lalten lalten deleted the whl-filegroup branch May 28, 2024 08:49
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.

Target aliases don't work with annotations in pip_parse()
3 participants