Stream: git-wasmtime

Topic: wasmtime / PR #13933 check for and return WASIp2 UDP sock...


view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 13:41):

dicej opened PR #13933 from dicej:p2-send-to-closed-receiver to bytecodealliance:main:

This addresses a failing Tokio test where receiving on a connected socket whose remote has disconnected after sending should return an error immediately.

Note that I've implemented the simplest thing that could work, possibly at a cost to performance. A more sophisticated alternative could be to update the Pollable impl for IncomingDatagramStream to check the tokio::io::Ready for "error" readiness and only call tokio::net::UdpSocket::take_error in that case.

<!--
Please make sure you include the following information:

Our development process is documented in the Wasmtime book:
https://docs.wasmtime.dev/contributing-development-process.html

Please ensure all communication follows the code of conduct:
https://github.com/bytecodealliance/wasmtime/blob/main/CODE_OF_CONDUCT.md
-->

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 13:41):

dicej requested pchickey for a review on PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 13:41):

dicej requested wasmtime-wasi-reviewers for a review on PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 13:41):

dicej requested wasmtime-core-reviewers for a review on PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 14:14):

:thumbs_up: alexcrichton submitted PR review.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 14:15):

alexcrichton added PR #13933 check for and return WASIp2 UDP socket errors when receiving to the merge queue.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 14:47):

github-merge-queue[bot] removed PR #13933 check for and return WASIp2 UDP socket errors when receiving from the merge queue.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 16:08):

github-actions[bot] added the label wasi on PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 16:48):

dicej commented on PR #13933:

Ah, the Windows test failures are not unexpected, given https://github.com/tokio-rs/tokio/blob/bc0933ccffb62e010d3ccb497abc22cec2e73f54/tokio/tests/udp.rs#L79-L85

I'll update the code to turn ConnectionReset into ConnectionRefused on Windows in the host implementation of udp-socket.receive unless someone has a better idea.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 16:49):

dicej commented on PR #13933:

Or maybe just update the tests to match what Tokio does? I don't know how important it is to have consistent behavior across host platforms for a situation like this.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 16:54):

dicej updated PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 16:54):

dicej has enabled auto merge for PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 17:04):

dicej added PR #13933 check for and return WASIp2 UDP socket errors when receiving to the merge queue.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 17:32):

alexcrichton commented on PR #13933:

Yeah I think updating to expect a number of error codes is fine

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 17:40):

github-merge-queue[bot] removed PR #13933 check for and return WASIp2 UDP socket errors when receiving from the merge queue.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 22 2026 at 17:57):

dicej commented on PR #13933:

Ugh, now the MSVC builds pass but the MinGW one fails. Wonder if I'm going to need to borrow my wife's Windows laptop :sob:

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 13:53):

badeend commented on PR #13933:

@dicej Does the problem persist after yesterday's changes?

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 14:02):

dicej commented on PR #13933:

@badeend I'll rebase and find out when I get a chance.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 14:11):

dicej updated PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 14:24):

dicej added PR #13933 check for and return WASIp2 UDP socket errors when receiving to the merge queue.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 14:48):

github-merge-queue[bot] removed PR #13933 check for and return WASIp2 UDP socket errors when receiving from the merge queue.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 15:04):

dicej commented on PR #13933:

@badeend looks like your changes are at least as good as mine as far as making the new tests pass, but we're still seeing timeouts for the MinGW build (and a new C API failure on Windows, the cause of which is not obvious to me). I'll see if I can reproduce and debug when I get a chance (and access to a Windows machine).

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 22:00):

dicej updated PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 22:06):

dicej updated PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 22:08):

dicej has enabled auto merge for PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 22:16):

dicej added PR #13933 check for and return WASIp2 UDP socket errors when receiving to the merge queue.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 22:41):

github-merge-queue[bot] removed PR #13933 check for and return WASIp2 UDP socket errors when receiving from the merge queue.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 22:52):

dicej added PR #13933 check for and return WASIp2 UDP socket errors when receiving to the merge queue.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 23:16):

:check: dicej merged PR #13933.

view this post on Zulip Wasmtime GitHub notifications bot (Jul 23 2026 at 23:16):

dicej removed PR #13933 check for and return WASIp2 UDP socket errors when receiving from the merge queue.


Last updated: Jul 29 2026 at 05:03 UTC