fix(logging): make shutdown queue retry explicit

This commit is contained in:
BiFangKNT
2026-10-18 19:29:36 +08:00
parent 4a989dd8aa
commit de26cebdac
+3 -1
View File
@@ -136,7 +136,9 @@ class NonBlockingConsoleHandler(logging.Handler):
self._queue.get_nowait()
self.dropped_records += 1
except queue.Empty:
pass
# The writer consumed the last record after Full;
# retry inserting the shutdown sentinel.
continue
self._worker.join(timeout=CONSOLE_CLOSE_TIMEOUT)