PM ruling: drop the 4th and 5th tries (1095, 1155) from the test_ev13 T26
goldens T20-beside and T20-inside. test_ev59 gains T13e (a give-up never
blocks _undo, abandon or _begin), N8 and N10, and the fails-at-select and
fails-at-timeout asserts that kill mutant M12.
Co-Authored-By: Claude <noreply@anthropic.com>
A refused phase-change close ended its sequence with one `_failed`, so the
same value got 5 tries (3 closes, then 2 on the normal path). Manual now
counts the not-taken closes of the value owed since the last user change
(`_close_k`); at the capped close end `fails` = that count, so `gave_up` and
CHARGER_REFUSED come at the 3rd refused close, and a value changed during the
retries still gets 3 tries. SolarWriter overrides the end hook and is
unchanged (EV-60).
Tests: new test_ev59.py; test_ev56 T5, T5b and the T20 T5 [R] golden,
test_ev28 T15 and the test_ev13 T13 text per the brief rulings.
Co-Authored-By: Claude <noreply@anthropic.com>
ManualWriter._write catches an Exception from drv.write_current (not CancelledError) and returns False, so every caller in Manual and Solar counts it as a refused try: RETRY_S spacing, MAX_TRIES, CHARGER_REFUSED. The tracker is not told (Q2). One ERROR record per raised value, armed again by another value, a taken write, a user change or the charger's return (Q1, G2). Shutdown writes (abandon, release) pass strict and keep base's behaviour (F3, H1, G3); the peak cut path keeps EV-54's (G1). test_ev13 T13: fails is 1 now (Q2). New test_ev56.py.
Co-Authored-By: Claude <noreply@anthropic.com>
The exemption now applies whenever Solar is not live (also just after Solar
is chosen under a verdict Manual's refusals left), so Solar writes its 0 A
over the other current first and then the start rule runs. EV-13
T14 [8 A], T17 and T18 now assert that the energy meter does not flag the
frozen figure (PM accepted the trade-off); T14 [6 A] that it flags at +57 s.
Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VSY9UpTaUYnjJF5oVtbM1w
SPIKE-06 option 2 (PM decision). The stuck check's baseline is the reading
before the send, for accepted and refused writes; it clears on any change
from it (3a17012's power rules removed), so the race cannot arm it (C10,
C11, C13). Frozen power under an accepted write is left to the energy meter
and the read-back cap (EV-13 T14/T17/T18 changed). Once Solar's own 0 A
stands, a stuck verdict no longer blocks the start rule (C12), at most
MAX_TRIES starts per verdict, then CHARGER_REFUSED until Solar is pressed.
Rows in test_ev20_rig.py section 6.
Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VSY9UpTaUYnjJF5oVtbM1w
An accepted write keeps the car's power from the reading before the send
(begin_write); a later reading whose power differs from it, or that shows a
paused car (not charging, under PAUSED_W), clears the armed check. A refused
write's first sample after the send is not life by itself (EV-36). EV-13 T7/T8
and the refusal-window row get two-change variants so mutant M3 stays killed.
DECISIONS records the arming rule.
Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VSY9UpTaUYnjJF5oVtbM1w
A phase that drops out or comes back shifted the compressed current_a tuple and
read as life, so a frozen charger never armed. ChargerReading.phase_a keeps
L1/L2/L3 with None for a missing phase and the life test uses it.
Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VSY9UpTaUYnjJF5oVtbM1w
A refused write on a live charger no longer reads as a stuck reading 60 s
later, so a refused write shows one amber row (charger_refused). A frozen
charger still arms and is still caught.
Co-Authored-By: Claude <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VSY9UpTaUYnjJF5oVtbM1w