Files
nim-chronos/tests
Etan Kissling 44742adbf1 Revert "Always report Event.Error to both read/write callbacks" (#700)
#672 has a regression, triggering a latent bug on kqueue (macOS / BSD) backend, as kqueue does not deduplicate events per fd, i.e., {Read, Error} and {Write, Error} are separately reported, leading to the read callback being called multiple times. If the first read callback unregisters the reader, the second copy will still execute, triggering downstream problems.

This PR initially tried to solve the footgun (deduplicate in the kqueue engine), then tried to fix the failing caller (stream.nim if {TransportState.Closed, ReadPaused} * transp.state == {}:), but now that the blame is shifted to #672 it's better to revert that one (restoring the flaky CI that it attempted to fix), and rely on the kqueue backend never emitting {Error} alone (so the callback is not called spuriously anymore).

A proper fix can be applied later, for now let's just get back to stability.
2026-08-19 12:54:45 +00:00
..
2023-06-05 13:03:38 +02:00