-
-
Notifications
You must be signed in to change notification settings - Fork 645
Description
🚀 feature request
Relevant Rules
package_annotation() from pip.bzl
Description
From docs, as of time of writing, you can add BUILD content, or add / remove files, but doesn't seem like you can change py_library(deps, imports).
For example, rerun.io is an awesome-looking package.
But it doesn't work when using using bazel + rules_python @ 0.34.0:
https://github.com/EricCousineau-TRI/repro/tree/e084a7434286cf426a71350f79755c7cbab6d6eb/bazel/rules_python_rerun
Seems like either the wheel doesn't declare things s.t. rules_python adds ./site-packages/rerun_sdk to the Python path (it only adds ./site-packages).
Describe the solution you'd like
For now, would be nice to have something like
pip_parse(
...
annotations = {
"rerun-sdk": package_annotation(
extra_imports = ["site-packages/rerun_sdk"],
),
},
)
Describe alternatives you've considered
For now, will try package_annotation(..., additive_build_content), and include that whenever I use pip("rerun-sdk").
EDIT: This workaround worked: EricCousineau-TRI/repro@96e1336