World’s largest virtual agentic engineering & quality conference
Route a production signal through a coding agent and Kane CLI to auto-author a reproduction test, verified against a real browser and committed before the incident review starts.
Sparsh Kesari
Author

Harshit Paul
Reviewer
Last Updated on: July 20, 2026
The error was in your logs for six hours before anyone noticed. A customer hit a broken checkout, the 500 landed in your telemetry, and it sat there while the team shipped three more builds on top of it. By the time someone reproduced it by hand, wrote a test, and merged the fix, the incident was a day old and the postmortem action item, "add a regression test," was already sliding to the next sprint.
The log knew at minute one. The suite did not learn until the next day. That gap is where reproduction work lives, and it is almost always manual: read the log, guess what the user did, click through it in a browser, translate the flow into selectors, and only then have a test. This post closes that gap. You route the production signal into a coding agent and Kane CLI, TestMu AI's deterministic browser agent, and a reproduction test gets authored, verified against a real browser, and committed, before the incident review even starts.
Overview
What does it mean to turn a log into a test?
Routing a production signal, an error log, a telemetry event, or an incident, through a coding agent that writes a Kane CLI objective, which drives a real browser and returns a hard pass or fail. The confirmed reproduction is committed as a permanent test.
Why can't traditional automation do this?
A log describes intent, a user tried to check out and got a 500. A Selenium script is a list of selectors. Bridging the two by hand is the slow step. Kane CLI takes intent as input, so the bridge collapses.
What signals work best?
A signal with a URL and a clear user action reproduces well. A bare stack trace with no user context reproduces poorly, because no tool can invent the steps a user took from a server error alone.
What do you end up with?
A regression suite grown entirely from real failures, the bugs that actually reached production, logged to TestMu AI Test Manager and re-run on every build.
Traditional automation assumes the same input produces the same output, and that a test is a list of selectors. A production log breaks both assumptions about what the bridge needs.
This is the same non-determinism problem that testing AI applications runs into from the other direction: the interesting behavior is described in intent, and asserting exact strings misses it. The fix is a tool whose input is intent and whose output is a hard verdict.
Kane CLI takes a natural-language objective and drives a real Chrome browser. In agent mode, it returns newline-delimited JSON, one event per line, ending in a terminal result with a binary verdict and a standard exit code.
That single property, intent in and verdict out, is what makes a log-to-test bridge practical. The coding agent handles the messy translation from log to objective, where being adaptive is an asset. Kane CLI handles whether the test passed, where being deterministic is the whole point. You never want the tool that decides whether to pass or fail to be the creative one.
The loop turns an incident into a test, moving Signal to Objective to Verdict to Gate:
The whole loop runs in the time it takes an agent to read a log and a browser to load a page. It is the same closed-loop idea behind loop engineering with Kane CLI, pointed at production signals instead of a coding agent's own output.
Install the CLI and set credentials:
npm install -g @testmuai/kane-cli
export LT_USERNAME="..." LT_ACCESS_KEY="..."Keep a secrets file for test data, never real customer values:
{
"card_number": { "value": "4242424242424242", "secret": true },
"test_email": { "value": "qa+checkout@example.com" }
}One rule throughout: a log tells you the shape of a user action, not the values to replay. Reproduce with synthetic data and test accounts. Never route real PII or real credentials out of a production log into a test.
Note: Kane CLI starts free on your local Chrome, so you can run the first three scenarios below without touching your cloud plan. Try Kane CLI free.
The scenarios below build from trivial to enterprise. Each adds one capability, so by the end you have seen assertions, variables, staged state, SSO with MFA, database verification, and the full agentic loop.
The simplest case. Your error tracker reports a 500 on a specific route.
Signal:
[error] 500 on GET /pricing | trace_id=a1b2c3Distilled objective:
go to https://app.example.com/pricing,
assert the page loads without a 500 or error banner,
assert the pricing table is visibleRun:
kane-cli run "go to https://app.example.com/pricing, assert the pricing table is visible, assert no error banner" --agent --headlessIf it fails, you have reproduced the outage against a real browser, with a video and a network capture, in seconds. If it passes, the failure was transient or state-dependent, and you know to look at load or data conditions rather than the route itself.
Now the log points at a user journey, not a single page. A checkout error is the classic example.
Signal:
{ "url": "/checkout", "action": "place order", "expected": "confirmation",
"observed": "spinner hangs, 500 in network tab" }Distilled objective:
go to https://app.example.com/checkout,
add a Visa test card ending 4242,
click Place Order,
assert the order confirmation page loads,
assert no error message is visibleRun with test data injected:
kane-cli run "go to https://app.example.com/checkout, fill card with '{{card_number}}', click Place Order, assert order confirmation loads" \
--variables-file ./secrets.json --agent --headlessBecause Kane CLI resolves elements by intent rather than brittle selectors, this same objective keeps reproducing the bug after the checkout UI is redesigned, which matters once the test lives in your suite for months.
Harder. The incident only affects users in a specific state, say, accounts with an expired trial. The log carries that context, and the objective has to set it up.
Signal:
{ "url": "/dashboard", "segment": "trial_expired",
"action": "click Upgrade", "observed": "Upgrade button disabled, no path forward" }Distilled objective, split into stages:
Stage 1: log in as a trial-expired test account,
go to the dashboard,
assert the trial-expired banner is visible
Stage 2: click Upgrade,
assert the upgrade plan selection page opens,
assert the Upgrade button is not disabledSplit conditional setups into stages. Kane CLI holds browser state across objectives in a session, so stage 1 establishes the condition and stage 2 tests the behavior. This is how you reproduce "only happens when" bugs that a single flat script cannot express.
Enterprise incidents often land behind a login wall, on internal tools where the failing flow is three menus deep, and the account is SSO-protected with MFA. A flat script chokes on the SAML round-trip; this workflow does not.
Signal:
{ "app": "servicenow", "url": "/incident/new", "auth": "Okta SSO + TOTP",
"action": "submit incident with attachment",
"observed": "Submit spins, attachment never uploads" }Distilled objective, auth first:
Stage 1: log in via Okta SSO using the test account,
complete TOTP from the provided secret,
assert the ServiceNow home loads
Stage 2: open a new incident,
attach the sample file,
click Submit,
assert the incident number is displayed,
assert no upload error is shownTwo enterprise-specific points. Kane CLI holds the authenticated session across stages, so you authenticate once and test the deep flow after. And MFA is not a blocker: KaneAI supports TOTP natively, so a test account protected by an authenticator app can be driven with the TOTP secret your IT team issues for that account. Internal apps built on nested menus and shadow DOM resolve by intent rather than by selectors that break every release.
In regulated software, reproducing the UI failure is only half the job. You also have to confirm the data behind it, and do it without touching real customer records.
Signal:
{ "app": "retail-banking", "url": "/transfer", "segment": "joint_account",
"action": "transfer between own accounts",
"observed": "UI shows success, balance does not update" }Distilled objective with a data assertion:
log in as a joint-account test user,
go to Transfers,
transfer 100 from Checking to Savings,
assert the confirmation shows 'Transfer complete',
store the displayed Savings balance as 'ui_balance'The UI half reproduces the "looks successful but isn't" bug directly, the most dangerous class in finance because the happy path lies. For the data half, KaneAI can run a database step to query the backing store and assert the persisted balance matches the value shown on screen, catching the exact gap between what the interface claims and what actually committed.
Every value here is synthetic: a test joint account, a test transfer, a staging database. Regulated flows are precisely where you must never replay real balances, real PII, or real credentials from a production log.
The complex case ties it together: an incident lands, a coding agent translates it, Kane CLI verifies it, and a confirmed reproduction is committed, all without a human writing the test.
Agent-side pseudocode:
on new incident:
ctx = extract(incident) # url, action, expected, observed
objective = to_objective(ctx) # LLM turns intent into a Kane CLI objective
result = run kane-cli(objective, "--agent --headless")
if result.status == "failed": # reproduced
open_pr(objective, result.share_link)
else:
comment(incident, "not reproducible from this path; needs state or data")The agent parses Kane CLI's NDJSON output, reads the terminal run_end verdict and exit code, and branches on it. A reproduced bug becomes a pull request with the objective and a link to the run. A non-reproduction becomes a note back on the incident itself, a useful signal: the bug depends on something the log did not capture.
In CI, the promoted test gates every future build:
- name: Reproduction suite
run: kane-cli run-suite ./tests --agent --headlessThe incident that reached one customer becomes a check that blocks it for all of them. The same idea, wired into a pull request, is how teams keep Kane CLI CI/CD-ready without a second framework.
The same Kane CLI syntax runs on your laptop and in CI, so a reproduction you confirm locally becomes a pipeline gate with no rewrite. You can see the worked examples in the Kane CLI repository.
The instinct is to have an engineer read the log, click through the flow, and write a test by hand. It works for one incident. It does not work for the volume real systems produce, and it front-loads the slowest step onto your most expensive people.
| Manual reproduction | Agent + Kane CLI loop | |
|---|---|---|
| Who writes the test | An engineer, per incident | A coding agent, from the log |
| Speed | Hours, often next sprint | Minutes, before the review |
| Resilience | Selectors break on redesign | Intent-based, survives UI change |
| What accumulates | A backlog of "add a test later" | A suite grown from real failures |
Automated reproduction flips the constraint. The agent does the translation, Kane CLI does the verification, and the reproduction that proves the bug is the same artifact that guards against it.
The quiet payoff is what accumulates. Each reproduction you confirm is logged to Test Manager when authenticated, so every incident the loop touches leaves a permanent test behind. The bug that paged you on Tuesday becomes a check that runs on every build after, without anyone deciding to write it.
Production logs are usually forensic evidence you read after the fact. Routed through a coding agent and Kane CLI, they become the raw material for a suite that grows itself from real failures. The signal that told you something broke becomes the test that stops it breaking again.
Start small: take one recent incident with a clear user action, distill it to an objective, and run it through Kane CLI on your local browser. Confirm the reproduction, commit it, and wire the runner into CI so every future build is re-validated. The reproduction test you would have written next sprint already exists.
Note: Turn your next incident into a permanent test. Start free on local Chrome, then read the setup for agent mode and CI. Read the Kane CLI docs.
Author
Sparsh Kesari is a community contributor with 3+ years of experience in developer relations, open-source engineering, and automation-focused tooling. At TestMu AI, he works as a Senior Developer Relations Engineer, supporting developer communities and contributing to initiatives around cross-browser testing, KaneAI, and HyperExecute. Sparsh has hands-on experience building and maintaining automation scripts, open-source projects, and developer platforms, with a strong background in JavaScript, Node.js, Docker, and cloud-native workflows. He holds a Bachelor’s degree in Computer Science.
Reviewer
Harshit Paul is Director of Product Marketing at TestMu AI (formerly LambdaTest), with over 8 years of experience in product and growth marketing for developer and QA tools, leading the Agentic AI in Quality Engineering space. He has authored 80+ technical articles for TestMu AI on software testing and automation, and hosted webinars on Selenium, automation testing, browser compatibility, DevOps, and continuous testing. He has led go-to-market and technical marketing initiatives across software testing products, contributing to SEO, content strategy, and developer marketing. He began his career as a certified Salesforce developer at Wipro Technologies, where he worked for 2 years before moving into marketing. Harshit holds a degree in computer programming from Vivekananda Institute of Professional Studies.
Did you find this page helpful?
More Related Blogs
TestMu AI forEnterprise
Get access to solutions built on Enterprise
grade security, privacy, & compliance