permissions.deny Overwritten Entirely Claude Code
Quick fix
Upgrade to cc-switch v4.0.0 or later; when switching providers, other settings.json content is preserved as is.
Symptom
Section titled “Symptom”通用配置的数组整体替换了原数组,"WebSearch" 被静默丢弃,且取消勾选后不会还原:The common configuration array replaces the entire original array, `"WebSearch"` is silently dropped, and it is not restored after unchecking:
In cc-switch 3.19.1, the “Apply common configuration” mechanism recursively merged objects but replaced arrays entirely when merging configuration, so `permissions.deny` in the common configuration overwrote the provider’s existing array. The maintainer stated that this merge mechanism was removed starting with v4.0.0; when switching providers, only key fields such as the address, credentials, and model are replaced, while other content in `settings.json`, including `permissions.deny`, is preserved as is.
Upgrade to cc-switch v4.0.0 or a later version. The maintainer said the “Apply common configuration” merge mechanism was removed starting with this version.
To share global settings, edit the configuration shown at the bottom of the provider editor; this content is written directly to `settings.json`.
Affected Versions
Section titled “Affected Versions”Source Issues
Section titled “Source Issues”This page is distilled from 1 real issues
(No FAQ yet)
Related problems
Section titled “Related problems”This is an unofficial community wiki with no affiliation to the cc-switch authors or the project itself. Its content is compiled from the project's public GitHub issues. This site distributes no software.