From d37f91c9c864302e750385297d2aa2a0c9b43035 Mon Sep 17 00:00:00 2001 From: Eric Callahan Date: Wed, 29 Jun 2022 12:06:36 -0400 Subject: [PATCH] power: type checking fix For legacy purposes its possible that "initialize()" may be an awaitable. Ignore the type as it consues mypy. Signed-off-by: Eric Callahan --- moonraker/components/power.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/moonraker/components/power.py b/moonraker/components/power.py index 52c3136..a9830a4 100644 --- a/moonraker/components/power.py +++ b/moonraker/components/power.py @@ -191,7 +191,7 @@ class PrinterPower: f"Device [{name}] already configured") success = device.initialize() if asyncio.iscoroutine(success): - success = await success + success = await success # type: ignore if not success: self.server.add_warning( f"Power device '{device.get_name()}' failed to initialize"