This repository was archived by the owner on Apr 26, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Logging loop after SIGHUP when a StreamHandler
is configured
#6550
Comments
I thought this used to work, but I just tried the same thing on v0.20.0 (the version that introduced reloading the log config on SIGHUP) and it did the same. |
This seems like yet another reason that redirecting stdio is a terrible idea, and we should implement #1539 (comment). |
StreamHandler
is configured
(the default logging config no longer has a |
as of #8268, you no longer get a stack overflow, but you do get logging that looks like this:
It's worth noting that this (logs-to-stderr plus redirect-stdio-to-logs) is the default configuration for the docker image. |
StreamHandler
is configuredStreamHandler
is configured
(a StreamHandler is no longer the default for the non-docker case as of #8040) |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
If you use the default logging config, which has a
StreamHandler
pointing at sys.stderr, and do not set--no-redirect-stdio
, then when you send synapse a SIGHUP, it will stack overflow and abort.The problem appears to be that when you SIGHUP it, the streamhandler gets repointed at the redirected stderr, which goes back into a logger: so as soon as anything is logged, we get an infinite loop.
The text was updated successfully, but these errors were encountered: