Skip to content

ui: list only human-started sessions by default - #132

Merged
hbrooks merged 1 commit into
mainfrom
default-manual-session-sources
Aug 24, 2026
Merged

ui: list only human-started sessions by default#132
hbrooks merged 1 commit into
mainfrom
default-manual-session-sources

Conversation

@hbrooks

@hbrooks hbrooks commented Aug 24, 2026

Copy link
Copy Markdown
Member

Summary

  • Startup session list defaults to manual, cli, mention sources; react and cron no longer appear.
  • An explicit "sources": [] in ~/.ellipsis/config.json still means every source.
  • The picker header omits the source clause when it matches the default.

Test plan

  • npm run typecheck
  • npx vitest run
  • Open the CLI in a repo with recent automatic PR reviews and confirm they are absent from the list

Important

Session bar defaults to human-started sources only, hiding automated session sources.

  • The session list now shows only manual, cli, and mention sources by default; react and cron automated sessions no longer appear.
  • An explicit "sources": [] in ~/.ellipsis/config.json restores all sources including automated ones.
  • The filter label in the picker header omits the source clause when it matches the default, reducing visual clutter.

This description was created by Ellipsis for 2dfd5ab. It will automatically update as commits are pushed.

The startup session list showed every source, so automatic PR reviews and
cron runs buried the sessions you were actually working in. Default to
manual/cli/mention; an explicit empty list in config still asks for all.
@hbrooks
hbrooks merged commit 3a5fbdd into main Aug 24, 2026
1 check passed
@hbrooks
hbrooks deleted the default-manual-session-sources branch August 24, 2026 00:01

@ellipsis-dev ellipsis-dev Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Caution

Changes requested ❌ — 3 issues

Reviewed 2dfd5ab in 5 minutes, 14 seconds.
  • Reviewed 1 commit with 77 lines of code in 3 files
  • Ran 1 review agent producing 3 comments where 3 were posted
  • This pipeline runs no gatekeeper, so findings are posted as written.
  • View full details on ellipsis.dev

This review was created by Ellipsis. You can tag @ellipsis in this pull request.

Comment thread src/lib/config.ts
repo: 'cwd',
statuses: 'all',
sources: undefined,
sources: ['manual', 'cli', 'mention'],

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new default silently drops api sessions too, not just react/cron; add api to the list.

SESSION_SOURCES (config.ts:251) has six values and the default keeps three, so api is filtered out as well — neither the comment at 237-238 nor the PR description mentions it. The CLI is documented to run against an ELLIPSIS_API_TOKEN credential (config.ts:288, and test/sessions.test.ts:246 covers the API-key path), and the server derives a session's source from the credential (constants.ts:17), so sessions this CLI starts under an API key come back as api. With this default the poll (SessionsApp.tsx:164) sends source=manual,cli,mention and never returns them — a user authenticated by env token sees an empty session list containing none of their own sessions.

Suggested change
sources: ['manual', 'cli', 'mention'],
sources: ['manual', 'cli', 'mention', 'api'],

Comment thread src/lib/config.ts
Comment on lines 260 to +262
const sources = Array.isArray(raw.sources)
? raw.sources.filter((s) => SESSION_SOURCES.includes(s))
: undefined
: null

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A sources list whose entries are all unknown still resolves to "every source", so a typo now widens the list instead of narrowing it — fall back to the default instead.

With {"sessionBar": {"sources": ["mannual"]}} the filter at 261 yields [], line 277 maps that to undefined, and sessionBarQuery omits the source filter — the user asked for one source and gets react and cron as well. Before this change undefined and "key absent" were the same thing, so the typo was harmless; now it is the widest possible setting. (test/config.test.ts:259 pins the old behavior and would need updating.)

Suggested change
const sources = Array.isArray(raw.sources)
? raw.sources.filter((s) => SESSION_SOURCES.includes(s))
: undefined
: null
const known = Array.isArray(raw.sources)
? raw.sources.filter((s) => SESSION_SOURCES.includes(s))
: null
// An all-unknown list is a typo, not the [] "every source" escape hatch.
const sources =
known && known.length === 0 && Array.isArray(raw.sources) && raw.sources.length > 0
? null
: known

Comment thread src/lib/config.ts
Comment on lines +47 to +49
// Only sessions started these ways, e.g. ["cli", "manual"]. An empty list
// means every source. Laptop sessions never appear whatever this says: there
// is nothing in the cloud to open.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

README's sessionBar docs now contradict this behavior and need the same edit.

README:188-190 says sources "lists only sessions started those ways ...; leave it out for all of them", and README:192 says the sample block's values "are what you get with no sessionBar at all". After this change omitting the key hides react/cron and [] is the only way to get them back — nothing in the README mentions either, and sessionBarFilterLabel (the one place that would have explained it in the UI) has no callers, so a user whose automated sessions vanished has no documented path back.

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