fix(claude): plumb track_progress so workflows stop clobbering each other's PR comment - #64
Conversation
…ther's PR comment anthropics/claude-code-action keys its sticky/progress comment on "authored by the Claude app bot" with no per-workflow marker (create-initial.ts matches user.id === 209825114 or any bot login containing "claude" and takes the first hit). Two Anthropic-path workflows on the same PR therefore share one comment and the later run overwrites the earlier one's content — dotCMS/core#36761, where the rollback-safety verdict replaced the AI code review in place. track_progress was hardcoded "true" in the executor, so consumers had no way to opt a secondary workflow out of the progress comment. Expose it on the executor and the orchestrator (default true, unchanged behaviour) so workflows that report through their own marker comment or a label can pass false and leave the sticky comment to its single owner. The bedrock-generic/harness/codex paths already namespace their markers via sticky_namespace and are unaffected. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G7gd5sQ41A3k4bFeNVnUkR
🤖 Bedrock Review —
|
The track_progress input is a mitigation, not a fix: the action's comment lookup is still hardcoded to "authored by the Claude app bot" and nothing in this repo enforces that only one workflow per PR opts in. Write the convention down where consumers will see it. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01G7gd5sQ41A3k4bFeNVnUkR
|
Acknowledging the review — the findings are factually correct and intentional, so recording the reasoning rather than changing the approach. Correct: the action's comment lookup is unchanged and not configurable. One correction: this is not a race condition. Any second Anthropic-path workflow with On enforcement: nothing here can enforce mutual exclusion — the state lives in the PR's comment list, not in this repo. Checked the blast radius: of the 10 consumer repos on Documented the limitation and the one-owner convention in the README ( |
sfreudenthaler
left a comment
There was a problem hiding this comment.
looks good. I see the review feedback but it's a known limitation at this point. only the code reviewer uses the default comment and it just updates that it's working. then when done it posts it's own comment
🤖 Bedrock Review —
|
Problem
anthropics/claude-code-action@v1finds the comment to (re)use with no per-workflow marker —src/github/operations/comments/create-initial.ts:Any comment authored by the Claude app bot matches. So two Anthropic-path workflows on the same PR share one comment, and the later run resets it to "Claude Code is working…" and writes over the earlier result.
Observed in dotCMS/core (#36761, PR #36759) — one comment, eight edits, two different workflows:
track_progresswas hardcoded"true"inclaude-executor.yml, so consumers had no way to opt a secondary workflow out of the progress comment.Change
track_progressinput onclaude-executor.ymlandclaude-orchestrator.yml, defaulttrue— no behaviour change for existing consumers. Workflows that report through their own marker comment or a label passfalseand leave the sticky comment to its single owner.The bedrock-generic / harness / codex paths already namespace their markers via
sticky_namespaceand are untouched.Follow-up
v3.xrelease +v3tag move before the core-side fix (Claude AI workflows overwrite each other's PR comments (rollback-safety clobbers the code review) core#36761) can referencetrack_progress.claude-code-action; worth an issue there.