summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2017-11-27 23:35:33 (GMT)
committerGitHub <noreply@github.com>2017-11-27 23:35:33 (GMT)
commitc16bacec3c2f08a74e4dc282f7d84f17ec70d0d5 (patch)
treed8dfc750fb89d86220dae7a20902b200b92755af /Lib
parent28e61650b23119b68cd7943ccc01b8b9af1b4103 (diff)
downloadcpython-c16bacec3c2f08a74e4dc282f7d84f17ec70d0d5.zip
cpython-c16bacec3c2f08a74e4dc282f7d84f17ec70d0d5.tar.gz
cpython-c16bacec3c2f08a74e4dc282f7d84f17ec70d0d5.tar.bz2
asyncio: Remove unused Future._tb_logger attribute (#4596)
It was only used on Python 3.3, now only Future._log_traceback is used.
Diffstat (limited to 'Lib')
-rw-r--r--Lib/asyncio/futures.py9
1 files changed, 1 insertions, 8 deletions
diff --git a/Lib/asyncio/futures.py b/Lib/asyncio/futures.py
index 472f2a8..b2e57ef 100644
--- a/Lib/asyncio/futures.py
+++ b/Lib/asyncio/futures.py
@@ -63,8 +63,7 @@ class Future:
# `yield Future()` (incorrect).
_asyncio_future_blocking = False
- _log_traceback = False # Used for Python 3.4 and later
- _tb_logger = None # Used for Python 3.3 only
+ _log_traceback = False
def __init__(self, *, loop=None):
"""Initialize the future.
@@ -156,9 +155,6 @@ class Future:
if self._state != _FINISHED:
raise InvalidStateError('Result is not ready.')
self._log_traceback = False
- if self._tb_logger is not None:
- self._tb_logger.clear()
- self._tb_logger = None
if self._exception is not None:
raise self._exception
return self._result
@@ -176,9 +172,6 @@ class Future:
if self._state != _FINISHED:
raise InvalidStateError('Exception is not set.')
self._log_traceback = False
- if self._tb_logger is not None:
- self._tb_logger.clear()
- self._tb_logger = None
return self._exception
def add_done_callback(self, fn):