Debuggingprompt onlyMedium

Bug Until Reproduced

A systematic debugging loop designed to help developers identify, isolate, and create reliable reproductions of software bugs. This loop iterates through test creation, execution, and analysis until a consistent reproduction of the issue is achieved, enabling effective root cause analysis and resolution.

← all loops
DebuggingTestingBug ReproductionQuality AssuranceRoot Cause Analysis

Goal

Create a reliable and minimal reproduction of a software bug through iterative testing and analysis

How to Run

Iterate through test creation and execution until a bug can be consistently reproduced

  1. 01

    Identify the Bug

    Provide detailed information about the bug, including symptoms, error messages, and affected components

  2. 02

    Run Check Command

    Execute 'repro test' to attempt to reproduce the bug with existing tests

  3. 03

    Inspect Results

    Analyze test output and system behavior to determine if the bug was reproduced

  4. 04

    Refine Tests

    Modify or create new test cases based on analysis to improve reproduction chances

  5. 05

    Repeat Until Exit

    Continue the loop until the exit condition is met: 'Reproduction exists'

Workflow Steps

  1. 01

    Bug Identification

    Analyze user-provided bug description and context to understand the problem space

  2. 02

    Context Gathering

    Collect relevant logs, error messages, recent changes, and environmental factors that may influence the bug

  3. 03

    Test Case Creation

    Develop initial test scenarios aimed at triggering the described bug behavior

  4. 04

    Check Execution

    Run the 'repro test' command with created test cases to observe system behavior

  5. 05

    Result Inspection

    Examine test output, logs, and system state to determine if the bug was successfully reproduced

  6. 06

    Analysis and Refinement

    If not reproduced, analyze failures and refine test cases to better target the bug conditions

  7. 07

    Iteration Decision

    Decide whether to continue iterating or terminate based on iteration count and exit condition

Kickoff Prompt

Start the "Bug Until Reproduced" loop.

Goal: Create a reliable and minimal reproduction of a software bug through iterative testing and analysis
Max iterations: 10
Between iterations run: repro test
Exit when: Reproduction exists


Start the 'Bug Until Reproduced' loop by providing a detailed bug description including error messages, expected vs actual behavior, and any relevant context such as recent code changes or specific conditions that trigger the issue.

Self-pace this loop. After each iteration, run `repro test` and evaluate the output, and only continue if the exit condition is not met (Reproduction exists). Stop when the exit condition passes or 10 iterations are reached. Give a short status update each pass.

Guardrails

hardcoded
  • ·Ensure reproduction steps are minimal and isolated from unrelated code
  • ·Verify that the check command 'repro test' correctly identifies the target bug
  • ·Maintain consistent testing environment and dependencies throughout iterations
  • ·Confirm that each test run actually exercises the suspected bug path
  • ·Stop iteration once a reliable reproduction is confirmed to prevent unnecessary cycles

Flow Diagram

rendering…

Related loops — Debugging