This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: assertion failure in FutureObj_finalize() after setting _log_traceback to True
Type: crash Stage: resolved
Components: asyncio Versions: Python 3.7
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: Oren Milman, asvetlov, yselivanov
Priority: normal Keywords:

Created on 2017-10-07 14:19 by Oren Milman, last changed 2022-04-11 14:58 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 5009 merged yselivanov, 2017-12-25 16:11
Messages (4)
msg303878 - (view) Author: Oren Milman (Oren Milman) * Date: 2017-10-07 14:19
The following code causes an assertion failure in FutureObj_finalize() (in

import asyncio
asyncio.Future()._log_traceback = True

Maybe we should allow Python code to only set it to False, and raise a
ValueError in case Python code tries to set it to True?

(PR 2050 made _log_traceback writable. Are there any usecases for setting it to
True from Python code?)
msg309036 - (view) Author: Andrew Svetlov (asvetlov) * (Python committer) Date: 2017-12-25 12:44
_log_traceback is a private property and asyncio implementation detail, you should never touch it.
msg309038 - (view) Author: Yury Selivanov (yselivanov) * (Python committer) Date: 2017-12-25 16:08
> _log_traceback is a private property and asyncio implementation detail, you should never touch it.

But still, we shouldn't let Python crash if someone sets it.  I'll make a PR to fix this the way Oren proposed.

Andrew, let's discuss later with what we want to replace _log_traceback. I don't like that it's a semi-public thing.
msg309042 - (view) Author: Yury Selivanov (yselivanov) * (Python committer) Date: 2017-12-25 21:16
New changeset e0aef4f3cd339a405d2a7fbd35a50afa64834f84 by Yury Selivanov in branch 'master':
bpo-31721: Allow Future._log_traceback to only be set to False (#5009)
Date User Action Args
2022-04-11 14:58:53adminsetgithub: 75902
2017-12-25 21:16:59yselivanovsetstatus: open -> closed
resolution: fixed
stage: patch review -> resolved
2017-12-25 21:16:13yselivanovsetmessages: + msg309042
2017-12-25 16:11:43yselivanovsetstatus: closed -> open
resolution: wont fix -> (no value)
stage: resolved -> patch review
2017-12-25 16:11:22yselivanovsetpull_requests: + pull_request4898
2017-12-25 16:08:39yselivanovsetmessages: + msg309038
2017-12-25 12:44:02asvetlovsetstatus: open -> closed

nosy: + asvetlov
messages: + msg309036

resolution: wont fix
stage: resolved
2017-10-07 14:19:24Oren Milmancreate