docs(commit): Add agent-specific Co-Authored-By attribution#72
Open
docs(commit): Add agent-specific Co-Authored-By attribution#72
Conversation
Replace the hardcoded Claude attribution in the AI-Generated Changes section with a mapping table that covers multiple agents (Claude Code, Cursor). The executing agent should infer the correct attribution from its own runtime context rather than always using Claude's. Co-Authored-By: Cursor <noreply@cursor.com>
| | Claude Code | `Co-Authored-By: Claude <noreply@anthropic.com>` | | ||
| | Cursor | `Co-Authored-By: Cursor <noreply@cursor.com>` | | ||
|
|
||
| Infer the correct agent from your own runtime context — do not ask the user which agent they are using. |
There was a problem hiding this comment.
Bug: The new agent attribution table is incomplete, missing entries for agents like Cline and GitHub Copilot which are documented as supported in the README.
Severity: HIGH
Suggested Fix
Either expand the table to include all officially supported agents mentioned in the README (like Cline and GitHub Copilot), or adopt a more flexible pattern that doesn't require a hardcoded list. For example, instruct the agent to use its own name and a placeholder email, similar to the pattern found in agents-md/SKILL.md.
Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.
Location: plugins/sentry-skills/skills/commit/SKILL.md#L93
Potential issue: The `commit` skill uses a hardcoded table for `Co-Authored-By`
attribution that only includes 'Claude Code' and 'Cursor'. However, the project's README
states support for additional agents like 'Cline' and 'GitHub Copilot'. When an agent
not listed in the table executes this skill, it cannot find its attribution string. The
skill's instructions explicitly forbid asking the user for this information, leaving the
agent with no way to generate the correct `Co-Authored-By` line. This will result in
incorrect or missing commit attribution for any supported agent not present in the
table.
Did we get this right? 👍 / 👎 to inform future reviews.
Member
|
there's something we do in agents.md that might be a better pattern to follow here vs the explicit mapping |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replace the hardcoded Claude attribution in the commit skill's
"AI-Generated Changes" section with a mapping table that supports
multiple agents (Claude Code, Cursor).
Previously, the skill always instructed agents to use
Co-Authored-By: Claude <noreply@anthropic.com>regardless of whichagent was executing the skill. This was incorrect when used from Cursor
or other non-Claude agents. The new table lets each agent infer the
correct attribution from its own runtime context.