Merge pull request #414 from kortix-ai/fix/tmux-capture-full-output

fix: ensure tmux capture-pane gets full output with -S - -E - flags
This commit is contained in:
Marko Kraemer 2025-05-20 15:49:32 +02:00 committed by GitHub
commit 29f2ed5a86
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 3 deletions

View File

@ -154,7 +154,7 @@ class SandboxShellTool(SandboxToolsBase):
break
# Get current output and check for common completion indicators
output_result = await self._execute_raw_command(f"tmux capture-pane -t {session_name} -p")
output_result = await self._execute_raw_command(f"tmux capture-pane -t {session_name} -p -S - -E -")
current_output = output_result.get("output", "")
# Check for prompt indicators that suggest command completion
@ -164,7 +164,7 @@ class SandboxShellTool(SandboxToolsBase):
break
# Capture final output
output_result = await self._execute_raw_command(f"tmux capture-pane -t {session_name} -p")
output_result = await self._execute_raw_command(f"tmux capture-pane -t {session_name} -p -S - -E -")
final_output = output_result.get("output", "")
# Kill the session after capture
@ -274,7 +274,7 @@ class SandboxShellTool(SandboxToolsBase):
return self.fail_response(f"Tmux session '{session_name}' does not exist.")
# Get output from tmux pane
output_result = await self._execute_raw_command(f"tmux capture-pane -t {session_name} -p")
output_result = await self._execute_raw_command(f"tmux capture-pane -t {session_name} -p -S - -E -")
output = output_result.get("output", "")
# Kill session if requested