fix: fail closed on unknown reconcile warnings

This commit is contained in:
Hermes Agent
2026-09-12 22:58:11 +09:00
parent 310b6f6dec
commit 853943f676
7 changed files with 92 additions and 7 deletions
@@ -280,6 +280,8 @@ def make_slots_rpc_handler(
codes = {case_code} if case_code else set()
if not codes:
raise RuntimeError(f"empty warning cases for slot_id={sid}")
if not codes.issubset(BLOCKING_RECONCILE_CASES):
raise RuntimeError(f"unsupported warning cases for slot_id={sid}")
warning_cases_by_slot[str(sid)] = codes
except Exception: # noqa: BLE001
_log.exception("warn_store warning query failed — fail-closed")