Factorio: Prevent pipes from breaking on invalid UTF-8 in client (#1078)

This commit is contained in:
recklesscoder
2022-10-09 04:10:22 +02:00
committed by GitHub
parent af6a72c3c3
commit 7b3ef012b9

View File

@@ -211,6 +211,8 @@ async def game_watcher(ctx: FactorioContext):
def stream_factorio_output(pipe, queue, process):
pipe.reconfigure(errors="replace")
def queuer():
while process.poll() is None:
text = pipe.readline().strip()