Skip to content

Track gateway source, persist My Node banner, and update roles#368

Merged
SimmerV merged 7 commits intoMeshAddicts:developfrom
SimmerV:feature-addition
Mar 21, 2026
Merged

Track gateway source, persist My Node banner, and update roles#368
SimmerV merged 7 commits intoMeshAddicts:developfrom
SimmerV:feature-addition

Conversation

@SimmerV
Copy link
Collaborator

@SimmerV SimmerV commented Mar 20, 2026

Summary

  • Track which node relayed/gated each node's packets into meshinfo via the MQTT sender field (Add node gateway source #96)
  • Store gateway on the node model (in-memory and Postgres) — updated on every inbound message (neighborinfo, nodeinfo, position, telemetry)
  • Add idempotent ALTER TABLE nodes ADD COLUMN IF NOT EXISTS gateway migration to ensure_schema() so existing databases auto-migrate on startup
  • Display "Gateway" in the map detail panel with the gateway node's shortname, clickable to navigate to that node if it has a map position
  • Display "Gateway" in the nodes page detail panel with the same clickable behavior
  • Gateway field populates progressively as new MQTT messages arrive; existing nodes show it once they beacon after the update
  • Cap map details panel height to prevent overlap with the legend/settings panel
  • Replace ephemeral "My Node set to" toast with a persistent banner that stays visible while a My Node is active, with an X button to clear
  • Update node roles to match current Meshtastic protobufs: rename ATAK → TAK, ATAK_TRACKER → TAK_TRACKER, add Router Late (11) and Client Base (12) (Add missing roles #367)
  • Display full role titles (e.g. "Client Mute") instead of abbreviations ("CM") in the UI

@SimmerV SimmerV self-assigned this Mar 20, 2026
@SimmerV SimmerV added the enhancement New feature or request label Mar 20, 2026
@SimmerV SimmerV added this to meshinfo Mar 20, 2026
@github-project-automation github-project-automation bot moved this to Backlog in meshinfo Mar 20, 2026
@SimmerV SimmerV moved this from Backlog to In review in meshinfo Mar 20, 2026
@SimmerV SimmerV linked an issue Mar 20, 2026 that may be closed by this pull request
@SimmerV SimmerV marked this pull request as draft March 20, 2026 17:42
@SimmerV SimmerV moved this from In review to In progress in meshinfo Mar 20, 2026
@SimmerV SimmerV linked an issue Mar 20, 2026 that may be closed by this pull request
@SimmerV SimmerV marked this pull request as ready for review March 20, 2026 19:43
@SimmerV SimmerV added chore Housekeeping with no functional changes labels Mar 20, 2026
@SimmerV SimmerV changed the title Track and display node gateway source Track gateway source, persist My Node banner, and update roles Mar 20, 2026
@daviesgeek daviesgeek requested a review from Copilot March 20, 2026 23:52
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds end-to-end “gateway/source” tracking for nodes (persisted server-side and displayed in the UI), updates role naming to match current Meshtastic protobufs, and improves map UI behavior (details panel height + persistent “My Node” indicator).

Changes:

  • Persist and surface gateway (MQTT sender) on node updates, including an auto-migration for existing Postgres DBs.
  • Update node roles (ATAK → TAK, add Router Late / Client Base) and adjust UI role display to show full titles.
  • Improve map UX: cap details panel height and replace the transient “My Node set” toast with a persistent dismissible banner.

Reviewed changes

Copilot reviewed 15 out of 15 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
storage/db/postgres.py Adds gateway migration and persists gateway in node upserts and read models
postgres/sql/schema.sql Adds gateway column to the canonical schema
mqtt.py Captures MQTT sender into node.gateway across message handlers
models/node.py Adds gateway to default node shape (partial)
frontend/src/types/index.ts Adds gateway to node types; updates roles/titles
frontend/src/pages/nodes/nodesUtils.ts Updates role labels to TAK + new roles
frontend/src/pages/nodes/NodeDetailsPanel.tsx Displays Gateway field and enables clicking to select gateway node
frontend/src/pages/map/types.ts Adds gateway to map node types
frontend/src/pages/map/detailsHtml.ts Displays Gateway in the map details HTML (with optional click-to-select)
frontend/src/pages/map/MapDetailsPanel.tsx Adjusts max height to avoid UI overlap
frontend/src/pages/graph/graphUtils.ts Updates role colors/labels for new roles and TAK rename
frontend/src/pages/Nodes.tsx Wires onSelectNode into NodeDetailsPanel usage
frontend/src/pages/Node.tsx Updates role label mapping to TAK + new roles
frontend/src/pages/Map.tsx Plumbs gateway into map node-like objects; adds persistent “My Node” banner
frontend/src/components/Role.tsx Switches role display from abbreviation to full title

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@SimmerV SimmerV merged commit e4e37c1 into MeshAddicts:develop Mar 21, 2026
5 checks passed
@github-project-automation github-project-automation bot moved this from In progress to Done in meshinfo Mar 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

chore Housekeeping with no functional changes enhancement New feature or request

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Add missing roles Add node gateway source

2 participants