[New-bugs-announce] [issue29645] webbrowser module import has heavy side effects
Serhiy Storchaka
report at bugs.python.org
Sat Feb 25 04:26:58 EST 2017
New submission from Serhiy Storchaka:
`import webbrowser` has heavy side effects. It searches a number of executables. On X Window it also runs external program xdg-settings.
Cold start:
$ time ./python -c ''
real 0m1.719s
user 0m0.088s
sys 0m0.036s
$ time ./python -c 'import webbrowser'
real 0m5.713s
user 0m0.308s
sys 0m0.196s
Hot start:
$ time ./python -c ''
real 0m0.094s
user 0m0.072s
sys 0m0.020s
$ time ./python -c 'import webbrowser'
real 0m1.026s
user 0m0.284s
sys 0m0.100s
----------
components: Library (Lib)
messages: 288551
nosy: serhiy.storchaka
priority: normal
severity: normal
status: open
title: webbrowser module import has heavy side effects
type: performance
versions: Python 3.7
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue29645>
_______________________________________
More information about the New-bugs-announce
mailing list