From 5306efa2e1032246d591110e1c41010576caaaa2 Mon Sep 17 00:00:00 2001 From: Kevin Li Date: Mon, 8 Dec 2025 08:41:50 +0000 Subject: [PATCH 1/2] Install python into Docker images to fix multilingual image fail with python not found when running with Modal --- src/swerex/deployment/modal.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/swerex/deployment/modal.py b/src/swerex/deployment/modal.py index 75b3b05a..e2262508 100644 --- a/src/swerex/deployment/modal.py +++ b/src/swerex/deployment/modal.py @@ -61,7 +61,7 @@ def from_registry(self, image: str) -> modal.Image: else: self.logger.warning("DOCKER_USERNAME and DOCKER_PASSWORD not set. Using public images.") secrets = None - return modal.Image.from_registry(image, secrets=secrets) + return modal.Image.from_registry(image, secrets=secrets, add_python="3.11") def from_ecr(self, image: str) -> modal.Image: self.logger.info(f"Building image from ECR {image}") From f86cbc2667ebc1fa5785a53e1eaa52a7a309b45c Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 8 Dec 2025 08:44:40 +0000 Subject: [PATCH 2/2] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/swerex/runtime/local.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/swerex/runtime/local.py b/src/swerex/runtime/local.py index fa46866f..522ce374 100644 --- a/src/swerex/runtime/local.py +++ b/src/swerex/runtime/local.py @@ -55,12 +55,12 @@ __all__ = ["LocalRuntime", "BashSession"] -def _split_bash_command(inpt: str) -> list[str]: +def _split_bash_command(input: str) -> list[str]: r"""Split a bash command with linebreaks, escaped newlines, and heredocs into a list of individual commands. Args: - inpt: The input string to split into commands. + input: The input string to split into commands. Returns: A list of commands as strings. @@ -70,11 +70,11 @@ def _split_bash_command(inpt: str) -> list[str]: "cmd1\\\n asdf" is one command (because the linebreak is escaped) "cmd1< tuple[int, int]: @@ -88,7 +88,7 @@ def find_range(cmd: bashlex.ast.node) -> tuple[int, int]: for cmd in parsed: start, end = find_range(cmd) - cmd_strings.append(inpt[start:end]) + cmd_strings.append(input[start:end]) return cmd_strings