[issue19216] stat cache for import bootstrap

Eric Snow report at bugs.python.org
Sat Oct 19 23:37:26 CEST 2013


Eric Snow added the comment:

> I don't really understand the algorithm you're proposing.

In importlib._bootstrap:

We have some global like "_CHECK_STAT=True".  FileFinder would use it to decide on using stat checks or not.

In Python/pythonrun.c:

At the end of import_init(), we set importlib._bootstrap _CHECK_STAT to False.  Then at the end of _Py_InitializeEx_Private() we set it back to True.

(As an alternative, we could always not do stat checking for just the standard library)

> Also, have you read what I've just posted?

About the fuzziness of when startup is finished?  As implied above, I'd say at the end of Py_Initialize().

----------

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


More information about the Python-bugs-list mailing list