Spotify: alarms like every other key, any day (Sunday window is only for auto-fix)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -120,7 +120,7 @@ The **page number key** on every page follows the ALL button. It's green when ev
|
||||
| RESI | decoder (RossTalk connection and ping, 10.1.10.203); **encoder** (ping and its web page, 10.1.10.202, LAOEncoder); resi-studio-cues; Resi cloud reachable. Only shows they are on the network, not that the encoder is streaming. |
|
||||
| NET | NA Ingest's link; gateway 10.1.0.1 pings; **4+ connections from 3+ groups dropping within 10 s** (what happened Sunday 10/5 at 10:21). A blip **flashes amber** for 5 minutes, then goes by itself; press NET to stop the flashing, hold NET 2 s to clear it now. |
|
||||
| INGEST | the bridge (makes ProPresenter's stage screen count down to the next Resi cue), lobby captions server and caption screen, **ProdCom** (transcription, answering on :24480), ProdDash (running and its page on :24500); free disk |
|
||||
| SPOTIFY | Spotify on NA Ingest during Sunday services (06:30–13:30) must be playing the **Christian EDM 2026** playlist (`spotify:playlist:2uTpJVYQLFnKF1WnSOuco8`): **SPOTIFY CLOSED**, **NOT PLAYING**, or **WRONG PLAYLIST** (the song list comes from Spotify's public playlist page, refreshed every 6 h; it shows the first 100 of the playlist's songs, so the alarm needs 3 songs in a row that are not on it). Outside services it just shows PLAYING / PAUSED / CLOSED. Hold 2 s (and Sunday auto-fix) plays the playlist, opening Spotify first if needed. |
|
||||
| SPOTIFY | Spotify on NA Ingest must be playing the **Christian EDM 2026** playlist (`spotify:playlist:2uTpJVYQLFnKF1WnSOuco8`): **SPOTIFY CLOSED**, **NOT PLAYING**, or **WRONG PLAYLIST** (the song list comes from Spotify's public playlist page, refreshed every 6 h; it shows the first 100 of the playlist's songs, so the alarm needs 3 songs in a row that are not on it). Hold 2 s (and Sunday auto-fix) plays the playlist, opening Spotify first if needed. |
|
||||
| RF (group) | Shure connections; battery ≤1 bar red, 2 bars amber; RF interference (only while that transmitter is on); PSM RF muted; each receiver pinged every 3 s ("AXIENT 1 NO PING" in about 6–9 s; Companion's Shure modules take 18–27 s to notice). The address is the one set on its Companion connection, read from Companion's settings every minute, so changing it there is enough; `"host"` in `config.json` is only the fallback. |
|
||||
|
||||
A problem has to last 3 seconds before it shows, so one bad reading doesn't trigger an alarm. Recovery shows immediately.
|
||||
|
||||
+1
-2
@@ -170,8 +170,7 @@
|
||||
{ "type": "midi_rx", "source": "Network NA Ingest Listen", "name": "TRACKS IN" }
|
||||
] },
|
||||
{ "id": "spotify", "label": "SPOTIFY", "pos": [2, 7], "hold_always": "spotify_play", "checks": [
|
||||
{ "type": "spotify", "playlist": "spotify:playlist:2uTpJVYQLFnKF1WnSOuco8", "name": "Christian EDM 2026", "fix": "spotify_play",
|
||||
"windows": [{ "days": ["sun"], "start": "06:30", "end": "13:30" }] }
|
||||
{ "type": "spotify", "playlist": "spotify:playlist:2uTpJVYQLFnKF1WnSOuco8", "name": "Christian EDM 2026", "fix": "spotify_play" }
|
||||
] },
|
||||
{ "id": "vista", "label": "VISTA", "pos": [2, 5], "checks": [
|
||||
{ "type": "artnet", "source": "10.1.10.206", "max_silence_seconds": 5, "fix": "vista" }
|
||||
|
||||
Binary file not shown.
Binary file not shown.
+1
-4
@@ -424,14 +424,11 @@ def check_http(chk, snap, ctx):
|
||||
|
||||
|
||||
def check_spotify(chk, snap, ctx):
|
||||
"""Spotify on NA Ingest must be playing the service playlist during the check's "windows"
|
||||
(Sunday service). Outside them the button just says what it is doing."""
|
||||
"""Spotify on NA Ingest must be playing the service playlist."""
|
||||
sp_ = snap.spotify
|
||||
if sp_ is None:
|
||||
return [("spotify", Result(OK))] # not read yet
|
||||
state = "CLOSED" if not sp_.get("running") else (sp_.get("state") or "?").upper()
|
||||
if not in_windows(chk.get("windows", []), ctx["now"]):
|
||||
return [("spotify", Result(OK if state == "PLAYING" else OFF, info=state))] # grey when not playing
|
||||
if not sp_.get("running"):
|
||||
return [("spotify", Result(ERR, "SPOTIFY CLOSED", named=True))]
|
||||
if state != "PLAYING":
|
||||
|
||||
@@ -115,7 +115,7 @@ class TestChecks(unittest.TestCase):
|
||||
self.assertEqual(msg().level, sp.OK) # not read yet
|
||||
s.spotify = {"running": False}
|
||||
self.assertEqual(msg().msg, "SPOTIFY CLOSED")
|
||||
self.assertEqual(msg({"now": WEDNESDAY}).level, sp.OFF) # grey, not an alarm, outside services
|
||||
self.assertEqual(msg({"now": WEDNESDAY}).msg, "SPOTIFY CLOSED") # alarms like every other key, any day
|
||||
s.spotify = {"running": True, "state": "paused", "track": "spotify:track:a"}
|
||||
self.assertEqual(msg().msg, "NOT PLAYING")
|
||||
s.spotify["state"] = "playing"
|
||||
|
||||
Reference in New Issue
Block a user