Skip to content

fix(sessions): filter out child sessions from /sessions list#61

Merged
grinev merged 1 commit intogrinev:mainfrom
CODe5753:fix/sessions-filter-subsessions
Mar 28, 2026
Merged

fix(sessions): filter out child sessions from /sessions list#61
grinev merged 1 commit intogrinev:mainfrom
CODe5753:fix/sessions-filter-subsessions

Conversation

@CODe5753
Copy link
Copy Markdown
Contributor

Description of changes

The /sessions command returns every session from the API, including child sessions
spawned by tool calls (look_at, task, etc.). This clutters the list and makes it
hard to find actual user sessions.
Passes roots: true to session.list() so the server only returns root sessions.
This is the same approach the official OpenCode CLI and web app already use.
Relates to #1.

How it was tested

  • Confirmed roots: true is implemented server-side in OpenCode:
  • All existing tests updated and passing: npm run lint, npm run build, npm test (405/405)

Checklist

  • PR title follows Conventional Commits: <type>(<scope>)?: <description>
  • This PR contains one logically complete change
  • Branch is rebased on the latest main
  • I ran npm run lint, npm run build, and npm test
  • If this PR is OS-sensitive, behavior/limitations for Linux/macOS/Windows are described

@grinev
Copy link
Copy Markdown
Owner

grinev commented Mar 28, 2026

@CODe5753 thanks for cinrtibution!

@grinev grinev merged commit afacade into grinev:main Mar 28, 2026
1 check passed
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.

2 participants