Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions apps/server/src/provider/Layers/ClaudeAdapter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2576,6 +2576,7 @@ function makeClaudeAdapter(options?: ClaudeAdapterLiveOptions) {
includePartialMessages: true,
canUseTool,
env: process.env,
settingSources: ["user", "project"],
Copy link

Copilot AI Mar 22, 2026

Choose a reason for hiding this comment

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

settingSources changes the Claude SDK session behavior, but there’s no test assertion that createQuery receives the expected sources. Please add/extend a unit test (e.g. in ClaudeAdapter.test.ts) to verify createInput.options.settingSources is set, so regressions don’t silently disable Skills/Commands/CLAUDE.md again.

Copilot uses AI. Check for mistakes.
Copy link

Copilot AI Mar 22, 2026

Choose a reason for hiding this comment

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

Hard-coding settingSources: ["user", "project"] means the server process will load host-level ~/.claude/* settings and project .claude/* files for every session. In web mode (where the server can bind to non-loopback), this can unintentionally apply/possibly expose host-specific CLAUDE.md memory, Skills, or slash commands to any authenticated client. Consider making settingSources configurable (e.g. via providerOptions.claudeAgent) and/or defaulting to a safer value (like only "project", or only enabling "user" in desktop mode).

Copilot uses AI. Check for mistakes.
...(input.cwd ? { additionalDirectories: [input.cwd] } : {}),
};

Expand Down
Loading