[Python-Dev] requirements for moving __import__ over to importlib?

Brett Cannon brett at python.org
Fri Feb 10 22:42:28 CET 2012


On Fri, Feb 10, 2012 at 16:29, Tres Seaver <tseaver at palladion.com> wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> On 02/10/2012 03:38 PM, Brett Cannon wrote:
> > Changes in any fashion to the directory. Do filesystems atomically
> > update the mtime of a directory when they commit a change? Otherwise
> > we have a potential race condition.
>
> Hmm, maybe I misundersand you.  In POSIX land, the only thing which
> changes the mtime of a directory is linking / unlinking / renaming a
> file:  changes to individual files aren't detectable by examining their
> containing directory's stat().
>

Individual file changes are not important; either the module is already in
sys.modules so no attempt is made to detect a change or it hasn't been
loaded and so it will have to be read regardless. All I'm asking is whether
filesystems typically update the filesystem for a e.g. file deletion
atomically with the mtime for the containing directory or not.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20120210/8742dad4/attachment.html>


More information about the Python-Dev mailing list