-
-
Notifications
You must be signed in to change notification settings - Fork 232
Required secondaryFiles outputs do not work in CWL CommandLineTools which run in Docker #1869
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Hello @ThomasHickman
Can you try a more recent release? The latest version is dated 2023-06-24: https://pypi.org/project/cwltool/3.1.20230624081518/ |
I tried with the latest version and can confirm this incorrect behavior with docker (version 24.0.2), |
Even old Changing the syntax a bit fixes it. Note from the CWL v1.2 standard:
outputs:
output:
type: File
secondaryFiles:
- ^.ext2 Even though it is not required, it is still found:
|
Okay, here is a fix; I'll add a test and a new cwltool release and I'll submit a new conformance test to be included in CWL v1.2.1+ ; thank you @ThomasHickman ! diff --git a/cwltool/command_line_tool.py b/cwltool/command_line_tool.py
index 53805b00..854d2725 100644
--- a/cwltool/command_line_tool.py
+++ b/cwltool/command_line_tool.py
@@ -1454,7 +1454,10 @@ class CommandLineTool(Process):
continue
if isinstance(sfitem, str):
sfitem = {"path": pathprefix + sfitem}
- if not fs_access.exists(sfitem["path"]) and sf_required:
+ if (
+ not fs_access.exists(revmap(sfitem)["location"])
+ and sf_required
+ ):
raise WorkflowException(
"Missing required secondary file '%s'"
% (sfitem["path"]) |
Expected Behavior
If you have a CommandLineTool with an output of something like:
cwltool should succeed if output files with extensions
.ext1
and.ext2
exist in the output folder, when using:Actual Behavior
This causes an error.
Workflow Code
Full Traceback
Your Environment
The text was updated successfully, but these errors were encountered: