Skip to content

fix(inbox): track inbox session cutoff per server - #1983

Merged
Brendonovich merged 1 commit into
devfrom
fix/inbox-per-server-cutoff
Dec 1, 2026
Merged

Brendonovich merged 1 commit into
devfrom
fix/inbox-per-server-cutoff

Conversation

@opencode-agent

@opencode-agent opencode-agent Bot commented Dec 1, 2026

Copy link
Copy Markdown
Contributor

Summary

Ports anomalyco/opencode#67442 (5225062b7c) to OpenCode (Rune):

  • Persist per-server inbox cutoffs (serverCutoffs) in sidebar.inbox (features/restore/src/state.rs, lib.rs, persist.rs), keyed by ServerScope — wire-compatible with OpenCode Desktop.
  • Reconcile cutoffs in apps/desktop/src/session/inbox/cutoff.rs once restore hydrates:
    • Already-connected servers on first init start at 0 (no cutoff), so existing inbox items stay put on upgrade.
    • Newly added servers start at now_ms, hiding their older settled and archived sessions while still letting currently working, needs-attention, pinned, and opened sessions through (along with anything created/updated/archived at or after the cutoff).
  • Include inbox_server_cutoffs in inbox_order_key (apps/desktop/src/session/inbox/order.rs) and restore_stamp (features/restore/src/persist.rs) so cutoff changes immediately refresh the inbox and persist.

Verification

  • bun scripts/guardrails/run.mjs: 11/11 passed (including arch-check and 800-line ceiling).
  • cargo check -p opencode-feature-restore -p opencode-desktop: 0 errors.
  • cargo clippy -p opencode-feature-restore -p opencode-desktop --no-deps: 0 warnings in touched files.

Requested by: @Brendonovich (Brendan via Slack)

@Brendonovich
Brendonovich merged commit 92090b8 into dev Dec 1, 2026
8 checks passed
@Brendonovich
Brendonovich deleted the fix/inbox-per-server-cutoff branch December 1, 2026 09:20
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