fix: give a stale trip start no hint before cleanup drops it #827
All Vouch review confidence checks passed
Residual risk 0.14 = Change Risk (0.33) × (1 − Review Confidence (0.57)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.33 · 156 lines diff across 1 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.303
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #827"
general
weight: 0.35
aaronbrethorst
A follow-up to #770, which forgets a trip start that got no report inside the staleness window. The tracker's comment says a first report that comes after a long silence then gets no hint, like any other vehicle with no recent place.
hintchecks a vehicle's previous place against the window on every call, but took a trip start as it found it, and onlycleanupdropped a stale one. cleanup runs once everySTALENESS_THRESHOLD, so a start could be stale for up to another threshold before it went. A first report in that time was placed from the start of the shape, where on a loop or an out-and-back it can take the wrong pass, and the feed's stop fields and deviation were wrong until later reports put them right.hintnow honours a trip start only while it is inside the window, as it does a previous place. cleanup still drops old starts, for memory.Test: a start six minutes old with a five-minute window gives no hint before cleanup has run, and a fresh one still gives the start of the shape. It fails on main; the existing test runs cleanup first, which is why it passed. The suite passes with the database tests, and the tracker tests pass with -race. It changes tracker.go, as #818 does, and the two merge cleanly in either order.