Skip to content

fix(release): fixes to prep for release#4546

Merged
jamesarich merged 5 commits intomainfrom
fix/releasefixes
Feb 12, 2026
Merged

fix(release): fixes to prep for release#4546
jamesarich merged 5 commits intomainfrom
fix/releasefixes

Conversation

@jamesarich
Copy link
Collaborator

@jamesarich jamesarich commented Feb 12, 2026

This pull request introduces enhancements to how transport mechanisms and node statuses are tracked and stored in the codebase, along with refactoring status message handling to improve clarity. The main changes span across the data models, database entities, and service logic, ensuring that information about how packets and nodes are communicated (e.g., via LoRa or MQTT) is accurately captured and propagated. Additionally, status messages are now handled through a more descriptive connectionProgress interface, and node status updates are streamlined.

Transport mechanism and node status tracking:

  • Added transportMechanism field to DataPacket, PacketEntity, and Message models, enabling tracking of the transport method for each packet. (Fb5cd4d5L71R71, core/database/src/main/kotlin/org/meshtastic/core/database/entity/Packet.ktR61, F459e0f8L93R93)
  • Extended NodeEntity, NodeWithRelations, and Node models to include lastTransport and nodeStatus fields, enabling storage of the last transport mechanism and node status for each node. [1] [2] [3] [4] [5]
  • Updated logic in MeshMessageProcessor and MeshDataHandler to set viaMqtt, lastTransport, and nodeStatus based on incoming packets, including handling LoRa transport detection. [1] [2] [3]

Refactoring and improved status message handling:

  • Replaced setStatusMessage calls with setConnectionProgress throughout service handlers and tests for clearer progress reporting. [1] [2] [3] [4] [5]
  • Streamlined node status updates by adding updateNodeStatus to MeshNodeManager and ensuring status changes are propagated consistently. [1] [2] [3]

Database migrations:

  • Incremented database version and added auto-migrations to support new fields in node and packet entities.

These changes collectively improve the visibility and traceability of node and packet states, enhance progress reporting, and ensure data consistency across the application.

This commit introduces the display of a user-set status message for nodes within the app. The status message is now visible in both the detailed node view and the node list item.

Specific changes:
- Adds a `StatusMessageRow` to `NodeDetailsSection.kt` to show the full status message.
- Integrates the status message display into `NodeItem.kt`, showing it with an icon and allowing for text ellipsis if it's too long.
- Includes new `Preview` composables for components displaying the status message.
- Adds the `status_message` string resource and the `Notes` icon.

Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com>
This commit refactors the `NodeDetailScreen` by decomposing the monolithic `NodeDetailList` composable into smaller, more manageable components. The logic previously contained within `NodeDetailList.kt` has been moved directly into `NodeDetailScreen.kt`.

The main `NodeDetailList` function, previously a `Column` with `verticalScroll`, has been replaced with a `LazyColumn`. This improves performance by composing and laying out only the visible items on the screen.

Specific changes include:
- Deleted `NodeDetailList.kt`.
- Replaced the `Column` with a `LazyColumn` in `NodeDetailScreen.kt` for improved performance.
- Moved composable sections (Position, Device Details, Notes, etc.) into `LazyColumn` items.
- Updated the `MainAppBar` to show a generic "Details" title with the node's long name as the subtitle.

Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com>
@github-actions github-actions bot added the bugfix PR tag label Feb 12, 2026
This commit introduces the ability to receive, store, and display node status messages. The primary goal is to provide users with real-time feedback from their nodes, especially during configuration.

A new `nodeStatus` field has been added to the `NodeInfo` model and the `NodeEntity` in the database. The database version is bumped to 36 to accommodate this schema change.

The application now handles `node_status` updates from a `StatusModule` config, updating the local node database accordingly. This ensures that status messages sent from remote nodes or the local node itself are captured and persisted.

Additionally, the `statusMessage` flow in the `ServiceRepository` has been renamed to `connectionProgress` to more accurately reflect its purpose of showing progress during the initial connection and configuration sequence. UI and service components have been updated to use this new flow.

Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com>
@codecov
Copy link

codecov bot commented Feb 12, 2026

Codecov Report

❌ Patch coverage is 10.38961% with 69 lines in your changes missing coverage. Please review.
✅ Project coverage is 14.43%. Comparing base (c5f2b1b) to head (2e596e7).
⚠️ Report is 1 commits behind head on main.
✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
.../kotlin/org/meshtastic/core/database/model/Node.kt 4.00% 24 Missing ⚠️
...om/geeksville/mesh/service/MeshMessageProcessor.kt 0.00% 8 Missing ⚠️
...a/com/geeksville/mesh/service/MeshConfigHandler.kt 0.00% 6 Missing ⚠️
...htastic/feature/node/detail/NodeDetailViewModel.kt 0.00% 5 Missing ⚠️
...ava/com/geeksville/mesh/service/MeshDataHandler.kt 0.00% 4 Missing ⚠️
...otlin/org/meshtastic/core/model/util/Extensions.kt 0.00% 4 Missing ⚠️
.../org/meshtastic/core/database/entity/NodeEntity.kt 40.00% 3 Missing ⚠️
...n/org/meshtastic/core/service/ServiceRepository.kt 0.00% 3 Missing ⚠️
.../main/kotlin/org/meshtastic/core/ui/icon/Status.kt 0.00% 3 Missing ⚠️
...a/com/geeksville/mesh/service/MeshActionHandler.kt 0.00% 2 Missing ⚠️
... and 6 more
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4546   +/-   ##
=======================================
  Coverage   14.43%   14.43%           
=======================================
  Files         424      424           
  Lines       14518    14582   +64     
  Branches     2411     2428   +17     
=======================================
+ Hits         2095     2105   +10     
- Misses      12120    12170   +50     
- Partials      303      307    +4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

This commit introduces the tracking and display of the transport mechanism (e.g., LoRa, UDP, API) for both nodes and messages. This provides clearer insight into how data is being received.

### Key Changes:

-   **Database:**
    -   A `lastTransport` field has been added to the `NodeEntity` to store the last known transport mechanism for each node.
    -   The database version is bumped to 37 to accommodate this schema change.

-   **Data Models:**
    -   The `DataPacket`, `Message`, and `Node` models are updated to include the `transportMechanism` information.

-   **UI Enhancements:**
    -   A new composable `TransportIcon` is introduced to visually represent the transport type (LoRa, MQTT, UDP, etc.).
    -   The `NodeItem` (in the node list) and `MessageItem` now display this icon, replacing the previous simple cloud icon for MQTT.
    -   The hop count display logic is refined to correctly show `?` for unknown hops (e.g., via MQTT) and to hide signal quality indicators (SNR/RSSI) for non-direct LoRa packets.

-   **Backend Logic:**
    -   The `MeshMessageProcessor` now correctly populates the `lastTransport` for nodes and sets `hopsAway` to `-1` for MQTT messages.
    -   Signal metrics (SNR/RSSI) are now only updated for direct LoRa packets to avoid showing misleading information.
    -   Signal metric charting in the node detail view is now filtered to only include direct LoRa packets.

Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com>
@jamesarich jamesarich changed the title fix(node): wire up status message and fix longname title fix(release): fixes to prep for release Feb 12, 2026
@jamesarich jamesarich requested a review from Copilot February 12, 2026 20:05
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 pull request introduces comprehensive tracking of transport mechanisms and node status messages across the Meshtastic Android application. The changes enable the app to record and display how packets arrived (LoRa, MQTT, UDP, API, or Internal) and to show custom status messages set by node operators. Additionally, the service repository interface has been refactored from setStatusMessage to setConnectionProgress for improved clarity.

Changes:

  • Added transportMechanism field to DataPacket, Message models and lastTransport field to Node models to track how packets/nodes communicate
  • Added nodeStatus field to Node models to store and display user-configured status messages
  • Introduced TransportIcon UI component to visually indicate transport method with appropriate icons
  • Refactored service progress reporting from setStatusMessage to setConnectionProgress throughout the codebase
  • Updated signal metrics filtering to only include direct LoRa packets (excluding MQTT and relayed packets)
  • Added database migrations (35→36→37) to support new node fields
  • Reorganized NodeDetailList from separate file into NodeDetailScreen.kt

Reviewed changes

Copilot reviewed 30 out of 30 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
core/model/src/main/kotlin/org/meshtastic/core/model/util/Extensions.kt Added isLora() extension to check if packet uses LoRa transport
core/model/src/main/kotlin/org/meshtastic/core/model/DataPacket.kt Added transportMechanism field and Parcel serialization
core/model/src/main/kotlin/org/meshtastic/core/model/NodeInfo.kt Added nodeStatus field to NodeInfo
core/database/src/main/kotlin/org/meshtastic/core/database/entity/NodeEntity.kt Added lastTransport and nodeStatus fields with proper conversion methods
core/database/src/main/kotlin/org/meshtastic/core/database/model/Node.kt Added lastTransport and nodeStatus fields, plus toEntity() helper
core/database/src/main/kotlin/org/meshtastic/core/database/model/Message.kt Added transportMechanism field
core/database/src/main/kotlin/org/meshtastic/core/database/entity/Packet.kt Updated to pass transportMechanism from DataPacket to Message
core/database/src/main/kotlin/org/meshtastic/core/database/MeshtasticDatabase.kt Incremented version to 37 and added auto-migrations
core/database/schemas/*.json Database schema files for versions 36 and 37
core/ui/src/main/kotlin/org/meshtastic/core/ui/component/TransportIcon.kt New component to display transport mechanism icons
core/ui/src/main/kotlin/org/meshtastic/core/ui/icon/Status.kt Added icons for UDP, API, and Ethernet transport types
core/strings/src/commonMain/composeResources/values/strings.xml Added strings for via_udp, via_api, and internal transport labels
core/service/src/main/kotlin/org/meshtastic/core/service/ServiceRepository.kt Renamed setStatusMessage to setConnectionProgress
feature/node/src/main/kotlin/org/meshtastic/feature/node/detail/NodeDetailViewModel.kt Updated signal metrics filtering to check isLora() and exclude MQTT
feature/node/src/main/kotlin/org/meshtastic/feature/node/detail/NodeDetailScreen.kt Changed app bar to show "Details" as title with node name as subtitle, added preview, moved NodeDetailList from separate file
feature/node/src/main/kotlin/org/meshtastic/feature/node/detail/NodeDetailList.kt Deleted file (content moved to NodeDetailScreen.kt)
feature/node/src/main/kotlin/org/meshtastic/feature/node/component/NodeItem.kt Added transport icon display and node status display in node cards
feature/node/src/main/kotlin/org/meshtastic/feature/node/component/NodeDetailsSection.kt Added status message row display
feature/node/src/main/kotlin/org/meshtastic/feature/node/component/DeviceDetailsSection.kt Minor formatting change
feature/messaging/src/main/kotlin/org/meshtastic/feature/messaging/component/MessageItem.kt Replaced MQTT icon with TransportIcon component, added handling for unknown hops
app/src/main/java/com/geeksville/mesh/service/MeshMessageProcessor.kt Updated to set lastTransport and only update SNR/RSSI for direct LoRa packets
app/src/main/java/com/geeksville/mesh/service/MeshDataMapper.kt Added transportMechanism mapping
app/src/main/java/com/geeksville/mesh/service/MeshDataHandler.kt Added logic to update node status from module config responses
app/src/main/java/com/geeksville/mesh/service/MeshConfigHandler.kt Updated to use setConnectionProgress, added status message handling for own node
app/src/main/java/com/geeksville/mesh/service/MeshActionHandler.kt Added status message update when setting module config remotely
app/src/main/java/com/geeksville/mesh/service/MeshNodeManager.kt Added updateNodeStatus() helper method
app/src/main/java/com/geeksville/mesh/service/FromRadioPacketHandler.kt Updated to use setConnectionProgress
app/src/main/java/com/geeksville/mesh/model/BTScanModel.kt Updated to use connectionProgress flow
app/src/test/java/com/geeksville/mesh/service/FromRadioPacketHandlerTest.kt Updated test to verify setConnectionProgress call

This commit refines the `isLora()` extension function for `MeshPacket` by removing `TRANSPORT_INTERNAL` from the set of conditions that identify a LoRa transport mechanism. This ensures the function more accurately reflects packets transmitted over LoRa.

Signed-off-by: James Rich <2199651+jamesarich@users.noreply.github.com>
@jamesarich jamesarich enabled auto-merge February 12, 2026 20:15
@jamesarich jamesarich added this pull request to the merge queue Feb 12, 2026
Merged via the queue into main with commit 80d9a2e Feb 12, 2026
8 checks passed
@jamesarich jamesarich deleted the fix/releasefixes branch February 12, 2026 20:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bugfix PR tag

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants