Make the DANTE button count all 19 watched devices.

It now reads 19/19 to match Dante Controller. NA-Tracks, SuperRack and the
ProPresenter Mac still alarm on their own buttons, so a drop is not flagged
twice; DANTE just shows 18/19 while one of them is missing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-08 09:15:46 -04:00
co-authored by Claude Opus 5.5
parent 195b111bb7
commit 38b6616e3f
4 changed files with 23 additions and 5 deletions
+11 -2
View File
@@ -268,7 +268,12 @@ def check_dante(chk, snap, ctx):
out.append((name, Result(OK)))
else:
out.append((name, Result(ERR, alias + " GONE", service_only=chk.get("service_only", False))))
if len(devices) > 1:
if chk.get("count_all"):
# Count every Dante device watched anywhere on the page, so the number
# matches Dante Controller; alarms still belong to each device's own button.
everything = ctx["dante_all"].get(label, set())
out.insert(0, ("conn", Result(OK, info="%d/%d" % (len(everything & present), len(everything)))))
elif len(devices) > 1:
out.insert(0, ("conn", Result(OK, info="%d/%d" % (seen, len(devices)))))
return out
@@ -571,7 +576,11 @@ class Engine:
# raw results for every check key
def evaluate(self, snap, now, service_on):
ctx = {"now": now, "service": service_on, "any_recording": False}
ctx = {"now": now, "service": service_on, "any_recording": False, "dante_all": {}}
for t in self.cfg["tiles"]:
for chk in t.get("checks", []):
if chk["type"] == "dante":
ctx["dante_all"].setdefault(chk["conn"], set()).update(chk["devices"])
for t in self.cfg["tiles"]:
for chk in t.get("checks", []):
if chk["type"] == "hyperdeck" and chk.get("rec_sync", True):