Skip to content

Stop scanning ~/.claude/skills when CLAUDE_CONFIG_DIR moves it - #7076

Merged
ymichael merged 1 commit into
mainfrom
bb/3926-a-provider-s-declared-user-skill-root-is-sc-thr_d4khv4ivcc
Nov 6, 2026
Merged

ymichael merged 1 commit into
mainfrom
bb/3926-a-provider-s-declared-user-skill-root-is-sc-thr_d4khv4ivcc

Conversation

@ymichael

@ymichael ymichael commented Nov 5, 2026

Copy link
Copy Markdown
Collaborator

Human comments

What was wrong

provider-claude-code declared a static user skill root (.claude/skills under home) and also set experimental_resolvesNativeRoots, resolving its roots from CLAUDE_CONFIG_DIR. bb scans declared roots in addition to resolved ones, so with CLAUDE_CONFIG_DIR set the skill list included ~/.claude/skills as well as $CLAUDE_CONFIG_DIR/skills. Claude Code reads only the configured directory, so the listing offered skills the agent never loads (#3926).

What changed

  • plugins/provider-claude-code/src/native-roots.ts: removed the declared user skill root. resolveClaudeNativeRoots already returns <claudeDir>/skills, which is ~/.claude/skills by default and $CLAUDE_CONFIG_DIR/skills when set. The declared project roots are unchanged.
  • tests/integration/native-roots-golden: the fixture now treats the home skills (home-claude-skill, linked-home-skill) as present in the default variant and absent in the config-dir variant, and the claude-code.config-dir.json golden drops them.

This is the skills half of closed #6495. The health/usage, fork and config-directory.ts changes are out of scope; #3607 covers them. The change stays inside the plugin: no protocol bump, no SDK change.

How you verified

  • pnpm exec turbo run test --filter=bb-plugin-provider-claude-code: 29 files, 430 tests pass.
  • vitest run native-roots-golden in tests/integration: 22 tests pass, including the default and config-dir Claude Code variants. Without the native-roots change, the updated fixture fails because the home skills are reported under CLAUDE_CONFIG_DIR.
  • CI runs the full suites.

Fixes #3926

🤖 Generated with Claude Code

AGENT GENERATED

The Claude Code provider declared a static user skill root
(.claude/skills under home) while also resolving its own roots from
CLAUDE_CONFIG_DIR. bb scanned both, so with CLAUDE_CONFIG_DIR set the
skill list offered home skills the agent never loads. The resolver
already returns the configured skills root, so drop the declared user
root and make the config-dir golden expect the home skills absent.

Fixes #3926

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@ymichael
ymichael merged commit 5538a27 into main Nov 6, 2026
35 checks passed
@ymichael
ymichael deleted the bb/3926-a-provider-s-declared-user-skill-root-is-sc-thr_d4khv4ivcc branch November 6, 2026 04:45
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.

A provider's declared user skill root is scanned even when its resolver moved that root (CLAUDE_CONFIG_DIR)

1 participant