Skip to content

Commit dd11a20

Browse files
committed
Remove unused function
1 parent 318751b commit dd11a20

2 files changed

Lines changed: 0 additions & 19 deletions

File tree

src/codechecker.bzl

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ load(
2727
)
2828
load(
2929
"common.bzl",
30-
"python_path",
3130
"python_toolchain_type",
3231
"version_specific_attributes",
3332
)
@@ -231,7 +230,6 @@ def _codechecker_test_impl(ctx):
231230
environment_variables = {
232231
"RULES_CODECHECKER_MODE": "Test",
233232
"RULES_CODECHECKER_VERBOSITY": "INFO",
234-
"RULES_CODECHECKER_PYTHONPATH": python_path(ctx), # "/usr/bin/env python3",
235233
"RULES_CODECHECKER_CODECHECKER_BIN": CODECHECKER_BIN_PATH,
236234
"RULES_CODECHECKER_CODECHECKER_FILES": codechecker_files.short_path,
237235
"RULES_CODECHECKER_SEVERITIES": " ".join(ctx.attr.severities),

src/common.bzl

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -50,23 +50,6 @@ def python_toolchain_type():
5050
return "@bazel_tools//tools/python:toolchain_type"
5151
return "@rules_python//python:toolchain_type"
5252

53-
def python_path(ctx):
54-
"""
55-
Returns version specific Python path
56-
"""
57-
py_toolchain = ctx.toolchains[python_toolchain_type()]
58-
if hasattr(py_toolchain, "py3_runtime_info"):
59-
py_runtime_info = py_toolchain.py3_runtime_info
60-
python_path = py_runtime_info.interpreter
61-
elif hasattr(py_toolchain, "py3_runtime"):
62-
py_runtime = py_toolchain.py3_runtime
63-
python_path = py_runtime.interpreter_path
64-
else:
65-
fail("The resolved Python toolchain does not provide a Python3 runtime.")
66-
if not python_path:
67-
fail("The resolved Python toolchain does not provide a Python3 interpreter.")
68-
return python_path
69-
7053
def warning(ctx, msg):
7154
"""
7255
Prints message if the debug tag is enabled.

0 commit comments

Comments
 (0)