Skip to content

fix: union disabled_tools in mergeConfigs() like other disabled_* arrays#2559

Merged
acamq merged 1 commit intocode-yeongyu:devfrom
MoerAI:fix/issue-2555-disabled-tools-merge
Mar 15, 2026
Merged

fix: union disabled_tools in mergeConfigs() like other disabled_* arrays#2559
acamq merged 1 commit intocode-yeongyu:devfrom
MoerAI:fix/issue-2555-disabled-tools-merge

Conversation

@MoerAI
Copy link
Copy Markdown
Contributor

@MoerAI MoerAI commented Mar 13, 2026

Summary

  • disabled_tools was defined in OhMyOpenCodeConfigSchema (Zod) but omitted from mergeConfigs(), causing project-level config to shadow user-level disabled_tools instead of preserving both
  • Added Set union for disabled_tools following the exact same pattern as the other 5 disabled_* arrays
  • Added regression test verifying union and deduplication

Changes

  • src/plugin-config.ts: Add disabled_tools Set union in mergeConfigs() (5 lines, between disabled_skills and claude_code)
  • src/plugin-config.test.ts: Add test case for disabled_tools merge with overlap

Testing

  • bun test src/plugin-config.test.ts — 12/12 pass (was 11 before this change)
  • New test verifies base ["todowrite", "interactive_bash"] + override ["interactive_bash", "look_at"] → merged result ["todowrite", "interactive_bash", "look_at"] (3 items, no duplicates)

Closes #2555


Summary by cubic

Fix the merge of disabled_tools in mergeConfigs() so user and project configs are unioned and deduplicated, matching other disabled_* arrays; closes #2555. Adds a regression test for overlapping lists.

Written for commit 9a774f1. Summary will update on new commits.

disabled_tools was defined in the Zod schema but omitted from
mergeConfigs(), causing project-level config to shadow user-level
disabled_tools instead of merging both sets. Add Set union and
regression test.

Closes code-yeongyu#2555
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

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

No issues found across 2 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Auto-approved: The PR correctly fixes an inconsistency by applying the established Set-based union pattern to disabled_tools, supported by a new regression test.

@acamq
Copy link
Copy Markdown
Collaborator

acamq commented Mar 15, 2026

LGTM. Thank you!

@acamq acamq merged commit 8f9bdf0 into code-yeongyu:dev Mar 15, 2026
8 checks passed
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.

Merge disabled_tools across user and project config without dropping entries

2 participants