[BUG] Claude Code intermittenly fails to include Co-Authored-By in git commit messages

Open 💬 3 comments Opened May 11, 2026 by marcindulak

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

The commit messages often lack the expected Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> attribution. This behaved erratically as early as in Jnauary 2026, or maybe eariler, but recently the attribution appears to be lacking more often.

What Should Happen?

All commit messages include the attribution.

Error Messages/Logs

No errors printed in the CLI.

Steps to Reproduce

See https://github.com/marcindulak/learning-api-styles-gen-ai-experiments/pull/45/commits.

All commits, except the earliest three and the lastest commit should have the defailt Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com> attribution added, but this is not the case.

This is the .claude/CLAUDE.md file used, and here is the prompt.

Here are the full project level .claude/settings.json

{
  "autoMemoryEnabled": false,
  "env": {
    "CLAUDE_BASH_MAINTAIN_PROJECT_WORKING_DIR": "1",
    "CLAUDE_CODE_DISABLE_AUTO_MEMORY": "1",
    "CLAUDE_CODE_DISABLE_FEEDBACK_SURVEY": "1",
    "CLAUDE_CODE_HIDE_ACCOUNT_INFO": 1,
    "DISABLE_AUTOUPDATER": "1",
    "DISABLE_ERROR_REPORTING": "1",
    "DISABLE_TELEMETRY": "1",
    "IS_DEMO": "1",
    "PIP_CACHE_DIR": ".cache/pip",
    "XDG_CACHE_HOME": ".cache",
    "npm_config_cache": ".cache/npm"
  },
  "model": "opus",
  "permissions": {
    "allow": [
      "Bash(behave *)",
      "Bash(cat *)",
      "Bash(docker *)",
      "Bash(find *)",
      "Bash(grep *)",
      "Bash(ls *)",
      "Bash(sort *)",
      "Bash(wc *)"
    ],
    "ask": [],
    "defaultMode": "default",
    "deny": [
      "Bash(git config *)",
      "Bash(git push *)",
      "Bash(sudo *)",
      "Edit(**/.gitconfig)",
      "Read(./.azure/**)",
      "Read(./.env)",
      "Read(./.terraform/**)",
      "Read(~/.aws/**)",
      "Read(~/.azure/**)",
      "Read(~/.config/gcloud/**)",
      "Read(~/.ssh/**)",
      "Read(~/.terraform.d/**)",
      "Write(**/.gitconfig)"
    ]
  },
  "sandbox": {
    "allowUnsandboxedCommands": false,
    "autoAllowBashIfSandboxed": true,
    "enabled": true,
    "network": {
      "allowAllUnixSockets": true,
      "allowLocalBinding": true
    }
  }
}

and here the user ~/.claude/settings.json

{
  "autoUpdatesChannel": "stable"
}

Claude Model

Opus

Is this a regression?

No, this never worked

Last Working Version

_No response_

Claude Code Version

2.1.126 (Claude Code)

Platform

Anthropic API

Operating System

Other Linux

Terminal/Shell

Other

Additional Information

See the screenshot below of the example commits that lack attribution.

<img width="1226" height="806" alt="Image" src="https://github.com/user-attachments/assets/4e68a2ae-b28c-48d0-9f6c-82ba90a375ec" />

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗