Woonsocket's startup list covered: M32, SoundGrid link, MIDI on Macs without python

From the WS Production Startup checklist (check.watersmedia.org):
- M32 (the "X32" there is a Midas M32 at 10.2.1.146): Woonsocket's Companion got the X32/M32
  module (imported from NA's copy through Companion's own API) and an m32 connection; auto-setup
  names a single M32 connection's key M32.
- SuperRack's link to the Waves SoundGrid server: a soundgrid check builder (SuperRack's control
  connection on port 19000) inside every SUPERRACK key.
- MIDI ("Open Audio MIDI"): Macs without the Command Line Tools have their sessions read with
  JavaScript for Automation (coremidi.JXA_SESSIONS) - by the watchdog every 2 s and by discovery. A
  peer with no state (older macOS) counts as configured. A peer joined by name or IPv6 gets the
  wired address of the Mac whose session it is (matched by session name), at that session's port.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-20 16:48:28 -04:00
co-authored by Claude Opus 5.5
parent e1c9b2f974
commit 457335bc96
6 changed files with 98 additions and 4 deletions
+9 -2
View File
@@ -212,6 +212,8 @@ def items(inv, nets):
item["group"] = "VIDEO"
if a.get("group"):
item["group"] = a["group"]
if a["app"] == "superrack": # and its link to the Waves SoundGrid server
item["checks"].append({"type": "remote", "template": "soundgrid", "params": {"host": alias}, "msg": "SOUNDGRID LOST"})
out.append(item)
apps_at[(a["app"], c.get("ip"))] = item
for ip in c.get("ips") or []:
@@ -229,6 +231,8 @@ def items(inv, nets):
ident = "conn:" + label
many = counts.get(conn["module"], 0) > 1
text = spec["label"] if not many else key_text(label)
if conn.get("module") == "behringer-x32" and "m32" in label.lower() and not many:
text = "M32" # a Midas M32 on the same module (Woonsocket)
if spec["kind"] == "hyperdeck":
hd_n += 1
text = "HD%d" % hd_n if many else "HD"
@@ -265,16 +269,19 @@ def items(inv, nets):
out.append({"ident": ident, "group": spec["group"], "label": text, "checks": checks, "fixes": {}, "restart": [], "also": []})
# Network MIDI: every peer in the sessions here and on the other Macs, at its wired address.
midi_checks = []
# Whose session a peer is, by its name: a peer joined by name or by an IPv6 address gets that Mac's wired address.
owner = {sname: alias for alias, sessions in (inv.get("midi") or {}).items() if alias for sname in (sessions or {})}
for host, sessions in (inv.get("midi") or {}).items():
for sname, sess in (sessions or {}).items():
for p in sess.get("peers") or []:
addr = p.get("address") or ""
if not in_nets(nets, addr):
alias = computer_named(inv, p.get("name"))
alias = owner.get(p.get("name")) or computer_named(inv, p.get("name"))
ip = alias and next((i for i in comps[alias].get("ips") or [] if in_nets(nets, i)), None)
if not ip:
continue # no wired address known: the wired check will name it
addr = "%s:5004" % ip
port = (((inv.get("midi") or {}).get(alias) or {}).get(p.get("name")) or {}).get("port") or 5004
addr = "%s:%d" % (ip, port)
chk = {"type": "midi_peer", "session": sname, "peer": p["name"], "address": addr, "fix": "midi_reconnect",
"tag": tag_for(p["name"])}
if host:
+6
View File
@@ -327,6 +327,12 @@ CHECK_TEMPLATES = {
"params": [P_HOST, ("exe", "Program file", "As Task Manager shows it (Vista.exe).", "str", None)],
"render": lambda p, cfg: win_running(win(p["exe"], "program file")),
},
"soundgrid": {
"words": "SuperRack is connected to its SoundGrid server", "type": "remote",
"params": [P_HOST],
# SuperRack keeps a control link to the Waves server (port 19000, over the SoundGrid network).
"render": lambda p, cfg: "lsof -nP -iTCP -sTCP:ESTABLISHED -a -c SuperRack 2>/dev/null | grep -q ':19000 (ESTABLISHED)'",
},
"helper_flag": {
"words": "A helper file does not say something is wrong", "type": "remote",
"params": [P_HOST, ("file", "File", "In the helper's folder (solo-mode.json).", "str", "solo-mode.json"),
+2
View File
@@ -252,6 +252,8 @@ def look_at(cfg, alias, host):
m = subprocess.run(sp.ssh_cmd(cfg, alias) + sp.remote_python("-"), input=sp.remote_midi_script(), capture_output=True, text=True, timeout=15)
out["midi"] = sp.parse_remote_midi(m.stdout) or {}
out["python"] = m.returncode != 97
if not out["python"]:
out["midi"] = sp.jxa_midi(cfg, alias) or {}
except subprocess.TimeoutExpired:
out["midi"] = {}
else: