diff --git a/ripper/encode.py b/ripper/encode.py index e5a0e92..7aa5939 100644 --- a/ripper/encode.py +++ b/ripper/encode.py @@ -83,6 +83,8 @@ def run_encode(cmd: list[str], input_path: str | None = None) -> int: stdout=subprocess.PIPE, stderr=subprocess.STDOUT, text=True, + encoding="utf-8", + errors="replace", ) progress = Progress( diff --git a/ripper/scanner.py b/ripper/scanner.py index 18ff0af..481d47b 100644 --- a/ripper/scanner.py +++ b/ripper/scanner.py @@ -74,6 +74,8 @@ def run(cmd: list[str], capture: bool = True) -> subprocess.CompletedProcess: cmd, capture_output=capture, text=True, + encoding="utf-8", + errors="replace", )