| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
|
@vstinner, what's your opinion on this approach?
It might be better to move the skipForRefleakHuntinIf in test_socket to refleak_helper as well (while removing the client_skip functionality), although that requires some additional changes to test_socket. |
Sorry, something went wrong.
There was a problem hiding this comment.
For me, LGTM
Sorry, something went wrong.
| except ImportError: | ||
| _socket = None | ||
|
|
||
| def skipForRefleakHuntinIf(condition, issueref): |
There was a problem hiding this comment.
Maybe it's make sense to store it in test.support.refleak_helper (as you said above)? It's can be useful in future in other situations like this
Sorry, something went wrong.
|
I thought I had spotted a potential real FD leak in the "sendAncillaryIfPossible" helper method: cpython/Lib/test/test_socket.py Line 3762 in 8907efc If the message sending fails (or the ancillary data otherwise isn't passed correctly), the included FDs are never passed to SCMRightsTest.registerRecvmsgResult and hence never scheduled for cleanup. However, any FDs allocated by the newFDs helper are already registered for cleanup regardless of whether they're received or not, so I think that's a red herring. Is it possible we're provoking a false alarm in the fd leak hunting somehow? |
Sorry, something went wrong.
Not impossible, but unlikely given that this only is a problem on macOS in a particular scenario. I'll work on a reproducer in C for the issue, that would rule out problems in our code and is needed to file a bug with Apple about this. |
Sorry, something went wrong.
|
Thanks @ronaldoussoren for the PR 🌮🎉.. I'm working now to backport this PR to: 3.11. |
Sorry, something went wrong.
|
Thanks @ronaldoussoren for the PR 🌮🎉.. I'm working now to backport this PR to: 3.12. |
Sorry, something went wrong.
…macOS (pythonGH-114057) Some socket tests related to sending file descriptors cause a file descriptor leak on macOS, all of them tests that send one or more descriptors than cannot be received on the read end. This appears to be a platform bug. This PR skips those tests when doing a refleak test run to avoid hiding other problems. (cherry picked from commit 5adff3f) Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
…macOS (pythonGH-114057) Some socket tests related to sending file descriptors cause a file descriptor leak on macOS, all of them tests that send one or more descriptors than cannot be received on the read end. This appears to be a platform bug. This PR skips those tests when doing a refleak test run to avoid hiding other problems. (cherry picked from commit 5adff3f) Co-authored-by: Ronald Oussoren <ronaldoussoren@mac.com>
|
GH-114380 is a backport of this pull request to the 3.11 branch. |
Sorry, something went wrong.
|
GH-114381 is a backport of this pull request to the 3.12 branch. |
Sorry, something went wrong.
…macOS (python#114057) Some socket tests related to sending file descriptors cause a file descriptor leak on macOS, all of them tests that send one or more descriptors than cannot be received on the read end. This appears to be a platform bug. This PR skips those tests when doing a refleak test run to avoid hiding other problems.
…macOS (python#114057) Some socket tests related to sending file descriptors cause a file descriptor leak on macOS, all of them tests that send one or more descriptors than cannot be received on the read end. This appears to be a platform bug. This PR skips those tests when doing a refleak test run to avoid hiding other problems.
|
I don't think this should be backported? |
Sorry, something went wrong.
TBH I haven't checked if the issue is actually present in 3.11 and 3.12. I'd expect that the issue is present there as well unless the problematic tests are only present on main. I'll check during the weekend. |
Sorry, something went wrong.
…macOS (python#114057) Some socket tests related to sending file descriptors cause a file descriptor leak on macOS, all of them tests that send one or more descriptors than cannot be received on the read end. This appears to be a platform bug. This PR skips those tests when doing a refleak test run to avoid hiding other problems.
| Back | FazBrowse Home | New Git URL |
Uh oh!
There was an error while loading. Please reload this page.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.