[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M79JXN03EESASBAWTVA0XPY8":3,"skill-same:01M79JXN03EESASBAWTVA0XPY8":48},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":27,"repositoryHtmlUrl":28,"repositoryHomepageUrl":29,"ownerHtmlUrl":30,"ownerBlogUrl":31,"ownerDescription":32,"updatedAt":33,"install":34,"resources":47},"01M79JXN03EESASBAWTVA0XPY8","issue-handler",null,"Own a GitHub issue end-to-end in strike-cli — worktree, implement, test, PR, spawn review agents that comment on the PR, address feedback in a loop, CI, merge. Use when asked to handle\u002Ffix\u002Fclose an issue, ship a PR from an issue, or babysit issue work through merge to main.","jonathanung\u002Fstrike","jonathanung","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F53621118?v=4","01M79JX057ZT3VSF94GXQBDAXY","Jonathan Ung","01M79JX05QHGCWABW16WQN8DHV",5,"Apache-2.0","https:\u002F\u002Fgithub.com\u002Fjonathanung\u002Fstrike\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fissue-handler\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: issue-handler\ndescription: Own a GitHub issue end-to-end in strike-cli — worktree, implement, test, PR, spawn review agents that comment on the PR, address feedback in a loop, CI, merge. Use when asked to handle\u002Ffix\u002Fclose an issue, ship a PR from an issue, or babysit issue work through merge to main.\n---\n\n# Issue handler (strike-cli)\n\nOwn the issue end-to-end with due diligence on research, testing, and validation. Shipping is ownership: commit → push → PR → **review-agent loop** → CI green → merge → cleanup. All code edits happen inside a **git worktree**, never the primary checkout.\n\nFor agents developing strike. Authoring skills\u002Fdocs may use this pipeline; apply when the user frames work as an issue (or asks you to own issue→main).\n\n## Preconditions\n- `gh auth status` ok; git repo; network; issue number\u002FURL known.\n- **Stop-and-ask:** no write access; `gh` missing; issue already has an open PR you did not create (attach or ask — no duplicate). Dirty primary is fine for `git worktree add` from `origin\u002Fmain` — do not clean\u002Fstash primary WIP.\n\n## Workflow\n0. **Orient** — `gh issue view N` (+ comments). Read `AGENTS.md` + `docs\u002FARCHITECTURE.md` for boundaries. Note issue headers (`wave`\u002F`depends`\u002F`conflicts`\u002F`priority`) if present.\n1. **Research** — map issue→packages; read code + nearest tests. Optional local `.plan\u002Ffeatures.md` \u002F `FEATURES_STATUS.md` **if present** (never block if missing). State acceptance criteria bullets. Stop-and-ask if ambiguous.\n2. **Worktree** — create\u002Fenter; confirm `pwd` + branch before edits.\n3. **Plan** — smallest correct change; no drive-by refactors. Assign **risk tier A\u002FB\u002FC** (see Verification tiers).\n4. **Implement** — worktree only; load sibling skills when domain matches.\n5. **Test** — load `write-go-tests` when behavior changes.\n6. **Validate** — load `test-and-validate` for the **tier gate**; smoke when applicable.\n7. **Sync main** — if the PR will be open >~1h or `origin\u002Fmain` moved, `git fetch origin main && git merge origin\u002Fmain` then re-run tier gate before\u002Fat push.\n8. **Ship** — commit, push `origin\u002F\u003Cbranch>`, PR with `Fixes #N`.\n9. **Review loop** — tier-scaled (below); post findings; address; re-review until merge-ready.\n10. **Babysit CI** — fix branch-related failures; re-push; re-enter review loop after material code changes.\n11. **Merge** — only when merge gates pass (below).\n12. **Cleanup** — remove worktree after merge; leave cwd outside deleted tree.\n\n## Worktree setup\n```sh\nMAIN_ROOT=$(dirname \"$(git rev-parse --path-format=absolute --git-common-dir)\")\nWT_PARENT=\"$(dirname \"$MAIN_ROOT\")\u002Fstrike-cli-worktrees\"\nBRANCH=\"worktree-\u003Cslug>\"   # e.g. worktree-24-model-prefix; 2–4 kebab words; include issue # if helpful\nmkdir -p \"$WT_PARENT\"\ngit fetch origin main\n# Resume if yours; else create. Never delete others' worktrees.\nif [ -d \"$WT_PARENT\u002F$BRANCH\" ] && git worktree list | grep -q \"$WT_PARENT\u002F$BRANCH\"; then\n  # On $BRANCH and yours (clean or only your WIP): cd and continue.\n  # Stop-and-ask: foreign worktree, unexpected dirty state you don't own, or ambiguous collision.\n  cd \"$WT_PARENT\u002F$BRANCH\"\nelse\n  git worktree add -b \"$BRANCH\" \"$WT_PARENT\u002F$BRANCH\" origin\u002Fmain\n  cd \"$WT_PARENT\u002F$BRANCH\"\nfi\n```\nBefore every edit session:\n```sh\npwd   # must be $WT_PARENT\u002F$BRANCH\ngit rev-parse --abbrev-ref HEAD   # must be $BRANCH\n```\nRefuse Write\u002FEdit under primary checkout for issue implementation.\n\n## Verification tiers (local ship gate)\n\nSource of truth: root `AGENTS.md` *Verification tiers*. Summary:\n\n| Tier | When | Local gate |\n|---|---|---|\n| **A** | Docs\u002Fskills\u002Fmarkdown only | gofmt if any `.go`; no full test suite |\n| **B** | Normal code (default) | gofmt → TUI generate if `_src` → `web-check` if `web\u002F` → `make test && make vet && make build` |\n| **C** | tool \u002F permission \u002F auth \u002F session \u002F engine concurrency \u002F protocol wire \u002F sandbox | Tier B + `go test -race .\u002F... -count=1` + focused package tests |\n\nCI runs `go test -race .\u002F...` on every PR — do **not** always re-run full local race on A\u002FB.\n\n**Smoke:** load skill `smoke` when the diff touches `cmd\u002F`, `harness\u002Fengine`, TUI input\u002Fkeymap\u002Fapp, `session`, or `auth`.\n\n**Contract freeze:** default keybind or config-schema changes must update `docs\u002Fkeybinds.md` \u002F `docs\u002Fconfig.md` and call out migration in the PR body.\n\n**Flakes:** see `test-and-validate` flake policy — do not block unrelated merges on known env-only flakes; file `wave: 0` bugs.\n\nLoad `test-and-validate` for report format. Never weaken\u002Fdelete tests for green.\n\n## Commit and push\n```sh\ngit status && git diff && git log --oneline -10\ngit add \u003Cintended paths only>\ngit commit -m \"$(cat \u003C\u003C'EOF'\ntype(scope): concise summary\n\nFixes #\u003CN>\nEOF\n)\"\ngit push -u origin HEAD\n```\nConventional commits: `feat`\u002F`fix`\u002F`docs`\u002F`refactor`\u002F`test`\u002F`chore`. No secrets. No force-push main. No hook skips. Prefer new commits over amend\u002Fforce on shared PR branch.\n\n## Open PR\n```sh\ngh pr create --base main --head \"$BRANCH\" --title \"type(scope): summary\" --body \"$(cat \u003C\u003C'EOF'\n## Summary\n- …\n\n## Issue\nFixes #\u003CN>\n\n## Tier\nA | B | C\n\n## Verification\n- \u003Cexact commands from tier gate>\n- smoke: ran | skipped (reason)\nEOF\n)\"\n```\nFocused PR; no AI wall of text. If PR exists: `gh pr view`.\n\n## Review-agent loop (required for B\u002FC; optional for A)\n\nAfter the PR exists, **do not merge until the tier’s review bar is met**. You own dispatching reviewers, posting findings on the PR, fixing code, and repeating.\n\n### Pass budget (risk-scaled)\n\n| Tier | Review passes | Merge bar |\n|---|---|---|\n| **A** | 0–1 optional | Owner judgment; no blocking findings if a pass ran |\n| **B** | **1** clean pass on current HEAD | 0 **blocking**; should-fix fixed or explicitly deferred with reason on the PR |\n| **C** | **1–2** passes on current HEAD | 0 **blocking** and 0 **should-fix** |\n\nStall ceiling: **5** passes max — if still dirty, stop-and-ask (do not merge). Five is a cap, not a target.\n\n### When to run\n- Tier B\u002FC: once after first push + PR open (may run in parallel with CI).\n- Again after **any** push that changes production, test, skill, agent, workflow, or other merge-bound files — including review\u002FCI fixes.\n- Skip re-review only for pure changelog typos that cannot affect behavior or process — when unsure, re-review.\n- A clean review on an **older** SHA does **not** satisfy merge gates after a new push.\n\n### Resolve PR identity\n```sh\nPR=$(gh pr view --json number -q .number)\nHEAD_SHA=$(gh pr view --json headRefOid -q .headRefOid)\nREPO=$(gh repo view --json nameWithOwner -q .nameWithOwner)\n```\n\n### Spawn reviewers\n**Preferred:** dispatch a read-only reviewer subagent:\n- Task `subagent_type: reviewer` when the host provides it, **or**\n- the in-repo agent at `.claude\u002Fagents\u002Fstrike-reviewer.md`\n\n**Fallback** if Task\u002Freviewer is unavailable: you run the same rubric in-process — still load the diff, still post findings via `gh`. Never skip the loop on Tier B\u002FC.\n\nOptionally spawn a second pass focused on tests\u002Fsecurity if Tier C or the first pass is large.\n\nReviewer prompt **must** include:\n- PR number\u002FURL, base branch (`main`), and current `headRefOid`\n- Issue number and acceptance criteria\n- Hard requirement: run `gh pr diff $PR` (or receive the full patch) and read surrounding callers\u002Ftests before any verdict — **never** approve from title\u002FURL alone\n- Instruction: correctness bugs first (concrete failure scenario), then needless complexity \u002F missed reuse; no impact-free style nits\n- Instruction: return ranked findings with `path:line`, severity `blocking` | `should-fix` | `nit`, failure scenario, and the **head SHA actually reviewed**\n- Instruction: do **not** edit files; findings only; output must be paste-ready verbatim\n\nAlso pull human\u002FGitHub review state:\n```sh\ngh pr view \"$PR\" --json reviews,comments,reviewDecision,headRefOid\ngh api \"repos\u002F$REPO\u002Fpulls\u002F$PR\u002Fcomments\"\ngh api \"repos\u002F$REPO\u002Fissues\u002F$PR\u002Fcomments\"\n```\n\n### Post findings as PR review comments\nPost reviewer output on the PR (not only chat). **Post the reviewer’s ranked findings verbatim** — do not omit, soften, or downgrade severity. If you disagree with a blocking\u002Fshould-fix item, still post it and **stop-and-ask** (or reply on the thread with the dispute); silent drop is forbidden.\n\n**Event policy (handler is usually the PR author):**\n- Automated\u002Fhandler-authored reviews **always** use `\"event\": \"COMMENT\"` (never `REQUEST_CHANGES` or `APPROVE` — GitHub rejects self-approve and self-request-changes leaves merge gates stuck).\n- Encode severity in the review body and inline comment text (`**blocking:**`, `**should-fix:**`, `**nit:**`).\n- Reserve GitHub `APPROVE` \u002F `REQUEST_CHANGES` for **distinct human** reviewers only.\n\n**Preferred — single COMMENT review with inline notes** (only for lines in the PR diff hunk on `$HEAD_SHA`):\n```sh\nHEAD_SHA=$(gh pr view \"$PR\" --json headRefOid -q .headRefOid)\ngh api \"repos\u002F$REPO\u002Fpulls\u002F$PR\u002Freviews\" --method POST --input - \u003C\u003CEOF\n{\n  \"commit_id\": \"$HEAD_SHA\",\n  \"event\": \"COMMENT\",\n  \"body\": \"Review pass N on $HEAD_SHA\\n\\n(verbatim summary of blocking \u002F should-fix \u002F nits)\",\n  \"comments\": [\n    {\n      \"path\": \"path\u002Fto\u002Ffile.go\",\n      \"line\": 42,\n      \"side\": \"RIGHT\",\n      \"body\": \"**blocking:** …\\n\\nFailure scenario: …\"\n    }\n  ]\n}\nEOF\n```\nIf an inline `line` is not part of the diff hunk, the API 422s — put that finding in the top-level review body instead (do not invent lines).\n\n**Fallback — top-level PR comment** when inline mapping is impractical:\n```sh\ngh pr comment \"$PR\" --body \"$(cat \u003C\u003CEOF\n## Review pass N (head \\`$HEAD_SHA\\`)\n### Blocking\n- \\`file:line\\` — … (failure scenario)\n\n### Should-fix\n- …\n\n### Nits (optional)\n- …\nEOF\n)\"\n```\n\n**Clean pass (meets tier bar) — still required on the PR for B\u002FC:**\nA chat-only “LGTM” does **not** count. Always record the clean pass against `$HEAD_SHA`:\n```sh\nHEAD_SHA=$(gh pr view \"$PR\" --json headRefOid -q .headRefOid)\ngh pr comment \"$PR\" --body \"$(cat \u003C\u003CEOF\n## Review pass N (head \\`$HEAD_SHA\\`) — clean\n0 blocking, 0 should-fix (or should-fix deferred per tier B). Merge checklist may proceed for this SHA only.\nEOF\n)\"\n```\n\nWhen building `gh api` JSON for inline reviews, encode bodies with `jq -n --arg body \"$text\"` so quotes\u002Fnewlines do not break the payload.\n\nRules for posted comments:\n- Include severity tag and failure scenario for blocking\u002Fshould-fix.\n- Anchor path:line to the diff on this PR’s current head SHA.\n- Do not spam duplicates across passes — reply on the existing thread or mark resolved in the next summary with the new SHA.\n\n### Address comments\n1. List open review threads \u002F new comments (human + automated).\n2. For each **blocking** (and **should-fix** on Tier C, or B when not deferring): fix in the worktree, add\u002Fadjust tests when behavior changes, run tier gate.\n3. **Nits:** fix if cheap and clearly better; otherwise reply on the thread why deferred (one line).\n4. Commit and push (new commit; no amend\u002Fforce on shared PR branch).\n5. Reply on each addressed thread (or in a single PR comment) with what changed (`commit` shortsha + brief note).\n6. Re-run tier gate; watch CI; **spawn another review pass on the new `headRefOid`** when the tier requires it.\n\n### Merge-ready checklist (all required for the tier)\n- [ ] Review bar met for tier A\u002FB\u002FC on **current** `headRefOid` (posted review\u002Fcomment cites that SHA)\n- [ ] That SHA matches `gh pr view --json headRefOid` at merge time\n- [ ] Latest pass findings posted **verbatim** on the PR (when a pass ran)\n- [ ] All actionable human review comments addressed or explicitly deferred with reason\n- [ ] `reviewDecision` is not `CHANGES_REQUESTED` (human reviewers); do not use self-REQUEST_CHANGES\n- [ ] CI checks green on the same head SHA\n- [ ] `mergeable=MERGEABLE`, not draft, state `OPEN`\n- [ ] Local tier gate passed on the same commit\n\n## CI watch \u002F fix\ngh-only (no Python watchers):\n```sh\ngh pr checks --watch\n# or poll:\ngh pr view --json state,mergeable,mergeStateStatus,statusCheckRollup,reviewDecision,isDraft\ngh pr checks\ngh run list --branch \"$BRANCH\" --limit 5\ngh run view \u003Crun-id> --log-failed\n```\n| Class | Action |\n|---|---|\n| Branch-related | fix in worktree → commit → push → re-watch → **re-enter review loop** if tier requires |\n| Flaky\u002Finfra | `gh run rerun \u003Cid> --failed` ≤2; then stop-and-ask |\n| Ambiguous | one diagnosis; then stop-and-ask |\n| Actionable review | fix → commit → push → **re-enter review loop** |\n\n## Merge\nMerge **only when** the merge-ready checklist above is fully satisfied:\n```sh\ngh pr merge --merge\n```\n`--merge` matches repo history. Do not pass `--delete-branch` while still checked out on the feature branch in the worktree — remote\u002Flocal branch deletion happens in Cleanup after `git worktree remove`. Blocked on review\u002Fpermissions → stop-and-ask; never force. **Hard forbids:** force-push; careless `reset --hard`; merge with failing checks; merge without meeting the tier review bar; close\u002Freopen PR unprompted.\n\n## Cleanup (after merge)\nFrom `MAIN_ROOT`:\n```sh\ncd \"$MAIN_ROOT\" && git fetch origin main\ngit worktree remove \"$WT_PARENT\u002F$BRANCH\"\ngit branch -d \"$BRANCH\" 2>\u002Fdev\u002Fnull || true\ngit worktree prune\n```\nDo not leave cwd inside deleted worktree. Only delete branch you created.\n\n## Sibling skills\n| When | Load |\n|---|---|\n| Writing\u002Fextending `*_test.go` | `write-go-tests` |\n| Before claiming done \u002F after impl or CI-fix | `test-and-validate` |\n| User-visible cmd\u002Fengine\u002Ftui\u002Fsession\u002Fauth | `smoke` |\n| Cutting a version tag | `release` |\n| Any `internal\u002Ffrontend\u002Ftui` view\u002Fpanel\u002Fmodal\u002Ftheme | `tui-components` first |\n\n## Hard rules\n1. Own issue end-to-end through merge — including review-agent loop on B\u002FC.\n2. Never edit primary checkout for issue implementation.\n3. Never claim done without the **tier** local gate (not always full race).\n4. Never push secrets. Never weaken\u002Fdelete tests for green.\n5. Never force-push main; no destructive git on shared history.\n6. Smallest correct change; honor `AGENTS.md` scope. TUI imports: `protocol`, `host`, `tui\u002F…` only.\n7. `.plan\u002F` optional research only — never required; never treat unscoped roadmap as the issue.\n8. Stop-and-ask on ambiguity rather than guess.\n9. Never merge with open blocking findings (or tier-C should-fix) from the latest pass on the **current** head SHA.\n10. Always post review findings on the PR via `gh` (COMMENT review or comment) when a pass runs — chat-only review does not count.\n11. Post reviewer findings verbatim; never omit or downgrade severity. Disputes → stop-and-ask.\n12. Handler-authored automated reviews use `event: COMMENT` only — never self-APPROVE or self-REQUEST_CHANGES.\n\n## Stop-and-ask\n- `gh` auth\u002Fpermission failures; unclear\u002Fcontradictory acceptance criteria\n- Foreign\u002Funexpected dirty worktree; ambiguous path\u002Fbranch collision; CI red outside branch after 2 reruns\n- Merge conflicts with main you cannot resolve confidently (prefer `git merge origin\u002Fmain` over rebase)\n- Review requires product decision; would commit secrets or change CI\u002Fsecurity unexpectedly\n- Review loop still fails the tier bar after 5 passes\n- Desire to drop or downgrade a reviewer’s blocking\u002Fshould-fix finding\n\n## What this skill is not\n- Not unscoped `.plan\u002Ffeatures.md` implementer\n- Not multi-agent orchestrator requirement (beyond required PR review subagent \u002F strike-reviewer)\n- Not Python CI babysitter\n- Not a substitute for sibling domain skills\n","# Issue handler (strike-cli)\n\nOwn the issue end-to-end with due diligence on research, testing, and validation. Shipping is ownership: commit → push → PR → **review-agent loop** → CI green → merge → cleanup. All code edits happen inside a **git worktree**, never the primary checkout.\n\nFor agents developing strike. Authoring skills\u002Fdocs may use this pipeline; apply when the user frames work as an issue (or asks you to own issue→main).\n\n## Preconditions\n- `gh auth status` ok; git repo; network; issue number\u002FURL known.\n- **Stop-and-ask:** no write access; `gh` missing; issue already has an open PR you did not create (attach or ask — no duplicate). Dirty primary is fine for `git worktree add` from `origin\u002Fmain` — do not clean\u002Fstash primary WIP.\n\n## Workflow\n0. **Orient** — `gh issue view N` (+ comments). Read `AGENTS.md` + `docs\u002FARCHITECTURE.md` for boundaries. Note issue headers (`wave`\u002F`depends`\u002F`conflicts`\u002F`priority`) if present.\n1. **Research** — map issue→packages; read code + nearest tests. Optional local `.plan\u002Ffeatures.md` \u002F `FEATURES_STATUS.md` **if present** (never block if missing). State acceptance criteria bullets. Stop-and-ask if ambiguous.\n2. **Worktree** — create\u002Fenter; confirm `pwd` + branch before edits.\n3. **Plan** — smallest correct change; no drive-by refactors. Assign **risk tier A\u002FB\u002FC** (see Verification tiers).\n4. **Implement** — worktree only; load sibling skills when domain matches.\n5. **Test** — load `write-go-tests` when behavior changes.\n6. **Validate** — load `test-and-validate` for the **tier gate**; smoke when applicable.\n7. **Sync main** — if the PR will be open >~1h or `origin\u002Fmain` moved, `git fetch origin main && git merge origin\u002Fmain` then re-run tier gate before\u002Fat push.\n8. **Ship** — commit, push `origin\u002F\u003Cbranch>`, PR with `Fixes #N`.\n9. **Review loop** — tier-scaled (below); post findings; address; re-review until merge-ready.\n10. **Babysit CI** — fix branch-related failures; re-push; re-enter review loop after material code changes.\n11. **Merge** — only when merge gates pass (below).\n12. **Cleanup** — remove worktree after merge; leave cwd outside deleted tree.\n\n## Worktree setup\n```sh\nMAIN_ROOT=$(dirname \"$(git rev-parse --path-format=absolute --git-common-dir)\")\nWT_PARENT=\"$(dirname \"$MAIN_ROOT\")\u002Fstrike-cli-worktrees\"\nBRANCH=\"worktree-\u003Cslug>\"   # e.g. worktree-24-model-prefix; 2–4 kebab words; include issue # if helpful\nmkdir -p \"$WT_PARENT\"\ngit fetch origin main\n# Resume if yours; else create. Never delete others' worktrees.\nif [ -d \"$WT_PARENT\u002F$BRANCH\" ] && git worktree list | grep -q \"$WT_PARENT\u002F$BRANCH\"; then\n  # On $BRANCH and yours (clean or only your WIP): cd and continue.\n  # Stop-and-ask: foreign worktree, unexpected dirty state you don't own, or ambiguous collision.\n  cd \"$WT_PARENT\u002F$BRANCH\"\nelse\n  git worktree add -b \"$BRANCH\" \"$WT_PARENT\u002F$BRANCH\" origin\u002Fmain\n  cd \"$WT_PARENT\u002F$BRANCH\"\nfi\n```\nBefore every edit session:\n```sh\npwd   # must be $WT_PARENT\u002F$BRANCH\ngit rev-parse --abbrev-ref HEAD   # must be $BRANCH\n```\nRefuse Write\u002FEdit under primary checkout for issue implementation.\n\n## Verification tiers (local ship gate)\n\nSource of truth: root `AGENTS.md` *Verification tiers*. Summary:\n\n| Tier | When | Local gate |\n|---|---|---|\n| **A** | Docs\u002Fskills\u002Fmarkdown only | gofmt if any `.go`; no full test suite |\n| **B** | Normal code (default) | gofmt → TUI generate if `_src` → `web-check` if `web\u002F` → `make test && make vet && make build` |\n| **C** | tool \u002F permission \u002F auth \u002F session \u002F engine concurrency \u002F protocol wire \u002F sandbox | Tier B + `go test -race .\u002F... -count=1` + focused package tests |\n\nCI runs `go test -race .\u002F...` on every PR — do **not** always re-run full local race on A\u002FB.\n\n**Smoke:** load skill `smoke` when the diff touches `cmd\u002F`, `harness\u002Fengine`, TUI input\u002Fkeymap\u002Fapp, `session`, or `auth`.\n\n**Contract freeze:** default keybind or config-schema changes must update `docs\u002Fkeybinds.md` \u002F `docs\u002Fconfig.md` and call out migration in the PR body.\n\n**Flakes:** see `test-and-validate` flake policy — do not block unrelated merges on known env-only flakes; file `wave: 0` bugs.\n\nLoad `test-and-validate` for report format. Never weaken\u002Fdelete tests for green.\n\n## Commit and push\n```sh\ngit status && git diff && git log --oneline -10\ngit add \u003Cintended paths only>\ngit commit -m \"$(cat \u003C\u003C'EOF'\ntype(scope): concise summary\n\nFixes #\u003CN>\nEOF\n)\"\ngit push -u origin HEAD\n```\nConventional commits: `feat`\u002F`fix`\u002F`docs`\u002F`refactor`\u002F`test`\u002F`chore`. No secrets. No force-push main. No hook skips. Prefer new commits over amend\u002Fforce on shared PR branch.\n\n## Open PR\n```sh\ngh pr create --base main --head \"$BRANCH\" --title \"type(scope): summary\" --body \"$(cat \u003C\u003C'EOF'\n## Summary\n- …\n\n## Issue\nFixes #\u003CN>\n\n## Tier\nA | B | C\n\n## Verification\n- \u003Cexact commands from tier gate>\n- smoke: ran | skipped (reason)\nEOF\n)\"\n```\nFocused PR; no AI wall of text. If PR exists: `gh pr view`.\n\n## Review-agent loop (required for B\u002FC; optional for A)\n\nAfter the PR exists, **do not merge until the tier’s review bar is met**. You own dispatching reviewers, posting findings on the PR, fixing code, and repeating.\n\n### Pass budget (risk-scaled)\n\n| Tier | Review passes | Merge bar |\n|---|---|---|\n| **A** | 0–1 optional | Owner judgment; no blocking findings if a pass ran |\n| **B** | **1** clean pass on current HEAD | 0 **blocking**; should-fix fixed or explicitly deferred with reason on the PR |\n| **C** | **1–2** passes on current HEAD | 0 **blocking** and 0 **should-fix** |\n\nStall ceiling: **5** passes max — if still dirty, stop-and-ask (do not merge). Five is a cap, not a target.\n\n### When to run\n- Tier B\u002FC: once after first push + PR open (may run in parallel with CI).\n- Again after **any** push that changes production, test, skill, agent, workflow, or other merge-bound files — including review\u002FCI fixes.\n- Skip re-review only for pure changelog typos that cannot affect behavior or process — when unsure, re-review.\n- A clean review on an **older** SHA does **not** satisfy merge gates after a new push.\n\n### Resolve PR identity\n```sh\nPR=$(gh pr view --json number -q .number)\nHEAD_SHA=$(gh pr view --json headRefOid -q .headRefOid)\nREPO=$(gh repo view --json nameWithOwner -q .nameWithOwner)\n```\n\n### Spawn reviewers\n**Preferred:** dispatch a read-only reviewer subagent:\n- Task `subagent_type: reviewer` when the host provides it, **or**\n- the in-repo agent at `.claude\u002Fagents\u002Fstrike-reviewer.md`\n\n**Fallback** if Task\u002Freviewer is unavailable: you run the same rubric in-process — still load the diff, still post findings via `gh`. Never skip the loop on Tier B\u002FC.\n\nOptionally spawn a second pass focused on tests\u002Fsecurity if Tier C or the first pass is large.\n\nReviewer prompt **must** include:\n- PR number\u002FURL, base branch (`main`), and current `headRefOid`\n- Issue number and acceptance criteria\n- Hard requirement: run `gh pr diff $PR` (or receive the full patch) and read surrounding callers\u002Ftests before any verdict — **never** approve from title\u002FURL alone\n- Instruction: correctness bugs first (concrete failure scenario), then needless complexity \u002F missed reuse; no impact-free style nits\n- Instruction: return ranked findings with `path:line`, severity `blocking` | `should-fix` | `nit`, failure scenario, and the **head SHA actually reviewed**\n- Instruction: do **not** edit files; findings only; output must be paste-ready verbatim\n\nAlso pull human\u002FGitHub review state:\n```sh\ngh pr view \"$PR\" --json reviews,comments,reviewDecision,headRefOid\ngh api \"repos\u002F$REPO\u002Fpulls\u002F$PR\u002Fcomments\"\ngh api \"repos\u002F$REPO\u002Fissues\u002F$PR\u002Fcomments\"\n```\n\n### Post findings as PR review comments\nPost reviewer output on the PR (not only chat). **Post the reviewer’s ranked findings verbatim** — do not omit, soften, or downgrade severity. If you disagree with a blocking\u002Fshould-fix item, still post it and **stop-and-ask** (or reply on the thread with the dispute); silent drop is forbidden.\n\n**Event policy (handler is usually the PR author):**\n- Automated\u002Fhandler-authored reviews **always** use `\"event\": \"COMMENT\"` (never `REQUEST_CHANGES` or `APPROVE` — GitHub rejects self-approve and self-request-changes leaves merge gates stuck).\n- Encode severity in the review body and inline comment text (`**blocking:**`, `**should-fix:**`, `**nit:**`).\n- Reserve GitHub `APPROVE` \u002F `REQUEST_CHANGES` for **distinct human** reviewers only.\n\n**Preferred — single COMMENT review with inline notes** (only for lines in the PR diff hunk on `$HEAD_SHA`):\n```sh\nHEAD_SHA=$(gh pr view \"$PR\" --json headRefOid -q .headRefOid)\ngh api \"repos\u002F$REPO\u002Fpulls\u002F$PR\u002Freviews\" --method POST --input - \u003C\u003CEOF\n{\n  \"commit_id\": \"$HEAD_SHA\",\n  \"event\": \"COMMENT\",\n  \"body\": \"Review pass N on $HEAD_SHA\\n\\n(verbatim summary of blocking \u002F should-fix \u002F nits)\",\n  \"comments\": [\n    {\n      \"path\": \"path\u002Fto\u002Ffile.go\",\n      \"line\": 42,\n      \"side\": \"RIGHT\",\n      \"body\": \"**blocking:** …\\n\\nFailure scenario: …\"\n    }\n  ]\n}\nEOF\n```\nIf an inline `line` is not part of the diff hunk, the API 422s — put that finding in the top-level review body instead (do not invent lines).\n\n**Fallback — top-level PR comment** when inline mapping is impractical:\n```sh\ngh pr comment \"$PR\" --body \"$(cat \u003C\u003CEOF\n## Review pass N (head \\`$HEAD_SHA\\`)\n### Blocking\n- \\`file:line\\` — … (failure scenario)\n\n### Should-fix\n- …\n\n### Nits (optional)\n- …\nEOF\n)\"\n```\n\n**Clean pass (meets tier bar) — still required on the PR for B\u002FC:**\nA chat-only “LGTM” does **not** count. Always record the clean pass against `$HEAD_SHA`:\n```sh\nHEAD_SHA=$(gh pr view \"$PR\" --json headRefOid -q .headRefOid)\ngh pr comment \"$PR\" --body \"$(cat \u003C\u003CEOF\n## Review pass N (head \\`$HEAD_SHA\\`) — clean\n0 blocking, 0 should-fix (or should-fix deferred per tier B). Merge checklist may proceed for this SHA only.\nEOF\n)\"\n```\n\nWhen building `gh api` JSON for inline reviews, encode bodies with `jq -n --arg body \"$text\"` so quotes\u002Fnewlines do not break the payload.\n\nRules for posted comments:\n- Include severity tag and failure scenario for blocking\u002Fshould-fix.\n- Anchor path:line to the diff on this PR’s current head SHA.\n- Do not spam duplicates across passes — reply on the existing thread or mark resolved in the next summary with the new SHA.\n\n### Address comments\n1. List open review threads \u002F new comments (human + automated).\n2. For each **blocking** (and **should-fix** on Tier C, or B when not deferring): fix in the worktree, add\u002Fadjust tests when behavior changes, run tier gate.\n3. **Nits:** fix if cheap and clearly better; otherwise reply on the thread why deferred (one line).\n4. Commit and push (new commit; no amend\u002Fforce on shared PR branch).\n5. Reply on each addressed thread (or in a single PR comment) with what changed (`commit` shortsha + brief note).\n6. Re-run tier gate; watch CI; **spawn another review pass on the new `headRefOid`** when the tier requires it.\n\n### Merge-ready checklist (all required for the tier)\n- [ ] Review bar met for tier A\u002FB\u002FC on **current** `headRefOid` (posted review\u002Fcomment cites that SHA)\n- [ ] That SHA matches `gh pr view --json headRefOid` at merge time\n- [ ] Latest pass findings posted **verbatim** on the PR (when a pass ran)\n- [ ] All actionable human review comments addressed or explicitly deferred with reason\n- [ ] `reviewDecision` is not `CHANGES_REQUESTED` (human reviewers); do not use self-REQUEST_CHANGES\n- [ ] CI checks green on the same head SHA\n- [ ] `mergeable=MERGEABLE`, not draft, state `OPEN`\n- [ ] Local tier gate passed on the same commit\n\n## CI watch \u002F fix\ngh-only (no Python watchers):\n```sh\ngh pr checks --watch\n# or poll:\ngh pr view --json state,mergeable,mergeStateStatus,statusCheckRollup,reviewDecision,isDraft\ngh pr checks\ngh run list --branch \"$BRANCH\" --limit 5\ngh run view \u003Crun-id> --log-failed\n```\n| Class | Action |\n|---|---|\n| Branch-related | fix in worktree → commit → push → re-watch → **re-enter review loop** if tier requires |\n| Flaky\u002Finfra | `gh run rerun \u003Cid> --failed` ≤2; then stop-and-ask |\n| Ambiguous | one diagnosis; then stop-and-ask |\n| Actionable review | fix → commit → push → **re-enter review loop** |\n\n## Merge\nMerge **only when** the merge-ready checklist above is fully satisfied:\n```sh\ngh pr merge --merge\n```\n`--merge` matches repo history. Do not pass `--delete-branch` while still checked out on the feature branch in the worktree — remote\u002Flocal branch deletion happens in Cleanup after `git worktree remove`. Blocked on review\u002Fpermissions → stop-and-ask; never force. **Hard forbids:** force-push; careless `reset --hard`; merge with failing checks; merge without meeting the tier review bar; close\u002Freopen PR unprompted.\n\n## Cleanup (after merge)\nFrom `MAIN_ROOT`:\n```sh\ncd \"$MAIN_ROOT\" && git fetch origin main\ngit worktree remove \"$WT_PARENT\u002F$BRANCH\"\ngit branch -d \"$BRANCH\" 2>\u002Fdev\u002Fnull || true\ngit worktree prune\n```\nDo not leave cwd inside deleted worktree. Only delete branch you created.\n\n## Sibling skills\n| When | Load |\n|---|---|\n| Writing\u002Fextending `*_test.go` | `write-go-tests` |\n| Before claiming done \u002F after impl or CI-fix | `test-and-validate` |\n| User-visible cmd\u002Fengine\u002Ftui\u002Fsession\u002Fauth | `smoke` |\n| Cutting a version tag | `release` |\n| Any `internal\u002Ffrontend\u002Ftui` view\u002Fpanel\u002Fmodal\u002Ftheme | `tui-components` first |\n\n## Hard rules\n1. Own issue end-to-end through merge — including review-agent loop on B\u002FC.\n2. Never edit primary checkout for issue implementation.\n3. Never claim done without the **tier** local gate (not always full race).\n4. Never push secrets. Never weaken\u002Fdelete tests for green.\n5. Never force-push main; no destructive git on shared history.\n6. Smallest correct change; honor `AGENTS.md` scope. TUI imports: `protocol`, `host`, `tui\u002F…` only.\n7. `.plan\u002F` optional research only — never required; never treat unscoped roadmap as the issue.\n8. Stop-and-ask on ambiguity rather than guess.\n9. Never merge with open blocking findings (or tier-C should-fix) from the latest pass on the **current** head SHA.\n10. Always post review findings on the PR via `gh` (COMMENT review or comment) when a pass runs — chat-only review does not count.\n11. Post reviewer findings verbatim; never omit or downgrade severity. Disputes → stop-and-ask.\n12. Handler-authored automated reviews use `event: COMMENT` only — never self-APPROVE or self-REQUEST_CHANGES.\n\n## Stop-and-ask\n- `gh` auth\u002Fpermission failures; unclear\u002Fcontradictory acceptance criteria\n- Foreign\u002Funexpected dirty worktree; ambiguous path\u002Fbranch collision; CI red outside branch after 2 reruns\n- Merge conflicts with main you cannot resolve confidently (prefer `git merge origin\u002Fmain` over rebase)\n- Review requires product decision; would commit secrets or change CI\u002Fsecurity unexpectedly\n- Review loop still fails the tier bar after 5 passes\n- Desire to drop or downgrade a reviewer’s blocking\u002Fshould-fix finding\n\n## What this skill is not\n- Not unscoped `.plan\u002Ffeatures.md` implementer\n- Not multi-agent orchestrator requirement (beyond required PR review subagent \u002F strike-reviewer)\n- Not Python CI babysitter\n- Not a substitute for sibling domain skills\n",{"name":5,"description":7},"main","33cd31acc8c3b15e8bdead40f26a5957a6f4210f",".claude\u002Fskills\u002Fissue-handler",2,"https:\u002F\u002Fgithub.com\u002Fjonathanung\u002Fstrike","https:\u002F\u002Fstrike.jonathanung.ca\u002F","https:\u002F\u002Fgithub.com\u002Fjonathanung","https:\u002F\u002Fjonathanung.ca","for fun programmer larping as a student","2026-11-14 19:25:31",{"source":8,"skillName":5,"commands":35,"prompt":45,"zipAvailable":46},[36,39,42],{"tool":37,"command":38},"npx","npx skills add jonathanung\u002Fstrike --skill issue-handler",{"tool":40,"command":41},"bunx","bunx skills add jonathanung\u002Fstrike --skill issue-handler",{"tool":43,"command":44},"pnpm","pnpm dlx skills add jonathanung\u002Fstrike --skill issue-handler","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fjonathanung\u002Fstrike\u002Fblob\u002Fmain\u002F.claude\u002Fskills\u002Fissue-handler\u002FSKILL.md",true,[],[49,56,63,70,77,83],{"skillNo":50,"name":51,"nameZh":6,"description":52,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":53,"categories":54,"keywords":55,"publishedAt":19},"01M79JZ3BTYJTXTH62TTMQTRSY","keep","Kept despite unknown fields","https:\u002F\u002Fgithub.com\u002Fjonathanung\u002Fstrike\u002Fblob\u002Fmain\u002Finternal\u002Fintegrate\u002Fplugin\u002Ftestdata\u002Faps\u002Funknown-fields\u002Fskills\u002Fkeep\u002FSKILL.md",[],[],{"skillNo":57,"name":58,"nameZh":6,"description":59,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":60,"categories":61,"keywords":62,"publishedAt":19},"01M79JYZBHM1ETESYN0P255ZQN","ok","Immediate skill","https:\u002F\u002Fgithub.com\u002Fjonathanung\u002Fstrike\u002Fblob\u002Fmain\u002Finternal\u002Fintegrate\u002Fplugin\u002Ftestdata\u002Faps\u002Fskills-layout\u002Fskills\u002Fok\u002FSKILL.md",[],[],{"skillNo":64,"name":65,"nameZh":6,"description":66,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":67,"categories":68,"keywords":69,"publishedAt":19},"01M79JYYFSHFEQJF8VNZ6CWAJ7","deep","Must not be discovered","https:\u002F\u002Fgithub.com\u002Fjonathanung\u002Fstrike\u002Fblob\u002Fmain\u002Finternal\u002Fintegrate\u002Fplugin\u002Ftestdata\u002Faps\u002Fskills-layout\u002Fskills\u002Fnested\u002Fdeep\u002FSKILL.md",[],[],{"skillNo":71,"name":72,"nameZh":6,"description":73,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":74,"categories":75,"keywords":76,"publishedAt":19},"01M79JYXN8XTSQ8P4E2EWAGE54","summarize","Summarize text","https:\u002F\u002Fgithub.com\u002Fjonathanung\u002Fstrike\u002Fblob\u002Fmain\u002Finternal\u002Fintegrate\u002Fplugin\u002Ftestdata\u002Faps\u002Fportable-ok\u002Fskills\u002Fsummarize\u002FSKILL.md",[],[],{"skillNo":78,"name":51,"nameZh":6,"description":79,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":80,"categories":81,"keywords":82,"publishedAt":19},"01M79JYWT8JKCZ6B255CTWVHTX","Survives MCP disable","https:\u002F\u002Fgithub.com\u002Fjonathanung\u002Fstrike\u002Fblob\u002Fmain\u002Finternal\u002Fintegrate\u002Fplugin\u002Ftestdata\u002Faps\u002Fmcp-schema-mismatch\u002Fskills\u002Fkeep\u002FSKILL.md",[],[],{"skillNo":84,"name":51,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":19},"01M79JYTNMJS2GSKCQ9BWYWBKQ","Survives invalid mcp.json kind","https:\u002F\u002Fgithub.com\u002Fjonathanung\u002Fstrike\u002Fblob\u002Fmain\u002Finternal\u002Fintegrate\u002Fplugin\u002Ftestdata\u002Faps\u002Fmcp-not-file\u002Fskills\u002Fkeep\u002FSKILL.md",[],[]]