From 0909f20d592e7bfd0dab5a556aa5e937772f65a6 Mon Sep 17 00:00:00 2001 From: webbrain-one <295484252+webbrain-one@users.noreply.github.com> Date: Tue, 11 Aug 2026 09:13:56 +0300 Subject: [PATCH] Fix crash with non-seekable stdout in Python 3 Using `/dev/stdout` raises `io.UnsupportedOperation` in Python 3 because standard streams are not seekable. Adjust the runner to support non-seekable file paths. --- daemon/runner.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/daemon/runner.py b/daemon/runner.py index 3f9f658..3972339 100644 --- a/daemon/runner.py +++ b/daemon/runner.py @@ -77,9 +77,9 @@ def __init__(self, app): self.app = app self.daemon_context = DaemonContext() self.daemon_context.stdin = open(app.stdin_path, 'r') - self.daemon_context.stdout = open(app.stdout_path, 'w+') + self.daemon_context.stdout = open(app.stdout_path, 'w') self.daemon_context.stderr = open( - app.stderr_path, 'w+', buffering=0) + app.stderr_path, 'w', buffering=0) self.pidfile = None if app.pidfile_path is not None: