Skip to content

fix(sidecar): stop wasm stdin stream-event flood; tolerate shadow-sync races#210

Merged
NathanFlurry merged 1 commit into
mainfrom
fix/wasm-stdin-flood-and-shadow-races
Jul 2, 2026
Merged

fix(sidecar): stop wasm stdin stream-event flood; tolerate shadow-sync races#210
NathanFlurry merged 1 commit into
mainfrom
fix/wasm-stdin-flood-and-shadow-races

Conversation

@NathanFlurry

Copy link
Copy Markdown
Member
  • Sidecar-managed wasm guests read stdin through the kernel (__kernel_stdin_read), but every host stdin write also emitted a stdin stream event to the guest's V8 session. Nothing consumes those events for wasm, and while the guest thread is blocked in a sync bridge call each one lands in the session's bounded deferred-message queue — one dead event per keystroke, killing the session with "sync bridge deferred message queue exceeded limit of 256" after ~256 keystrokes in an interactive shell. Wasm stdin writes now feed the kernel only.
  • The host-shadow → guest reconciliation walk failed the entire VM when an entry vanished mid-walk or the guest-side path could not receive the write (editor swap-file churn, e.g. vim's .swp/.swo dance). One transient race then poisoned every subsequent fs op on the VM (ls returning i/o errors, vim E212 on write, sessions dying on the next sync). NotFound/ENOENT during the walk is now treated as "entry mid-churn, skip", matching native semantics.

@railway-app railway-app Bot temporarily deployed to secure-exec / secure-exec-pr-210 July 2, 2026 16:50 Destroyed
@NathanFlurry NathanFlurry merged commit 2643e3f into main Jul 2, 2026
2 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant