From aa9762d6543fb6d41bdd3243337277ebe28fe5f4 Mon Sep 17 00:00:00 2001 From: Matias Palma Date: Sat, 18 Apr 2026 23:13:30 -0400 Subject: [PATCH] fix: remove activePtyPath short-circuit that blocked pty respawn under strict mode --- apps/desktop/src/components/Terminal.tsx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/apps/desktop/src/components/Terminal.tsx b/apps/desktop/src/components/Terminal.tsx index 49d2be3b..827ca510 100644 --- a/apps/desktop/src/components/Terminal.tsx +++ b/apps/desktop/src/components/Terminal.tsx @@ -16,7 +16,6 @@ const Terminal: React.FC = () => { const xtermRef = useRef(null); const fitAddonRef = useRef(null); const initialized = useRef(false); - const activePtyPath = useRef(undefined); // tracks last spawned path // 1. Initialize Xterm once on mount useEffect(() => { @@ -97,10 +96,6 @@ const Terminal: React.FC = () => { const targetPath = terminalPath || rootPath || undefined; - // Skip if we're already running a PTY for this exact path - if (activePtyPath.current !== undefined && activePtyPath.current === targetPath) return; - activePtyPath.current = targetPath ?? null; - let isCanceled = false; let unlisten: (() => void) | undefined;