Find the Commit That Broke a Request
Binary-search your git history to isolate the first bad commit — like git bisect, but for production behaviour.
Scenario: a request that was passing last week is now failing. You have 40 commits between a known-good state and now.
Step 1 — Find the failing request ID
$ flux tail --filter status=500
POST /signup 500 44ms req:550e8400
Step 2 — Run bisect
$ flux bug bisect --request 550e8400
Bisecting 42 commits (2026-03-01..2026-03-10)…
Testing abc123… ✔ passes
Testing fde789… ✔ passes
Testing def456… ✗ fails
FIRST BAD COMMIT
def456 "feat: add retry logic to stripe.charge"
2026-03-08 alice@example.com
Bisect re-runs the request input from the execution record against your code at each commit, checking out each in binary search order. It stops at the first commit where the request outcome changed from passing to failing.
Step 3 — Confirm what changed
$ flux trace diff abc123:550e8400 def456:550e8400
SPAN COMMIT abc123 COMMIT def456
──────────────────────────────────────────────────────
stripe.charge 68ms ✔ → timeout (10s) ✗
The diff confirms exactly which span changed behaviour between the last good commit and the first bad one.
Bisect options
# Search a specific commit range
$ flux bug bisect --request 550e8400 --since 2026-03-01 --until 2026-03-10
# Bisect against a different environment
$ flux bug bisect --request 550e8400 --env staging
# Use a specific pass/fail criterion instead of status code
$ flux bug bisect --request 550e8400 --fail-if "span.stripe.charge.duration > 5000"
How bisect works
- Reads the
request_inputfrom the execution record (550e8400) - Checks out each commit in binary search order
- Re-runs the request input against the code at that commit in an isolated sandbox
- Compares the response status and span tree signature to determine pass/fail
- Continues until it isolates the first failing commit
Bisect requires your project to be a git repository with flux auth configured. It does not deploy to production — it runs in an isolated build environment per commit.
Requirements
- Git repository with commit history covering the regression window
FLUX_API_KEYwith CI scope (flux auth ci)- The failing request must have an execution record within the retention window