File tree 1 file changed +4
-4
lines changed 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -299,13 +299,13 @@ def setUp(self):
299
299
sys .dont_write_bytecode = True
300
300
301
301
# Because these tests create Python source files at runtime,
302
- # it's possible for the importlib.machinery.FileFinder for
303
- # a directory to have an outdated cache in the following situation:
302
+ # it's possible in Python >=3.3 for the importlib.machinery.FileFinder
303
+ # for a directory to have an outdated cache when
304
304
# * a module in that directory is imported,
305
305
# * then a new module is created in that directory,
306
306
# * then that new module is imported.
307
- #
308
- # invalidate_cache() is used to prevent this .
307
+ # Automatic cache invalidation is based on the second-resolution mtime
308
+ # of the directory, so we need to manually call invalidate_caches() .
309
309
#
310
310
# see https://docs.python.org/3/library/importlib.html
311
311
# sections #importlib.machinery.FileFinder and
You can’t perform that action at this time.
0 commit comments