New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test_socket: testCongestion() hangs on my Fedora 28 #78768
Comments
Hi, test_socket started to hang recently on my Fedora 28 laptop. No idea why it started to hang. vstinner@apu$ ./python -m test -v test_socket -m testCongestion --timeout=5 Thread 0x00007fcd082ee080 (most recent call first): |
It seems there was a similar report pointing to the same line in the test using Fedora 28. Ref : https://bugs.python.org/issue34354 Thanks |
Linux RDS manual page says: "The receive queue size limits how much data RDS will put on the receive queue of a socket before marking the socket as congested. When a socket becomes congested, RDS will send a congestion map update to the other participating hosts, who are then expected to stop sending more messages to this port." => "other participating hosts (...) are (...) expected to stop sending" By design, it seems like the Python unit test is going to fail, so I suggest to remove the test. I don't think that the role of Python is to check how the kernel handles congestion on local RDS sockets. |
Same problem here. However, checking the test code, it seems that what's happening is that even though the sending socket has been put into non-blocking mode, self.cli.sendto in the _testCongestion helper method invoked by the ThreadableTest base class [1] has *not* thrown OSError, and hence the finally clause setting the event has *not* been triggered, and hence the test is hanging. Neither socket.py nor test_socket.py have changed recently though, so it seems to me that this is either a recent Fedora bug (where the socket is blocking when it shouldn't), or else a Fedora change that has uncovered a latent defect in the socket module code. [1] https://github.com/python/cpython/blob/master/Lib/test/test_socket.py#L228 |
I proposed PR 9277 to remove the test: see the PR for the rationale.
IMHO it's a change in the implementation of the RDS protocol in Linux, likely in the kernel. |
I removed the test from Python 3.6, 3.7 and master. |
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:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: