dicej requested alexcrichton for a review on PR #12360.
dicej requested wasmtime-core-reviewers for a review on PR #12360.
dicej opened PR #12360 from dicej:fix-component-async-test-ready-interface to bytecodealliance:main:
This changes the
readyinterface used bycomponent-async-testsfrom:interface ready { // Set the `ready` state set-ready: func(ready: bool); // Block until `ready` is `true` when-ready: async func(); }to:
interface ready { resource thing { constructor(); set-ready: func(ready: bool); when-ready: async func(); } }The problem with the original version was that it required global state and thus caused cross-talk across concurrent tasks. Due to implementation details inside Wasmtime, the tests worked anyway, but
https://github.com/bytecodealliance/wasmtime/pull/12357 perturbed that and revealed how fragile tests based on that interface were.The new version puts the state inside a resource type, allowing each task create its own instance of that resource type and thereby avoid crosstalk.
<!--
Please make sure you include the following information:
If this work has been discussed elsewhere, please include a link to that
conversation. If it was discussed in an issue, just mention "issue #...".Explain why this change is needed. If the details are in an issue already,
this can be brief.Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.htmlPlease ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->
alexcrichton submitted PR review.
dicej added PR #12360 make async tests using ready interface more robust to the merge queue.
dicej merged PR #12360.
dicej removed PR #12360 make async tests using ready interface more robust from the merge queue.
Last updated: Jan 29 2026 at 13:25 UTC