Skip to content

Commit 94d5ee3

Browse files
committed
pre-commit
1 parent 63924fe commit 94d5ee3

File tree

8 files changed

+20
-17
lines changed

8 files changed

+20
-17
lines changed

python/bin/BUILD.bazel

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
load("//python:defs.bzl", "py_binary")
21
load(":interpreter.bzl", "interpreter")
32

43
package(default_visibility = ["//visibility:public"])

python/bin/interpreter.bzl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
load("//python/private:interpreter.bzl", _interpeter="interpreter")
1+
load("//python/private:interpreter.bzl", _interpeter = "interpreter")
22

33
interpreter = _interpeter

python/private/interpreter.bzl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
load("@bazel_skylib//lib:paths.bzl", "paths")
2-
load("@bazel_skylib//rules:common_settings.bzl", "BuildSettingInfo")
32
load("//python:py_runtime_info.bzl", "PyRuntimeInfo")
43
load(":sentinel.bzl", "SentinelInfo")
54
load(":toolchain_types.bzl", "TARGET_TOOLCHAIN_TYPE")

python/private/pypi/dependency_resolver/dependency_resolver.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,9 @@ def main(
173173
# the lines like: # via -r /absolute/path/to/<requirements_file>
174174
# with: # via -r <requirements_file>
175175
# For Windows, we should explicitly call .as_posix() to convert \\ -> /
176-
absolute_src_prefixes = [Path(src).absolute().parent.as_posix() + "/" for src in src_files]
176+
absolute_src_prefixes = [
177+
Path(src).absolute().parent.as_posix() + "/" for src in src_files
178+
]
177179

178180
if UPDATE:
179181
print("Updating " + requirements_file_relative)

python/private/site_init_template.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,9 @@ def _maybe_add_path(path):
163163
if cov_tool:
164164
_print_verbose_coverage(f"Using toolchain coverage_tool {cov_tool}")
165165
elif cov_tool := os.environ.get("PYTHON_COVERAGE"):
166-
_print_verbose_coverage(f"Using env var coverage: PYTHON_COVERAGE={cov_tool}")
166+
_print_verbose_coverage(
167+
f"Using env var coverage: PYTHON_COVERAGE={cov_tool}"
168+
)
167169

168170
if cov_tool:
169171
if os.path.isabs(cov_tool):

python/private/stage2_bootstrap_template.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -398,6 +398,7 @@ def main():
398398

399399
if os.environ.get("COVERAGE_DIR"):
400400
import _bazel_site_init
401+
401402
coverage_enabled = _bazel_site_init.COVERAGE_SETUP
402403
else:
403404
coverage_enabled = False

tests/interpreter/BUILD.bazel

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,17 @@ load("//tests/support:sh_py_run_test.bzl", "py_reconfig_test")
1717
[py_reconfig_test(
1818
name = "python_version_%s_test" % python_version,
1919
srcs = ["interpreter_test.py"],
20-
main = "interpreter_test.py",
2120
data = [
2221
"//python/bin:python",
2322
],
24-
deps = [
25-
"//python/runfiles",
26-
],
27-
python_version = python_version,
2823
env = {
2924
"EXPECTED_PYTHON_VERSION": python_version,
3025
},
26+
main = "interpreter_test.py",
27+
python_version = python_version,
28+
deps = [
29+
"//python/runfiles",
30+
],
3131
) for python_version in (
3232
"3.10",
3333
"3.11",
@@ -37,18 +37,18 @@ load("//tests/support:sh_py_run_test.bzl", "py_reconfig_test")
3737
[py_reconfig_test(
3838
name = "python_src_%s_test" % python_version,
3939
srcs = ["interpreter_test.py"],
40-
main = "interpreter_test.py",
4140
data = [
4241
"//python/bin:python",
4342
],
44-
deps = [
45-
"//python/runfiles",
46-
],
47-
python_src = "//tools/publish:twine",
48-
python_version = python_version,
4943
env = {
5044
"EXPECTED_PYTHON_VERSION": "3.11",
5145
},
46+
main = "interpreter_test.py",
47+
python_src = "//tools/publish:twine",
48+
python_version = python_version,
49+
deps = [
50+
"//python/runfiles",
51+
],
5252
) for python_version in (
5353
"3.10",
5454
"3.11",

tests/interpreter/interpreter_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
# limitations under the License.
1414

1515
import os
16-
import unittest
1716
import subprocess
17+
import unittest
1818

1919
from python.runfiles import runfiles
2020

0 commit comments

Comments
 (0)