Companion module 0.1.5: settings save even before Resi answers
While the connection wasn't connected, nothing in its settings could be saved. The saved decoder showed as "??" because the list only fills once Resi answers, and a cue refresh that had never been saved showed as 0, below its minimum. Either blocks Save, including the login change that would have fixed the connection. That's how North Attleboro's connection stayed on a locked login. - The saved decoder is always a choice, "(not connected to Resi yet)" until Resi answers. - An upgrade script fills settings an older connection never saved with their defaults (and leaves a complete one alone). - Event details are read once per event instead of on every cue refresh: one Resi request fewer every few seconds on a shared account. - Cue requests share the login/rate-limit hold-off; "Loaded N cues" and repeated cue-refresh failures are logged once, not every few seconds. - "inf0" in the decoder info poll label. source/config_test.js covers all of it (6 tests; the first fails on 0.1.4). backoff_test.js 5/5 and the estimator matrix still pass. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -90,7 +90,7 @@ Resi's API is undocumented and unsupported, so don't open a Resi ticket about th
|
||||
| `install_bridge.sh` | Installs it as a login service on the Mac it runs on, and runs `--setup` when needed. |
|
||||
| `make_kit.sh` | Builds `resi-propresenter-kit.zip` for another site (no site settings inside). |
|
||||
| `source/` | The Companion module `resi-studio-cues` (`dist/` is what ships, plus `manifest.json` and `HELP.md`). |
|
||||
| `resi-studio-cues-0.1.4.tgz` | The current Companion package: import it in Companion → Modules. |
|
||||
| `resi-studio-cues-0.1.5.tgz` | The current Companion package: import it in Companion → Modules. |
|
||||
|
||||
Tests. All run offline against fakes, except the end-to-end one:
|
||||
|
||||
@@ -99,6 +99,7 @@ python3 test_playhead.py # the playhead estimator, nine Resi profiles plu
|
||||
python3 test_stage_message.py # stage message sent once per cue, never when switched off
|
||||
python3 test_rate_limit.py # backs off when Resi says "too many requests"
|
||||
node source/backoff_test.js # Companion module: login hold-off, no crash loop on a locked account
|
||||
node source/config_test.js # Companion module: settings always save, upgrade fills defaults, quieter cue refresh
|
||||
```
|
||||
|
||||
`source/tick_test.js` is the Companion module's estimator test (run with JavaScriptCore's
|
||||
|
||||
Reference in New Issue
Block a user