Skip to content

Conversation

@alex-feel
Copy link
Owner

Profile-only servers (scope: profile) were not calling configure_mcp_server(), causing them to skip the removal logic that cleans up servers from user/local/project scopes before applying profile configuration.

This fix adds a call to configure_mcp_server() for profile-only servers, which triggers removal from all scopes while skipping the claude mcp add command (via early-return for scope == 'profile').

Added 5 comprehensive test methods to verify the fix and prevent regressions:

  • Profile-only servers trigger removal from all 3 scopes
  • Multi-scope servers work correctly with both removal and add
  • User-scope servers unchanged (regression test)
  • Multiple profile-only servers handled correctly
  • Comprehensive scope mix integration test

Profile-only servers (scope: profile) were not calling configure_mcp_server(), causing them to skip the removal logic that cleans up servers from user/local/project scopes before applying profile configuration.

This fix adds a call to configure_mcp_server() for profile-only servers, which triggers removal from all scopes while skipping the claude mcp add command (via early-return for scope == 'profile').

Added 5 comprehensive test methods to verify the fix and prevent regressions:
- Profile-only servers trigger removal from all 3 scopes
- Multi-scope servers work correctly with both removal and add
- User-scope servers unchanged (regression test)
- Multiple profile-only servers handled correctly
- Comprehensive scope mix integration test
@github-actions
Copy link

Coverage report

Click to see where and how coverage changed

FileStatementsMissingCoverageCoverage
(new stmts)
Lines missing
  scripts
  setup_environment.py
Project Total  

This report was generated by python-coverage-comment-action

@alex-feel alex-feel merged commit 37f1d7d into main Jan 22, 2026
12 checks passed
@alex-feel alex-feel deleted the alex-feel-dev branch January 22, 2026 19:07
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.

2 participants