openai / gpt-6-astra / medium / medium effort preferred over xai / grok-4.7-efficient / medium / medium effort · clear win.
Primary judge: Sol 6.1, requested Low. Effective provider effort and internal attempts were not verified. A close win is still a scored preference; it does not establish a material defect.
Reviewed public evidence
Task goal
MVP source audit; taskCategory=ux; module category=ux, difficulty=high, expectedTests=none. Workspace navigation, role-aware shell and layout state across the shell and its focused navigation tests. Source review only; no tests run. Use only exact supplied files and cite file plus original line. Do not run tests, use shell/globs/root traversal, live services, databases, customer data, or edit source. Report concrete source-proven issues with impact and confidence, otherwise state no findings. Identify every excluded boundary explicitly; do not infer production readiness. This source-only audit packet is bound to verified merged main commit 9dab4e99d3bfadf995dbaa031b9b6a365970e1e3; it does not verify runtime or production behavior.
openai / gpt-6-astra / medium / medium effort answer
## Conclusion
Direct, independent review of all 20 supplied files found **five source-proven issues**. No tools, tests, runtime checks, or edits were performed.
Evidence is limited to packet `sha256:d44ebc3ebabfab1c97f69230cb62766b52edc2ac299c211c46c8eb0ba17fcb67`, bound to commit `9dab4e99d3bfadf995dbaa031b9b6a365970e1e3`. This does not establish runtime behavior or production readiness.
## Findings
### 1. Standard navigation offers server-excluded modules
**Severity: Medium · Confidence: 0.99**
- `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:332–343` constructs Standard navigation from the entire fixed registry, without checking `workspace.modules`.
- `[REDACTED: private project name]/frontend/src/lib/navRegistry.ts:184–189` includes Map & Pipes and Plans & Reports unconditionally.
- `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:200–214` rejects an unavailable server-backed module and redirects to the default landing.
**Impact:** When the resolved workspace excludes Reports, the shell still supplies a Reports navigation item whose handler leads back to another page. Workspace-specific navigation is inconsistent with module eligibility.
**Recommendation:** Derive Standard items from resolved modules plus the intentional client-only allowlist.
**Boundary:** The supplied code proves the incompatible navigation inputs and handler behavior; actual rendering by the excluded `V3Sidebar` is unverified. This is not evidence of backend authorization bypass.
### 2. Legacy workspace hamburger changes state that its shell never renders
**Severity: Medium · Confidence: 0.99**
- `[REDACTED: private project name]/frontend/src/components/layout/TopBar.tsx:23–30` toggles `sidebarDrawerOpen` below 1280px.
- `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:368–392` renders the legacy sidebar using only `sidebarCollapsed`.
- Its complete legacy return, lines **368–689**, contains no drawer.
- `[REDACTED: private project name]/frontend/src/hooks/useV3Shell.ts:43–50` supports selecting this legacy branch.
**Impact:** In legacy workspace mode below 1280px, the hamburger announces opening/closing the menu but cannot change the rendered sidebar. The expanded sidebar continues consuming 240px.
**Recommendation:** Connect the legacy workspace branch to a drawer or give its hamburger a supported collapse action.
### 3. Workspace switching leaves existing workspace reads able to overwrite optimistic state
**Severity: Medium · Confidence: 0.92**
- `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:119–124` maintains an active workspace query.
- The switch handler at **226–276** overwrites its cache and starts the PATCH without cancelling an existing query.
- Only the newly requested invalidation is sequenced after PATCH success, at **254–257**.
- Canonical navigation immediately follows whatever workspace occupies that cache, at **213–214**.
**Impact:** If a workspace GET is already in flight when a switch occurs, its old response can replace the optimistic target and redirect the user back before the post-PATCH refetch corrects it. Sequencing the new refetch does not protect against the existing read.
**Recommendation:** Cancel outstanding workspace queries before the optimistic update and protect overlapping switches from stale completion/rollback.
**Boundary:** This identifies a source-level race under the stated request ordering, not an observed runtime occurrence.
### 4. Focused navigation tests exercise copies rather than the implementation
**Severity: Medium · Confidence: 1.00**
- `[REDACTED: private project name]/frontend/src/__tests__/WorkspaceShell.multinav.test.tsx:189–202` defines its own switch handler; **199–200** patch and immediately invalidate.
- The actual handler defers invalidation until success: `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:251–258`.
- The test also uses `['userWorkspace']` at line **192**, whereas the real key is `['user-workspace']` in `[REDACTED: private project name]/frontend/src/api/queryKeys.ts:662–664`.
- `[REDACTED: private project name]/frontend/src/__tests__/PlatformWorkspacesPage.test.tsx:89–100` invokes a locally created mock directly and asserts that same invocation, without exercising a production handler.
**Impact:** These tests cannot catch removal or breakage of the actual switch/save behavior. The switch test specifically preserves the immediate-invalidation sequence that production code intentionally avoids.
**Recommendation:** Exercise exported production logic or mounted handlers, including PATCH settlement and rollback, rather than inline mirrors.
### 5. Standard smoke assertions require routes that the current resolver deliberately redirects
**Severity: Medium · Confidence: 1.00**
- `[REDACTED: private project name]/frontend/tests/app-layout/v3-shell-smoke.spec.ts:209–214` includes `/inspections` and `/repairs`.
- Lines **238–243** require those route segments to survive navigation.
- `[REDACTED: private project name]/frontend/src/lib/workspaceModules.ts:215–230` excludes both from the client-only allowlist.
- The smoke workspace fixture at **69–73** also excludes them from server modules.
- `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:200–214` therefore resolves both to the fixture’s default landing.
**Impact:** The assertions contradict the supplied resolver and fixture. Successful rendering of the intended fallback would fail these tests.
**Recommendation:** Assert the intended redirects or replace the removed destinations with supported routes.
Additional coverage limits: the Pro suite is explicitly skipped at `[REDACTED: private project name]/frontend/tests/app-layout/v3-shell-smoke.spec.ts:138`; its purported nonblank assertion accepts zero characters at **178**. Neither establishes working Pro layout.
## Discarded or unproven hypotheses
- Client-only Uploads bypasses workspace-module filtering intentionally (`[REDACTED: private project name]/frontend/src/lib/workspaceModules.ts:117–122`); excluded module/backend implementations prevent any authorization-bypass conclusion.
- Frontend role values matching the test’s hardcoded list does not prove backend enum parity.
- Drawer accessibility, breakpoint coordination in V3 chrome, feature enforcement inside modules, and tenant isolation cannot be established from the supplied shell alone.
## Explicit excluded boundaries
All files outside the declared 20-file packet are excluded. Specifically, the listed direct dependencies below were **not reviewed**. Paths are relative to `[REDACTED: private project name]/frontend/src/`, retaining the packet’s dependency names:
- **API/auth:** `api/client.js`, `api/superAdmin.js`, `api/auth.js`, `api/dashboard.js`, `auth/AuthContext.js`.
- **Configuration/hooks:** `config/features.js`, `hooks/useMediaQuery.js`, `hooks/usePermissions.js`, `hooks/useCommandCenter.js`.
- **Supporting logic:** `lib/roleLabels.js`, `lib/clientToServerMigration.js`, `lib/useUserPreferencesQueue.js`, `components/review-tabs/playbackSpeeds.js`.
- **Chrome:** `components/layout/OrgSwitcher.js`, `components/layout/SurfaceSwitcher.js`, `components/layout/OffboardingBanner.js`, `components/layout/SidebarDrawer.js`, `components/layout/TrustStrip.js`, `components/layout/V3Sidebar.js`, `components/layout/V3TopBar.js`.
- **Other components:** `components/alerts/AlertDropdown.js`, `components/assistant/AssistantBubble.js`, `components/assistant/assistantBubbleVisibility.js`, `components/chat/ChatPanel.js`, `components/common/ErrorBoundary.js`, `components/common/Toast.js`, `components/consultant/CommandCenter.js`, `components/media/ProcessingIndicator.js`, `components/v3-review/V3ProDevToggle.js`.
- **Stores:** `store/useAIStore.js`, `store/useExplorerStore.js`, `store/useLayerStore.js`, `store/useMapRailUIStore.js`, `store/useMonitorUIStore.js`, `store/useProfileBankFilterStore.js`, `store/useViewUIStore.js`, `store/useWorkspaceProModeStore.js`, `stores/useV3SessionStore.js`.
- **Module bodies:** `components/workspace/modules/MunicipalExplorerModule.js`, `components/workspace/modules/MunicipalReportsModule.js`, `components/workspace/modules/MunicipalUploadsModule.js`, `components/workspace/modules/V3InspectionsModule.js`, `components/workspace/modules/V3RepairsModule.js`, `components/workspace/modules/V3TodayModule.js`, `pages/v3/V3InspectionReview.js`.
Also excluded: route mounting and guards; platform workspace editor implementation; backend resolver, schemas, role enum, persistence and authorization; global CSS and tooling configuration; dependency implementations; live services, databases and customer data; browser rendering, assistive-technology behavior, actual network ordering, test execution and deployment state.
**Next useful action:** Correct the navigation/state mismatches and align focused test contracts with production behavior in a separately authorized implementation task.
MATERIAL_EVIDENCE_CONFLICT: `[REDACTED: private project name]/frontend/tests/app-layout/v3-shell-smoke.spec.ts:238–243` requires inspections/repairs URLs to remain, while `[REDACTED: private project name]/frontend/src/lib/workspaceModules.ts:225–229` removes their routability and `[REDACTED: private project name]/frontend/src/components/workspace/WorkspaceShell.tsx:200–214` redirects them.
xai / grok-4.7-efficient / medium / medium effort answer
Source review only. The default shell’s navigation is not workspace- or role-aware, and the focused tests pin copies of behavior the shell no longer implements. This does not establish runtime or production readiness.
## Findings
1. **Default V3 nav is a fixed municipal list; server module and role gates are ignored.** Confidence: 0.93.
`useV3Shell()` is on unless `?v3shell=0` or `pp.v3_shell=0` (`useV3Shell.ts:57-61`). On that path `WorkspaceShell` always passes `V3_STANDARD_NAV` (`today`, `municipal.explorer`, `municipal.reports-amp`, `municipal.uploads`) and never passes `sidebarModules` (`WorkspaceShell.tsx:294-300`, `332-353`; `navRegistry.ts:180-190`). `WorkspaceShell` does not read the user role (auth hook removed at `WorkspaceShell.tsx:28`).
Impact: after a switch to a non-municipal workspace (the multinav tests use `consultant` / `consultant.client-list`), the task nav stays municipal. Server-omitted keys silently bounce to `default_landing` with no toast (`WorkspaceShell.tsx:200-214`). `today` and `municipal.uploads` are client-only, so they render inside any workspace, including one whose `workspace.modules` omitted them (`workspaceModules.ts:117-127`, `215-230`, `239-240`). Uploads is a write surface with no role filter in this packet. Legacy `?v3shell=0` still injects icon-bearing client-only modules into every workspace (`WorkspaceShell.tsx:294-300`; `getClientSidebarModules` at `workspaceModules.ts:253-261`).
2. **A URL for an accessible but non-active workspace is rewritten with no explanation.** Confidence: 0.9.
Any `workspace.key !== workspaceKey` becomes `<Navigate replace>` to the server-active key (`WorkspaceShell.tsx:213-214`). The info toast runs only when the URL key is absent from `accessible_workspaces` (`WorkspaceShell.tsx:177-189`). The multinav mirror documents the same split (`WorkspaceShell.multinav.test.tsx:140-147`).
Impact: bookmarks and shared `/w/{other-accessible-workspace}/…` links snap back to the persisted workspace. Multi-workspace URLs are not selectable entry points.
3. **Gated or dormant module clicks fail silently.** Confidence: 0.92.
Same redirect (`WorkspaceShell.tsx:200-214`) covers `municipal.reports-amp` / `municipal.explorer` when missing from `workspace.modules`, and `/w/:ws/inspections` and `/repairs` after those keys were removed from `CLIENT_ONLY_MODULE_KEYS` (`workspaceModules.ts:225-229`) while remaining in `MODULE_REGISTRY` (`workspaceModules.ts:139-148`) and in the smoke route list (`v3-shell-smoke.spec.ts:209-214`, `242-243`). No module-level toast exists.
Impact: nav clicks and those two URLs look like no-ops or unexplained jumps to `default_landing`.
4. **Focused nav tests do not lock the shell.** Confidence: 0.95.
Both vitest files state they do not mount React (`PlatformWorkspacesPage.test.tsx:5-8`; `WorkspaceShell.multinav.test.tsx:5-10`) and assert in-file copies. The switch copy expects `setQueryData` → `patch` → `invalidate` → `navigate` and uses `['userWorkspace']` (`WorkspaceShell.multinav.test.tsx:163-211`). Production calls `mutate`, navigates immediately, and invalidates only in `onSuccess` under `queryKeys.userWorkspace.all` = `['user-workspace']` (`WorkspaceShell.tsx:245-276`; `queryKeys.ts:662-663`). `onError` cache restore (`WorkspaceShell.tsx:259-270`) is untested. Role tests reimplement `toggle` / `orderedSelection` locally (`PlatformWorkspacesPage.test.tsx:53-100`) and do not import a page. The smoke spec’s “Standard routes below DO run green” comment (`v3-shell-smoke.spec.ts:137-137`) disagrees with finding 3; its Pro `<main>` length check is `>= 0` inside a skipped suite (`v3-shell-smoke.spec.ts:138`, `178`).
Impact: CI can stay green while switch order, query key, rollback, role payload, and inspections/repairs routing drift.
5. **Layout chrome does not match loading or lazy module states.** Confidence: 0.88.
`isLoading` returns `WorkspaceShellSkeleton` before the V3 branch (`WorkspaceShell.tsx:192` vs `332`), so the default shell is replaced by a fake 48px header plus 192px sidebar (`WorkspaceShell.tsx:39-59`). The same skeleton is the Suspense fallback inside the real main (`WorkspaceShell.tsx:356-361`, `678-685`). `key={resolvedModuleKey}` remounts the lazy module on every switch (`WorkspaceShell.tsx:358`, `681`).
Impact: full-page skeleton, then V3 chrome, then a nested fake header/sidebar inside `<main>` on chunk load.
6. **Role-removed empty state is not on the default shell.** Confidence: 0.84.
“No workspaces assigned” renders only in the legacy return (`WorkspaceShell.tsx:425-445`). The V3 return (`WorkspaceShell.tsx:345-364`) happens first and only passes `sidebarWorkspaces`, which still prepends a synthetic active row (`WorkspaceShell.tsx:306-319`). Whether `V3Sidebar` repeats that notice is outside this packet.
Impact: on the default shell, a mid-session role strip can leave modules visible via the synthetic row with no administrator notice.
7. **View-as banner can ignore an explicit server “not view-as”.** Confidence: 0.74.
`isServerViewAs` is true only when both ids are non-null and differ (`ContextBanner.tsx:44-45`). Otherwise `activeOrgName` falls through to `getActiveOrgName()` (`ContextBanner.tsx:46-47`), and `isViewAs = !!activeOrgName` (`ContextBanner.tsx:53`). A server home-org result does not clear a leftover legacy name. `getActiveOrgName()` itself is outside the packet, so whether that helper is null at home is unverified.
Impact: possible false “ACTING AS … any changes affect this client” ribbon (`ContextBanner.tsx:177-178`) on a compliance banner.
8. **Stacked context ribbon can clip its unwind controls.** Confidence: 0.8.
Impersonation plus view-as uses `flex-wrap` inside `height: 32` (`ContextBanner.tsx:86-92`) with two buttons (`ContextBanner.tsx:105-127`). View-as-only is `height: 40` and does not wrap (`ContextBanner.tsx:167-173`).
Impact: on a narrow viewport the End Impersonation / Return Home controls can clip or overflow. Neither impersonation ribbon has `aria-live`; only the view-as ribbon does (`ContextBanner.tsx:174`).
## Discarded or not treated as defects
- Immediate `invalidateQueries` before PATCH is not the current handler bug. Production intentionally invalidates inside `onSuccess` (`WorkspaceShell.tsx:245-257`). The defect is the stale test contract (finding 4).
- Optimistic `setQueryData` leaves `can_use_pro_surface` / `effective_capabilities` from the previous payload (`WorkspaceShell.tsx:234-243`). Comments describe Pro access as org-level (`workspace.ts:42-54`). No in-packet shell control reads those fields during the switch window.
- Shared `sidebarCollapsed` across Pro and workspace is documented (`WorkspaceShell.tsx:380-383`), not an accidental mismatch.
- `aria-current="page"` on both the active workspace and the active module (`WorkspaceShell.tsx:464`, `521`, `557`, `613`) is a legacy-only a11y defect; the default path does not render that `<nav>`.
- Tooltip `aria-describedby` is set while the tooltip node exists only when visible (`Tooltip.tsx:103-107`, `129`). Real, but secondary to navigation.
## Excluded boundaries
Not in this packet, so not reviewed and not assumed: `client.js` (`getActiveOrgName`, `switchActiveOrg`), `AuthContext`, `superAdmin`, `features`, `usePermissions`, `useMediaQuery`, `roleLabels`, `useAIStore`, `V3Sidebar`, `V3TopBar`, `SidebarDrawer`, `TrustStrip`, `OffboardingBanner`, `SurfaceSwitcher`, `OrgSwitcher`, dashboard/command-center/assistant modules, preference stores and `clientToServerMigration`, all `workspaceModules` lazy targets, backend `Role` enum and `workspace_resolver.py`, and `PlatformWorkspacesPage` (tests name it; source is absent). No tests were run. No production or runtime behavior was verified. Commit binding `9dab4e99d3bfadf995dbaa031b9b6a365970e1e3` is the packet identity only.
## Next useful action
Filter `standardItems` through `workspace.modules` plus an explicit client-only allowlist before passing them to `V3AppShell`, and toast when a URL module is dropped to `default_landing`. Point the multinav and smoke specs at those real branches instead of local mirrors.
MATERIAL_EVIDENCE_CONFLICT: v3-shell-smoke.spec.ts:242-243 expects `/inspections` and `/repairs` to stay on those URLs, but workspaceModules.ts:225-229 removed them from `CLIENT_ONLY_MODULE_KEYS` and WorkspaceShell.tsx:200-214 redirects unknown module keys to `default_landing`; WorkspaceShell.multinav.test.tsx:163-211 requires synchronous invalidate before navigate on key `['userWorkspace']`, but WorkspaceShell.tsx:251-276 invalidates only in patch `onSuccess` and navigates immediately via `queryKeys.userWorkspace.all` (`['user-workspace']`, queryKeys.ts:662-663).Primary judge's stated reason
A provides a more reliable actionable audit: its legacy hamburger finding traces an actual disconnected state path, and its navigation finding avoids asserting excluded rendering or authorization behavior. This supports a clear comparative advantage in evidentiary discipline and useful coverage, not a claim that every A finding is an established runtime defect.
This reason is the judge's assessment. No independent factual-defect finding is asserted by this record.
Battle wave: 87604684-5410-4204-96bf-6143dab2c1dc. Pair: brp1_ed2cdc3a4ac70dd1ecc39857a0de7cdd552f0ef5e9a3fcf654ec4c7cf382e301. A separate independent review is required before calling a concern a verified factual defect. Judge disagreement is not recorded here.