From c0ce78c64ab0d477e9744c671cffe52e5b12d068 Mon Sep 17 00:00:00 2001
From: llamantino <213239228+llamantino@users.noreply.github.com>
Date: Mon, 13 Oct 2025 16:00:10 +0200
Subject: [PATCH] fix: remove the hardcoded 5-minute timeout from the docker
pull command (#11322)
---
openhands-cli/openhands_cli/gui_launcher.py | 11 +----------
openhands-cli/tests/test_gui_launcher.py | 2 --
openhands/cli/gui_launcher.py | 11 +----------
3 files changed, 2 insertions(+), 22 deletions(-)
diff --git a/openhands-cli/openhands_cli/gui_launcher.py b/openhands-cli/openhands_cli/gui_launcher.py
index 49cb5579c4..d2c149c9d5 100644
--- a/openhands-cli/openhands_cli/gui_launcher.py
+++ b/openhands-cli/openhands_cli/gui_launcher.py
@@ -113,21 +113,12 @@ def launch_gui_server(mount_cwd: bool = False, gpu: bool = False) -> None:
pull_cmd = ['docker', 'pull', runtime_image]
print_formatted_text(HTML(_format_docker_command_for_logging(pull_cmd)))
try:
- subprocess.run(
- pull_cmd,
- check=True,
- timeout=300, # 5 minutes timeout
- )
+ subprocess.run(pull_cmd, check=True)
except subprocess.CalledProcessError:
print_formatted_text(
HTML('❌ Failed to pull runtime image.')
)
sys.exit(1)
- except subprocess.TimeoutExpired:
- print_formatted_text(
- HTML('❌ Timeout while pulling runtime image.')
- )
- sys.exit(1)
print_formatted_text('')
print_formatted_text(
diff --git a/openhands-cli/tests/test_gui_launcher.py b/openhands-cli/tests/test_gui_launcher.py
index ce8abadaa4..05d5c00c74 100644
--- a/openhands-cli/tests/test_gui_launcher.py
+++ b/openhands-cli/tests/test_gui_launcher.py
@@ -111,8 +111,6 @@ class TestLaunchGuiServer:
[
# Docker pull failure
(subprocess.CalledProcessError(1, 'docker pull'), None, 1, False, False),
- # Docker pull timeout
- (subprocess.TimeoutExpired('docker pull', 300), None, 1, False, False),
# Docker run failure
(MagicMock(returncode=0), subprocess.CalledProcessError(1, 'docker run'), 1, False, False),
# KeyboardInterrupt during run
diff --git a/openhands/cli/gui_launcher.py b/openhands/cli/gui_launcher.py
index fb3b6a6ff8..544f8987c7 100644
--- a/openhands/cli/gui_launcher.py
+++ b/openhands/cli/gui_launcher.py
@@ -103,21 +103,12 @@ def launch_gui_server(mount_cwd: bool = False, gpu: bool = False) -> None:
pull_cmd = ['docker', 'pull', runtime_image]
print_formatted_text(HTML(_format_docker_command_for_logging(pull_cmd)))
try:
- subprocess.run(
- pull_cmd,
- check=True,
- timeout=300, # 5 minutes timeout
- )
+ subprocess.run(pull_cmd, check=True)
except subprocess.CalledProcessError:
print_formatted_text(
HTML('❌ Failed to pull runtime image.')
)
sys.exit(1)
- except subprocess.TimeoutExpired:
- print_formatted_text(
- HTML('❌ Timeout while pulling runtime image.')
- )
- sys.exit(1)
print_formatted_text('')
print_formatted_text(