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

fix(bzlmod): pass only non-default values to whl_library #2002

Merged
merged 1 commit into from
Jun 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ A brief description of the categories of changes:
other toolchains support.
* (providers) {obj}`PyRuntimeInfo` doesn't require passing the
`interpreter_version_info` arg.
* (bzlmod) Correctly pass `isolated`, `quiet` and `timeout` values to `whl_library`
and drop the defaults from the lock file.

### Removed
* (pip): Removes the `entrypoint` macro that was replaced by `py_console_script_binary` in 0.26.0.
Expand Down
6 changes: 5 additions & 1 deletion python/private/bzlmod/pip.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,11 @@ def _create_whl_repos(module_ctx, pip_attr, whl_map, whl_overrides, group_map, s
quiet = (pip_attr.quiet, True),
timeout = (pip_attr.timeout, 600),
)
whl_library_args.update({k: v for k, (v, default) in maybe_args_with_default.items() if v == default})
whl_library_args.update({
k: v
for k, (v, default) in maybe_args_with_default.items()
if v != default
})

if get_index_urls:
# TODO @aignas 2024-05-26: move to a separate function
Expand Down