Skip to content

Follow-ups from Spec 108-i Web UI profiles review (#1444) #1446

Closed

Description

@Dumbris

Low-severity findings left after the gpt-6.1-sol review and live QA of #1444 (Spec 108-i Web UI). Most are stale-response races or cosmetic; all fail safe.

  • frontend/src/components/clients/UpgradeAdminKeyDialog.vue:75 (F4.2): The done step always renders the 'Rotate the admin API key' panel, including after partial failures with no next_step; FR-025 shows the prompt once no supported client reports admin_key or the operator accepts the remaining ones stop working. Mitigated: the panel text states every remaining copy stops working and the dialog never rotates the key itself. Re-mapped medium -> low.
  • frontend/src/views/ProfileEditor.vue:424 and :399-402 (F2.1): An in-flight save or SSE refresh replaces the whole draft on completion, discarding edits made while the request was pending (form stays editable during saving; onChangedElsewhere checks dirty only before the GET starts). Narrow timing window; re-mapped medium -> low.
  • frontend/src/components/profiles/AssignClientDialog.vue:51 (Profiles.vue:115) (F2.2): Assign-to-client eligible list derives from the shared clients store, which can still hold the filtered rows loaded by Clients.vue (clearScope only resets the scope variable, not the rows); the refresh is skipped when any rows exist, so eligible clients are missing until the next 30 s sidebar poll. Same root cause as F1.3 and F4.1.
  • frontend/src/stores/clients.ts:39 (F1.1): load() and refreshPresence() use independent tickets, so an older load() completing after a newer SSE-triggered refreshPresence() overwrites rows and warnings with stale binding state until the next refresh.
  • frontend/src/composables/useScopeQuery.ts:358 (used by ViewingFilter.vue:98-110) (F1.2): pageIdForRouteName maps by route name only, so every Clients tab (including ?tab=tokens, which redirects from /tokens, and ?tab=endpoint) resolves to page 'clients' and the Viewing chip shows 'client' as applied on the tokens tab and profile/client as applied on Endpoint, contradicting FR-044 dimming.
  • frontend/src/stores/clients.ts:50,59 (F1.3): liveCount (sidebar Clients badge) is computed from the shared store, which holds the scoped list while the Clients page filter is active, so filtering by profile/client lowers the global badge.
  • frontend/src/components/ClientConnectList.vue:834 (F3.1): onBindingToggle changes intent before awaiting refreshPreview and keeps the old preview (and its precondition token) with Connect enabled; clicking Connect in that window sends new intent with the old token and is refused by the server as precondition_failed. Safe failure (refused, nothing written); overlapping refreshes also lack a generation check.
  • frontend/src/views/AgentTokens.vue:559 (F5.1): loadTokens assigns its response unconditionally with no request ticket (unlike stores/clients.ts), so a slower older response for the previous Viewing filter can overwrite the current filter's token list.
  • frontend/src/components/AccessExplainer.vue:130 (F5.2): run() writes its response unconditionally; closing and reopening the still-mounted explainer during a pending explain lets the old response repopulate the reset dialog with the previous verdict and actionable fix buttons.
  • frontend/src/components/AccessExplainer.vue:163 (F6.1): follow() builds router.push targets for allow/classify/add_server/move_client/enable_server by hand; only edit_token uses scope.linkTo, so FR-045 (link only through the link map) is not followed for the other fixes and sticky scope params are dropped. Dropping profile/client is arguably desirable for move_client (it would hide the row), so impact is narrow; re-mapped medium -> low.
  • frontend/src/components/ClientConnectList.vue:823 (bulkRefusals), 922, 986-998 (luna:1.F7.1): The new bulkRefusals computed treats ANY stored guard refusal for a client without an open preview as a bulk refusal. A single-client guard refusal is kept in connectRefusal, and connect() never clears it on success. If the user retries Connect in the retained preview (for example after the guard was satisfied out of band, such as in another tab), confirmConnect() clears the preview on success and the stale refusal then renders as ' was not connected' with obsolete bindings and fix buttons next to the success message. Verified by reading the code. Codex rated it medium. Re-mapped to low: the in-modal fix buttons navigate to Settings and now close the modal, which resets connectRefusal on reopen, so only an out-of-band fix followed by a retry in the same modal session reaches it. It is a regression introduced by the round-1 fix. Suggested fix: call setRefusal(clientId, null) on a successful connect(), or key bulkRefusals to a bulk-run id set recorded in connectAll.
  • frontend/src/components/ClientConnectList.vue:291, 888, 823 (orch.1): Same root cause as luna:1.F7.1. Cancel on a refused single-client preview calls cancelPreview(), which leaves connectRefusal[id] set. The refusal then re-renders in the bulk-refusals block as ' was not connected' after the panel is dismissed. It is stale UI that clears on the next startConnect or connectAll, and the message is factually accurate. Fold into the F7.1 follow-up.
  • frontend/src/components/clients/BulkMoveDialog.vue:106 (affected), :30 (submit disabled) (luna:2.F4.1-residual): STILL-BROKEN in a narrow window. allClients stays null until the unscoped getClients() succeeds, and affected falls back to the filtered props.clients. While the request is pending or if it fails, the preview line and the 'Move N clients' button count only the page-filtered rows, although POST /clients/bulk-assign moves every client on the from-profile (internal/runtime/clients_service.go:526-543). If the filtered rows hold no from-profile clients, the submit button is disabled during that window. The normal case (GET succeeds quickly) is fixed and the new test covers it. Codex rated it medium. Re-mapped to low: it needs a slow or failed GET under an active ?profile=/?client= filter, and the result panel lists exactly what moved. Suggested fix: show a loading or unknown count and disable submit until the unscoped list arrives, or use a server-side count.
  • frontend/src/components/clients/BulkMoveDialog.vue:81-102 (luna:2.F4.3): loadAllClients has no per-open generation check. It only tests props.open, so a slow response from an earlier open can land after the response from the current open and overwrite allClients with an older snapshot. The preview count then understates or overstates the move. Verified by reading the code. The dialog component stays mounted in Clients.vue:48. Codex rated it medium. Re-mapped to low: it needs overlapping open, close and reopen cycles with out-of-order responses, and it is the same stale-async class as ledger items F1.1, F5.1 and F5.2. Suggested fix: use a request ticket, as stores/clients.ts does.

QA notes:

  • NON-BLOCKING (low), stale e2e expectation: navigation-consistency.spec.ts 'header and sidebar lay out cleanly at 390px' (corporate and dark) fails when the instance has at least one profile or credentialed client. At 390 px the header now also shows header-viewing-slot (the Viewing icon chip), but the test still expects exactly drawer, search icon, status pill, attention (if any) and Add. The PR edited this file but missed this case. It passes in the CI smoke because that instance has no profiles when the spec runs. Follow-up: add header-viewing-slot to the expected phone controls when profiles exist.
  • NON-BLOCKING (environmental, not a PR defect): web-ui-sweep.spec.ts 'tools page lists upstream tools and search narrows them' failed only on my profile-fixture instance, because no fixture tool matches 'echo'. It passes on the clean smoke instance with mcpfixture.
  • NON-BLOCKING (low, cosmetic): on the Tokens tab at 1440 the Profile column is narrow. 'Work Read-only' chips wrap over 3 lines, the e2e-gone chip text overlaps its border, and the 'Legacy scope' badge is cramped under the token name.
  • NOTE (Spec 109 contract, not 108-i): a sidebar click (for example Activity to Tools) drops the profile filter, while in-app linkTo links and Back keep it. This matches contract rule 3, but the plan's wording 'persists /ui/activity → /ui/tools → Back' is only met through links and Back.
  • NOTE (backend, outside this PR): PATCH /config returns 'No configuration changes detected' with requires_restart false even when the value changed (require_mcp_auth and anonymous_profile did apply). A stale-classification PUT /profiles returns warnings:[] while effective-tools reports the stale entry.

Metadata

Metadata

Assignees

No one assigned

    Labels

    kind/bugpriority/lowtriage/accepted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions