fix(api): expose region_scope in /packets/recent raw events (eng-ne feed toggle)

The raw=1 response path (getRecentPacketEvents) omitted region_scope, so
consumers filtering on region scope (nemesh.uk compat region=eng-ne) could
never match, even though packets were correctly tagged at ingest. Add the
column to the SELECT. Verified live: 1000-row raw fetch now carries
region_scope and the compat filter serves #eng-ne rows from real data.
This commit is contained in:
hermes-gadget committed 2026-09-17 14:16:44 +00:00
1 parent a8921b89f0
commit ffa3160348
1 file changed
+2 -1
+2 -1
View File
@@ -1118,7 +1118,8 @@ export async function getRecentPacketEvents(limit = 200, network?: string, obser
p.topic, p.iata,
p.packet_type, p.hop_count, p.rssi, p.snr, p.payload,
p.payload->>'_summary' AS summary,
p.advert_count, p.path_hashes, p.path_hash_size_bytes
p.advert_count, p.path_hashes, p.path_hash_size_bytes,
p.region_scope
FROM packets p
LEFT JOIN node_identity_aliases rx_alias
ON rx_alias.source_node_id = UPPER(BTRIM(p.rx_node_id))