diff options
Diffstat (limited to 'AGENTS.md')
| -rw-r--r-- | AGENTS.md | 17 |
1 files changed, 17 insertions, 0 deletions
@@ -30,6 +30,23 @@ longer follows the wallpaper accent. - Pairing trades the security code on the gateway label for an identity and key, stored in `~/.config/agent-lamp/tradfri.json` (mode 0600). +## Runtime + +- State: `$XDG_RUNTIME_DIR/agent-lamp/state.json`, every read-modify-write + under `flock` on `state.lock`. One renderer (`--run`) at a time holds + `run.lock`; a second exits at once. The renderer drops `run.lock` under + the state lock when it decides to exit, and writers spawn only after + releasing the state lock, so no event is lost. Spawns happen only when + the state changed. +- A colour is never sent while a brightness fade runs (`level_at`): the + gateway would drop it. +- `coap-client` exits 0 on a 4.xx/5.xx response and prints the code on + stderr only; `coap()` treats that as failure. +- Install is a symlink, `~/bin/agent-lamp`, so edits are live; a running + renderer keeps the old code until it exits. +- Known limit: opencode's notifier has no "permission granted" event, so an + opencode permission stays purple until that session's next event. + ## Conventions - Unknown state words exit 0 silently: hook callers must never break. |
