##// END OF EJS Templates
Make changes of Application.log_format effective (#3236) ...
Boris de Laage -
Show More
@@ -136,6 +136,12 b' class Application(SingletonConfigurable):'
136 136 log_format = Unicode("[%(name)s] %(message)s", config=True,
137 137 help="The Logging format template",
138 138 )
139 def _log_format_changed(self, name, old, new):
140 """Change the log formatter when log_format is set."""
141 _log_handler = self.log.handlers[0]
142 _log_formatter = logging.Formatter(new)
143 _log_handler.setFormatter(_log_formatter)
144
139 145 log = Instance(logging.Logger)
140 146 def _log_default(self):
141 147 """Start logging for this application.
General Comments 0
You need to be logged in to leave comments. Login now