fix(native-sidecar): stop stranding child process.fd_read on mapped fds#1814
Conversation
Last instance of the class fixed in the mapped-host-fd work: a guest-supplied fd was stat'ed against the kernel fd table with a bare `?`, but mapped host fds live in the per-process map. The resulting EBADF escapes to the process-event pump and strands the in-flight sync RPC, so the guest blocks until the ~31s bridge deadline. The sibling process.fd_write arm already converted its errors into a delivered RPC error; this one did not. Adds the regression test the class never had. crash_isolation.rs previously covered only a guest THROWING, which never reaches the sidecar's own error paths and so could not catch either production failure. The new phase drives a host-backed write beside a peer VM and asserts both properties: - it completes within the collector's deadline (catches the 31s hang; a test that only checked eventual success would pass while hanging, which is exactly how that failure went unnoticed), and - the peer VM still executes afterwards (catches the cross-tenant crash). Verified by negative control that the new phase actually executes rather than silently passing.
This was referenced Jul 20, 2026
Member
Author
This was referenced Jul 20, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Last instance of the class fixed in the mapped-host-fd work: a guest-supplied
fd was stat'ed against the kernel fd table with a bare
?, but mapped hostfds live in the per-process map. The resulting EBADF escapes to the
process-event pump and strands the in-flight sync RPC, so the guest blocks
until the ~31s bridge deadline. The sibling process.fd_write arm already
converted its errors into a delivered RPC error; this one did not.
Adds the regression test the class never had. crash_isolation.rs previously
covered only a guest THROWING, which never reaches the sidecar's own error
paths and so could not catch either production failure. The new phase drives
a host-backed write beside a peer VM and asserts both properties:
that only checked eventual success would pass while hanging, which is
exactly how that failure went unnoticed), and
Verified by negative control that the new phase actually executes rather
than silently passing.