From 0ff0f27e222633c97ba4291f6b9be4137002ca84 Mon Sep 17 00:00:00 2001 From: Can Celik Date: Mon, 21 Sep 2026 00:29:45 +0300 Subject: fix: preserve session layouts across shutdown and restore failures (#4400) * fix: preserve session layouts across shutdown and restore failures refs #4320 * test: update subscription fixture for pane restore errors --------- Co-authored-by: JJ Liebig --- src/terminal/runtime.rs | 4 ++++ src/terminal/state.rs | 2 ++ 2 files changed, 6 insertions(+) (limited to 'src/terminal') diff --git a/src/terminal/runtime.rs b/src/terminal/runtime.rs index a10bec78..7d5542a6 100644 --- a/src/terminal/runtime.rs +++ b/src/terminal/runtime.rs @@ -562,6 +562,10 @@ impl TerminalRuntime { self.0.cwd() } + pub fn cwd_for_persistence(&self) -> Option { + self.0.cwd_for_persistence() + } + pub fn follow_cwd(&self) -> Option { self.0.follow_cwd() } diff --git a/src/terminal/state.rs b/src/terminal/state.rs index 7ceaede7..c084b034 100644 --- a/src/terminal/state.rs +++ b/src/terminal/state.rs @@ -148,6 +148,7 @@ pub struct TerminalState { recent_agent_process_exit: Option, agent_process_acquisition_pending: bool, pub pending_agent_resume_plan: Option, + pub restore_error: Option, } impl TerminalState { @@ -183,6 +184,7 @@ impl TerminalState { recent_agent_process_exit: None, agent_process_acquisition_pending: false, pending_agent_resume_plan: None, + restore_error: None, } } -- cgit v1.2.3