Skip to content

Commit 98dea66

Browse files
committed
update the example
1 parent 087fb57 commit 98dea66

File tree

2 files changed

+14
-4
lines changed

2 files changed

+14
-4
lines changed

examples/bzlmod/MODULE.bazel

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,11 +105,21 @@ python.single_version_platform_override(
105105
use_repo(python, "python_3_10", "python_3_9", "python_versions", "pythons_hub")
106106

107107
# EXPERIMENTAL: This is experimental and may be removed without notice
108-
uv = use_extension("@rules_python//python/uv:uv.bzl", "uv")
109-
uv.toolchain(uv_version = "0.4.25")
108+
uv = use_extension(
109+
"@rules_python//python/uv:uv.bzl",
110+
"uv",
111+
dev_dependency = True,
112+
)
113+
uv.toolchain(
114+
name = "uv_toolchains",
115+
version = "0.5.24",
116+
)
110117
use_repo(uv, "uv_toolchains")
111118

112-
register_toolchains("@uv_toolchains//:all")
119+
register_toolchains(
120+
"@uv_toolchains//:all",
121+
dev_dependency = True,
122+
)
113123

114124
# This extension allows a user to create modifications to how rules_python
115125
# creates different wheel repositories. Different attributes allow the user

python/uv/private/uv.bzl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ def _uv_toolchain_extension(module_ctx):
106106
# NOTE: We may wish to enforce a policy where toolchain configuration is only allowed in the root module, or in rules_python. See https://github.com/bazelbuild/bazel/discussions/22024
107107
continue
108108

109-
# Note, that the first registration will always win, givin priority to
109+
# Note, that the first registration will always win, giving priority to
110110
# the root module.
111111

112112
for platform_attr in mod.tags.platform:

0 commit comments

Comments
 (0)