This commit is contained in:
Octopus
2026-07-20 13:41:44 +08:00
committed by GitHub
+4 -1
View File
@@ -66,7 +66,10 @@ class LogInterceptor(io.TextIOWrapper):
super().write(data)
def flush(self):
super().flush()
try:
super().flush()
except (OSError, ValueError):
pass
for cb in self._flush_callbacks:
cb(self._logs_since_flush)
self._logs_since_flush = []