diff --git a/CHANGELOG.md b/CHANGELOG.md index 16d7086..923475b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,35 @@ Format follows [Keep a Changelog](https://keepachangelog.com/) and [Semantic Ver --- +## [1.20.2] - 2026-04-19 + +### Fixed +- **Public API omitted `sender_pubkey` and `path_names` from the message payload** + (`services/public_api_service.py`): + `get_messages_payload()` built each item dict with `sender`, `text`, + `timestamp`, `hops` and `path_hashes`, but silently dropped the already- + resolved `sender_pubkey` and `path_names` fields that `BleEventHandler` + writes to every archived message (see `_resolve_path_names()` in + `ble/events.py` and the archive schema in `services/message_archive.py` + lines 135–137). Downstream consumers were therefore forced to re-resolve + path hashes themselves using only the 1-byte path-hash prefix — a lookup + that collides heavily in networks with more than ~256 nodes and yields + the wrong repeater name, type and coordinates on nearly every hop. The + `sender_pubkey` omission had a similar effect on the sender column: + clients could only match on display-name, which is ambiguous when two + nodes share a name stem (e.g. `NL-OV-ZWO-LGH-PD5WB` vs the mobile + variant `NL-OV-ZWO-LGH-PD5WB-MOB`). + Fix: added `"sender_pubkey"` and `"path_names"` to the item dict. Both + fields are read straight from the archive — no new resolution logic is + introduced, so there is no additional cost on the hot path. The response + schema change is additive: existing clients that ignore unknown keys + continue to work unchanged. + +### Changed +- `config.py`: version bump `1.20.1 → 1.20.2`. + +--- + ## [1.20.1] - 2026-04-15 ### Fixed diff --git a/meshcore_gui/config.py b/meshcore_gui/config.py index 122ec09..3b1e8bf 100644 --- a/meshcore_gui/config.py +++ b/meshcore_gui/config.py @@ -25,7 +25,7 @@ from typing import Any, Dict, List # ============================================================================== -VERSION: str = "1.20.1" +VERSION: str = "1.20.2" # ============================================================================== diff --git a/meshcore_gui/services/public_api_service.py b/meshcore_gui/services/public_api_service.py index b8770f6..9a2c0ef 100644 --- a/meshcore_gui/services/public_api_service.py +++ b/meshcore_gui/services/public_api_service.py @@ -261,14 +261,16 @@ def get_messages_payload( items: List[Dict[str, Any]] = [] for i, msg in enumerate(page): items.append({ - "id": offset + i + 1, # 1-based stable ID - "channel_idx": msg.get("channel"), - "channel_name": msg.get("channel_name", ""), - "sender": msg.get("sender", ""), - "text": msg.get("text", ""), - "timestamp": msg.get("timestamp_utc"), - "hops": msg.get("path_len", 0) or 0, - "path_hashes": msg.get("path_hashes") or [], + "id": offset + i + 1, # 1-based stable ID + "channel_idx": msg.get("channel"), + "channel_name": msg.get("channel_name", ""), + "sender": msg.get("sender", ""), + "sender_pubkey": msg.get("sender_pubkey", "") or "", + "text": msg.get("text", ""), + "timestamp": msg.get("timestamp_utc"), + "hops": msg.get("path_len", 0) or 0, + "path_hashes": msg.get("path_hashes") or [], + "path_names": msg.get("path_names") or [], }) return { diff --git a/meshcore_guiAnalyse.zip b/meshcore_guiAnalyse.zip new file mode 100644 index 0000000..6eafca1 Binary files /dev/null and b/meshcore_guiAnalyse.zip differ diff --git a/meshcore_guiAnalyse2.zip b/meshcore_guiAnalyse2.zip new file mode 100644 index 0000000..1193ee4 Binary files /dev/null and b/meshcore_guiAnalyse2.zip differ