From 1b03d31c6b8aed3260108299afc9a435131ac972 Mon Sep 17 00:00:00 2001 From: jesopo Date: Mon, 26 Nov 2018 14:23:20 +0000 Subject: Switch back to logging events as 2 messages as a lot of other logs can happen between the start and end of an event and grouping them together is very useful --- src/EventManager.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/EventManager.py') diff --git a/src/EventManager.py b/src/EventManager.py index 5dba8f73..a9ee6066 100644 --- a/src/EventManager.py +++ b/src/EventManager.py @@ -178,6 +178,8 @@ class EventHook(object): def _call(self, kwargs: dict, safe: bool, maximum: typing.Optional[int] ) -> typing.List[typing.Any]: event_path = self._get_path() + self.log.trace("calling event: \"%s\" (params: %s)", + [event_path,kwargs]) start = time.monotonic() event = self._make_event(kwargs) @@ -195,8 +197,8 @@ class EventHook(object): raise total_milliseconds = (time.monotonic() - start) * 1000 - self.log.trace("called event in %fms: \"%s\" (params: %s)", - [total_milliseconds, event_path, kwargs]) + self.log.trace("event \"%s\" called in %fms", + [event_path, total_milliseconds]) self.check_purge() -- cgit v1.3.1-10-gc9f91