Take a GitHub issue, or a one-line task, to a pull request that is ready for the maintainer's review - branch from main, build it with its tests, run the suite, review the diff, open the pull request with evidence, see CI pass, answer its review, and stop. Use when asked to work on, fix, build or implement something in this repo.
Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Work On An Issue?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/amahpour-work-on-an-issue)
---
name: work-on-an-issue
description: Take a GitHub issue, or a one-line task, to a pull request that is ready for the maintainer's review - branch from main, build it with its tests, run the suite, review the diff, open the pull request with evidence, see CI pass, answer its review, and stop. Use when asked to work on, fix, build or implement something in this repo.
argument-hint: "<issue number, or what to do>"
---
# Work on an issue
The rules are in [CLAUDE.md](../../../CLAUDE.md); this is the order of work. It ends at a pull request the maintainer can review, never a merge.
1. **Read it whole.** `gh issue view <n> --comments`: the body, every comment, what it links. Unclear and the maintainer is here: ask. Unclear and nobody is: the most conservative reading, listed under **Assumptions** at the top of the pull request.
2. **Branch.** `git fetch origin && git switch -c <type>/<name> origin/main`, where `<type>` is the title's Conventional Commits type (`fix`, `feat`, `docs`, `ci`, `test`, `refactor`, `chore`). In a shared checkout, a worktree: `git worktree add .worktrees/<name> -b <type>/<name> origin/main`.
3. **Build it, with its tests.** Write what each test checks and why before its body, then see it fail without the change: for a bug, the test first. Only this issue. Something else you find follows CLAUDE.md's step 3: an issue for an Important one, a line in the pull request for anything smaller. Commit as you go, files by name, never `--no-verify`.
4. **Run lint, security reports and the suite.** `uv run python scripts/lint.py` (or `--fix` while editing), `uv run python scripts/security_scan.py` (findings are report-only), then `uv run pytest -q -n auto`. Then what the change calls for:
| It touches | Also |
|---|---|
| `src/switchboard/web/static/` | `uv run pytest -m e2e tests/e2e`, and `uv run python docs/media/ui_shots.py --out <dir>` for the previews; for something a person does there (a click path, a dialog), a recording of it working too: the [`record-verification`](../record-verification/SKILL.md) skill |
| CLI output | `uv run python docs/media/cli_shots.py --out <dir>` for the previews |
| `deploy/` (the image's `deploy/image/Dockerfile`) | `uv run pytest -m image tests/image` (Docker) |
| `plugins/<harness>/`, `adapters/https.py`, hook replies, delivery to a harness | that harness's live test, `SWITCHBOARD_LIVE=<harness> uv run pytest -m live tests/live/test_live_<harness>.py -s -q`: it runs the real CLI against a throwaway broker, costs a few cents and needs the CLI logged in ([CONTRIBUTING.md](../../../CONTRIBUTING.md)); put its `LIVE RESULTS` in the pull request |
| timing, processes or sockets in a test | that test 20 times alone: `for i in $(seq 20); do uv run pytest -q -p no:cacheprovider <test> \|\| break; done` |
On a machine other agents share, one suite at a time: take the lock and cap the workers before any of these ([CONTRIBUTING.md](../../../CONTRIBUTING.md), "Sharing a machine"). Several `-n auto` runs at once can freeze the machine.
A test that fails under `-n auto` and passes alone is flaky, and a flaky test is a bug whoever's change it is: find the cause and fix it, in a pull request of its own if this change didn't cause it. Never re-run it until it passes.
5. **Read the diff as a reviewer** (`git diff origin/main...HEAD`), for the things tests don't catch: a value from outside with no length limit; an `else` that defaults to the permissive case; a blocking call inside `async def`; a secret in a log, an error or a URL; a test that would pass without the change, or whose setup quietly drops what it checks; a sleep standing in for an event; a home path, a host name or a person's name. For what a person sees: the phone preview, a walk by keyboard (where the focus goes when a click hides what had it), and every user-facing line checked against what the code does (a count, who a feature reaches). And the issue: every "Done when" met, or the pull request says which one isn't and why. Fix what you find and nothing around it.
6. **Check the docs, every time.** Search them for every name, command, setting, message and behavior the change touches: `git grep -n <name> -- '*.md'`. Fix each place that's now wrong or missing: the README, `docs/USAGE.md` and the feature's guide in `docs/guide/` for what people see (a new feature gets a guide, with its pictures, added to `zensical.toml`'s nav), DESIGN.md for the design, `docs/ARCHITECTURE.md` when a part, the path of a message or a rule moves, SECURITY.md when the threat model moves, CONTRIBUTING.md, CLAUDE.md and this skill for how work is done. `changes/<name>.md` for anything a user would notice (never CHANGELOG.md). Then build the site the way CI does, `uv run --group docs zensical build --strict`, and fix every warning: a link from `docs/` to a file outside it is an absolute GitHub URL. Each merge publishes the site, so this is what keeps it current. The pull request's Docs section says what you searched and what changed; "checked, nothing to change" is an answer, an empty section isn't.
7. **Open the pull request.** `git push -u origin <branch>`, then `gh pr create` with the title and [the template](../../../.github/pull_request_template.md) filled in: what it does, the previews (still pictures only, pushed to `design-assets` under `pr-<number>/`, or a branch of your fork, and linked by commit SHA; never a video or a GIF, on any branch), the change working as a command and its output, a picture or a recording, the docs, `Closes #<n>`. The number comes with the pull request, so push the previews after opening it and edit the description.
8. **Watch CI.** `gh pr checks <pr> --watch`. On red: `gh run view <run> --log-failed`, fix with a new commit, push, watch again. A test that fails sometimes is never waved through, even one the diff can't have touched: fix it (step 4). Re-run (`gh run rerun <run> --failed`) only to unblock this pull request while that fix is open, and say so.
9. **Answer the review.** Each finding has a level (the root `REVIEW.md`, "Levels"). Fix the Important ones. For each, look for the same problem everywhere the change reaches, not only the line named, and list every place you checked in the proof, so one pass can confirm it. Fix a Nit if that is cheap; otherwise contest its card with the reason before you concede it (a contest works only on a raised card; for one you have already conceded, say so in the room). List a Pre-existing one in the pull request, and contest its card the same way, saying where. The raiser drops or defers what it accepts, and confirms a sound fix: only the raiser or a person can. A fix that needs a new mechanism (a lock, a migration, a file format, a new state) stops here: say so, and ask the maintainer, because the design is moving and a review round is the wrong place to build it. After two rounds only Important findings stay open (after one, for a pull request of only tests or tooling).
10. **Stop.** Report the link, what it does in two sentences, the evidence, and any assumption. Don't merge. After the maintainer merges: `git worktree remove .worktrees/<name>` if there was one, and `git branch -d <branch>`.