Skip to content

Commit f17fed0

Browse files
author
boysha
committed
Merge branch 'master' into fix/requirement_class
2 parents c7e257f + 2a35392 commit f17fed0

File tree

6 files changed

+160
-68
lines changed

6 files changed

+160
-68
lines changed

draft-4/CommandLineTool.yml

Lines changed: 58 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,16 @@ $graph:
4141
This specification represents the fourth milestone of the CWL group.
4242
Since draft-3, this draft introduces the following changes and additions:
4343
44-
* Preliminary support for initialWorkDir & the Directory type
44+
* The [Directory](#Directory) type.
4545
* "id: name" is now just "name"; "class: Classname" is now just
46-
"Classtname".
46+
"Classname".
47+
* [InitialWorkDirRequirement](#InitialWorkDirRequirement): list of
48+
files and subdirectories to be present in the output directory prior
49+
to execution.
50+
* Shortcuts for specifying the standard [output](#stdout) and/or
51+
[error](#stderr) streams as a (streamable) File output.
52+
* SoftwareRequirement: a lightweight method of describing software
53+
dependencies
4754
4855
## Purpose
4956
@@ -385,15 +392,33 @@ $graph:
385392
is equivalent to
386393
```
387394
outputs:
388-
an_output_name:
389-
type: File
390-
outputBinding:
391-
glob: a_stdout_file
395+
an_output_name:
396+
type: File
397+
streamable: true
398+
outputBinding:
399+
glob: a_stdout_file
392400
393401
stdout: a_stdout_file
394402
```
395403
396404
If there is no `stdout` name provided, a random filename will be created.
405+
For example, the following
406+
```
407+
outputs:
408+
an_output_name:
409+
type: stdout
410+
```
411+
is equivalent to
412+
```
413+
outputs:
414+
an_output_name:
415+
type: File
416+
streamable: true
417+
outputBinding:
418+
glob: random_stdout_filenameABCDEFG
419+
420+
stdout: random_stdout_filenameABCDEFG
421+
```
397422
398423
399424
- name: stderr
@@ -407,21 +432,42 @@ $graph:
407432
The following
408433
```
409434
outputs:
410-
an_output_name:
411-
type: stderr
435+
an_output_name:
436+
type: stderr
412437
413438
stderr: a_stderr_file
414439
```
415440
is equivalent to
416441
```
417442
outputs:
418-
an_output_name:
419-
type: File
420-
outputBinding:
421-
glob: a_stderr_file
443+
an_output_name:
444+
type: File
445+
streamable: true
446+
outputBinding:
447+
glob: a_stderr_file
448+
449+
stderr: a_stderr_file
422450
```
423451
424452
If there is no `stderr` name provided, a random filename will be created.
453+
For example, the following
454+
```
455+
outputs:
456+
an_output_name:
457+
type: stderr
458+
```
459+
is equivalent to
460+
```
461+
outputs:
462+
an_output_name:
463+
type: File
464+
streamable: true
465+
outputBinding:
466+
glob: random_stderr_filenameABCDEFG
467+
468+
stderr: random_stderr_filenameABCDEFG
469+
```
470+
425471
426472
- type: record
427473
name: CommandLineTool

draft-4/Process.yml

Lines changed: 26 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,10 @@ $graph:
6767
- name: location
6868
type: string?
6969
doc: |
70-
A URI that identifies the file resource. This may be a relative
71-
reference, in which case it must be resolved using the base URI of the
70+
An IRI that identifies the file resource. This may be a relative
71+
reference, in which case it must be resolved using the base IRI of the
7272
document. The location may refer to a local or remote resource; the
73-
implementation must use the URI to retrieve file content. If an
73+
implementation must use the IRI to retrieve file content. If an
7474
implementation is unable to retrieve the file content stored at a
7575
remote resource (due to unsupported protocol, access denied, or other
7676
issue) it must signal an error.
@@ -98,6 +98,14 @@ $graph:
9898
As a special case, if the `path` field is provided but the `location`
9999
field is not, an implementation may assign the value of the `path`
100100
field to `location`, and remove the `path` field.
101+
102+
If the `path` contains [POSIX shell metacharacters](http://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_02)
103+
(`|`,`&`, `;`, `<`, `>`, `(`,`)`, `$`,`` ` ``, `\`, `"`, `'`,
104+
`<space>`, `<tab>`, and `<newline>`) or characters
105+
[not allowed](http://www.iana.org/assignments/idna-tables-6.3.0/idna-tables-6.3.0.xhtml)
106+
for [Internationalized Domain Names for Applications](https://tools.ietf.org/html/rfc6452)
107+
then implementations may terminate the process with a
108+
`permanentFailure`.
101109
jsonldPredicate:
102110
"_id": "cwl:path"
103111
"_type": "@id"
@@ -175,7 +183,7 @@ $graph:
175183
_type: "@id"
176184
identity: true
177185
doc: |
178-
The format of the file. This must be a URI of a concept node that
186+
The format of the file. This must be a IRI of a concept node that
179187
represents the file format, preferrably defined within an ontology.
180188
If no ontology is available, file formats may be tested by exact match.
181189
@@ -223,11 +231,11 @@ $graph:
223231
- name: location
224232
type: string?
225233
doc: |
226-
A URI that identifies the directory resource. This may be a relative
227-
reference, in which case it must be resolved using the base URI of the
234+
An IRI that identifies the directory resource. This may be a relative
235+
reference, in which case it must be resolved using the base IRI of the
228236
document. The location may refer to a local or remote resource. If
229237
the `listing` field is not set, the implementation must use the
230-
location URI to retrieve directory listing. If an implementation is
238+
location IRI to retrieve directory listing. If an implementation is
231239
unable to retrieve the directory listing stored at a remote resource (due to
232240
unsupported protocol, access denied, or other issue) it must signal an
233241
error.
@@ -250,6 +258,14 @@ $graph:
250258
must not be used in any other context. The command line tool being
251259
executed must be able to to access the directory at `path` using the POSIX
252260
`opendir(2)` syscall.
261+
262+
If the `path` contains [POSIX shell metacharacters](http://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_02)
263+
(`|`,`&`, `;`, `<`, `>`, `(`,`)`, `$`,`` ` ``, `\`, `"`, `'`,
264+
`<space>`, `<tab>`, and `<newline>`) or characters
265+
[not allowed](http://www.iana.org/assignments/idna-tables-6.3.0/idna-tables-6.3.0.xhtml)
266+
for [Internationalized Domain Names for Applications](https://tools.ietf.org/html/rfc6452)
267+
then implementations may terminate the process with a
268+
`permanentFailure`.
253269
jsonldPredicate:
254270
_id: "cwl:path"
255271
_type: "@id"
@@ -349,7 +365,7 @@ $graph:
349365
doc: |
350366
Only valid when `type: File` or is an array of `items: File`.
351367
352-
For input parameters, this must be one or more URIs of a concept nodes
368+
For input parameters, this must be one or more IRIs of a concept nodes
353369
that represents file formats which are allowed as input to this
354370
parameter, preferrably defined within an ontology. If no ontology is
355371
available, file formats may be tested by exact match.
@@ -675,8 +691,7 @@ $graph:
675691
doc: "A long, human-readable description of this process object."
676692
- name: cwlVersion
677693
type:
678-
- "null"
679-
- "#CWLVersions"
694+
- CWLVersions
680695
doc: "CWL document version"
681696
jsonldPredicate:
682697
"_id": "cwl:cwlVersion"
@@ -713,7 +728,7 @@ $graph:
713728
doc: |
714729
This field consists of an array of type definitions which must be used when
715730
interpreting the `inputs` and `outputs` fields. When a `type` field
716-
contain a URI, the implementation must check if the type is defined in
731+
contain a IRI, the implementation must check if the type is defined in
717732
`schemaDefs` and use that definition. If the type is not found in
718733
`schemaDefs`, it is an error. The entries in `schemaDefs` must be
719734
processed in the order listed such that later schema definitions may refer

draft-4/Workflow.yml

Lines changed: 25 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,12 @@ $graph:
2222
- |
2323
# Abstract
2424
25-
A Workflow is an analysis task represented by a directed graph describing
26-
a sequence of operations that transform an input data set to output.
27-
This specification defines the Common Workflow Language (CWL) Workflow
28-
description, a vendor-neutral standard for representing workflows
29-
intended to be portable across a variety of computing platforms.
25+
One way to define a workflow is: an analysis task represented by a
26+
directed graph describing a sequence of operations that transform an
27+
input data set to output. This specification defines the Common Workflow
28+
Language (CWL) Workflow description, a vendor-neutral standard for
29+
representing workflows intended to be portable across a variety of
30+
computing platforms.
3031
3132
- {$include: intro.md}
3233

@@ -85,7 +86,7 @@ $graph:
8586
specializeTo: "#ExpressionToolOutputParameter"
8687
documentRoot: true
8788
doc: |
88-
Execute an expression as a process step.
89+
Execute an expression as a Workflow step.
8990
fields:
9091
- name: "class"
9192
jsonldPredicate:
@@ -164,7 +165,7 @@ $graph:
164165
- name: source
165166
doc: |
166167
Specifies one or more workflow parameters that will provide input to
167-
the underlying process parameter.
168+
the underlying step parameter.
168169
jsonldPredicate:
169170
"_id": "cwl:source"
170171
"_type": "@id"
@@ -187,7 +188,7 @@ $graph:
187188
doc: |
188189
The input of a workflow step connects an upstream parameter (from the
189190
workflow inputs, or the outputs of other workflows steps) with the input
190-
parameters of the underlying process.
191+
parameters of the underlying step.
191192
192193
## Input object
193194
@@ -296,9 +297,9 @@ $graph:
296297
docParent: "#Workflow"
297298
doc: |
298299
A workflow step is an executable element of a workflow. It specifies the
299-
underlying process implementation (such as `CommandLineTool`) in the `run`
300-
field and connects the input and output parameters of the underlying
301-
process to workflow parameters.
300+
underlying process implementation (such as `CommandLineTool` or another
301+
`Workflow`) in the `run` field and connects the input and output parameters
302+
of the underlying process to workflow parameters.
302303
303304
# Scatter/gather
304305
@@ -436,15 +437,15 @@ $graph:
436437
specializeTo: "#WorkflowOutputParameter"
437438
doc: |
438439
A workflow describes a set of **steps** and the **dependencies** between
439-
those processes. When a process produces output that will be consumed by a
440-
second process, the first process is a dependency of the second process.
440+
those steps. When a step produces output that will be consumed by a
441+
second step, the first step is a dependency of the second step.
441442
442443
When there is a dependency, the workflow engine must execute the preceeding
443-
process and wait for it to successfully produce output before executing the
444-
dependent process. If two processes are defined in the workflow graph that
445-
are not directly or indirectly dependent, these processes are
446-
**independent**, and may execute in any order or execute concurrently. A
447-
workflow is complete when all steps have been executed.
444+
step and wait for it to successfully produce output before executing the
445+
dependent step. If two steps are defined in the workflow graph that
446+
are not directly or indirectly dependent, these steps are **independent**,
447+
and may execute in any order or execute concurrently. A workflow is
448+
complete when all steps have been executed.
448449
449450
Dependencies between parameters are expressed using the `source` field on
450451
[workflow step input parameters](#WorkflowStepInput) and [workflow output
@@ -458,21 +459,21 @@ $graph:
458459
459460
## Workflow success and failure
460461
461-
A completed process must result in one of `success`, `temporaryFailure` or
462-
`permanentFailure` states. An implementation may choose to retry a process
462+
A completed step must result in one of `success`, `temporaryFailure` or
463+
`permanentFailure` states. An implementation may choose to retry a step
463464
execution which resulted in `temporaryFailure`. An implementation may
464465
choose to either continue running other steps of a workflow, or terminate
465466
immediately upon `permanentFailure`.
466467
467-
* If any step of a workflow execution results in `permanentFailure`, then the
468-
workflow status is `permanentFailure`.
468+
* If any step of a workflow execution results in `permanentFailure`, then
469+
the workflow status is `permanentFailure`.
469470
470471
* If one or more steps result in `temporaryFailure` and all other steps
471472
complete `success` or are not executed, then the workflow status is
472473
`temporaryFailure`.
473474
474-
* If all workflow steps are executed and complete with `success`, then the workflow
475-
status is `success`.
475+
* If all workflow steps are executed and complete with `success`, then the
476+
workflow status is `success`.
476477
477478
# Extensions
478479

0 commit comments

Comments
 (0)