fix-issue
Autonomously fix one or many GitHub issues end-to-end — thin wrapper that shells out to the external `sdlc` controller, which owns the deterministic fix pipeline.
- License 许可
- MIT
- 最近更新
- 2026-11-15
- Stars
- ★ 2
- Forks
- 2
01 前言 Front Matter
- name
- fix-issue
- description
- Autonomously fix one or many GitHub issues end-to-end — thin wrapper that shells out to the external `sdlc` controller, which owns the deterministic fix pipeline.
- allowed-tools
- Bash
- argument-hint
- <issue-number|next|all> [--skip-coverage] [--e2e-gate=warn|off] [--skip-e2e] [--limit=N] [--coverage-threshold=N] [--skip-preflight] [--sequential] [--concurrency=N]
- user-invocable
- true
- disable-model-invocation
- false
02 资源文件 11
- 参考文档backfill-docs-prompt.md6.7 KB
- 参考文档batch-mode.md1.6 KB
- 参考文档bugfix-agent-prompt.md33 B
- 参考文档build-agent-prompt.md3.1 KB
- 参考文档coverage-gate-prompt.md34 B
- 参考文档doc-update-prompt.md31 B
- 参考文档e2e-gate-prompt.md2.1 KB
- 参考文档investigation-agent-prompt.md2.6 KB
- 参考文档merge-agent-prompt.md2.3 KB
- 参考文档review-gate-prompt.md3.4 KB
- 参考文档summary-prompt.md1.4 KB
03 SKILL.md 正文
You are a thin wrapper around the external sdlc controller (issue #436).
Orchestration logic — issue fetch, the stop conditions, investigation, the
build → coverage → review → merge loop, the bugfix loop, the optional E2E
warn-gate, the batch doc-update phase, schema-validated agent I/O, and the
SQLite ledger writes — lives in deterministic Python in controller/, not in
this prompt. Your only job is to invoke the controller and return its exit code.
Running the controller
Forward the user's arguments to the controller verbatim, then surface its stdout/stderr and propagate its exit code unchanged. Do not re-implement any of the orchestration here.
sdlc fix $ARGUMENTS
If sdlc is not on PATH, fall back to running it from the controller
checkout:
if command -v sdlc >/dev/null 2>&1; then
sdlc fix $ARGUMENTS
elif [ -d controller ]; then
( cd controller && uv run sdlc fix $ARGUMENTS )
else
echo "error: sdlc controller not found. Install it with:" >&2
echo " uv tool install ./controller" >&2
exit 1
fi
Flag surface (forwarded to the controller)
- Target (positional, pass exactly one):
<issue-number>(a single open issue),all(every open issue), ornext(the highest-priority open bug). - Batch mode — only when the target is
allornextwith--limit=N, read${CLAUDE_SKILL_DIR}/batch-mode.mdfor the batch-only flags and batch behavior; the single-issue path never needs it. --skip-coverage— the build agent opens the PR directly (no coverage gate).--coverage-threshold=N— required new-code coverage % (default 90).--skip-preflight— skip the preflight quality gate.--e2e-gate=warn|off— run the advisory E2E gate after review (defaultoff); inwarnmode a FAIL is logged and the fix still merges (it never blocks).--skip-e2e— alias for--e2e-gate=off.
Changed from the pre-migration skill (issue #436): two accepted inputs were
deliberately narrowed and now fail with an explicit FixConfigError instead of
silently misbehaving:
- Issue URLs are no longer accepted — pass the bare
<issue-number>(sdlc fix 123, notsdlc fix https://github.com/owner/repo/issues/123). --e2e-gate=blockis no longer supported — onlywarn/offexist. The old skill's blocking E2E mode (route a FAIL to the bugfix loop) is out of scope for this migration;warnis strictly advisory.
What the controller does (reference only)
The controller (controller/src/sdlc/fix_issue.py) owns the full lifecycle:
- Fetch + stop conditions — reads the issue(s) via
gh; a closed / assigned elsewhere /wontfixissue is a deliberate stop (no run row). - Preflight — shells out to the detected test command; aborts if red
(unless
--skip-preflight). - Investigation — a
sonnetagent produces a structured, schema-validated fix plan; a BLOCKED investigation parks the issue for a human decision. - Build → Coverage → Review → Merge — dispatches each agent as a subprocess
and validates every response against its JSON-schema contract
(
controller/src/sdlc/schemas/). A missing or schema-invalid result block is treated as a failure and routed to the bugfix loop — the next stage never runs on garbage. Model routing mirrors the Balanced profile: build, review, and bugfix default tosonnetand escalate toopuswhen the investigation reportsCOMPLEXITY: HIGHor the issue carries a high-risk/security label (risk:high,high-risk,security); coverage stayssonnet, merge and summary stayhaiku. A docs-only fix (every built file matches the shared docs patterns —**/*.md,docs/**, plus any.sdlc-change-class.yamlallowlist) skips the coverage dispatch — the controller pushes the branch and opens the PR itself — recording itSKIPPEDwithskip_reason=docs-only(Story 27.2-003); the review still runs. - E2E warn-gate (optional) — with
--e2e-gate=warn, an advisoryqa-engineerpass runs the project's existing E2E suite after review; a FAIL is logged and merge proceeds. A docs-only fix skips this gate too (recordedSKIPPED). - Bugfix loop — bounded retries per stage before marking the issue FAILED.
- Merge — rebases, squash-merges, closes the issue; a
risk:highPR with no approval parks the runAWAITING_APPROVALrather than force-merging. - Summary — a best-effort, non-blocking per-fix summary (batch runs add a
doc-update phase; see
batch-mode.md). - Ledger writes — every stage transition is persisted to the SQLite ledger
(
.sdlc-state.db) before the next begins, so afixrun shows up insdlc dashboardbesidesdlc buildruns.
The *-agent-prompt.md / *-gate-prompt.md template files in this skill
directory are retained for reference only — the controller now renders every
fix-stage prompt inline, so the renderers in controller/src/sdlc/fix_issue.py
(render_investigation_prompt, render_build_prompt, render_coverage_prompt,
render_review_prompt, render_e2e_prompt, render_merge_prompt,
render_bugfix_prompt, render_summary_prompt, render_doc_update_prompt) are
the authoritative source of what each dispatched agent receives.
04 同仓库更多 Skills
evil
A poisoned skill fixture carrying an encoded payload.
demo
A harmless demo skill used as a clean supply-chain fixture.
skills
暂无简介
telegram
Post messages to Telegram via Bot API. Supports Markdown formatting, reply-to, and silent mode.
fix-github-issue
Fix a GitHub issue with quality gates — coverage, code review, E2E, and bugfix triage loop.
execute-e2e-tests
Run and manage Playwright E2E tests. Setup, write, execute, and debug end-to-end tests for any project.