Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def launchNextTask() :
taskIndex = len(allTasks)
workerTaskLabel = "workerTask_%05i" % (taskIndex)
workerTaskFile = "outputFile_%05i" % (taskIndex)
workerTaskCmd=[sys.executable, workerJob, workerTaskFile]
self.addTask(workerTaskLabel, workerTaskCmd)
allTasks.add(workerTaskLabel)
taskByIndex.append(workerTaskLabel)
sumTaskLabel="sumTask_%05i" % (taskIndex)
self.addWorkflowTask(sumTaskLabel, SumWorkflow(taskIndex, workerTaskFile, totalWorkCompleted), dependencies=workerTaskLabel)