From 07fcc32319f323e07e522c8743e77155efa03073 Mon Sep 17 00:00:00 2001 From: "Dustin J. Mitchell" Date: Thu, 19 Mar 2009 13:02:36 -0400 Subject: [PATCH] (refs #459) use already-existing hasContents, rather than the duplicate logfileExists --- buildbot/status/builder.py | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/buildbot/status/builder.py b/buildbot/status/builder.py index e880ac7..1babe7f 100644 --- a/buildbot/status/builder.py +++ b/buildbot/status/builder.py @@ -275,13 +275,6 @@ class LogFile: self.finishedWatchers.append(d) return d - def logfileExists(self): - if self.openfile: return True - fn = self.getFilename() - for f in (fn, fn + ".bz2"): - if os.path.exists(f): return True - return False - def getFile(self): if self.openfile: # this is the filehandle we're using to write to the log, so @@ -963,7 +956,7 @@ class BuildStepStatus(styles.Versioned): def checkLogfiles(self): # filter out logs that have been deleted - self.logs = [ l for l in self.logs if l.logfileExists() ] + self.logs = [ l for l in self.logs if l.hasContents() ] # persistence -- 2.11.4.GIT