From 3aa24c27c62c740cd7647831d0a14a9b180992da Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Thu, 1 Oct 2026 10:04:23 -0300 Subject: An exec or Tty from a pane whose directory is a peer's path refuses before making any pane: `exec: : no such directory`, no `exit 127` pane left A peer's directory (`/n/peer/x`) is no directory on this host, where the shell starts, so a command there ran in a pane that could only say `(pwd) exit 127`, and a Tty made a new/del pair. missingDir now counts such a path missing, as it does a local directory that is not there. Co-Authored-By: Claude Opus 5.5 --- test/fs.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'test') diff --git a/test/fs.py b/test/fs.py index 0e1e44df..424a67e2 100644 --- a/test/fs.py +++ b/test/fs.py @@ -467,6 +467,16 @@ def run_file(binary): with tempfile.TemporaryDirectory() as directory: root = Path(directory) with session(binary, root, 'run') as (client, address): + # From a pane on a peer's path no command or terminal starts: + # refused before any pane is made, no `exit 127` pane left. + peer = new_pane(client, b'') + client.write(f'/pane/{peer}/name', b'/n/nosuchpeer/d/f.txt\n') + count = len(client.read('/index').splitlines()) + execute_refused(client, peer, 'ls', 'no such directory') + execute_refused(client, peer, 'Tty', 'no such directory') + assert len(client.read('/index').splitlines()) == count, client.read('/index') + assert b'exit 127' not in client.read('/log') + client.remove(f'/pane/{peer}') client.write('/exec', b'Shell bash\n') client.write('/exec', b'Tty\n') term = int(max(r.split()[0] for r in client.read('/index').splitlines() if r.split()[1] == b'term')) -- cgit v1.3