Skip to content

Commit 63813eb

Browse files
committed
set the tcw
1 parent 80088c6 commit 63813eb

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

python/uv/private/BUILD.bazel

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ bzl_library(
4242
visibility = ["//python/uv:__subpackages__"],
4343
deps = [
4444
"//python:py_test_bzl",
45+
"//python/private:bzlmod_enabled_bzl",
4546
"@bazel_skylib//rules:expand_template",
4647
],
4748
)

python/uv/private/lock.bzl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717

1818
load("@bazel_skylib//rules:expand_template.bzl", "expand_template")
1919
load("//python:py_test.bzl", "py_test")
20+
load("//python/private:bzlmod_enabled.bzl", "BZLMOD_ENABLED") # buildifier: disable=bzl-visibility
2021

2122
visibility(["//..."])
2223

@@ -282,6 +283,7 @@ def lock(*, name, srcs, out, args = [], env = None, **kwargs):
282283
locker_target = "{}.run".format(name)
283284
maybe_out = _maybe_file(out)
284285
out_new = out + ".new"
286+
target_compatible_with = kwargs.pop("target_compatible_with", []) if BZLMOD_ENABLED else ["@platforms//:incompatible"]
285287

286288
_lock(
287289
name = name,
@@ -300,6 +302,7 @@ def lock(*, name, srcs, out, args = [], env = None, **kwargs):
300302
],
301303
args = args,
302304
env = env,
305+
target_compatible_with = target_compatible_with,
303306
)
304307

305308
# A target for updating the in-tree version directly by skipping the in-action

0 commit comments

Comments
 (0)