X-Git-Url: http://woldlab.caltech.edu/gitweb/?p=htsworkflow.git;a=blobdiff_plain;f=htsworkflow%2Fpipelines%2Frun_status.py;h=0903e7018f7760aa43fafeb3289c7194ebd0d9d6;hp=e6a3ed8e6b2f41793f1109dac1334900860e8eaf;hb=refs%2Fheads%2Fpython3-django1.5;hpb=4262586d10cc0cc227390873b301b55244204c11 diff --git a/htsworkflow/pipelines/run_status.py b/htsworkflow/pipelines/run_status.py index e6a3ed8..0903e70 100644 --- a/htsworkflow/pipelines/run_status.py +++ b/htsworkflow/pipelines/run_status.py @@ -78,7 +78,7 @@ def _p2f(pattern, lane, tile=None, cycle=None): # lane, and cycle provided (INVALID) if tile is None and cycle is not None: msg = "Handling of cycle without tile is not currently implemented." - raise ValueError, msg + raise ValueError(msg) # lane, tile, cycle provided elif cycle: @@ -299,7 +299,7 @@ class GARunStatus(object): """ firecrest = self.status['firecrest'] total = len(firecrest) - completed = firecrest.values().count(True) + completed = list(firecrest.values()).count(True) return (completed, total) @@ -310,7 +310,7 @@ class GARunStatus(object): """ bustard = self.status['bustard'] total = len(bustard) - completed = bustard.values().count(True) + completed = list(bustard.values()).count(True) return (completed, total) @@ -321,7 +321,7 @@ class GARunStatus(object): """ gerald = self.status['gerald'] total = len(gerald) - completed = gerald.values().count(True) + completed = list(gerald.values()).count(True) return (completed, total) @@ -410,13 +410,13 @@ def _cmdLineStatusMonitorFunc(conf_info): while 1: if conf_info.status is None: - print "No status object yet." + print("No status object yet.") time.sleep(SLEEP_AMOUNT) continue report = conf_info.status.statusReport() - print os.linesep.join(report) - print + print(os.linesep.join(report)) + print() time.sleep(SLEEP_AMOUNT) @@ -446,7 +446,7 @@ def main(cmdline=None): parser.error("need name of configuration file") status = GARunStatus(args[0]) - print os.linesep.join(status.statusReport()) + print(os.linesep.join(status.statusReport())) return 0 if __name__ == "__main__":