From 61cfd72d1fc4766a9736405f1c3cbe84b2cd6c38 Mon Sep 17 00:00:00 2001 From: alemidev Date: Tue, 26 Apr 2022 23:23:46 +0200 Subject: [PATCH] Assure notifier is initialized first --- src/treepuncher/treepuncher.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/treepuncher/treepuncher.py b/src/treepuncher/treepuncher.py index d0d9823..25d208b 100644 --- a/src/treepuncher/treepuncher.py +++ b/src/treepuncher/treepuncher.py @@ -235,8 +235,10 @@ class Treepuncher( await super().start() if not self.notifier: self.notifier = Notifier(self) + await self.notifier.initialize() for m in self.modules: - await m.initialize() + if not isinstance(m, Notifier): + await m.initialize() self._processing = True self._worker = asyncio.get_event_loop().create_task(self._work()) self.scheduler.resume()