From 47082362ad45bd5bb283226eb16d945a19b3e7bc Mon Sep 17 00:00:00 2001 From: Giampaolo Rodola Date: Mon, 24 Oct 2016 21:14:58 +0200 Subject: [PATCH] fix #927: Popen.__del__ may cause maximum recursion depth error. --- HISTORY.rst | 10 ++++++++++ psutil/__init__.py | 4 ---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/HISTORY.rst b/HISTORY.rst index 864efe670..04e1d6cc7 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -1,5 +1,15 @@ *Bug tracker at https://github.com/giampaolo/psutil/issues* + +4.4.1 - XXXX-XX-XX +================== + +Bug fixes +--------- + +- 927_: ``Popen.__del__`` may cause maximum recursion depth error. + + 4.4.0 - 2016-10-23 ================== diff --git a/psutil/__init__.py b/psutil/__init__.py index dfd3b1737..575780ada 100644 --- a/psutil/__init__.py +++ b/psutil/__init__.py @@ -1264,10 +1264,6 @@ def __init__(self, *args, **kwargs): def __dir__(self): return sorted(set(dir(Popen) + dir(subprocess.Popen))) - def __del__(self, *args, **kwargs): - self.__subproc.__del__(*args, **kwargs) - self.__subproc = None - def __enter__(self): if hasattr(self.__subproc, '__enter__'): self.__subproc.__enter__()