Skip to content

Commit 11bb383

Browse files
committed
Merge remote-tracking branch 'upstream/master'
2 parents 187e032 + 26af97e commit 11bb383

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

cwltool/main.py

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -270,6 +270,12 @@ def load_tool(argsworkflow, updateonly, strict, makeTool, debug, print_pre=False
270270
workflowobj = {"cwlVersion": "https://w3id.org/cwl/cwl#draft-2",
271271
"id": fileuri,
272272
"@graph": workflowobj}
273+
274+
jobobj = None
275+
if "cwl:tool" in workflowobj:
276+
jobobj = workflowobj
277+
workflowobj = document_loader.fetch(urlparse.urljoin(uri, workflowobj["cwl:tool"]))
278+
273279
workflowobj = update.update(workflowobj, document_loader, fileuri)
274280
document_loader.idx.clear()
275281

@@ -301,6 +307,11 @@ def load_tool(argsworkflow, updateonly, strict, makeTool, debug, print_pre=False
301307
_logger.error("Tool definition failed initialization:\n%s", e, exc_info=(e if debug else False))
302308
return 1
303309

310+
if jobobj:
311+
for inp in t.tool["inputs"]:
312+
if shortname(inp["id"]) in jobobj:
313+
inp["default"] = jobobj[shortname(inp["id"])]
314+
304315
return t
305316

306317
def main(args=None,

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
'rdflib >= 4.2.0',
3434
'rdflib-jsonld >= 0.3.0',
3535
'shellescape',
36-
'schema_salad >= 1.0.4'
36+
'schema_salad >= 1.0.6'
3737
],
3838
test_suite='tests',
3939
tests_require=[],

0 commit comments

Comments
 (0)