[issue18810] Stop doing stat calls in importlib.machinery.FileFinder to see if something is a file or folder

Brett Cannon report at bugs.python.org
Thu Aug 22 16:49:46 CEST 2013


New submission from Brett Cannon:

If the check was done based on simply the format what was being searched for (e.g. just assume it's a file if "module.py" exists in the directory) then a couple of stat calls per search could be saved.

If that is deemed to dangerous due to backwards-compatibility, at least extract an API so people can skip the stat calls if they know they are not going to do something as silly as have something named module.py that is not a file.

----------
components: Library (Lib)
messages: 195900
nosy: brett.cannon
priority: normal
severity: normal
stage: test needed
status: open
title: Stop doing stat calls in importlib.machinery.FileFinder to see if something is a file or folder
type: performance
versions: Python 3.4

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue18810>
_______________________________________


More information about the Python-bugs-list mailing list