Skip to content

Commit 4d1b211

Browse files
committed
adjust expression refactor logic for the fixed refscope
1 parent 05d7cd4 commit 4d1b211

File tree

2 files changed

+3
-8
lines changed

2 files changed

+3
-8
lines changed

cwl_utils/cwl_v1_2_expression_refactor.py

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -702,14 +702,9 @@ def process_workflow_inputs_and_outputs(
702702
target_type.name = None
703703
target = cwl.WorkflowInputParameter(id=None, type=target_type)
704704
if not isinstance(param2.outputSource, list):
705-
sources: Union[List[str], str] = "/".join(
706-
param2.outputSource.split("#")[-1].split("/")[1:]
707-
)
705+
sources: Union[List[str], str] = param2.outputSource.split("#")[-1]
708706
else:
709-
sources = [
710-
"/".join(s.split("#")[-1].split("/")[1:])
711-
for s in param2.outputSource
712-
]
707+
sources = [s.split("#")[-1] for s in param2.outputSource]
713708
source_type_items = utils.type_for_source(workflow, sources)
714709
if "null" not in source_type_items:
715710
if isinstance(source_type_items, list):

cwl_utils/expression_refactor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
Callable,
1414
Dict,
1515
List,
16-
MutableSequence,
1716
MutableMapping,
17+
MutableSequence,
1818
Optional,
1919
Tuple,
2020
Union,

0 commit comments

Comments
 (0)