Repository navigation
Description
Delivery phase
Phase 1 - frontend with mock services
Goal
Let a verified mock user browse releases and nested category paths without losing hierarchy or loading the whole catalog into the DOM.
Context and authority
Milestone F3; read AGENTS.md, docs/team/product-manager.md, docs/product/LCA_diff_PRD.md, docs/engineering/roadmap.md, and docs/engineering/LCA_diff_Implementation_Specification.md §§6.2, 6.8, 7.1. Current planning baseline is on docs/agent-workflow, pending review/merge into main; proposed ADRs are not accepted authority. Implement process-selector tree components/hooks using discovery services; add synthetic deep-tree and paginated fixtures/tests. These application paths are planned until created. Exclude all archive/reference folders.
Requirements and constraints
Render release → category → subcategory segments → process/geography. Respect provider path segments and preserve source strings; display versions as separately expandable roots. Fetch through the service boundary and support cursor continuation, cancellation and safe loading/error/empty states. Establish accessible disclosure/tree navigation; checkbox selection is added separately.
One session-sized task/PR including verification and handoff. Run all development, installation and checks in containers; install nothing on the host. No real backend, Firebase project, cloud credentials or proprietary inputs. If the current PRD/spec must change, prepare an ADR and updates to both current documents in the same PR.
Acceptance criteria
- AC1 - The mock release tree shows nested path segments and process geography with stable node identities; separate release roots remain distinct.
- AC2 - Paging/window continuation reveals descendants beyond the first page without replacing or duplicating already loaded tree nodes.
- AC3 - Disclosure controls are keyboard-operable with appropriate labels/expanded state; tree item focus remains usable as nodes load/unmount.
- AC4 - Loading, empty catalog, retryable error and cancellation scenarios are visible and do not leak protected data after logout.
- AC5 - Tests exercise deep paths, duplicate display labels with distinct identities, pagination and service-driven retry; no component reads fixtures directly.
Out of scope and follow-ups
Reactive search is #17; individual selection/selected list is #18; scoped bulk checkboxes are #19. No real API or database.
Verification plan
Inside ./dev shell, run format:check/lint/typecheck/test:unit/build and npm --prefix apps/frontend run test:e2e. Browse a paginated synthetic tree by keyboard, trigger a failed/retried page and confirm protected reads stop when auth is revoked.
Engineer records branch/SHA and exact results, leaves issue open, and hands off to QA. QA verifies every criterion at that SHA and reports PASS/FAIL/BLOCKED; mock evidence is not proof of real security/integration.
Dependencies and readiness
Blocked by #15, #7. No implementation until dependencies and the M1 environment runtime gate are satisfied. This body is groomed planning material, not PM READY while blockers remain. Coordinator/PM rechecks merged dependencies and session-sized scope before starting.
Current readiness — supersedes historical planning baseline/blockers above
PM: READY for Phase 1/F3 on merged main at 1f8277439cc4a74d23126c87267505944a06fd92.
Dependencies.
- [Task] F2: verify complete mock authentication and accessible shell journeys #15 is closed. It had independent QA PASS at
0143fba, hostedqualityand full-suite dispatch SUCCESS, and a maintainer merge of PR F2: verify complete mock authentication and accessible shell journeys #49 as1f82774. All F2 tasks [Task] F2: build the direct application shell and accessible locked login dialog #11–[Task] F2: verify complete mock authentication and accessible shell journeys #15 are closed. - [Task] F1: implement asynchronous mock discovery and selection services #7 is closed. PR Implement asynchronous mock discovery and selection services #41 was merged as
af4aa98, with QA PASS and hosted CI recorded. - M1 ([Task] M1: complete container runtime verification and the bootstrap lock #2) and M2 ([Task] M2: activate issue forms and publish the F1–F5 execution backlog #3) are closed.
The merged documents, contracts and code on main replace the historical planning-branch statements above. AC1–AC5 are unchanged; the decisions below make them objective.
No ADR or specification change. The work uses the existing DataService.releases/search contracts unchanged. Adding an app-layer infinite-query factory and a pinned virtualization dependency are ordinary implementation choices within §3 ("appropriate virtual-grid primitives") and the provisional-DTO latitude. If implementation finds that the contract cannot express a requirement, stop and report it. Do not widen DTOs silently.
Merged interfaces this issue consumes (do not change behavior)
src/services/contracts.ts:releases()returns a terminalPage<Release>:next_cursor: null, with the activerevision_snapshot.search(SearchRequest)takesfields, an optional exact-segmentbranch_path,limit,cursorandrevision_snapshot, and returnsPage<SearchNode>.- Branch nodes carry
id,release_id,label,pathandmatching_descendant_count. Process nodes carryid,release_id,label,geographyandpath. - Node IDs are opaque.
src/services/mock/discovery.ts:- Each page bounds process leaves (
limit≤window_limit, default 100; more givesREQUEST_WINDOW_TOO_LARGE). Leaves are sorted by case-insensitive name, then geography, then ID. - Each page repeats each returned leaf's full ancestor chain from the release root (
path: []). total_countcounts matching processes.- Cursors are bound to operation, fields, branch and snapshot. Replaying a cursor with other inputs gives
INVALID_FILTER. branch_path-scoped paging with a single-release snapshot is supported.matching_descendant_countcounts over the request's whole match set. It is therefore exact for nodes at or below the requestedbranch_pathand partial for ancestors above it.scenario.latency_msmay be a number or(operation, sequence) => ms.scenario.failuresis a static per-instance map.createDiscoveryCatalog(n)only generates more leaves on the fixture's paths.
- Each page bounds process leaves (
src/app/queries.ts:useServiceQueries()gives plainqueryOptionskeyed["lca-services", 1, namespace, uid, operation, dto],enabledonly for a verified UID. No infinite or cursor query exists yet.src/App.tsx: theWorkspace#process-sidebarholds the placeholder text "Choose processes here…" under the heading "Processes", andWorkspaceis keyed by UID. Sign-out locks the session and clears the QueryClient (service-context.ts).- Default composed demo catalog: one release, "Synthetic precision fixture", version "fixture v1", active revision two. It has three processes:
- transport systems › road › operations › Synthetic road service Alpha — CH
- transport systems › road › operations › Synthetic road service Gamma — CH
- transport systems › road › operations › infrastructure › Synthetic road service Beta — DE
Decisions
D1 — Loading model: lazy per-branch loading, cursor-paged.
- Roots come from the shared
queries.releases()options. Reuse that exact key so the existingsession.test.tsxread counts stay valid. - Every release is a separate root, labelled from
display_nameplusversionverbatim. Roots start collapsed, and nothing is searched until the user expands a node. - Expanding a release root or branch issues
search({ fields: {}, branch_path: node.path, revision_snapshot: [that release's {release_id, revision_id}], limit: TREE_PAGE_LIMIT }). Continuation passes that query'snext_cursor. TREE_PAGE_LIMITis an exported module constant of 50 with no runtime configuration. Tests size their catalogs against it.- There is no single whole-catalog walk and no per-node child-listing endpoint.
D2 — App-layer query factory and no service change.
- Add an infinite-query factory (for example
searchPages(input)) tocreateServiceQueries. - It uses the same auth guard and capture, and a distinct key segment so it never collides with the plain
searchkey:["lca-services", 1, namespace, uid, "searchPages", dtoWithoutCursor]. - Use
initialPageParam: undefinedandgetNextPageParam: (last) => last.next_cursor ?? undefined. - Do not change
src/services/**behavior, contracts or the mock runner. - For retry, tests wrap the injected
DataServicelocally, for example to fail on the first call and then delegate. The staticfailuresmap cannot express fail-then-succeed, and it is not to be extended here.
D3 — Merge rules (pure, unit-tested model).
- Build the visible tree as a pure function of the loaded pages in the query cache. Do not keep a separate long-lived store of protected data.
- Parent linkage comes from
release_idplus apathprefix: a branch's parent haspath.slice(0, -1), and a process's parent branch haspathequal to the process path. - Never parse or construct service node IDs. The branch at
path: []is that release's root. - Deduplicate by
(release_id, id)across all scoped queries. A node keeps its React key and identity when later pages arrive. - Accept
matching_descendant_countfor a node only from queries whosebranch_pathis a prefix of, or equal to, that node's path. Ignore counts reported for ancestors of a deeper scope. - Order siblings deterministically, independent of load order:
- sub-branches first, ordered by lower-cased label (code-unit compare) and then ID;
- then processes, in the service order (lower-cased name, geography, ID).
- Render labels, segments and geography verbatim: no trimming, case change or re-splitting.
- Pages for a release are bound to the snapshot used by its root. A different snapshot creates different keys and never mixes with earlier pages.
D4 — Accessible pattern: ARIA tree with roving tabindex. Use role="tree", named "Processes", containing flat, virtualized role="treeitem" rows.
- Each row carries
aria-level,aria-posinsetandaria-setsize. Use-1while the parent still has anext_cursor. Branches carryaria-expanded, andaria-busywhile their pages load. - One tab stop. Keyboard behavior:
- ArrowDown/ArrowUp move to the next/previous visible item.
- ArrowRight expands a collapsed branch, or moves to the first child of an expanded one.
- ArrowLeft collapses an expanded branch, or moves to the parent.
- Home/End move to the first/last visible item.
- Enter toggles a branch, or activates a continuation/retry row.
- Space is reserved (left unbound) for [Task] F3: manage individual selection order and a virtualized selected-process list #18/[Task] F3: implement filter-scoped bulk selection and tri-state parent checkboxes #19 selection.
- An optional pointer chevron is not a separate tab stop.
- Justification:
- Virtualization flattens the DOM, so nested disclosure-button groups and
aria-controlscannot survive windowing. - Level, set size and position convey hierarchy for unmounted rows.
- A single tab stop scales to thousands of rows.
- ARIA 1.2 treeitems support
aria-checkedtrue/false/mixed. [Task] F3: manage individual selection order and a virtualized selected-process list #18/[Task] F3: implement filter-scoped bulk selection and tri-state parent checkboxes #19 will add checkbox state to these rows, which satisfies §6.8'saria-checked="mixed".
- Virtualization flattens the DOM, so nested disclosure-button groups and
- §6.8's "tree disclosure buttons … accessible via keyboard" is met by keyboard-operable
aria-expandedtreeitems. This is an interpretation, not a spec deviation. - Accessible names:
- Branches: label plus count, for example "operations, 2 processes".
- Processes: "name — geography".
- Continuation rows: "Load more in ( of loaded)".
- Show a visible focus ring.
D5 — Focus through loading and unmounting. The active item is tracked by node identity, not index.
- The active row is always kept mounted (for example with a virtualizer
rangeExtractor) and scrolled into view on keyboard moves. DOM focus never falls tobodyduring scrolling or loading. - After a continuation load, focus stays on the continuation row if more pages remain. Otherwise it moves to the first newly revealed item.
- Collapsing an ancestor of the focused item moves focus to that ancestor.
- A failed load leaves focus on the branch or its retry row.
D6 — Virtualization: introduce @tanstack/react-virtual here.
- Add it as an exact-pinned runtime dependency (no range). Use the latest 3.x release published at least 14 days before installation and compatible with the React 19.3.1 peer. Record the version and publish date in the PR.
- Install only inside the container (
npm --prefix apps/frontend install --save-exact @tanstack/react-virtual@<x.y.z>). Commit thepackage.jsonandpackage-lock.jsondiff, limited to that package.npm cimust pass. - Use fixed-height rows with modest overscan. F4/[Task] F4 — Virtualize comparison rows and columns with sticky alignment #23 reuses the same primitive for variable rows and columns, so do not add a second library later.
- Fetch subscriptions belong to expanded branches whose ancestors are all expanded, never to mounted virtual rows. Scrolling therefore never aborts or refetches a page.
D7 — States.
- Loading releases shows a polite loading status.
- An empty catalog (zero releases) shows "No published releases are available." without an error.
- A root or branch with zero matches shows an explicit empty row.
- A failed releases load or page load shows a safe message from
ServiceError, without request details beyond the message. A Retry control appears only whenretryableis true. Retry re-requests only the failed page, and loaded nodes remain. - Non-retryable errors (for example
STALE_SNAPSHOT) show the message without automatic retries. - Session-loss codes keep the existing guard behavior: lock the session and clear the cache.
- Announce page-load completion and failure through one polite live region outside the tree.
D8 — Cancellation.
- Collapsing a branch, or an ancestor of it, while its page is in flight aborts that request through the TanStack signal. No error is shown, already loaded pages stay cached, and re-expanding starts the request again.
- Signing out during an in-flight page aborts the request or discards its result through the guard epoch. No tree data or error is rendered afterwards.
- Expanded state is in-memory React state only. Per §6.8 it is never written to browser storage, and it resets on account change.
D9 — Scenario controls: component-level injection; no shipped scenario switch.
- Add no query parameters, window globals, environment or build flags, or UI to select latency, failure, empty or large catalogs in the composed app.
createApplication("mock")stays as is. - Latency, failure/retry, empty, large, deep, duplicate-label, multi-release, pagination and cancellation scenarios are covered with Vitest/RTL. Those tests inject
createMockDiscovery({ catalog, window_limit, scenario })(wrapped where needed) throughApplicationProviderswithmode: "test". - Test catalogs are plain
DiscoveryCatalogobjects built in test files, or in a test-only helper that no production module imports. Keep the ESLint service boundary unchanged; do not weaken any rule. - Browser tests use the composed default demo catalog. That catalog is too small to page with a 50-leaf limit, so the browser does not prove continuation, latency or large-catalog DOM bounds.
- Record these as component-level evidence, not browser PASS. The browser-reachable large synthetic scenario decision is carried to F4 #23, whose 200×2,000 Chromium workload needs the same mechanism, and to the F3 gate in [Task] F3: implement filter-scoped bulk selection and tri-state parent checkboxes #19 AC6. If added there, it must be explicit, validated, mock-mode-only, visibly identified as demo, and never a fallback.
D10 — Existing tests.
- The verified workspace now issues only
releases()on mount, and nosearchuntil the user expands a node. - Deliberately update
src/App.test.tsxassertions that expected zero data calls in verified states. The two verified cases currently callexpectNoDataCalls. Change them to "onlyreleases" and give their harness unprotected discovery data so that a mockAUTH_REQUIREDdoes not lock the session. - Keep every pre-verification zero-call assertion. Update the e2e/component tests that referenced the "Choose processes…" placeholder; keep the "Processes" heading.
D11 — Roadmap: include the status update in this PR. The #16 PR includes a small supporting-documentation commit to docs/engineering/roadmap.md:
- Mark the F2 row in Current position Complete: [Task] F2: build the direct application shell and accessible locked login dialog #11–[Task] F2: verify complete mock authentication and accessible shell journeys #15 merged, final PR F2: verify complete mock authentication and accessible shell journeys #49 at
1f82774, independent QA and hosted CI passed. - Change the F2 paragraph's "not complete until [Task] F2: verify complete mock authentication and accessible shell journeys #15…" sentence to "complete".
- Set the F3 row to "[Task] F3: render the paginated release and nested process tree #16 in progress".
The #15 closure comment deferred this to "the next roadmap-touching PR", and no separate issue exists. This is a status correction tied to work already closed, so the issue-first rule is kept. Make no other roadmap changes beyond the D9 carry-forward note, which is optional, at most one line in F3 and F4.
Scope
- Change/add:
src/components/process-tree/(pure model plus tests,ProcessTreecomponent, CSS, component tests);src/app/queries.ts(infinite factory);src/App.tsx(replace the sidebar placeholder with the tree);- affected existing tests (D10);
e2e/process-tree.spec.ts(new);apps/frontend/package.jsonandpackage-lock.json(D6);src/services/README.md: a short "Tree consumption ([Task] F3: render the paginated release and nested process tree #16)" paragraph recording D1/D3 as an I1 adapter-parity expectation. The real search must support single-releasebranch_pathpaging with ancestor chains and exact in-scope counts.docs/engineering/roadmap.md(D11).
- Out of scope:
- search fields, debounce or filter expansion ([Task] F3: add reactive AND-tokenized process search with cancellation #17);
- checkboxes, the selected list and selection state ([Task] F3: manage individual selection order and a virtualized selected-process list #18);
- bulk/tri-state actions and
resolveSelection([Task] F3: implement filter-scoped bulk selection and tri-state parent checkboxes #19); - headers or comparison work (F4);
- persistence (F5);
- the browser-reachable scenario configuration ([Task] F4 — Virtualize comparison rows and columns with sticky alignment #23/[Task] F3: implement filter-scoped bulk selection and tri-state parent checkboxes #19, D9);
- auto infinite scroll (continuation is explicit);
- type-ahead;
- any change to service, contract, composition or Playwright projects.
Objective verification (maps to AC1–AC5)
Model unit tests (model.test.ts):
- (AC1) Paths of six or more segments, including segments with mixed case and
/,&and surrounding spaces, render verbatim. Two releases with identical paths stay distinct. - (AC5) Duplicate labels produce distinct nodes:
- an "operations" branch under two different parents;
- two same-name, same-geography processes with different IDs.
- (AC2) Merging a second page and a deeper-scoped query deduplicates and does not change existing node identity or order. Ancestor counts from deeper scopes are ignored. Sibling order is the same in every load order.
Component tests (ProcessTree.test.tsx plus App/session integration, with injected createMockDiscovery):
- (AC1) The release roots render collapsed with
display_name/version. Expanding issues a single-release,branch_path-scopedsearchwithlimit50 (spy on the DTO). - (AC2) A branch with at least 120 leaves shows "Load more"; continuation reveals leaves 51–100 and then 101–120. Previously rendered treeitem elements remain the same DOM nodes, every key is unique, and the continuation disappears when the branch is exhausted.
- (AC3) Each key in D4 moves focus and toggles
aria-expanded. The tests checkaria-level,aria-setsize(including-1),aria-posinset, accessible names, and a singletabindex=0. Focus follows D5 through load, collapse and continuation completion. Space does not toggle expansion. - (AC3/§9.1) With at least 2,000 loaded leaves and mocked element sizes in jsdom, the mounted treeitem count stays at or below the viewport rows plus overscan plus the pinned active row. Keyboard navigation to an off-screen item scrolls it in and focuses it.
- (AC4) The following are covered:
- the loading status under latency;
- an empty catalog;
- a zero-match branch;
- a releases failure and a page failure,
TEMPORARILY_UNAVAILABLEthen success through the wrapper, where Retry recovers and the loaded nodes remain; - a non-retryable error with no Retry control;
- collapse during an in-flight page, where the spied
signal.abortedis true, no error is shown, and re-expanding refetches; - sign-out during an in-flight page and after load, where no tree text remains and the QueryClient holds no
lca-servicesentries; - signing in again as the same or a different UID, where roots are collapsed and expansion state is not in storage.
- (AC5) The existing lint boundary test still passes. No component imports
services/mock/**.
Browser (e2e/process-tree.spec.ts, Chromium and Firefox, composed mock; not @smoke):
- Sign in as
[email protected]. - Tab once into the tree and confirm the visible focus ring.
- Use the keyboard to expand the root, then transport systems › road › operations, and assert:
- the infrastructure branch;
- "Synthetic road service Alpha — CH" and "Synthetic road service Gamma — CH";
aria-level1 (root) to 5 (infrastructure and the operations processes) with matchingaria-expanded;- after expanding infrastructure, "Synthetic road service Beta — DE" at level 6;
- ArrowLeft returns to the parent;
- branch counts (root 3, operations 3, infrastructure 1).
- Assert no fetch/XHR or external requests and no console errors.
- Sign out and assert that no tree text remains.
- Sign in again and assert the root is collapsed and no tree or expansion storage key was written.
Record pagination, latency and large-DOM checks as component-level only (D9).
Verification (container only; nothing installed on the host)
COMPOSE_PROJECT_NAME=lca-diff-f3-tree FRONTEND_PORT=<free port> ./dev up
COMPOSE_PROJECT_NAME=lca-diff-f3-tree FRONTEND_PORT=<free port> ./dev check
docker compose -p lca-diff-f3-tree exec -T workspace bash -lc 'npm --prefix apps/frontend install --save-exact @tanstack/react-virtual@<x.y.z> --no-audit --no-fund' # once, D6
docker compose -p lca-diff-f3-tree exec -T workspace bash -lc 'npm --prefix apps/frontend ci --no-audit --no-fund'
docker compose -p lca-diff-f3-tree exec -T workspace bash -lc 'cd apps/frontend && npm run format:check && npm run lint && npm run typecheck && npm run test:unit && npm run build'
docker compose -p lca-diff-f3-tree exec -T workspace bash -lc 'cd apps/frontend && npm run test:e2e -- --grep @smoke'
docker compose -p lca-diff-f3-tree exec -T workspace bash -lc 'cd apps/frontend && npm run test:e2e'Expected evidence:
- Chromium and Firefox pass both the smoke subset and the full suite, with counts recorded.
- The lockfile diff is limited to
@tanstack/react-virtual. - Hosted PR
qualitypasses at the delivered SHA. The full-suiteworkflow_dispatchrun is recorded, or marked NOT RUN with the reason.
Handoff. The engineer hands off the branch/SHA, the PR (Refs #16, no closing keyword), the D9 component-only evidence list and its limitations to independent QA, which verifies at that SHA. Mock evidence does not prove real authentication, authorization, data security or real search performance.
Activity
DavidVFitzGerald commentedon Nov 13, 2026
PM: BLOCKED
Groomed using docs/team/product-manager.md for F3, Phase 1 — frontend with mock services. Documentation review: PASS for scope, required sections, specification coverage and acyclic dependency links; this is not application QA or implementation readiness.
Blocking predecessor issues: #15, #7. The M1 runtime gate (#2) and merged bootstrap/M2 configuration (#3) also remain required. PM must recheck merged dependencies and current interfaces before changing this to READY.
Engineer implements one issue, commits regularly and hands the delivered SHA plus exact container checks to independent QA; do not close before QA, review and approved merge. No backend/Firebase/cloud credentials or host installations are required for Phase 1.
DavidVFitzGerald commentedon Nov 14, 2026
PM: READY — Phase 1/F3, AC1–AC5 unchanged, on main
1f82774. Dependencies: #15 is closed with independent QA PASS, hostedqualityand full-suite SUCCESS, and a maintainer merge of PR #49 (1f82774); all F2 tasks #11–#15 are closed. #7 is closed, merged by PR #41 asaf4aa98. M1 (#2) and M2 (#3) are closed. Spec §§6.2, 6.8, 7.1, 7.3 and 9.1. No ADR and no contract, service or spec change.Decisions (full detail in the appended body section):
search({fields:{}, branch_path, single-release snapshot, limit 50})and explicit cursor continuation. Roots come from the sharedreleases()key and start collapsed.searchPagesinfinite-query factory with a distinct key. Retry is tested through test-local wrappers.aria-checked.@tanstack/react-virtualas an exact-pinned 3.x dependency (at least 14 days old), installed in the container. Fetch subscriptions belong to expanded branches, not to mounted rows.createMockDiscovery. The browser covers the default demo catalog only. The browser-reachable large-scenario decision is carried to [Task] F4 — Virtualize comparison rows and columns with sticky alignment #23 and [Task] F3: implement filter-scoped bulk selection and tri-state parent checkboxes #19 AC6.roadmap.md, a supporting status correction with no separate issue.Out of scope: #17 (search), #18 (selection), #19 (bulk), F4 and F5. Exact files, tests and container commands are in the body. Handoff to the Software Engineer, then independent QA at the delivered SHA.
DavidVFitzGerald commentedon Nov 14, 2026
Engineering: READY FOR QA
feat/f3-process-tree, delivered SHAf8d5370(commits fb84a37, 83519b4, f8d5370); PR F3: lazily paged release and nested process tree (#16) #50 (Refs #16, no closing keyword).lca-diff-f3-tree):./dev checkPASS; frozennpm ciPASS (232 pkgs; lockfile diff limited to @tanstack/react-virtual 3.14.24 + virtual-core 3.19.9); format/lint/typecheck/build PASS; test:unit 185/185 (11 files, 5 consecutive runs); e2e @smoke 10 PASS; full e2e 28 PASS (Chromium+Firefox).docs/engineering/f3-process-tree-verification.md.src/services/mock/process-tree.test.tsx(lint boundary forbids mock imports elsewhere);e2e/f2-gate.spec.tsnow tabs through the tree's single tab stop.f8d5370.DavidVFitzGerald commentedon Nov 14, 2026
Hosted CI at
f8d5370: PRqualityPASS (https://github.com/DavidVFitzGerald/LCA-diff/actions/runs/43605437956); full-suiteworkflow_dispatchPASS (https://github.com/DavidVFitzGerald/LCA-diff/actions/runs/43605436596). Independent QA in progress.DavidVFitzGerald commentedon Nov 14, 2026
QA: PASS
QA: PASS at SHA
f8d537053633979ef9a0457bc3103c1ee7acdb6a(f8d5370, branchfeat/f3-process-tree, PR #50). Phase 1, mock mode only. This does not prove real authentication, authorization, data security or real search performance.Environment. Independent detached worktree
/tmp/lca-diff-qa16atf8d5370, rootless compose projectlca-diff-qa16(FRONTEND_PORT=5187). Every install, check and test ran in theworkspacecontainer, and nothing was installed on the host. I removed the worktree and compose project (down -v) afterwards. No application code was changed or committed; the temporary QA scratch test was deleted andgit statuswas clean.Commands and results
./dev up,./dev checknpm --prefix apps/frontend ci --no-audit --no-fundnpm run format:check/lint(--max-warnings 0) /typechecknpm run test:unitnpm run buildnpm run test:e2e -- --grep @smokenpm run test:e2eprocess-tree.spec.tsin bothgit diff main...HEAD -- package.json package-lock.json@tanstack/react-virtual3.14.24(exact, no range) and its dependency@tanstack/virtual-core3.19.9were added.npm lsconfirms the treenpm view … timequalitypass atf8d5370. Full dispatch run 43605436596 success,headShaf8d5370Adversarial checks (temporary component tests with injected
createMockDiscovery, deleted afterwards)aborted: true) and shows no error. On re-expand, the cached first page ("50 of 120") comes back without a refetch. PASSaccount-bkeys, andsessionStorageis empty. PASSAUTH_REQUIREDon a page read locks the session and leaves no tree text. PASSPer-criterion verdicts
releases()key and are labelleddisplay_name+versionverbatim. They start collapsed (ProcessTree.tsx:205-217) and nothing is searched until a node is expanded. Expanding issuessearch({fields:{}, branch_path, single-release snapshot, limit: TREE_PAGE_LIMIT=50})(ProcessTree.tsx:96-105,model.ts:9). Node keys are JSON of (kind, release, id), or release+path for linkage, and IDs are never parsed (model.ts:49-58). Model tests cover six-segment verbatim paths and two releases with identical paths. The e2e checks levels 1–6 and the counts 3/3/3/1.next_cursor. The paging test keeps the same DOM node for leaf 0000 across pages 1–3, all keys are unique, 120 leaf rows end up rendered, and the continuation disappears when the branch is exhausted. The merge deduplicates by (release, id), and sibling order is independent of load order (model.ts:142-174). Ancestor counts from deeper scopes are ignored (model.ts:117). Pages from another revision are ignored.role=treelabelled by the "Processes" heading, with onetabindex=0(roving). Arrow, Home, End and Enter follow D4, and Space is unbound (ProcessTree.tsx:383-420). Each row carriesaria-level/posinset/setsize(-1whilenext_cursorremains),aria-expandedandaria-busy. Accessible names follow D4, and the focus ring is a 3px solid outline (e2e). The active row is pinned throughrangeExtractor(ProcessTree.tsx:332-337), and the focus fallbacks follow D5 (:298-321). With 2,000 leaves, mounted rows stay within viewport + overscan + pinned row, and keyboard focus scrolls into view (component-level, jsdom geometry stubs).STALE_SNAPSHOTshows no Retry. Collapsing aborts the request without an error. Sign-out during and after loading aborts and leaves no tree text and nolca-servicescache entries. Re-login as the same or another UID starts collapsed, with nothing in storage. Expansion state isuseStateonly, with no storage access insrc/components. In the browser, sign-out leaves no tree text, and re-login has a collapsed root and an unchangedlocalStoragekey set.grepfinds noservices/mock,fetch(, XHR, Firebase or storage use insrc/components,queries.tsorApp.tsx, and the lint boundary is unchanged and passing. No scenario switch ships (no query parameters, globals or new env flags;composition.tsis not in the diff).searchPageskey is["lca-services",1,ns,uid,"searchPages",dto]without the cursor, behind the sameenabled/auth guard (queries.ts:76-102), andsrc/services/**behavior is unchanged. D10:App.test.tsxnow asserts "onlyreleases", and the pre-verification zero-call assertions are kept. D11: the roadmap marks F2 Complete (F2: verify complete mock authentication and accessible shell journeys #49 /1f82774) and F3 "[Task] F3: render the paginated release and nested process tree #16 in progress". Accepted deviations: the scenario tests are insrc/services/mock/process-tree.test.tsxbecause of the lint boundary, and the e2e reaches the tree tab stop by focusing the root, then Shift+Tab and Tab, rather than one Tab from page load. Both are acceptable. No PRD or spec deviation, so no ADR is required.Findings (none blocking)
ProcessTree.tsx:465-469clearstreeFocusedonly whenrelatedTargetis a Node outside the tree. Clicking a non-focusable area (header text, the "Processes" heading) orelement.blur()givesrelatedTarget === null, so the flag staystrue. The effect at:355-356then callselement.focus()when rows change, for example when a pending page arrives.document.activeElement.blur()(activeElement is now body). Wait for "transport" to appear.mainmoves focus to a focusable element and there is no latency. It becomes realistic with Phase 2 latency.nullrelatedTargetas leaving the tree, or checkdocument.activeElementinside the tree before callingfocus(), and add a regression test. Recommend fixing in this PR or in a linked Bug before [Task] F3: manage individual selection order and a virtualized selected-process list #18 builds on the tree.activestate is updated only by keyboard moves andonClick, notonFocus(ProcessTree.tsx:462-464,489-492). If focus reaches atabindex=-1row by programmatic or assistive-technology focus, Enter acts on the previously active row, not the focused one. Suggest syncingactivefrom a row's focus event.treeitems at the child level withoutaria-posinset/aria-setsize, so the reported set size excludes them (ProcessTree.tsx:565-607). This is acceptable for now; revisit with [Task] F3: manage individual selection order and a virtualized selected-process list #18/[Task] F3: implement filter-scoped bulk selection and tri-state parent checkboxes #19aria-checkedwork.f3-process-tree-verification.md. QA confirmed the date independently (2026-10-29).ProcessTree.tsx:249-259), for stable names and counts. D3 discourages a separate long-lived store. Here the state is bounded by the UID-keyedWorkspaceand verified cleared on sign-out and account change, so this is not a leak. Note it for [Task] F3: add reactive AND-tokenized process search with cancellation #17/[Task] F3: implement filter-scoped bulk selection and tri-state parent checkboxes #19, so cache eviction does not diverge from the rendered data.localStoragekeys only.sessionStorage/IndexedDB are not checked in the browser, although the code has no storage access and the component test checkssessionStorage.Next action
PASS goes to the coordinator and maintainer review/merge of PR #50. I recommend Engineering address F-1 (and optionally F-2) before merge or in a linked Bug issue, with QA re-checking any fix SHA. QA has not closed the issue.
fix: stop the tree reclaiming focus after blur and track focused rows…
DavidVFitzGerald commentedon Nov 14, 2026
Engineering: QA findings addressed — READY FOR QA re-check at
dbc5ff0(PR #50).onBlurwith no next target clears the focus flag when the blurred row is still mounted (user left to a non-focusable area); unmounted focused rows (collapse/virtualization) still restore focus per D5. Regression test: blur during a 60 ms page load leaves focus on body.onFocusmakes the focused row active. Regression test: script focus on root, Enter expands it, not the previous active row.docs/engineering/f3-process-tree-verification.md.DavidVFitzGerald commentedon Nov 14, 2026
Hosted CI at
dbc5ff0: PRqualityPASS (https://github.com/DavidVFitzGerald/LCA-diff/actions/runs/43606493535); full-suite dispatch PASS (https://github.com/DavidVFitzGerald/LCA-diff/actions/runs/43606547785). QA re-check in progress.DavidVFitzGerald commentedon Nov 14, 2026
QA: PASS
QA re-check: PASS at SHA
dbc5ff087541340c56b48d4c56ad60e1006b2ed3(dbc5ff0, branchfeat/f3-process-tree, PR #50). Phase 1, mock mode only. This does not prove real authentication, authorization, data security or real search performance. Hosted CI fordbc5ff0is tracked by the coordinator and is not covered here.Environment. Fresh detached worktree
/tmp/lca-diff-qa16atdbc5ff0, rootless compose projectlca-diff-qa16(FRONTEND_PORT=5187). All tooling ran in the container. Nothing was installed on the host and no application code was changed. The temporary QA scratch tests were deleted,git statuswas clean, and the compose project (down -v) and the worktree were removed.Change reviewed (
git diff f8d5370 dbc5ff0):ProcessTree.tsxonFocus/onBlur(+21/-3), two new regression tests insrc/services/mock/process-tree.test.tsx, and the verification record. No dependency, service, contract or composition changes. Againstmain, the lockfile diff is still only@tanstack/react-virtual3.14.24 +@tanstack/virtual-core3.19.9.Gates (container)
./dev up,./dev checknpm ciformat:check,lint,typechecktest:unit(vitest run) repeatedsrc/auth/AuthDialog.test.tsx:248, unrelated to #16; see F-6buildtest:e2e --grep @smoketest:e2efullRe-verification of the findings
document.activeElement.blur(), wait for the "transport" rows. Focus stays on body; atf8d5370it was reclaimed.does not take focus back after the user leaves the tree to a non-focusable areapasses.nullrelatedTargetclears the flag only when, in a microtask, the blurred row is still connected and focus is outside the tree. When the focused row unmounts (exhausted continuation, error→row, collapse), the flag is kept, so D5 restoration still applies.document.activeElementon the row, so the flag is correctly kept in that case too.onFocusmakes the focused row active. Scratch test: focus "Alpha catalog 2026 v2" by script, press Enter, and v2 expands (v1 does not). v2 is then the onlytabindex=0. Engineering's regression test also passes.f3-process-tree-verification.mdrecords the publish date 2026-10-29, and the note that newer releases were under 14 days old. That matches QA's earliernpm viewcheck.moves focus to a collapsed ancestor and keeps focus out of the bodypasses.tabindex=0.Per-criterion verdicts
AC1–AC5 all PASS, as recorded in the first QA pass at
f8d5370. Nothing in this fix changes data loading, merging, paging, cancellation or the session-clearing paths, and the gates above confirm this. D1–D11 are still satisfied. The D9 limitation is unchanged: continuation, latency, failure and large-DOM evidence is component-level only.Remaining findings (non-blocking)
aria-posinset/aria-setsize. Revisit with [Task] F3: manage individual selection order and a virtualized selected-process list #18/[Task] F3: implement filter-scoped bulk selection and tri-state parent checkboxes #19.localStorageonly, notsessionStorage/IndexedDB.AuthDialog.test.tsx› "resets a known account, reports unknown ones and returns to sign-in" intermittently fails at:248(expect(back).toHaveFocus()) under the full parallel suite.dbc5ff0it failed once in 60 runs. It also reproduces onmain1f82774(failed on run 19 of a 40-run loop). The test renders the anonymous shell, where the tree is not mounted, andsrc/auth/**is untouched by this PR.for i in $(seq 1 40); do npx vitest run || break; doneinapps/frontend.docs/issue_templates/bug.yml. It is not filed by QA.Next action
PASS goes to the coordinator: record hosted CI for
dbc5ff0, then maintainer review and merge of PR #50. QA has not closed the issue.DavidVFitzGerald commentedon Nov 14, 2026
Coordinator: QA re-check PASS at
dbc5ff0(issuecomment-6879186783); hosted CI PASS atdbc5ff0(quality run 43606493535, full dispatch 43606547785). State: ready for review — PR #50 awaits maintainer merge. Follow-ups filed: #51 (pre-existing flaky AuthDialog focus test, F-6), #52 (pseudo-row ARIA positions F-3 and sessionStorage/IndexedDB browser check). F-5 is an observation; no action needed.feat: render the lazily paged release and nested process tree (Refs #16)
test: cover tree paging, keyboard, virtualization and cancellation (R…
docs: record #16 tree evidence and mark F2 complete (Refs #16)
fix: stop the tree reclaiming focus after blur and track focused rows…
DavidVFitzGerald commentedon Nov 14, 2026
Closed by coordinator: PR #50 merged by the maintainer after QA PASS (re-check at
dbc5ff0) and hosted CI PASS. Follow-ups: #51, #52.