fix(rectification): exhaustion exit, explain layer, range reading, unknown-time scan (BUG-565–568)
Independent Staging Quality Gate / validate (push) Successful in 9m20s
Independent Staging Quality Gate / publish (push) Successful in 6m51s

Keep askable cards after exhaustion, explain each probe, read the adopted credible range in reports and chat, and compare declared periods before the minute grid when the clock is unknown.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Jesse_Chen
2026-09-07 09:10:37 +08:00
parent 43a26a3ccb
commit 814c924e4a
91 changed files with 5362 additions and 224 deletions
+6 -2
View File
@@ -96,7 +96,11 @@ def _candidate_datetimes(request: RectificationEventRequest) -> list[datetime]:
minute_count = int((end - start).total_seconds() // 60) + 1
if minute_count < 1 or minute_count > 1_440:
raise RectificationEventCalculationError("candidate_range_out_of_bounds")
return [start + timedelta(minutes=offset) for offset in range(minute_count)]
raw_step = request.get("minute_step") if isinstance(request, dict) else None
step = int(raw_step or 1)
if step < 1 or step > 15:
raise RectificationEventCalculationError("minute_step_out_of_bounds")
return [start + timedelta(minutes=offset) for offset in range(0, minute_count, step)]
def _active_vimshottari(
@@ -627,7 +631,7 @@ def _canonical_input_contract(request: RectificationEventRequest) -> tuple[dict,
"candidate_range": {
"start_time": request["start_time"],
"end_time": request["end_time"],
"step_minutes": 1,
"step_minutes": int(request.get("minute_step") or 1),
},
"location": {
"latitude": float(request["lat"]),