v2.13.1: the Clawdmeter dot lights only when it should
A one-line fix on the Clawdmeter screen's status dot, which turns out to have been wrong in both directions.
The status dot
drawUsage() decided whether to show the small accent dot with a 7-character prefix compare against "allowed". Two things fall out of that.
The daemon changed vocabulary. clawdmeter-daemon v1.1.0 reads Claude's usage endpoint instead of POSTing an inference request for its rate-limit headers, so st now carries the session limit severity (normal / warning / rejected) rather than the old header status (allowed / allowed_warning / rejected). Nothing cleared the dot for normal, so a perfectly healthy session showed the warning dot permanently.
And the prefix compare was too short all along. "allowed_warning" matches "allowed" across its first seven characters, so the warning state never raised the dot either.
Both calm values now clear the dot, compared exactly:
st |
2.13.0 | 2.13.1 |
|---|---|---|
allowed |
off | off |
allowed_warning |
off | on |
rejected |
on | on |
normal |
on | off |
warning |
on | on |
Both vocabularies are accepted, so the screen behaves with old and new daemons alike.
Upgrading
Nothing to reconfigure. Self-update offers this build on every board, and each variant stays on its own image. Firmware for every board is attached below, built from this tag.
If you also run the PC-side daemon, update it to v1.1.0: from that release polling no longer spends an inference request against the quota it reports.