@@ -26,6 +26,8 @@ pub(super) struct RestoredReloadInput {
2626 pub todo_confidence_spike_challenged : bool ,
2727 pub last_todo_ownership_fingerprint : Option < String > ,
2828 pub final_response_todo_fingerprint : Option < String > ,
29+ pub last_auto_poke_fingerprint : Option < String > ,
30+ pub auto_poke_attempts : u8 ,
2931}
3032
3133impl App {
@@ -264,6 +266,7 @@ impl App {
264266 && !self . todo_confidence_spike_challenged
265267 && self . last_todo_ownership_fingerprint . is_none ( )
266268 && self . final_response_todo_fingerprint . is_none ( )
269+ && self . last_auto_poke_fingerprint . is_none ( )
267270 {
268271 // Nothing to save, but a stale file from an earlier run could
269272 // still hold old queued messages/input. Leaving it behind would
@@ -357,6 +360,8 @@ impl App {
357360 "todo_confidence_spike_challenged" : self . todo_confidence_spike_challenged,
358361 "last_todo_ownership_fingerprint" : self . last_todo_ownership_fingerprint,
359362 "final_response_todo_fingerprint" : self . final_response_todo_fingerprint,
363+ "last_auto_poke_fingerprint" : self . last_auto_poke_fingerprint,
364+ "auto_poke_attempts" : self . auto_poke_attempts,
360365 } ) ;
361366 let _ = std:: fs:: write ( & path, data. to_string ( ) ) ;
362367 }
@@ -613,6 +618,15 @@ impl App {
613618 . get ( "final_response_todo_fingerprint" )
614619 . and_then ( |v| v. as_str ( ) )
615620 . map ( str:: to_owned) ,
621+ last_auto_poke_fingerprint : value
622+ . get ( "last_auto_poke_fingerprint" )
623+ . and_then ( |v| v. as_str ( ) )
624+ . map ( str:: to_owned) ,
625+ auto_poke_attempts : value
626+ . get ( "auto_poke_attempts" )
627+ . and_then ( |v| v. as_u64 ( ) )
628+ . unwrap_or ( 0 )
629+ . min ( u8:: MAX as u64 ) as u8 ,
616630 last_todo_ownership_fingerprint : value
617631 . get ( "last_todo_ownership_fingerprint" )
618632 . and_then ( |v| v. as_str ( ) )
@@ -646,6 +660,8 @@ impl App {
646660 todo_confidence_spike_challenged : false ,
647661 last_todo_ownership_fingerprint : None ,
648662 final_response_todo_fingerprint : None ,
663+ last_auto_poke_fingerprint : None ,
664+ auto_poke_attempts : 0 ,
649665 } )
650666 }
651667
0 commit comments