Skip to content

Commit a7b6f36

Browse files
committed
Update backend.py
1 parent 36ab0fe commit a7b6f36

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

_build_backend/backend.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
get_requires_for_build_sdist = _orig.get_requires_for_build_sdist
1515

1616

17-
def strtobool(value: str) -> bool:
17+
def _strtobool(value: str) -> bool:
1818
"""
1919
Converts a environment variable string into a boolean value.
2020
"""
@@ -31,7 +31,7 @@ def get_requires_for_build_wheel(
3131
) -> list[str]:
3232
packages_orig = _orig.get_requires_for_build_wheel(config_settings)
3333
allow_ninja = any(
34-
strtobool(os.environ.get(var, ""))
34+
_strtobool(os.environ.get(var, ""))
3535
for var in ("CMAKE_PYTHON_DIST_FORCE_NINJA_DEP", "CMAKE_PYTHON_DIST_ALLOW_NINJA_DEP")
3636
)
3737
packages = []
@@ -45,7 +45,7 @@ def get_requires_for_build_wheel(
4545
return packages
4646

4747

48-
def bootstrap_build(temp_path: str, config_settings: dict[str, list[str] | str] | None = None) -> str:
48+
def _bootstrap_build(temp_path: str, config_settings: dict[str, list[str] | str] | None = None) -> str:
4949
import hashlib
5050
import re
5151
import shutil
@@ -126,7 +126,7 @@ def build_wheel(
126126
# Let's try bootstrapping CMake
127127
import tempfile
128128
with tempfile.TemporaryDirectory() as temp_path:
129-
cmake_path = bootstrap_build(temp_path, config_settings)
129+
cmake_path = _bootstrap_build(temp_path, config_settings)
130130
assert cmake_path
131131
os.environ["CMAKE_EXECUTABLE"] = cmake_path
132132
return _orig.build_wheel(wheel_directory, config_settings, metadata_directory)

0 commit comments

Comments
 (0)