Skip to content

fix: use defaultUser fallback for CapabilityCache invalidation on stdio logout#454

Merged
teemow merged 1 commit intomainfrom
fix/capability-cache-stdio-logout
Mar 12, 2026
Merged

fix: use defaultUser fallback for CapabilityCache invalidation on stdio logout#454
teemow merged 1 commit intomainfrom
fix/capability-cache-stdio-logout

Conversation

@teemow
Copy link
Member

@teemow teemow commented Mar 12, 2026

Summary

  • Fix stale CapabilityCache entries surviving logout in stdio transport mode

Approach

handleAuthLogout skipped cache invalidation when the OAuth subject was empty (stdio transport), but session_connection_helper populated the cache under the "default-user" key. This left stale tools visible after logout in stdio mode.

Mirrors the defaultUser fallback already used at cache population time so that stdio sessions are correctly evicted on logout. The HTTP logout paths (DELETE /user-tokens, DELETE /auth/{server}) are not affected because they 401 early when subject is empty.

Relates to #452

Test plan

  • All aggregator unit tests pass
  • oauth-sso-reconnect-after-relogin integration test passes
  • CI checks

🤖 Generated with Claude Code

…io logout

handleAuthLogout skipped cache invalidation when the OAuth subject was
empty (stdio transport), but session_connection_helper populated the
cache under the "default-user" key. This left stale tools visible after
logout in stdio mode.

Mirror the defaultUser fallback already used at cache population time
so that stdio sessions are correctly evicted on logout.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@teemow teemow requested a review from a team as a code owner March 12, 2026 13:18
@teemow teemow merged commit 39975de into main Mar 12, 2026
7 of 8 checks passed
@teemow teemow deleted the fix/capability-cache-stdio-logout branch March 12, 2026 13:27
@teemow teemow restored the fix/capability-cache-stdio-logout branch March 12, 2026 13:27
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