-
-
Notifications
You must be signed in to change notification settings - Fork 30.5k
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
Refleak in test_importlib
on aarch64 RHEL8
#101766
Comments
First failing build that I was able to find: https://buildbot.python.org/all/#/builders/802/builds/582 See #101394 |
Linux 65cf87cd990d 6.1.9-200.fc37.aarch64 #1 SMP PREEMPT_DYNAMIC Thu Feb 2 00:41:31 UTC 2023 aarch64 aarch64 aarch64 GNU/Linux
|
@corona10 If you found a suspect can you link it here? |
Sure |
@gvanrossum @sobolevn @mdickinson @brettcannon @exarkun I finally found the suspect: I run The root cause has yet to be discovered. |
Is the SEND fix it? |
@corona10 great work, thank you! |
Do you mean c776624? No, it doesn't solve the issue. |
Usually leaks are C code. There is no C code in the importlib PR. Maybe the blocking_on dict needs to be cleared? |
I think sameway.
I will try it. |
Yeah, this was the root cause. Amazing intuition!! diff --git a/Lib/importlib/_bootstrap.py b/Lib/importlib/_bootstrap.py
index bebe7e15cb..e42e7bc653 100644
--- a/Lib/importlib/_bootstrap.py
+++ b/Lib/importlib/_bootstrap.py
@@ -85,6 +85,7 @@ def __enter__(self):
def __exit__(self, *args, **kwargs):
"""Remove self.lock from this thread's _blocking_on list."""
self.blocked_on.remove(self.lock)
+ del _blocking_on[self.thread_id] I am checking the proper solution. |
Whenever there's a global cache you get things like this, I've debugged these since 2000. :-) Good work finding the missing Also @sobolevn thanks for flagging this -- I had seen this occasionally but always just ignored it as being a flake. It was so much more than that! All in all great teamwork. |
Close this issue |
…pythongh-101942)" This reverts commit 775f881.
Re-open the issue due to #101942 (comment) |
I am not sure what is going on with this test run:
See https://buildbot.python.org/all/#builders/802/builds/623
Linked PRs
The text was updated successfully, but these errors were encountered: