fix: classify active default-network transport - #1037
Merged
Conversation
added 6 commits
July 28, 2026 12:12
Contributor
Greptile SummaryThis PR makes Android interface restrictions follow the active default network consistently.
Confidence Score: 5/5The PR appears safe to merge, with no concrete changed-code failure identified. Default-network identity tracking, UNKNOWN classification, host filtering, and UI presentation are aligned, and the transition and stale-callback cases are covered by focused tests. Important Files Changed
Sequence DiagramsequenceDiagram
participant Android as Android ConnectivityManager
participant Observer as InterfaceTransportObserver
participant Host as NetworkChangeManager
participant Filter as InterfaceTransportFilter
participant Backend as Reticulum backend
Android->>Observer: onAvailable(default network)
Android->>Host: onAvailable(default network)
Android->>Observer: onCapabilitiesChanged(default, capabilities)
Android->>Host: onCapabilitiesChanged(default, capabilities)
Observer->>Filter: classify and filter enabled interfaces
Observer->>Backend: reloadInterfaces(filtered configs)
Host->>Filter: publish classified transport
Note over Observer,Host: Non-default capability events and stale onLost events are ignored
Android->>Observer: onLost(current default)
Android->>Host: onLost(current default)
Observer->>Filter: classify as NONE
Observer->>Backend: reload without IP-carrier interfaces
Reviews (1): Last reviewed commit: "fix: prevent stale observer startup seed" | Re-trigger Greptile |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
activeNetworksnapshotonLostcallbacksNONEfor the absence of a default route and represent VPN-only, unsupported, or temporarily unpublished capabilities asUNKNOWNUNKNOWNwhile conservatively filtering Wi-Fi-only and cellular-only interfacesInterfaceTransportObserver, host manager, and interface-management UI with the same transport truth tableport-deviations.mdThis is a current-main replacement for stale draft PR #903. The old draft is intentionally left open pending explicit closure authorization.
Verification
Exact rebased head:
253b11d322520efe17143c172dd4c9e70b13c7b5NetworkChangeManagerTestandInterfaceTransportFilterTestInterfaceTransportObserverTestandInterfaceManagementUtilsTest:rns-host:ktlintCheck :rns-host:detekt: passed:app:ktlintCheck :app:detekt: passed:app:assembleNoSentryPythonBackendDebug: passedgit diff --check origin/main...HEAD: passedBehavior
WIFI_LIKE.CELLULAR.UNKNOWN;ANYremains active while transport-specific interfaces pause.NONE; IP interfaces pause.