Handle errors more gracefully.

This commit is contained in:
Georg Brandl 2008-03-25 10:20:09 +00:00
parent 10e231bf12
commit 55aacf998a

View File

@ -360,12 +360,17 @@ class BuildEnvironment:
continue continue
# finally, check the mtime of dependencies # finally, check the mtime of dependencies
for dep in self.dependencies.get(docname, ()): for dep in self.dependencies.get(docname, ()):
deppath = path.join(self.srcdir, dep) try:
if not path.isfile(deppath): deppath = path.join(self.srcdir, dep)
changed.add(docname) if not path.isfile(deppath):
break changed.add(docname)
depmtime = path.getmtime(deppath) break
if depmtime > mtime: depmtime = path.getmtime(deppath)
if depmtime > mtime:
changed.add(docname)
break
except EnvironmentError:
# give it another chance
changed.add(docname) changed.add(docname)
break break