Skip to content

v0.16.2

Choose a tag to compare

@github-actions github-actions released this 20 Nov 12:12
· 6 commits to master since this release

A request queued on an already-connected pooled socket is now on the wire before the step loop is asked to wait, which is the Windows stall that ended the first round after every tool phase in no response for 10000 ms.

A queued request leaves with the queue

nm_request_queue drains a socket that is already CONNECTED in the same call, so it returns READING — or SENDING only for a real would-block on the send buffer or a stale-reuse redial, both events the loop can be woken for (d2e4b1a). The step drives had left a queued request waiting for a writability event: POSIX's level-triggered poll answers that at once, but WinSock's FD_WRITE is edge-triggered — the socket's first connect, or a send that hit WSAEWOULDBLOCK and a later send succeeded — so a pooled socket that connected rounds ago signals nothing, and with nothing sent FD_READ could not fire either. The round then sat until its inactivity deadline, which is what the first request after every tool phase did, because it is the first one on a reused connection. PENDING from the queue is progress, not failure: chat_begin, the one-shot fetch and web_search accept it and let their steps drive it. The blocking drive was never affected — nm_socket_request_send has always been queue + drain.

The case pins the fact, not a delivery instant

test_keepalive gains a case that queues from the pool and asserts the transport's contract before any step: nm_connection_interest reports READ alone, the server finds the request with no client step, and the reply drains on that declared interest (d2e4b1a, 5082620). The case's first version read immediately after the server's passes and treated the would-block as EOF — a loopback send is queued, not instantly visible to the peer's recv, deterministic on Linux and a timing accident on macOS — so it now waits on the interest it asserts and reads again, the shape every production drive has.

The readiness rules are written down

ARCHITECTURE states the rule every step drive rides: a queued request is on the wire before the loop is asked to wait, and PENDING means a genuine would-block or a redial in flight (312c35a). CONTRIBUTING records what was measured on the box — associating an already-connected socket with FD_WRITE records the event then, and a READ recorded under a retired slot's event survives re-association — and the symptom shape a wakeup problem leaves: a round a timeout ends, cleared by the next fresh dial, with keepalive = off the fastest attribution (312c35a, bb1bbbc). The nm_ts_pump trap is recorded beside its siblings: a pump's send is not the peer's readability (bb1bbbc).

Full Changelog

v0.16.1...v0.16.2