fix: clear stale errors on successful poll — prevents phantom error alerts
Same fix as applied to the pi Zulip extension: last_error_msg and last_error_at are now cleared on every successful poll cycle, not just on reconnect. Health monitors no longer show stale errors.
This commit is contained in:
@@ -449,6 +449,10 @@ class ZulipAdapter(BasePlatformAdapter):
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
# Clear stale errors on successful poll cycle
|
||||
self._health_stats["last_error_msg"] = None
|
||||
self._health_stats["last_error_at"] = None
|
||||
|
||||
# Gen 4: Heartbeat logging — prove poll loop is alive
|
||||
now = time.time()
|
||||
if now - self._last_heartbeat_time > HEARTBEAT_INTERVAL:
|
||||
|
||||
Reference in New Issue
Block a user