Repository navigation
Keep Wi-Fi indicator online when AP object is missing - #6918
patrickrodrigues-aa wants to merge 10 commits into
Conversation
There was a problem hiding this comment.
Pull request overview
Note
Copilot was unable to run its full agentic suite in this review.
This PR improves the network panel “bar pill” state derivation so Wi‑Fi can be treated as connected even when NetworkManager hasn’t yet surfaced the active access point, preventing the bar from briefly showing as offline.
Changes:
- Extracted connection-kind and signal-strength derivation into reusable
Modelhelpers. - Updated the QML panel to consider Wi‑Fi device connection state when the active access point isn’t available yet.
- Added test coverage for the new connection-kind and signal-strength logic.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| test/shell.d/network-test.sh | Adds assertions covering connectionKind and connectionSignalStrength behavior. |
| shell/plugins/panels/network/Panel.qml | Switches bar state logic to new model helpers and keeps Wi‑Fi “online” from device state. |
| shell/plugins/panels/network/Model.js | Introduces and exports connectionKind / connectionSignalStrength helpers. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
a848cc0 to
8e7a44f
Compare
Resolves the Model.js export list, where this branch's connectionKind and connectionSignalStrength sat beside quattro's connectivityState and captivePortalUrl.
…-less Wi-Fi A Wi-Fi card running a hotspot reports connected with no network object, the same shape as the missing-AP state, so the device fallback showed a machine sharing its card as online over Wi-Fi. Fall back on device state only in station mode. connectionKey also required the network object, so Wi-Fi coming up without one never prompted a connectivity check. Key it on the device, with the SSID when known. The new source assertions fail when Panel.qml goes back to deriving kind without the device state, which the helper tests alone did not. Co-Authored-By: Codex Medium <noreply@openai.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thanks for this, Patrick. Reviewed by Claude Opus 5.5 with Codex Medium as the second opinion. The change reads correctly, and I pushed two commits to your branch. Pushed
Checked on a worker VM (Omarchy ISO, Quickshell 0.3.1, the shell running from this branch):
Not reproduced: the state this pull request is about, a station connection with no network object. On the worker, a normal WPA2 association, a hidden SSID and a fresh Quickshell start while already connected all exposed the connected network. So the only evidence for that state so far is the probe in your description, and it can't be marked verified from the author's own machine. Two things would settle it. Either you tell me how to trigger the state, or a maintainer confirms the fix at Codex found the hotspot case, the missed connectivity check and the test gap. On its second pass over |
|
I can’t reproduce the bad state anymore either. It appeared during/after the Quattro upgrade and has cleared after subsequent reconnects/restarts/updates. Current state on the same machine is normal station Wi-Fi: The original failure was observed while the packaged widget still depended only on So I don’t have a live repro anymore. The PR is defensive for that state rather than a currently reproducible steady-state issue on my machine. |
The state the device fallback covers is Quickshell 0.3.1 dropping any NetworkManager profile whose 802-11-wireless.mode is unset: it never attaches that profile to a network, so the active connection matches nothing while the station is up. Upstream accepts an omitted mode after 0.3.1 (quickshell 052059f). Saying so tells a later reader when the fallback can go. Co-Authored-By: Codex Medium <noreply@openai.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The assertion stopped at the ternary's condition, so blanking the Wi-Fi key kept all 114 passing while Wi-Fi coming up without a network object no longer changed the key and never prompted a connectivity check. Match the key it builds as well. Co-Authored-By: Codex Medium <noreply@openai.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thanks for checking, Patrick. Your report led to the cause, and I could reproduce the bug this time. Reviewed by Claude Opus 5.5, with Codex Medium as the second opinion. Cause. Quickshell 0.3.1, which Omarchy ships, only links a NetworkManager profile to a network when the profile's Reproduced on a worker VM (Omarchy ISO, Quickshell 0.3.1, NetworkManager 1.58.1, simulated Wi-Fi via
Pushed
Limits. In this state the bar shows the lowest Wi-Fi signal, because no signal strength is known. The panel body still treats the network as not connected (no Disconnect button), because only the bar falls back to the device state. Updating Quickshell past 052059f would fix both. Competing pull requests. #13738 and #13662 also change how the bar decides Codex found the test gap and the outdated comment. On its second pass over |
[Medium impact] The PR appears safe to merge; no new blocking issue was found. SummaryThe PR excludes hotspot radios from the device-connected Wi-Fi fallback and prefers a station radio when several radios exist.
Previous unnumbered threads: Reviews (4) · Last reviewed commit: "Fall back to an idle station radio befor..." · Reviewed by Greptile |
|
#14133 has merged into Scope checked by GPT-6 in Codex and Codex Medium against the reports and landed source; independence is not guaranteed. No runtime tests were rerun for this reconciliation. |
|
Rebased after #14133 landed. The already-merged fallback and active-AP strength polling are now coming from I updated the OWE fixture to mock station mode and kept the source assertion that rejects the broader Checked:
|
Requiring station mode also dropped ad-hoc and mesh links, which Quickshell 0.3.1 never gives a network object either, back to the disconnected icon. Only a hotspot is connected without an uplink. Co-Authored-By: Codex Medium <noreply@openai.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Thanks for the rebase, Patrick. I reviewed the reduced change at Pushed: Checked on a worker VM (Omarchy ISO, Quickshell 0.3.1, NetworkManager 1.58.1, simulated Wi-Fi via
Codex found the ad-hoc and mesh regression. On its second pass over This is waiting on the maintainer, and on the shell test failures |
quattro removed the source-text assertions in network-test.sh and moved the OWE runtime test into network-panel-runtime-test.sh with shared fixtures. Take quattro's network-test.sh, drop the deleted network-owe-transition-test.sh, and check the hotspot case at runtime instead: the mock Wi-Fi device gains a Station mode, and the OWE fixture ends by bringing the device up in AccessPoint mode with no network listed and expects the bar to show disconnected. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With a hotspot on one radio and a station on another, findDevice returned whichever connected radio came first. When that was the hotspot, the AccessPoint guard in kind turned the bar to disconnected while the second radio was online. Skip a hotspot radio when choosing the connected device, so the station is the uplink the bar reads; a hotspot alone is still only the fallback and still shows disconnected. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With a hotspot running on the first radio and the second idle, findDevice still fell back to the hotspot, so the panel's network list, scanning and connect actions drove a radio that cannot join a network. Prefer any station radio as the fallback, and keep a hotspot only when it is the sole Wi-Fi device. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Co-Authored-By: muse-wonder via pi, thinking high <noreply@openrouter.ai>
|
Patrick, The merge,
Checked on a worker VM (Omarchy ISO, Quickshell 0.3.2, two simulated radios via
Codex Medium found nothing wrong in either round. muse-wonder raised the idle-station fallback in the first round, and both reviewers found nothing wrong at Waiting on you: the title and description still describe the device fallback that #14133 already merged. Could you update them to say what this PR now does: a connected hotspot no longer shows as online, and a station radio is preferred over a hotspot radio? |
|
The failed Tests run reports only GPT-6 in Codex (effort not exposed) checked the CI log, test setup and diff. Opus 5.5 High agreed from the supplied diff and earlier worker evidence; independence is not guaranteed. No runtime tests were rerun because worker preflight did not pass, and no branch changes were made. This remains waiting on the maintainer with CI red. |
Summary
Reproduction
On an upgraded Quattro install, the machine is online through Wi-Fi:
A small Quickshell probe showed the native NetworkManager backend had the device connected while its AP list was empty:
The panel previously derived
kind === "wifi"only fromconnectedWifiNetwork, so this state rendered the disconnected icon even though the network was online.Tests
bash test/shell.d/network-test.shbash test/shell.d/plugin-validate-test.shI also ran
bash test/shell.d/runtime-smoke-test.sh; it reached the shell IPC checks and then failed an existing handler-count assertion in this live session:each widget registers its IPC handler once per screen (saw 6 for 3 screen(s)).