feat(practice): flag suspiciously short laps and remove any lap in one click
Practice laps under 85% of the driver's own median (a likely shortcut) are flagged: counted, but never a best lap, record or training stat until approved. Timing and Race Day get a one-click Approve/Remove panel, overlays show a warning mark, and any lap can be removed or restored from Timing and Judging with undo. Also sends judge corrections straight to the server so its hot-results protection can no longer hold back a correction made right after a passing. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
3cc4fa0845
commit
8601954ea2
24 files changed
+556
-60
No files matched your search
@@ -226,7 +226,8 @@ export function syncTrainingLedger(training, state, { uid }) {
|
||||
(Array.isArray(result?.passings) ? result.passings : []).forEach((passing, index) => {
|
||||
const driverId = String(passing?.driverId || "");
|
||||
const lapMs = Math.round(Number(passing?.lapMs || 0) || 0);
|
||||
if (!driverId || passing?.validLap === false || lapMs <= 500) return;
|
||||
// A suspect practice lap (a likely shortcut) joins the stats only once it is approved.
|
||||
if (!driverId || passing?.validLap === false || passing?.suspect || lapMs <= 500) return;
|
||||
const timestamp = Math.max(0, Number(passing?.timestamp || 0) || 0);
|
||||
const sourceKey = getPassingSourceKey(sessionId, passing, index);
|
||||
current.push({
|
||||
|
||||
Reference in new issue
Block a user