projects
/
arvados.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
21356: Remove all Python 2/3 compatibility imports
[arvados.git]
/
sdk
/
cwl
/
arvados_cwl
/
executor.py
diff --git
a/sdk/cwl/arvados_cwl/executor.py
b/sdk/cwl/arvados_cwl/executor.py
index 8facc9f380b19f03a46b7988e2867eb34ba69c4b..240e014e5ab70b266e1a332e6685dee5396d2be1 100644
(file)
--- a/
sdk/cwl/arvados_cwl/executor.py
+++ b/
sdk/cwl/arvados_cwl/executor.py
@@
-2,12
+2,6
@@
#
# SPDX-License-Identifier: Apache-2.0
#
# SPDX-License-Identifier: Apache-2.0
-from __future__ import division
-from builtins import next
-from builtins import object
-from builtins import str
-from future.utils import viewvalues, viewitems
-
import argparse
import logging
import os
import argparse
import logging
import os
@@
-70,7
+64,7
@@
class RuntimeStatusLoggingHandler(logging.Handler):
kind = 'error'
elif record.levelno >= logging.WARNING:
kind = 'warning'
kind = 'error'
elif record.levelno >= logging.WARNING:
kind = 'warning'
- if kind == 'warning' and
(record.name == "salad" or record.name ==
"crunchstat_summary"):
+ if kind == 'warning' and
record.name in ("salad",
"crunchstat_summary"):
# Don't send validation warnings to runtime status,
# they're noisy and unhelpful.
return
# Don't send validation warnings to runtime status,
# they're noisy and unhelpful.
return
@@
-370,7
+364,8
@@
The 'jobs' API is no longer supported.
page = keys[:pageSize]
try:
proc_states = table.list(filters=[["uuid", "in", page]], select=["uuid", "container_uuid", "state", "log_uuid",
page = keys[:pageSize]
try:
proc_states = table.list(filters=[["uuid", "in", page]], select=["uuid", "container_uuid", "state", "log_uuid",
- "output_uuid", "modified_at", "properties"]).execute(num_retries=self.num_retries)
+ "output_uuid", "modified_at", "properties",
+ "runtime_constraints"]).execute(num_retries=self.num_retries)
except Exception as e:
logger.warning("Temporary error checking states on API server: %s", e)
remain_wait = self.poll_interval
except Exception as e:
logger.warning("Temporary error checking states on API server: %s", e)
remain_wait = self.poll_interval
@@
-420,7
+415,7
@@
The 'jobs' API is no longer supported.
if obj.get("class") == "InplaceUpdateRequirement":
if obj["inplaceUpdate"] and parentfield == "requirements":
raise SourceLine(obj, "class", UnsupportedRequirement).makeError("InplaceUpdateRequirement not supported for keep collections.")
if obj.get("class") == "InplaceUpdateRequirement":
if obj["inplaceUpdate"] and parentfield == "requirements":
raise SourceLine(obj, "class", UnsupportedRequirement).makeError("InplaceUpdateRequirement not supported for keep collections.")
- for k,v in
viewitems(obj
):
+ for k,v in
obj.items(
):
self.check_features(v, parentfield=k)
elif isinstance(obj, list):
for i,v in enumerate(obj):
self.check_features(v, parentfield=k)
elif isinstance(obj, list):
for i,v in enumerate(obj):
@@
-928,6
+923,11
@@
The 'jobs' API is no longer supported.
if self.final_output is None:
raise WorkflowException("Workflow did not return a result.")
if self.final_output is None:
raise WorkflowException("Workflow did not return a result.")
+ if runtimeContext.usage_report_notes:
+ logger.info("Steps with low resource utilization (possible optimization opportunities):")
+ for x in runtimeContext.usage_report_notes:
+ logger.info(" %s", x)
+
if runtimeContext.submit and isinstance(tool, Runner):
logger.info("Final output collection %s", tool.final_output)
if workbench2 or workbench1:
if runtimeContext.submit and isinstance(tool, Runner):
logger.info("Final output collection %s", tool.final_output)
if workbench2 or workbench1: