Skip to content

Commit 95f88cb

Browse files
committed
Fix unbound variable
1 parent a87de16 commit 95f88cb

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/gort/overwatcher/alerts.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -295,10 +295,10 @@ async def update_status(self) -> AlertsSummary:
295295
alerts_data = await get_lvmapi_route("/alerts/summary", timeout=10)
296296
except TimeoutException:
297297
self.log.warning("Timeout retrieving /alerts/summary from LVM API")
298-
self.state = None
299-
else:
300-
summary = AlertsSummary(**alerts_data)
301-
self.state = summary
298+
alerts_data = {}
299+
300+
summary = AlertsSummary(**alerts_data)
301+
self.state = summary
302302

303303
# For connectivity we want to avoid one single failure to trigger an alert
304304
# which closes the dome. The connectivity status is a set of triggers that

0 commit comments

Comments
 (0)