mirror of
https://github.com/shareAI-lab/analysis_claude_code.git
synced 2026-09-20 12:13:38 +08:00
fix: harden subprocess output decoding across lessons
This commit is contained in:
@@ -79,7 +79,7 @@ def run_bash(command: str) -> str:
|
||||
try:
|
||||
result = subprocess.run(
|
||||
command, shell=True, cwd=WORKDIR,
|
||||
capture_output=True, text=True, timeout=120,
|
||||
capture_output=True, text=True, errors="replace", timeout=120,
|
||||
)
|
||||
output = (result.stdout + result.stderr).strip()
|
||||
return output[:50000] if output else "(no output)"
|
||||
|
||||
Reference in New Issue
Block a user