diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2014-06-24 22:37:53 +0200 |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2014-06-24 22:37:53 +0200 |
commit | a02f81ff1757a257c7243ff53542d6f4f34668db (patch) | |
tree | ca6cbc226160469f0d16622f308ca88ee68aec1a /Lib/asyncio/futures.py | |
parent | 4c945fe9e9ea813ecb19ed705e1c7b3ae26b0d2a (diff) | |
download | cpython-git-a02f81ff1757a257c7243ff53542d6f4f34668db.tar.gz |
asyncio: Log an error if a Task is destroyed while it is still pending
Diffstat (limited to 'Lib/asyncio/futures.py')
-rw-r--r-- | Lib/asyncio/futures.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/asyncio/futures.py b/Lib/asyncio/futures.py index 91ea170661..4edd2e5059 100644 --- a/Lib/asyncio/futures.py +++ b/Lib/asyncio/futures.py @@ -169,6 +169,9 @@ class Future: res += '<{}>'.format(self._state) return res + # On Python 3.3 or older, objects with a destructor part of a reference + # cycle are never destroyed. It's not more the case on Python 3.4 thanks to + # the PEP 442. if _PY34: def __del__(self): if not self._log_traceback: |