fix(vision): stdin=DEVNULL on rasterizer subprocess (stdin guard)

The salvaged #52688 rasterizer shell-out predates the TUI subprocess
stdin= guard; a rasterizer that prompts on stdin could hang the tool
under prompt_toolkit. DEVNULL it.
This commit is contained in:
teknium1 2026-07-04 14:29:34 -07:00 committed by Teknium
parent 4ac8c7546b
commit 6c068358e4

View file

@ -289,7 +289,10 @@ def _rasterize_svg_to_png(svg_path: Path, out_path: Path) -> bool:
):
if _shutil.which(cmd[0]):
try:
_subprocess.run(cmd, check=True, capture_output=True, timeout=30)
_subprocess.run(
cmd, check=True, capture_output=True, timeout=30,
stdin=_subprocess.DEVNULL,
)
if out_path.exists() and out_path.stat().st_size > 0:
return True
except Exception: