feat(memory): scope inbox list queries by channel - #65
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces channel-based filtering for background jobs, notifications, and clarification tickets to prevent cross-channel starvation and pollution. It updates the MemoryMessage enum, SQLite actor queries, and API endpoints to support an optional channel parameter, and adds a corresponding unit test. The reviewer feedback suggests that instead of passing None for the channel filter in the agent logic and terminal UI, these queries should be explicitly scoped to the active channel (using inbound.channel and config.channel_name respectively) to ensure proper isolation.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
5237e89 to
568b652
Compare
|
Good catch. The channel filter remains optional for host-specific inboxes (including ALTAI), but native terminal polling and same-chat background recovery now keep channel unset so cross-channel notifications and jobs remain visible. Verified with cargo test --all-targets and cargo check --all-targets. |
Summary
Why
Host integrations must not fetch a global fixed-size list and filter it after the fact. A busy terminal/API channel could otherwise make ALTAI’s inbox appear empty even when it has items.
Verification
cargo test channel_scoped_inbox_query_filters_before_limit --libcargo check --all-targets