release: v1.18.1

ec55d31 fixed the inverted guard in noteLinkState but changed app.js without bumping
the version or the service-worker cache, so a field log from a phone running the fix
would still have read "v1.18.0" and could not have shown whether the fix was in.
Version, cache name and release notes go together.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012GJuEuyG3JMrSeAGCmJ1GP
This commit is contained in:
efitenandClaude Opus 5 committed 2026-09-14 10:20:34 +02:00
1 parent ec55d31bfe
commit 7c4df3afbf
4 files changed
+31 -4

No files matched your search

+27
View File
@@ -0,0 +1,27 @@
# CoreDrive RX v1.18.1
Fixes the link-state lines that v1.18.0 added, which fired the wrong way round.
## What's new
- **Fix: "companion link back" once a second on a healthy link, and never "link
down".** The guard in `noteLinkState` was inverted. The stored flag holds the inverse of
the link being up, so the steady state is `linkQuiet !== linkUp` and an edge is
`linkQuiet === linkUp`; the guard returned on the edge and fell through in the steady
state. Every tick of a working link announced a return, and the flag never left its
initial value, so a real drop could not be announced at all.
A field log from 2026-09-14 shows 157 of the 200 buffered lines spent on it, the whole
buffer covering 2 minutes 36 seconds, and not one "link down" line. The heard, asks
and regions lines had rolled out underneath.
The edge decision is now the pure `linkTransition` in `src/monitor.js`, with tests for
both steady states, both edges, and a full drop-and-return cycle.
## Upgrade notes
- **Service-worker cache bumped to `coredrive-rx-v50`.**
- No behaviour change beyond the log. The link gate itself (discover, RF sampling and
region asks standing down while the companion is gone) was correct in v1.18.0; only
its two announcements were wrong.
- Tests: 275 pass (+5).
+2 -2
View File
@@ -1,12 +1,12 @@
{
"name": "coredrive-rx",
"version": "1.18.0",
"version": "1.18.1",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "coredrive-rx",
"version": "1.18.0",
"version": "1.18.1",
"license": "GPL-3.0-or-later",
"dependencies": {
"@noble/ed25519": "^3.2.0",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "coredrive-rx",
"version": "1.18.0",
"version": "1.18.1",
"private": false,
"license": "GPL-3.0-or-later",
"type": "module",
+1 -1
View File
@@ -1,7 +1,7 @@
// Minimal service worker: makes the app installable and lets the shell load
// offline. Network-first (always fresh online), cache fallback (offline).
// Only the static app assets go through fetch; MQTT runs over WSS (not cached).
const CACHE = 'coredrive-rx-v49';
const CACHE = 'coredrive-rx-v50';
// config.json is deliberately NEVER cached, in either direction. It is
// per-deployment runtime config, and a stale copy is worse than none: flags added