Skip to content

vt-d-bug-report

Report a bug — creates a BugChen intake file (BUG-NNN.md) in intake/pending/bugs/

Plugin: vt-product-dev
Category: Other
Command: /vt-d-bug-report


/vt-d-bug-report — Bug Intake Skill

Create a structured bug report in the intake pipeline. Asks clarifying questions and writes a BUG-NNN.md file to intake/pending/bugs/ for later triage.

Invocation

/vt-d-bug-report                          # Start with no context
/vt-d-bug-report "login fails on Safari"  # Start with initial description

Execution

Step 1: Parse Argument

If an argument was provided, use it as the initial bug description. If no argument, set initial description to empty string.

Step 2: Detect Branch Context

Run: git branch --show-current

Extract related spec or bug: - If branch matches feature/spec-NNN-*: related_spec = SPEC-NNN - If branch matches fix/bug-NNN-*: related_bug = BUG-NNN - Otherwise: no related context

Step 3: Ask Structured Questions

Use AskUserQuestion to collect:

  1. Bug description (if not provided as argument): "What is the bug? Describe what happens."

  2. Severity: "What is the severity?" Options: critical (system down / data loss), high (major feature broken), medium (feature partially broken), low (minor issue / cosmetic)

  3. Domain: "Which domain does this bug belong to?" Build the option list dynamically from intake/projects.yaml:

  4. Collect the unique set of domain: values across all entries under projects:
  5. Append cross-cutting as a fixed final option (use for bugs that affect multiple domains or toolkit-wide concerns)
  6. If intake/projects.yaml is missing or yields zero domains, fall back to [cross-cutting] as the only option

Persist the chosen value to the BUG-NNN.md frontmatter as domain: (see Step 5).

Constraint: cross-cutting is valid for bugs ONLY — never for specs (per SPEC-122 Decision 1). The bug-report skill is the only intake path where this value may be assigned without further review.

  1. Steps to reproduce: "What are the steps to reproduce? (e.g. 1. Go to login page, 2. Enter email, 3. Click submit)"

  2. Expected behavior: "What should happen?"

  3. Actual behavior: "What actually happens?"

  4. Screenshots or logs (optional): "Any screenshot paths or log snippets? (press Enter to skip)"

Step 4: Auto-Increment BUG Number

Scan for the highest existing BUG number: 1. Glob intake/pending/bugs/BUG-*.md → extract NNN from each filename 2. Glob bugs/*/report.md → read YAML frontmatter id: from each

Take the maximum found. Next BUG number = max + 1 (pad to 3 digits: BUG-001, BUG-002, ...). If no existing bugs found, start at BUG-001.

Step 5: Write BugChen File

Write to intake/pending/bugs/BUG-NNN.md:

---
id: BUG-NNN
title: [first 60 chars of description]
severity: [critical|high|medium|low]
domain: [domain name from intake/projects.yaml, or 'cross-cutting']
status: reported
reporter: user
reported_at: [ISO-8601 date]
branch: [current branch name]
related_spec: [SPEC-NNN or null]
related_bug: [BUG-NNN or null]
screenshots: [list of paths, or []]
---

# BUG-NNN: [description]

## Severity
[severity]

## Steps to Reproduce
[steps]

## Expected Behavior
[expected]

## Actual Behavior
[actual]

## Screenshots / Logs
[screenshots or "None provided"]

Step 6: Confirm

Display:

✓ Bug report created: intake/pending/bugs/BUG-NNN.md
  Title: [title]
  Severity: [severity]

Next: /vt-d-triage-bugs  to promote to the bugs/ backlog