[New-bugs-announce] [issue32678] Lazy import ast in inspect
INADA Naoki
report at bugs.python.org
Fri Jan 26 07:30:50 EST 2018
New submission from INADA Naoki <songofacandy at gmail.com>:
inspect imports ast but it's used only for creating signature.
But asyncio uses inspect module for unwrap(), isgenerator(), etc...
And ast module is relatively heavy for import.
This is output of python -Ximporttime -c 'import asyncio':
import time: 147 | 147 | asyncio.constants
import time: 1456 | 1456 | _ast
import time: 363 | 1818 | ast
...
import time: 1890 | 5152 | inspect
...
import time: 303 | 5984 | asyncio.coroutines
...
import time: 731 | 37941 | asyncio.base_events
...
import time: 375 | 41383 | asyncio
----------
components: Library (Lib)
messages: 310759
nosy: inada.naoki
priority: normal
severity: normal
status: open
title: Lazy import ast in inspect
type: resource usage
versions: Python 3.7
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue32678>
_______________________________________
More information about the New-bugs-announce
mailing list