fix(simulator): try a trip start again when its failure may pass #792
All Vouch review confidence checks passed
Residual risk 0.18 = Change Risk (0.45) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.45 · 404 lines diff across 5 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.359
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #792"
general
weight: 0.35
aaronbrethorst
A follow-up to a note on #327:
drivestopped a vehicle for good on any single error in starting its next trip, so one 503 or one dropped connection cost that vehicle the rest of the run.What I changed:
make smokeagainst a server that fails every start would end with no report sent and exit 0.postJSONandgetJSONreturn thestatusErrorthat login and refresh already did. Their messages read as before.Not handled: a start the server took but whose answer was lost. The second try gets a 409 and the vehicle stops. Before, the lost answer itself stopped it.
Tests:
docs/demo.mdsays what a failed start does now. #746 edits the same file at another line, and the two merge cleanly. The admin session fix for #345's note also touchescmd/simulator/main.go, in other functions, and those two merge cleanly in either order.go fmt, go vet and go test ./... pass, with the database tests (4,658 tests).
<!-- This is an auto-generated comment: release notes by coderabbit.ai -->
<!-- coderabbit-ai-generated:v1 -->
Summary by CodeRabbit
Bug Fixes
Simulator vehicle starts now retry temporary network failures, rate limits, and server errors. The wait increases from one second up to 30 seconds while failures continue, and resets after a successful start. Permanent errors still stop the run without retrying.
If a run ends while a vehicle start is still failing, the simulator reports that failure.
Documentation
* Updated the simulator guide to describe retry timing and how an unresolved start failure is handled when a run ends.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->