|
13 | 13 |
|
14 | 14 | from sophios import compiler, input_output, plugins, utils_cwl, post_compile |
15 | 15 | from sophios import run_local as run_local_module |
16 | | -from sophios.cli import get_args |
| 16 | +from sophios.cli import get_args, get_known_and_unknown_args |
17 | 17 | from sophios.utils_graphs import get_graph_reps |
18 | 18 | from sophios.wic_types import CompilerInfo, RoseTree, StepId, Tool, Tools, YamlTree, Json |
19 | 19 |
|
@@ -785,15 +785,19 @@ def run(self) -> None: |
785 | 785 | logger.info(f"Running {self.process_name}") |
786 | 786 | plugins.logging_filters() |
787 | 787 | compiler_info = self.compile(write_to_disk=True) |
788 | | - args = get_args(self.process_name, self.user_args) # Use mock CLI args |
| 788 | + args, unknown_args = get_known_and_unknown_args(self.process_name, self.user_args) # Use mock CLI args |
789 | 789 | rose_tree: RoseTree = compiler_info.rose |
790 | 790 |
|
791 | 791 | post_compile.cwl_docker_extract(args.container_engine, args.pull_dir, self.process_name) |
792 | 792 | if args.docker_remove_entrypoints: |
793 | 793 | rose_tree = post_compile.remove_entrypoints(args.container_engine, rose_tree) |
794 | 794 | post_compile.find_and_create_output_dirs(rose_tree) |
795 | 795 | # Do NOT capture stdout and/or stderr and pipe warnings and errors into a black hole. |
796 | | - retval = run_local_module.run_local(args, rose_tree, args.cachedir, args.cwl_runner, True) |
| 796 | + if args.toil_passthrough_flags == 'yes': |
| 797 | + run_local_module.run_local(args, rose_tree, args.cachedir, args.cwl_runner, |
| 798 | + True, passthrough_args=unknown_args) |
| 799 | + else: |
| 800 | + run_local_module.run_local(args, rose_tree, args.cachedir, args.cwl_runner, True) |
797 | 801 |
|
798 | 802 | # Finally, since there is an output file copying bug in cwltool, |
799 | 803 | # we need to copy the output files manually. See comment above. |
|
0 commit comments