diff --git a/lib/galaxy/managers/workflows.py b/lib/galaxy/managers/workflows.py index 6de7c805b8be..3cd96a126223 100644 --- a/lib/galaxy/managers/workflows.py +++ b/lib/galaxy/managers/workflows.py @@ -1121,7 +1121,7 @@ def do_inputs(inputs, values, prefix, step, other_values=None): else: module = step.module step_dict["label"] = module.name - step_dict["inputs"] = do_inputs(module.get_runtime_inputs(), step.state.inputs, "", step) + step_dict["inputs"] = do_inputs(module.get_runtime_inputs(step), step.state.inputs, "", step) step_dicts.append(step_dict) return { "name": workflow.name, diff --git a/lib/galaxy/tools/parameters/basic.py b/lib/galaxy/tools/parameters/basic.py index 2da33539c9b9..c818716ad411 100644 --- a/lib/galaxy/tools/parameters/basic.py +++ b/lib/galaxy/tools/parameters/basic.py @@ -8,6 +8,7 @@ import os import os.path import re +import urllib.parse from typing import ( Any, Dict, @@ -2691,16 +2692,17 @@ def raw_to_galaxy(trans, as_dict_value): object_class = as_dict_value["class"] if object_class == "File": - relative_to = "/" # TODO - from galaxy.tool_util.cwl.util import abs_path - - path = abs_path(as_dict_value.get("location"), relative_to) - - name = os.path.basename(path) + # TODO: relative_to = "/" + location = as_dict_value.get("location") + name = ( + as_dict_value.get("identifier") + or as_dict_value.get("basename") + or os.path.basename(urllib.parse.urlparse(location).path) + ) extension = as_dict_value.get("format") or "data" dataset = Dataset() source = DatasetSource() - source.source_uri = path + source.source_uri = location # TODO: validate this... source.transform = as_dict_value.get("transform") dataset.sources.append(source)