Commit Graph
2 Commits
Author SHA1 Message Date
Cory Snider 97576abe7b .github: reject agent emails resolved to accounts
check-agent-coauthors only applied its agent email list to co-authors
GitHub could not resolve to an account. GitHub resolves
noreply@anthropic.com to Anthropic's "claude" user, which is not in
agentLogins, so the check treated Claude Code's default
"Co-Authored-By: Claude ... <noreply@anthropic.com>" trailer as a
human co-author and passed it.

Add "claude" to agentLogins, which also covers the account's other
addresses, such as its users.noreply.github.com address.

Check the address before the account too. The listed addresses belong
to agent vendors, so a match identifies an agent whichever account
GitHub resolves it to. The name heuristics stay limited to unresolved
co-authors, where a human with a matching name has no account to
distinguish them.

Assisted-By: Claude Opus 5.5
Signed-off-by: Cory Snider <csnider@mirantis.com>
2026-10-09 19:03:54 -04:00
Paweł Gronowski 8e242c97bc .github/workflows: Reject AI agent co-authors in PR commits
Contributors remain responsible for AI-assisted work. Agent credit
belongs in the PR body or an Assisted-By trailer, not Co-Authored-By.

Use the GitHub GraphQL API's Commit.authors list to check co-authors
as GitHub recognizes them, excluding the primary author. Reject known
agent accounts and use name and email heuristics only for co-authors
without a linked account.

Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
2026-09-16 20:20:31 +02:00