Repository navigation
feat(journeys): investigate diagnoses the journey step that breaks first - #12
Merged
Merged
Conversation
…est think time and compare
# Conflicts: # CHANGELOG.md # README.md # cli/src/prescale_cli/commands/run.py # cli/src/prescale_cli/journeys/load.py # cli/src/prescale_cli/journeys/replay.py # cli/src/prescale_cli/loadtest.py # cli/src/prescale_cli/render.py # cli/src/prescale_cli/schema/result.schema.json # cli/tests/test_journeys_load.py
…sive rows, escaped cells
# Conflicts: # CHANGELOG.md # README.md
…es, 4xx under load, steady baseline
…ording, jsonschema in dev
|
Preview deployment for your docs. Learn more about Mintlify Previews.
💡 Tip: Enable Automations to automatically generate PRs for you. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #11. The base is #11's branch, so the diff shows only this slice. It gets retargeted to
mainonce #11 merges.prescale runon journeys says which step breaks first. Nowprescale investigatesays why, and what to do about it. With journeys inprescale/journeys/,investigate:rundoesHow it works (
journeys/diagnose.py):--max-rps. It uses the median below 20 samples. Below 5 samples there's no baseline, and the evidence says so.investigate's existingclassifyandremediate, so a journey step and a URL route get the same diagnosis for the same evidence. No model is involved.--fail-undergates on the combined number.unexpected_answer: a step that answers an unexpected 4xx or loses an extract under load (users conflicting over shared data, or sessions failing). It's no longer misread as a pool or a queue.The
investigationfield gainsculprit_journey,culprit_stepandinterference. These are additive;schema_versionstays 1. Newinvestigateflags, the same asrun's:--journey,--no-combined,--urls,--allow-writes,--dir.runandcinever diagnose, sincediagnosedefaults to false.How it was verified
examples/fragile-shop.py, three times:connection_pool, high confidence, checkout step 3 "place order", every time--jsonstdout is the Result alone and validates againstresult.schema.json--fail-under 200exits 1test_journeys_diagnose.py, 17 new):investigate --jsonabove, against the real example shop (started by the test)runadds noinvestigationunexpected_answer--max-rpspacing of the 1-user replays--fail-undergating on the combined number--urlsand--pathstill taking URL moderuff check cli/src: clean ·pytest cli/tests -q: 346 passed.Risk
Tier: risky.
Public surface:
investigationgains fieldsbottleneck_classvalue,unexpected_answer. The dashboard shows class names as-is, so it needs no change.investigateflagsinvestigatenow tests journeys.--urlsrestores the old behaviour.jsonschemaadded to thedevextrasRollback: revert. Nothing stored by older versions changes meaning.
Fresh-context review: the first pass said fix first. Its blocker was that journeys that held alone but broke together printed "Held up — nothing to diagnose". It also had five should-fixes:
--max-rpsignoredAll are fixed. The re-review said ok to ship. Its three small should-fixes are also done:
--fail-undercounts a break that only happens togetherjsonschemaas a dev dependency, so the schema check never silently skipsNotes for review
prescale ci), MCP and the HTML report, plus a paste-ready fix prompt for coding agents.gunicornserver header adds "increase --workers" even for pool problems.Generated by Claude Code