From 5b8bca64fbeb2b944407758be8aadb8afea11359 Mon Sep 17 00:00:00 2001 From: AlexFucuson9 Date: Thu, 16 Jul 2026 20:06:45 +0700 Subject: [PATCH] fix: add creationflags to vision_tools SVG-to-PNG subprocess calls On Windows, rsvg-convert and inkscape subprocess calls flash a console window because CREATE_NO_WINDOW is missing. Both calls have stdin=DEVNULL and capture_output=True, so they are non-interactive. --- tools/vision_tools.py | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/vision_tools.py b/tools/vision_tools.py index 3c4724442c4c..1f0b6687727d 100644 --- a/tools/vision_tools.py +++ b/tools/vision_tools.py @@ -292,6 +292,7 @@ def _rasterize_svg_to_png(svg_path: Path, out_path: Path) -> bool: _subprocess.run( cmd, check=True, capture_output=True, timeout=30, stdin=_subprocess.DEVNULL, + **({"creationflags": 0x08000000} if sys.platform == "win32" else {}), ) if out_path.exists() and out_path.stat().st_size > 0: return True