fix(party-mode): decode subprocess JSON as UTF-8 on Windows (#2687)

This commit is contained in:
Alex Verkhovsky
2026-08-06 08:11:40 -07:00
committed by GitHub
parent 0601263bb1
commit ea6a5d900c
@@ -46,7 +46,9 @@ except ImportError: # pragma: no cover - guarded for <3.11
def _run_json(cmd):
"""Run a resolver script and parse its JSON stdout. None on any failure."""
try:
out = subprocess.run(cmd, capture_output=True, text=True, timeout=60)
out = subprocess.run(
cmd, capture_output=True, text=True, encoding="utf-8", timeout=60
)
except (OSError, subprocess.SubprocessError):
return None
if out.returncode != 0 or not out.stdout.strip():