mirror of
https://mau.dev/maunium/synapse.git
synced 2024-12-15 00:43:51 +01:00
Merge branch 'develop' of github.com:matrix-org/synapse into state-chache
This commit is contained in:
commit
91f0e41153
1 changed files with 3 additions and 1 deletions
|
@ -18,6 +18,7 @@ from synapse.util.logcontext import LoggingContextFilter
|
||||||
from twisted.python.log import PythonLoggingObserver
|
from twisted.python.log import PythonLoggingObserver
|
||||||
import logging
|
import logging
|
||||||
import logging.config
|
import logging.config
|
||||||
|
import yaml
|
||||||
|
|
||||||
|
|
||||||
class LoggingConfig(Config):
|
class LoggingConfig(Config):
|
||||||
|
@ -79,7 +80,8 @@ class LoggingConfig(Config):
|
||||||
logger.addHandler(handler)
|
logger.addHandler(handler)
|
||||||
logger.info("Test")
|
logger.info("Test")
|
||||||
else:
|
else:
|
||||||
logging.config.fileConfig(self.log_config)
|
with open(self.log_config, 'r') as f:
|
||||||
|
logging.config.dictConfig(yaml.load(f))
|
||||||
|
|
||||||
observer = PythonLoggingObserver()
|
observer = PythonLoggingObserver()
|
||||||
observer.start()
|
observer.start()
|
||||||
|
|
Loading…
Reference in a new issue