summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-10-01 02:57:15 -0300
committerGabriel Schneider <[email protected]>2026-10-01 02:57:15 -0300
commitb7182d34e12130ced98dee7726b3bc87d4584ca9 (patch)
tree131a87c368994d5c3f37aa0a9f68b06e70831c6d /test
parent0f5773256072b08a1ec294fa63822f63eb6a429b (diff)
downloadpardes-b7182d34e12130ced98dee7726b3bc87d4584ca9.tar.gz
pardes-b7182d34e12130ced98dee7726b3bc87d4584ca9.zip
An open past the session's 64 open records reaches a mount's caller as EMFILE, "Too many open files": pardes re-pins cloud9, whose 9ns maps the words
The refusal's words said too many open files, but 9ns matched none of its needles and handed the shell Input/output error. The re-pinned cloud9's 9ns maps them to EMFILE. selfmount opens the root exec for writing eighty times through the mount and hears EMFILE at the 65th. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'test')
-rw-r--r--test/selfmount.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/test/selfmount.py b/test/selfmount.py
index 503ce1e0..6b9d8740 100644
--- a/test/selfmount.py
+++ b/test/selfmount.py
@@ -196,6 +196,16 @@ def run(binary):
looped.unlink(missing_ok=True)
check(ran == '0' and got_line.startswith('FX') and got_line.rstrip().endswith('Msg ev-loop'),
f'a bash read loop on event reads a whole record ({got_line!r})')
+ # Past the session's 64 open records (write opens of exec take
+ # them too) an open is refused EMFILE, "Too many open files".
+ # (>> here: a truncating open of exec through the mount can
+ # hang, reported, not yet understood.)
+ many = Path(f'/tmp/{name}.many')
+ ran = run((f"timeout 10 bash -c 'for i in $(seq 80); do exec {{fd}}>>{mount}/exec || exit 9; done' 2> {many}; "
+ f"st=$?; echo rc=$st >> {many}; exit $st\n").encode())
+ said_many = many.read_text() if many.exists() else ''
+ many.unlink(missing_ok=True)
+ check(ran == '9' and 'Too many open files' in said_many, f'an open past the 64 records is EMFILE ({ran!r}, {said_many[-80:]!r})')
client.write('/exec', b'Msg still here\n')
text = ''.join(cell[0] for cell in client.screen()['cells'])
check('still here' in text, 'the editor answers after all of that')