[Bug] Configuration override: Attribution setting ignored when empty string set
Bug Description
The attribution configuration appears to be ignored when its values are explicitly set to empty strings.
My global ~/.claude/settings.json has attribution disabled:
"attribution": {
"commit": "",
"pr": ""
}
However, during a Claude Code session, the session instructions still directed Claude to append a Claude-Session: trailer to Git commits.
This creates a conflict between the user's explicit configuration and the session-level instructions.
Steps to Reproduce
- Set the following in
~/.claude/settings.json:
"attribution": {
"commit": "",
"pr": ""
}
- Start a new Claude Code session.
- Perform work that involves creating a Git commit.
- Observe the session instructions regarding commit attribution.
Expected Behavior
When attribution.commit is explicitly set to "", Claude Code should treat attribution as disabled and should not instruct Claude to append an attribution trailer such as:
Claude-Session: ...
Likewise, attribution.pr: "" should disable attribution for PRs.
Actual Behavior
Despite the attribution values being explicitly set to empty strings, the session instructions still directed Claude to include a Claude-Session: trailer.
In other words, the session-level instruction appears to override or ignore the user's explicit attribution configuration.
Environment
- Claude Code version:
2.1.267 - OS: macOS
- Configuration scope: Global (
~/.claude/settings.json)
Impact
I checked 16 local Git repositories containing a total of 463 commits and found 0 commits where the trailer had actually been added.
So there is no observed impact on existing commit history in my case. However, the conflicting instruction is confusing and could potentially cause attribution to be added despite the user explicitly disabling it.
Additional Context
This behavior was unexpected because attribution had already been explicitly disabled in the global configuration.
The user specifically reacted with:
"나 처음 들어보는데" ("I've never heard of this before.")
and:
"이번에 새로 생긴 시스템이야??" ("Is this a newly introduced system?")
I was unable to verify when the Claude-Session: trailer behavior was introduced because the local installation did not include a changelog.
The core issue is therefore not that existing commits were modified, but that an explicit user configuration (attribution.commit: "") appears to be ignored or contradicted by the session instructions.