fix(host-call): enforce parked execution timeout - #2329
Conversation
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
bashkit | aa47985 | Commit Preview URL | Aug 21 2026, 11:02 PM |
|
Reviewed in depth and rebased onto The blocker
#[cfg(not(all(target_arch = "wasm32", target_os = "unknown")))] // tokio::spawn
#[cfg(all(target_arch = "wasm32", target_os = "unknown"))] // wasm_bindgen_futures::spawn_localBut
wasm-bindgen-futures = "0.4" # not optional, not behind wasm_jsThe PR is also based on a pre- EvidenceI rebased, resolved the conflict the charitable way (made Same command on So this is a real regression, not a rebase artifact. Left un-gated as the PR has it, it is worse: the crate links and the guest imports JS symbols that a no-JS runtime cannot resolve — which the build script's own import check exists to catch. Why this needs a decision, not a patchOn a no-JS wasm runtime there is no executor to spawn onto. That is not a gating oversight; it is fundamental to the approach. You cannot make an execution future progress while the host is parked if nothing is driving it. So one of these has to be chosen:
There is also a second consequence worth calling out independently of wasm: I have the rebase (conflicts resolved, The rest of the PR is good — the Generated by Claude Code |
|
Re-checked this against current The green checkmarks on this PR are misleadingThe head commit has only 7 check runs: That matters because the job which would catch this regression is in # Guards the `wasm_js`-off configuration, which no other job covers: a
# stray JS-backed dependency only shows up as an unresolvable import here.
name: WASM component (no JS, no WASI)So the PR reads as "all checks passed" while the one job designed to catch exactly this class of failure never executed. Please don't take the green state as evidence of mergeability here. The blocker, re-confirmed structurallyNo rebuild needed to confirm it — the configuration on current
Still a design decision, not a patchGating the dependency correctly is mechanical, but it does not resolve the substance: on a no-JS wasm runtime there is no executor to spawn onto, so a spawned driver cannot exist there at all. The three options from the previous comment are unchanged, and I did not pick one unilaterally — each changes a documented contract:
There is also the non-wasm consequence: I did not rebase-and-push, because every version of this still fails the hyperlight job until the design question is settled, and Unrelated but checked in the same pass: advisories are clean — Generated by Claude Code |
Motivation
Description
spawn_localon wasm) so the timeout can elapse even when the host is not pollingnext_event(); implement a completion channel to report results or timed-out drop.Bash) and returning a clear error fromresume()when the request is no longer active.AbortHandleto abort the driver when the handle is dropped, and introducespawn_executionhelpers plus a smallExecutionHandlestate refactor.crates/bashkit/src/host_call.rs,crates/bashkit/tests/integration/host_call_execution_tests.rs,crates/bashkit/Cargo.toml, and docs/knowledge files.Testing
cargo test -p bashkit --test integration host_call_execution_tests -- --nocaptureand the focused timeout testsuspended_host_call_remains_inside_the_execution_timeout, both passed (all host-call lifecycle tests OK).cargo fmt --check,cargo clippy -p bashkit --all-targets -- -D warnings,just check-okf, andjust check-doc-links, all succeeded.rustup target add wasm32-unknown-unknownandcargo check -p bashkit --target wasm32-unknown-unknown, and validated the parallel bench build invocationcargo bench -p bashkit --bench parallel_execution --no-run; these checks succeeded.Codex Task