Conversation
- action.yml: composite action that installs Claude Code, uv, clones the deepwork plugin, runs /review in CI mode, commits all changes, and posts inline PR review comments - prompts/review.txt: CI-mode prompt (no AskUserQuestion, make all changes, write /tmp/deepwork_changes.json) - scripts/post-review-comments.py: posts GitHub PR review with one inline comment per changed file; falls back to diff stats if Claude's change summary is absent; uses base branch for robust diff detection - scripts/merge-mcp-config.py: safely merges deepwork MCP server entry into an existing .mcp.json (or creates one), backed up and restored - .github/workflows/example.yml: ready-to-copy example workflow - README.md: full usage docs, inputs table, prerequisites - .gitignore: exclude __pycache__ Agent-Logs-Url: https://github.com/Unsupervisedcom/deepwork-action/sessions/012963c8-b297-4729-9b7b-26919e945901 Co-authored-by: nhorton <204146+nhorton@users.noreply.github.com>
Agent-Logs-Url: https://github.com/Unsupervisedcom/deepwork-action/sessions/012963c8-b297-4729-9b7b-26919e945901 Co-authored-by: nhorton <204146+nhorton@users.noreply.github.com>
- Upgrade setup-node from v4/node-20 to v6/node-24 - Add actions/cache step to persist .deepwork/tmp across runs on the same PR, using a run-id suffix so the cache is always updated and restore-keys picks up the latest prior entry for the same PR number Agent-Logs-Url: https://github.com/Unsupervisedcom/deepwork-action/sessions/1f9e2774-9151-4bc9-8826-569167d36ad3 Co-authored-by: nhorton <204146+nhorton@users.noreply.github.com>
Done in 654752c. Added an |
… MCP config hack
- Replace npm + sparse-clone + --plugin-dir approach with the official
anthropics/claude-code-base-action@beta, which installs Claude Code
via curl and handles plugin installation natively through its
plugin_marketplaces and plugins inputs
- Remove "Set up Node.js" step (no longer needed; base action manages it)
- Remove "Install Claude Code CLI" step (base action installs via curl)
- Remove "Clone deepwork Claude plugin" step; replaced by:
plugin_marketplaces: https://github.com/Unsupervisedcom/deepwork.git
plugins: deepwork@deepwork-plugins
- Remove "Prepare MCP config" and "Restore MCP config" steps (proper
plugin install handles MCP config automatically)
- Delete scripts/merge-mcp-config.py (no longer needed)
- Update README to reflect new architecture and mention caching
Agent-Logs-Url: https://github.com/Unsupervisedcom/deepwork-action/sessions/9b5cd224-5209-435a-b81f-b5a83cd55f8b
Co-authored-by: nhorton <204146+nhorton@users.noreply.github.com>
All review feedback addressed in bc66f07. Summary of changes:
|
README.md
Outdated
| - Claude Code is installed and run via the official [`anthropics/claude-code-base-action`](https://github.com/anthropics/claude-code-base-action). | ||
| - The action runs with `--dangerously-skip-permissions` in a sandboxed GitHub Actions runner. It has no access to secrets beyond what you explicitly provide. | ||
| - Auto-fix commits are signed with the `deepwork-action[bot]` identity. | ||
| - The `[skip ci]` suffix on the default commit message prevents the action from triggering itself recursively. |
There was a problem hiding this comment.
This seems not ideal. Triggering other CI actions from the changes would make sense, and this name is confusing.
Can we instead skip commits that are signed by the deepwork-action[bot]` identity?
There was a problem hiding this comment.
Done in f1a5126. Removed [skip ci] from the default commit_message. The example workflow (and the README usage snippet) now include if: github.actor != 'deepwork-action[bot]' at the job level, so the workflow simply never starts when the push was made by the bot identity — no magic commit message required.
…guard - Change default model to claude-opus-4-6 in action.yml, README, and example.yml - Remove [skip ci] from default commit_message; instead add `if: github.actor != 'deepwork-action[bot]'` guard to example workflow job so the action never re-triggers on its own commits - Add "THIS IS A MAJOR TOKEN COST SAVER!!!" to README caching section - Update README security section to describe the bot-identity approach Agent-Logs-Url: https://github.com/Unsupervisedcom/deepwork-action/sessions/799d7276-12e1-4540-9650-c480b0a44b83 Co-authored-by: nhorton <204146+nhorton@users.noreply.github.com>
All addressed in f1a5126:
|
.github/workflows/example.yml
Outdated
| pull_request: | ||
| types: [opened, synchronize, reopened] |
There was a problem hiding this comment.
I don't think this it the right thing to run on. Shouldn't this run on push and not opened and such?
There was a problem hiding this comment.
In GitHub Actions, pull_request + synchronize is the "run on push to a PR branch" event — using bare push would lose all the PR context (github.event.pull_request.number, base.ref, etc.) that the action needs for caching, checkout, and posting review comments.
Simplified the types to [opened, synchronize] (dropped reopened) in 1290b16 — synchronize fires on every push to the PR branch, and opened handles the initial PR creation.
…ronize Agent-Logs-Url: https://github.com/Unsupervisedcom/deepwork-action/sessions/bfca66ea-ca2d-447c-a7d7-f829f2ee6ad4 Co-authored-by: nhorton <204146+nhorton@users.noreply.github.com>
Capture the full investigation of the DeepWork plugin MCP server failing to start inside anthropics/claude-code-action@v1, including: - Symptom (plugin install reports success; mcp_servers init payload reports plugin:deepwork:deepwork status: failed; silent, no error message; same plugin works fine outside CI). - Why slash commands still work (/review is a skill file, no MCP needed) vs. what's missing (get_configured_reviews, mark_review_as_passed, start_workflow, DeepSchema validation, the workflow state machine). - Root-cause hypotheses ranked by probability: 1. 70% — PR file restoration wipes plugin MCP registration 2. 60% — No automatic plugin → session MCP merge path 3. 30% — MCP_TIMEOUT/MCP_TOOL_TIMEOUT empty env vars - Three open upstream issues that match our exact symptoms: - anthropics/claude-code-action#813 (silent MCP failures) - anthropics/claude-code-action#1004 (--mcp-config silently dropped) - anthropics/claude-code-action#95 (no plugin → session MCP merge path) - Definitive diagnostic experiment to confirm root cause #1. - Speculative fix logic for the .claude/settings.json file added in the rule-5 reversal commit (enables plugin at project scope; only effective for PRs opened after the file lands on main, because PR file restoration pulls from origin/main). - BLOCKING status: PR parked as draft until upstream fixes land. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Implements this repo as a working composite GitHub Action: runs Claude Code with the DeepWork plugin on a PR, applies all review-driven improvements autonomously, commits them back to the PR branch, and posts inline review comments explaining each change.
Action structure
action.yml— composite action; 7 steps covering plugin setup, review state caching, Claude run, commit/push, and comment postingprompts/review.txt— CI-mode prompt: invokes/review, suppressesAskUserQuestion, applies all findings (not just "obvious" ones), and writes a structured change manifest to/tmp/deepwork_changes.jsonscripts/post-review-comments.py— posts a single GitHub PR review with one inline comment per changed file; uses Claude's/tmp/deepwork_changes.jsonsummary for descriptions, falls back to diff statistics.github/workflows/example.yml— minimal caller workflow to copy; triggers onpull_requestwith types[opened, synchronize]Key design decisions
anthropics/claude-code-base-action@beta— Claude Code is installed and run via the official Anthropic-managed action, which uses the curl-based installer (https://claude.ai/install.sh) rather than npmclaude plugin marketplace add+claude plugin installthrough the base action'splugin_marketplaces/pluginsinputs, eliminating the need for sparse-cloning or manual MCP config manipulation--dangerously-skip-permissionsfor fully non-interactive CI executionorigin/<base>→<base>→HEAD~1fallback) for correctness on shallow clones.deepwork/tmpcached per PR viaactions/cache@v4so already-passed reviews are not re-run on subsequent pushes to the same PR; uses arun_id-suffixed save key with a PR-scopedrestore-keysprefix to always write a fresh entry while restoring the most recent prior state — THIS IS A MAJOR TOKEN COST SAVER!!!claude-opus-4-6for best review qualityif: github.actor != 'deepwork-action[bot]'at the job level instead of a[skip ci]commit message suffix, so auto-fix commits can still trigger other CI workflows while the DeepWork review job itself never re-runs on its own commits[opened, synchronize]— fires when a PR is first created and on every subsequent push to the PR branch (synchronize);reopenedis omitted as it is rarely neededUsage
Original prompt