You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Cygwin: asyncio and asyncore test suites hang indefinitely due to bug in Cygwin #76063
bpo-45537: Cygwin is unsupported - close all open issues and list them here.
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee=Noneclosed_at=<Date2021-10-20.12:06:19.062>created_at=<Date2017-10-27.13:08:09.394>labels= ['type-crash']
title='Cygwin: asyncio and asyncore test suites hang indefinitely due to bug in Cygwin'updated_at=<Date2021-10-21.09:57:35.998>user='https://github.com/embray'
Some of the tests for asyncio and asyncore block forever on Cygwin, due to a known (and seemingly difficult to fix) bug [1] in Cygwin involving SO_PEERCRED on UNIX sockets.
SO_PEERCRED is a socket option that can be used to exchange file ownership info of the socket at the time the connection was established (specifically on UNIX sockets). This feature is technically supported on Cygwin, but the effect of the bug is that if two sockets are opened on the same process (even without using socketpair()), the credential exchange protocol can cause connect() on the "client" socket to block unless the "server" socket is already listen()-ing.
This situation is not all that common in practice (it is not a problem if the "client" and "server" are separate processes). But it does show up in the test suite in a number of places, since both sockets belong to the same process.
I have a patch to work around this and will post a PR shortly.
I originally opened this in https://bugs.python.org/issue29253 but then made a dupe of my own bug! Anyways, there's a (nearly year old) pull request for it now.
Activity
embray commentedon Oct 27, 2017
Some of the tests for asyncio and asyncore block forever on Cygwin, due to a known (and seemingly difficult to fix) bug [1] in Cygwin involving SO_PEERCRED on UNIX sockets.
SO_PEERCRED is a socket option that can be used to exchange file ownership info of the socket at the time the connection was established (specifically on UNIX sockets). This feature is technically supported on Cygwin, but the effect of the bug is that if two sockets are opened on the same process (even without using socketpair()), the credential exchange protocol can cause connect() on the "client" socket to block unless the "server" socket is already listen()-ing.
This situation is not all that common in practice (it is not a problem if the "client" and "server" are separate processes). But it does show up in the test suite in a number of places, since both sockets belong to the same process.
I have a patch to work around this and will post a PR shortly.
[1] https://cygwin.com/ml/cygwin/2017-01/msg00054.html
embray commentedon Jul 19, 2018
I originally opened this in https://bugs.python.org/issue29253 but then made a dupe of my own bug! Anyways, there's a (nearly year old) pull request for it now.
iritkatriel commentedon Oct 19, 2021
See discussion on bpo-31885.
embray commentedon Oct 19, 2021
To my knowledge this issue is *not* fixed upstream. However, my PR no doubt needs rebasing.
iritkatriel commentedon Oct 19, 2021
Sorry I thought this was the same issue.
Note that asyncore is deprecated now.