Site bugfix (debbie.codes)
Take a known bug from repro → fix → verify → regress. Complements site-bug-hunt.
Quick start (local)
Fix the bug described in qa/bug-candidates/<file>.md using the site-bugfix skill.
Reproduce in the browser first. Do not open a PR unless I ask.
Fix GitHub issue #<n> using site-bugfix. Reproduce first, then open a draft PR with Closes #<n>.
Modes
| Mode | Behavior |
|---|---|
| interactive (default) | Fix from candidate path, issue URL/number, or description. Open a PR only if the user asks. |
ci (SITE_BUG_FIX_MODE=ci) |
Select one eligible open issue → branch agent/fix-issue-<n> → draft PR with Closes #N. Max 1 PR per run. |
Tooling
- Browser:
playwright-cli(load theplaywright-cliskill) - Tests:
npx playwright test/npm test(base URL fromplaywright.config.ts) - GitHub:
ghfor issues/PRs
Eligible issues (CI)
Pick the oldest open issue that has:
- Labels including
bugandagent-hunt(or body containing agent-hunt fingerprint frontmatter) - Not assigned to a human who is actively working it (Copilot assignee OK to continue)
- No open PR that already closes it (
Closes #n/Fixes #n)
Prefer higher severity labels when present (severity:blocker / severity:major).
If none: exit successfully with “no eligible issues.”
Structured input
Prefer candidates/issues that include YAML frontmatter from the hunt template (fingerprint, url, severity, confidence, classification, area, fix_surface). Use fix_surface:
content→ prefer minimal edits undercontent/app→ preferpages/,components/, or site configmixed→ smallest change that fixes the user-visible bug
Workflow
1. Reproduce first (mandatory)
- Confirm the bug still happens (production URL from the issue, or local if local-only).
- Capture evidence with playwright-cli.
- If you cannot reproduce:
- Local: stop and report
- CI:
gh issue commentexplaining attempts; add labelneeds-humanif possible; do not open a PR
No product code changes until reproduction succeeds.
2. Fix with minimal scope
- Branch:
agent/fix-issue-<n>(CI) or a clear local branch name. - Smallest change; no drive-by refactors.
- Prefer a11y-friendly fixes when the bug is interaction/UI.
3. Verify
Re-run the exact original user action. Note before/after briefly.
4. Regression test when it pays off
- Stable user journey → add/adjust
tests/*.spec.ts - Run:
npx playwright test tests/<file>.spec.ts - Skip only with an explicit reason (flaky env, third-party-only)
5. Close the loop
If PR requested or CI mode:
gh pr create --draft --title "fix: …" --body "$(cat <<'EOF'
## Summary
…
## Repro
…
## Fix
…
## Verification
- playwright-cli: …
- tests: `npx playwright test …`
Closes #<n>
EOF
)"
Always use --draft for autonomous / CI PRs.
Update or remove the local candidate file notes when appropriate.
Rules
- Reproduce before fix.
- One bug per branch/PR.
- Don’t weaken tests to pass.
- Don’t commit secrets or unrelated WIP.
- Loud failure > fake fix.
Done means
- Reproduced with evidence or loud cannot-repro exit
- Fix + browser verification when reproduced
- Regression test added/updated or explicit skip reason
- Draft PR with
Closes #Nin CI / when asked locally