Rename simulate_32_bit to enforce_32_bit

This commit is contained in:
mayeut
2023-09-18 21:28:33 +02:00
parent 1646b08659
commit 137dc1a2cf
3 changed files with 15 additions and 15 deletions
+1 -1
View File
@@ -423,7 +423,7 @@ def build(options: Options, tmp_path: Path) -> None: # noqa: ARG001
with OCIContainer(
image=build_step.container_image,
simulate_32_bit=build_step.platform_tag.endswith("i686"),
enforce_32_bit=build_step.platform_tag.endswith("i686"),
cwd=container_project_path,
engine=options.globals.container_engine,
) as container:
+3 -3
View File
@@ -85,7 +85,7 @@ class OCIContainer:
self,
*,
image: str,
simulate_32_bit: bool = False,
enforce_32_bit: bool = False,
cwd: PathOrStr | None = None,
engine: OCIContainerEngineConfig = DEFAULT_ENGINE,
):
@@ -94,7 +94,7 @@ class OCIContainer:
raise ValueError(msg)
self.image = image
self.simulate_32_bit = simulate_32_bit
self.enforce_32_bit = enforce_32_bit
self.cwd = cwd
self.name: str | None = None
self.engine = engine
@@ -110,7 +110,7 @@ class OCIContainer:
if detect_ci_provider() == CIProvider.travis_ci and platform.machine() == "ppc64le":
network_args = ["--network=host"]
simulate_32_bit = self.simulate_32_bit
simulate_32_bit = self.enforce_32_bit
container_machine = call(
self.engine.name, "run", "--rm", self.image, "uname", "-m", capture_stdout=True
).strip()