Skip to content

Commit 81b26c6

Browse files
committed
buildifier fixes hopefully
1 parent 0c365e9 commit 81b26c6

File tree

3 files changed

+34
-2
lines changed

3 files changed

+34
-2
lines changed

python/bin/interpreter.bzl

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
# Copyright 2025 The Bazel Authors. All rights reserved.
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
"""Rules to access the underlying Python interpreter."""
16+
117
load("//python/private:interpreter.bzl", _interpeter = "interpreter")
218

319
interpreter = _interpeter

python/private/interpreter.bzl

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,19 @@
1+
# Copyright 2025 The Bazel Authors. All rights reserved.
2+
#
3+
# Licensed under the Apache License, Version 2.0 (the "License");
4+
# you may not use this file except in compliance with the License.
5+
# You may obtain a copy of the License at
6+
#
7+
# http://www.apache.org/licenses/LICENSE-2.0
8+
#
9+
# Unless required by applicable law or agreed to in writing, software
10+
# distributed under the License is distributed on an "AS IS" BASIS,
11+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12+
# See the License for the specific language governing permissions and
13+
# limitations under the License.
14+
15+
"""Implementation of the rules to access the underlying Python interpreter."""
16+
117
load("@bazel_skylib//lib:paths.bzl", "paths")
218
load("//python:py_runtime_info.bzl", "PyRuntimeInfo")
319
load(":sentinel.bzl", "SentinelInfo")

tests/support/sh_py_run_test.bzl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,8 +107,8 @@ to make the RBE presubmits happy, which disable auto-detection of a CC
107107
toolchain.
108108
""",
109109
),
110-
"python_version": attr.string(),
111110
"python_src": attr.label(),
111+
"python_version": attr.string(),
112112
"target": attr.label(executable = True, cfg = "target"),
113113
"_allowlist_function_transition": attr.label(
114114
default = "@bazel_tools//tools/allowlists/function_transition_allowlist",
@@ -135,9 +135,9 @@ def py_reconfig_test(*, name, **kwargs):
135135
reconfig_kwargs = {}
136136
reconfig_kwargs["bootstrap_impl"] = kwargs.pop("bootstrap_impl", None)
137137
reconfig_kwargs["extra_toolchains"] = kwargs.pop("extra_toolchains", None)
138+
reconfig_kwargs["python_src"] = kwargs.pop("python_src", None)
138139
reconfig_kwargs["python_version"] = kwargs.pop("python_version", None)
139140
reconfig_kwargs["target_compatible_with"] = kwargs.get("target_compatible_with")
140-
reconfig_kwargs["python_src"] = kwargs.pop("python_src", None)
141141

142142
inner_name = "_{}_inner".format(name)
143143
_py_reconfig_test(

0 commit comments

Comments
 (0)