17286: Tweak output if neither workbench2 or workbench1 is defined
authorPeter Amstutz <peter.amstutz@curii.com>
Mon, 25 Jan 2021 16:25:36 +0000 (11:25 -0500)
committerPeter Amstutz <peter.amstutz@curii.com>
Mon, 25 Jan 2021 16:25:36 +0000 (11:25 -0500)
Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <peter.amstutz@curii.com>

sdk/cwl/arvados_cwl/executor.py

index 20f4b7309fb217ccce414eb845bfc9241329c3f2..f60c480873b833dca11b0dba1a6cc853f4c29e2c 100644 (file)
@@ -526,7 +526,8 @@ The 'jobs' API is no longer supported.
 
         workbench1 = self.api.config()["Services"]["Workbench1"]["ExternalURL"]
         workbench2 = self.api.config()["Services"]["Workbench2"]["ExternalURL"]
-        logger.info("Using cluster %s (%s)", self.api.config()["ClusterID"], workbench2 or workbench1)
+        controller = self.api.config()["Services"]["Controller"]["ExternalURL"]
+        logger.info("Using cluster %s (%s)", self.api.config()["ClusterID"], workbench2 or workbench1 or controller)
 
         updated_tool.visit(self.check_features)
 
@@ -761,7 +762,9 @@ The 'jobs' API is no longer supported.
             raise WorkflowException("Workflow did not return a result.")
 
         if runtimeContext.submit and isinstance(tool, Runner):
-            logger.info("Final output collection %s (%scollections/%s)", tool.final_output, workbench2 or workbench1, tool.final_output)
+            logger.info("Final output collection %s", tool.final_output)
+            if workbench2 or workbench1:
+                logger.info("Output at %scollections/%s", workbench2 or workbench1, tool.final_output)
         else:
             if self.output_name is None:
                 self.output_name = "Output of %s" % (shortname(tool.tool["id"]))