Skip to content

Commit

Permalink
Logging: disable nice formatter
Browse files Browse the repository at this point in the history
This is an example to show that disabling the nice formatter, reduces the
response time and SQL queries executed when there is a `TemplateSyntaxError`.

See #10954
  • Loading branch information
humitos committed Feb 27, 2024
1 parent dd908ef commit 592c108
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion readthedocs/settings/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -901,7 +901,7 @@ def DOCKER_LIMITS(self):
'console': {
'level': 'INFO',
'class': 'logging.StreamHandler',
'formatter': 'plain_console',
'formatter': 'default',
},
'debug': {
'level': 'DEBUG',
Expand Down
1 change: 0 additions & 1 deletion readthedocs/settings/docker_compose.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,6 @@ def LOGGING(self):
# Allow Sphinx and other tools to create loggers
logging["disable_existing_loggers"] = False

logging["handlers"]["console"]["formatter"] = "colored_console"
logging["loggers"].update(
{
# Disable Django access requests logging (e.g. GET /path/to/url)
Expand Down

0 comments on commit 592c108

Please sign in to comment.