##// END OF EJS Templates
Backport PR #8111: Fix error when log_datefmt is changed...
Min RK -
Show More
@@ -159,7 +159,7 b' class Application(SingletonConfigurable):'
159 159 help="The date format used by logging formatters for %(asctime)s"
160 160 )
161 161 def _log_datefmt_changed(self, name, old, new):
162 self._log_format_changed()
162 self._log_format_changed('log_format', self.log_format, self.log_format)
163 163
164 164 log_format = Unicode("[%(name)s]%(highlevel)s %(message)s", config=True,
165 165 help="The Logging format template",
@@ -80,6 +80,7 b' class TestApplication(TestCase):'
80 80 # trigger reconstruction of the log formatter
81 81 app.log.handlers = [handler]
82 82 app.log_format = "%(message)s"
83 app.log_datefmt = "%Y-%m-%d %H:%M"
83 84 app.log.info("hello")
84 85 nt.assert_in("hello", stream.getvalue())
85 86
General Comments 0
You need to be logged in to leave comments. Login now