Skip to content

feat(sessions): flat search results with optional subsessions - #698

Merged
pascalandr merged 1 commit into
NeuralNomadsAI:devfrom
pascalandr:fix/flat-session-search
Sep 17, 2026
Merged

pascalandr merged 1 commit into
NeuralNomadsAI:devfrom
pascalandr:fix/flat-session-search

Conversation

@pascalandr

Copy link
Copy Markdown
Contributor

Summary

Follow-up to merged #649. Search/filter mode now displays independent, flat session results. A localized Show subsessions switch (off by default) includes matching children without requiring their parents. Each result uses its own native worktree, activity timestamp, name, badge and selection identity. Closing search restores normal hierarchy.

Native search results no longer hydrate ancestors just to render a child. Request-authority/deletion fences remain covered, and unqueried flat filters exhaust normal pagination. This supersedes the temporary root-only filter adjustment published on the former PR branch after #649 merged.

Validation

  • UI typecheck and production build passed.
  • 14 session-tree and 65 request-authority cases passed.
  • Real Solid/browser regression passed: toggle, activity/name/worktree sorts, combined text/directory filters, child badges, bulk selection, navigation, missing parents, and hierarchy restoration.
  • Rebuilt UI loaded in installed Windows Tauri: an existing child in D:\CodeNomad appeared alone under Workspace while its parent remained in pr649-final. Disabling subsessions or selecting the parent checkout hid it; closing search restored hierarchy and kept the current conversation active. No native locations changed.
  • One 30-second desktop search wait expired; the repeat completed within the extended 90-second bound. Search still traverses the local worktree catalogue; no latency guarantee is claimed.
  • Follow-up commit tree exactly matches the tested tree on the original worktree branch; it is based directly on the feat(v2): manage session families across worktrees #649 squash merge in dev.

Maintenance note

Existing touched oversized files: session-list.tsx (~1022 lines), session-api.ts (~1732), session-state.ts (~1307), session-request-authority.test.ts (~2016). No size-only refactor included.

Replace hierarchical search and worktree filtering with flat per-session results. Add a localized Show subsessions switch, disabled by default, so a matching child can appear without an unrelated parent. Each result keeps its own native directory, activity timestamp, worktree badge and selection identity; closing search restores normal browsing hierarchy.

Consume native search result identities directly instead of hydrating ancestors just to render a child. Preserve request-authority and deletion fences, and exhaust normal pagination for unqueried flat filters. This supersedes the root-only filter adjustment from 3921ba0.

Validated UI typecheck/build, 14 session-tree cases, 65 request-authority cases and a real-component browser regression covering toggle, sorts, combined filters, badges, selection and missing parents. Installed-renderer verification used an existing cross-worktree child and confirmed flat results plus hierarchy restoration without moving sessions. Documented the desktop search wait and retained large-catalogue latency limitation.
@pascalandr
pascalandr merged commit 6309a73 into NeuralNomadsAI:dev Sep 17, 2026
23 checks passed
@github-actions

Copy link
Copy Markdown

PR builds are available as GitHub Actions artifacts:

https://github.com/NeuralNomadsAI/CodeNomad/actions/runs/35278869167

Artifacts expire in 7 days.
Artifacts:

  • pr-698-d1f2aeaa4476b82a308c8c86cd7899e93976912f-electron-windows
  • pr-698-d1f2aeaa4476b82a308c8c86cd7899e93976912f-electron-linux
  • pr-698-d1f2aeaa4476b82a308c8c86cd7899e93976912f-tauri-linux
  • pr-698-d1f2aeaa4476b82a308c8c86cd7899e93976912f-tauri-macos
  • pr-698-d1f2aeaa4476b82a308c8c86cd7899e93976912f-tauri-windows
  • pr-698-d1f2aeaa4476b82a308c8c86cd7899e93976912f-electron-macos
  • pr-698-d1f2aeaa4476b82a308c8c86cd7899e93976912f-tauri-macos-arm64
  • session-pruning-plugin-ubuntu-latest
  • session-pruning-plugin-windows-latest
  • session-pruning-plugin-macos-latest

pascalandr added a commit that referenced this pull request Sep 17, 2026
## Summary
Small follow-up to #698: add **Show main sessions** immediately before
**Show subsessions**, enabled by default. The two independent controls
support main-only, subsession-only, combined and empty results. Controls
wrap at narrow widths and labels are translated in all ten locales.
Normal browsing retains its hierarchy.

## Validation
- UI typecheck passed.
- 14 session-tree cases passed.
- Existing real-component browser regression extended and passed:
defaults, control order, all four combinations, existing
filters/sorts/selection and restoring hierarchy with main results
disabled.
- git diff --check passed.

Maintenance note: existing packages/ui/src/components/session-list.tsx
is approximately 1040 lines; no size-only refactor included.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant