@@ -37,10 +37,156 @@ $graph:
37
37
- {$include: intro.md}
38
38
39
39
- |
40
+ ## Introduction to the CWL Command Line Tool draft standard v1.2.1
41
+
42
+ This specification represents the latest development draft from the
43
+ CWL project. There are no new features nor behavior changes in CWL v1.2.1
44
+ as compared to CWL v1.2. v1.2.1 fixes only typos, adds clarifications,
45
+ and adds additional conformance tests. Some changes to the schema defining
46
+ CWL have been changed to aid the auto-generation of libraries for the reading
47
+ and writing of CWL documents.
48
+
49
+ Do not write `cwlVersion: v1.2.1`, that is not a valid version of the CWL
50
+ syntax.
51
+
52
+ See also the [Schema-Salad v1.2.1 changelog](SchemaSalad.html#Changelog_for_v1.2.1)
53
+
54
+ ## Changelog for v1.2.1
55
+
56
+ * The schema for `Requirement`s has changed to enable faster parsing by
57
+ autogenerated libraries. The `class` field is now a static enum with a
58
+ single permissible value instead of a generic string (for example:
59
+ `class: DockerRequirement` for a `DockerRequirement` hint or requirement.)
60
+ This allows for autogenerated CWL parsers to recognize any requirement
61
+ immediatelly instead of having to check for matching field names and
62
+ valid values, as was done previously.
63
+ * Likewise, the schema for `CommandLineTool` has changed to enable faster parsing by
64
+ autogenerated libraries. The `class` field is now a static enum with a
65
+ single permissible value (`class: CommandLineTool`) instead of a generic
66
+ string.
67
+ This allows for autogenerated CWL parsers to recognize any `CommandLineTool`
68
+ immediatelly instead of having to check for matching field names and
69
+ valid values, as was done previously.
70
+ * The schema for the `CommandLineBinding.position` field now has an explicit
71
+ default value of `0`. Previously this was only expression textually in
72
+ the description of that field.
73
+ * The schema for the `File.streamable` field now has an explicit default
74
+ value of `false` to match the textual description.
75
+
76
+ Note: Other fields like `ResourceRequirement.coresMin`, `.coresMax`,
77
+ `.ramMin`, `.ramMax`, `.tmpdirMin`, `.tmpdirMax` have not had defaults
78
+ set in the schema so that parsers can discriminate easily between a
79
+ value not provided and the default value (`0`).
80
+ * Everywhere the schema allows a value of type `long` we also explictly
81
+ allow a value of type `int`. By JSON rules this is implicit, but by
82
+ making it explicit we aid autogenerated CWL libraries especially in
83
+ languages such as Java.
84
+ * The [difference between `$()` and `${}`](#Expressions_(Optional)) were
85
+ clarified. We now make more explicit that `${...}` evaluates to
86
+ `(function() { ... })()`.
87
+ * The publisher of this document is now explictly named; it is the
88
+ [Common Workflow Language project](https://www.commonwl.org), a member
89
+ project of [Software Freedom Conservancy](https://sfconservancy.org/).
90
+ * The [Parameter References](#Parameter_references) section has been updated
91
+ to clarify ambiguity on `null` and array `.length`. Three conformance tests to
92
+ verify this were added as well (`params_broken_null`, `length_for_non_array`,
93
+ `user_defined_length_in_parameter_reference`).
94
+ * It is now explicit in the description of the `size` field of a
95
+ [`File`](#File) object that `size` is measured in bytes, as was already
96
+ stated in the introduction to the `File` object description.
97
+ * The concept of "opaque identifier(s)"/"opaque strings" as mentioned in the
98
+ [`SecondaryFileSchema`](#SecondaryFileSchema), [Parameter References](#Parameter_references),
99
+ and [Runtime Environment](#Runtime_environment) sections is now defined
100
+ in the newly added [glossary](#Glossary): they are nonsensical values
101
+ that are swapped out with a real value later in the evaluation process.
102
+ Workflow and tool expressions **should not** rely on it nor try to parse it.
103
+
104
+ ### Updated Conformance Tests for v1.2.1
105
+ * Conformance tests are now refered to by their textual identifiers (`id`). Previously
106
+ this was the `label` field. Tests without a `label`/`id` have been give
107
+ one.
108
+ * `tests/loadContents/cwloutput-nolimit.cwl`: Made explicit that
109
+ `bigstring` is an additional output as generated by the existing
110
+ `mkfilelist.py` script's use of [`cwl.output.json`](#Output_binding).
111
+ * The number of different software containers used in the conformance tests
112
+ has been reduced to four. See [the list in the CONFORMANCE_TESTS.md instructions](https://github.com/common-workflow-language/cwl-v1.2/blob/1.2.1_proposed/CONFORMANCE_TESTS.md#writing-a-new-conformance-test).
113
+ * `tests/secondaryfiles/rename-inputs.cwl` has been simplified by changing
114
+ it to reference another input parameter instead of using `self`. The
115
+ behavior of processing secondary files patterns in order and being able
116
+ to reference earlier ones later is not part of CWL v1.2.
117
+
118
+ This doesn't exactly replicate the previous behavior, because it introduces
119
+ a new input parameter, however it does demonstrate the ability to rename
120
+ a file and have it staged as a secondary file without having to use
121
+ ` InitialWorkDirRequirement` .
122
+ * `tests/conditionals/cond-wf-002.cwl`, `tests/conditionals/cond-wf-002_nojs.cwl`,
123
+ `tests/conditionals/cond-wf-002_nojs.cwl`, `tests/conditionals/cond-wf-011_nojs.cwl` :
124
+ Marked the outputs as optional to remove ambiguity for these conditional
125
+ ` when` tests; allowing conformant CWL runners to be more strict in their
126
+ interpretation of the typing rules, if they choose so.
127
+ * `directory_input_docker` was incorrectly marked as required, it is optional
128
+ unless the feature `ShellCommandRequirement` is stated as being supported.
129
+ * `glob_outside_outputs_fails` was incorrectly marked as required, it is
130
+ optional unlewss the feature `DockerRequirement` is stated as being supported.
131
+ * `stage_file_array` was incorrectly marked as required, it is optional
132
+ unless both the features `InlineJavascriptRequirement` and `DockerRequirement`
133
+ are stated as being supported.
134
+ * `stage_file_array_basename` and `stage_file_array_entryname_overrides` were
135
+ both incorrectly marked as required, they are optional unless the feature
136
+ ` InitialWorkDirRequirement` and `InlineJavascriptRequirement` are both
137
+ stated as being supported.
138
+ * `optional_numerical_output_returns_0_not_null` was incorrectly marked as
139
+ required, it is optional unless `InlineJavascriptRequirement` is stated
140
+ as being supported.
141
+ * Made it explicit that if a `CommandLineTool` contains logically chained
142
+ commands (e.g. `echo a && echo b`) then the `stdout` File/object must
143
+ include the output of every command. The `stdout_chained_commands` mandatory
144
+ conformance test was added to verify this.
145
+ * `metadata`: The description and content of this test has been updated to
146
+ be more focused on the metadata present in the CWL file.
147
+
148
+ # ## New Mandatory Conformance Tests for v1.2.1
149
+ * `params_broken_null`: Test parameter reference that refers to
150
+ ` null.something` .
151
+ * `length_for_non_array`: Test parameter reference that refers to length
152
+ of non-array input.
153
+ * `user_defined_length_in_parameter_reference`: Test 'length' in a parameter
154
+ reference where it does not refer to length of an array input.
155
+ * `directory_literal_with_literal_file_in_subdir_nostdin`: Test non-`stdin`
156
+ reference to literal `File` via a nested `Directory` literal.
157
+ * `colon_in_paths`: Confirm that colons are tolerated in input paths,
158
+ string values, stdout shortcut, and output file & directory names.
159
+ * `colon_in_output_path`: Confirm that colons are tolerated in output
160
+ directory names.
161
+ * `record_with_default`: Confirm that records with defaults are accepted.
162
+ * `record_outputeval_nojs`: Use of `outputEval` on a record itself, not
163
+ the fields of the record (without javascript). An equivalent test with
164
+ `InlineJavascriptRequirement` was added as well : ` record_outputeval` .
165
+ * `runtime-outdir`: Test use of `$(runtime.outdir)` for `outputBinding.glob`.
166
+ * `stdout_chained_commands`: Test that chaining two `echo` calls causes
167
+ the workflow runner to emit the combined output to `stdout`. This is to
168
+ confirm that the workflow runner will **not** create an expression such as
169
+ ` echo a && echo b > out.txt` , but instead will produce the correct
170
+ ` echo a && echo b` , and capture the output correctly.
171
+ * `record_order_with_input_bindings`: Test sorting arguments at each level
172
+ (`inputBinding` for all levels).
173
+
174
+ # ## New Optional Conformance Tests for v1.2.1
175
+
176
+ # ### `InlineJavaScriptRequirement`
177
+ * `record_outputeval`: Use of `outputEval` on a record itself, not
178
+ the fields of the record.
179
+ * `staging-basename`: Use of an `ExpressionTool` to change `basename` of
180
+ file, then correctly staging the file using the new name.
181
+ * `js-input-record`: A test case for JavaScript with an input record.
182
+
183
+ # ### `MultipleInputFeatureRequirement`
184
+ * `multiple-input-feature-requirement`: MultipleInputFeatureRequirement on
185
+ workflow outputs.
186
+
40
187
# # Introduction to the CWL Command Line Tool standard v1.2
41
188
42
- This specification represents the latest development release from the
43
- CWL group. Since the v1.1 release, v1.2 introduces the
189
+ Since the v1.1 release, v1.2 introduces the
44
190
following updates to the CWL Command Line Tool standard.
45
191
Documents should use `cwlVersion : v1.2` to make use of new
46
192
syntax and features introduced in v1.2. Existing v1.1 documents
0 commit comments