26
26
27
27
def arg_parser () -> argparse .ArgumentParser :
28
28
parser = argparse .ArgumentParser (
29
- description = "Reference executor for Common Workflow Language standards."
29
+ description = "Reference executor for Common Workflow Language standards. "
30
+ "Not for production use."
30
31
)
31
32
parser .add_argument ("--basedir" , type = str )
32
33
parser .add_argument (
33
34
"--outdir" ,
34
35
type = str ,
35
36
default = os .path .abspath ("." ),
36
- help = "Output directory, default current directory" ,
37
+ help = "Output directory. The default is the current directory. " ,
37
38
)
38
39
39
40
parser .add_argument (
@@ -47,17 +48,18 @@ def arg_parser() -> argparse.ArgumentParser:
47
48
"--preserve-environment" ,
48
49
type = str ,
49
50
action = "append" ,
50
- help = "Preserve specific environment variable when "
51
- "running CommandLineTools. May be provided multiple "
52
- "times." ,
51
+ help = "Preserve specific environment variable when running "
52
+ "CommandLineTools without a software container . May be provided "
53
+ "multiple times. The default is to preserve only the PATH ." ,
53
54
metavar = "ENVVAR" ,
54
55
default = ["PATH" ],
55
56
dest = "preserve_environment" ,
56
57
)
57
58
envgroup .add_argument (
58
59
"--preserve-entire-environment" ,
59
60
action = "store_true" ,
60
- help = "Preserve all environment variable when running " "CommandLineTools." ,
61
+ help = "Preserve all environment variables when running CommandLineTools "
62
+ "without a software container." ,
61
63
default = False ,
62
64
dest = "preserve_entire_environment" ,
63
65
)
@@ -82,8 +84,8 @@ def arg_parser() -> argparse.ArgumentParser:
82
84
cidgroup = parser .add_argument_group (
83
85
"Options for recording the Docker container identifier into a file."
84
86
)
85
- # Disabled as containerid is now saved by default
86
87
cidgroup .add_argument (
88
+ # Disabled as containerid is now saved by default
87
89
"--record-container-id" ,
88
90
action = "store_true" ,
89
91
default = False ,
@@ -94,7 +96,7 @@ def arg_parser() -> argparse.ArgumentParser:
94
96
cidgroup .add_argument (
95
97
"--cidfile-dir" ,
96
98
type = str ,
97
- help = "Store the Docker " " container ID into a file in the specified directory." ,
99
+ help = "Store the Docker container ID into a file in the specified directory." ,
98
100
default = None ,
99
101
dest = "cidfile_dir" ,
100
102
)
@@ -112,23 +114,31 @@ def arg_parser() -> argparse.ArgumentParser:
112
114
parser .add_argument (
113
115
"--tmpdir-prefix" ,
114
116
type = str ,
115
- help = "Path prefix for temporary directories" ,
117
+ help = "Path prefix for temporary directories. If --tmpdir-prefix is not "
118
+ "provided, then the prefix for temporary directories is influenced by "
119
+ "the value of the TMPDIR, TEMP, or TMP environment variables. Taking "
120
+ "those into consideration, the current default is {}." .format (
121
+ DEFAULT_TMP_PREFIX
122
+ ),
116
123
default = DEFAULT_TMP_PREFIX ,
117
124
)
118
125
119
126
exgroup = parser .add_mutually_exclusive_group ()
120
127
exgroup .add_argument (
121
128
"--tmp-outdir-prefix" ,
122
129
type = str ,
123
- help = "Path prefix for intermediate output directories" ,
124
- default = DEFAULT_TMP_PREFIX ,
130
+ help = "Path prefix for intermediate output directories. Defaults to the "
131
+ "value of --tmpdir-prefix." ,
132
+ default = "" ,
125
133
)
126
134
127
135
exgroup .add_argument (
128
136
"--cachedir" ,
129
137
type = str ,
130
138
default = "" ,
131
- help = "Directory to cache intermediate workflow outputs to avoid recomputing steps." ,
139
+ help = "Directory to cache intermediate workflow outputs to avoid "
140
+ "recomputing steps. Can be very helpful in the development and "
141
+ "troubleshooting of CWL documents." ,
132
142
)
133
143
134
144
exgroup = parser .add_mutually_exclusive_group ()
@@ -173,7 +183,8 @@ def arg_parser() -> argparse.ArgumentParser:
173
183
action = "store_const" ,
174
184
const = "copy" ,
175
185
default = "move" ,
176
- help = "Copy output files to the workflow output directory, don't delete intermediate output directories." ,
186
+ help = "Copy output files to the workflow output directory and don't "
187
+ "delete intermediate output directories." ,
177
188
dest = "move_outputs" ,
178
189
)
179
190
@@ -196,19 +207,21 @@ def arg_parser() -> argparse.ArgumentParser:
196
207
197
208
parser .add_argument (
198
209
"--rdf-serializer" ,
199
- help = "Output RDF serialization format used by --print-rdf (one of turtle (default), n3, nt, xml)" ,
210
+ help = "Output RDF serialization format used by --print-rdf (one of "
211
+ "turtle (default), n3, nt, xml)" ,
200
212
default = "turtle" ,
201
213
)
202
214
203
215
parser .add_argument (
204
216
"--eval-timeout" ,
205
- help = "Time to wait for a Javascript expression to evaluate before giving an error, default 20s." ,
217
+ help = "Time to wait for a Javascript expression to evaluate before giving "
218
+ "an error, default 20s." ,
206
219
type = float ,
207
220
default = 20 ,
208
221
)
209
222
210
223
provgroup = parser .add_argument_group (
211
- "Options for recording provenance " " information of the execution"
224
+ "Options for recording provenance information of the execution"
212
225
)
213
226
provgroup .add_argument (
214
227
"--provenance" ,
@@ -310,7 +323,8 @@ def arg_parser() -> argparse.ArgumentParser:
310
323
exgroup .add_argument (
311
324
"--print-subgraph" ,
312
325
action = "store_true" ,
313
- help = "Print workflow subgraph that will execute " "(can combine with --target)" ,
326
+ help = "Print workflow subgraph that will execute. Can combined with "
327
+ "--target." ,
314
328
)
315
329
exgroup .add_argument (
316
330
"--print-targets" , action = "store_true" , help = "Print targets (output parameters)"
@@ -375,7 +389,7 @@ def arg_parser() -> argparse.ArgumentParser:
375
389
parser .add_argument (
376
390
"--timestamps" ,
377
391
action = "store_true" ,
378
- help = "Add " " timestamps to the errors, warnings, and " " notifications." ,
392
+ help = "Add timestamps to the errors, warnings, and notifications." ,
379
393
)
380
394
parser .add_argument (
381
395
"--js-console" , action = "store_true" , help = "Enable javascript console output"
@@ -388,7 +402,7 @@ def arg_parser() -> argparse.ArgumentParser:
388
402
parser .add_argument (
389
403
"--js-hint-options-file" ,
390
404
type = str ,
391
- help = "File of options to pass to jshint."
405
+ help = "File of options to pass to jshint. "
392
406
'This includes the added option "includewarnings". ' ,
393
407
)
394
408
dockergroup = parser .add_mutually_exclusive_group ()
@@ -432,11 +446,14 @@ def arg_parser() -> argparse.ArgumentParser:
432
446
conda_dependencies = argparse .SUPPRESS
433
447
434
448
if SOFTWARE_REQUIREMENTS_ENABLED :
435
- dependency_resolvers_configuration_help = "Dependency resolver configuration file describing how to adapt 'SoftwareRequirement' packages to current system."
449
+ dependency_resolvers_configuration_help = "Dependency resolver "
450
+ "configuration file describing how to adapt 'SoftwareRequirement' "
451
+ "packages to current system."
436
452
dependencies_directory_help = (
437
453
"Defaut root directory used by dependency resolvers configuration."
438
454
)
439
- use_biocontainers_help = "Use biocontainers for tools without an explicitly annotated Docker container."
455
+ use_biocontainers_help = "Use biocontainers for tools without an "
456
+ "explicitly annotated Docker container."
440
457
conda_dependencies = (
441
458
"Short cut to use Conda to resolve 'SoftwareRequirement' packages."
442
459
)
@@ -477,14 +494,15 @@ def arg_parser() -> argparse.ArgumentParser:
477
494
parser .add_argument (
478
495
"--enable-dev" ,
479
496
action = "store_true" ,
480
- help = "Enable loading and running development versions " "of CWL spec." ,
497
+ help = "Enable loading and running unofficial development versions of "
498
+ "the CWL standards." ,
481
499
default = False ,
482
500
)
483
501
484
502
parser .add_argument (
485
503
"--enable-ext" ,
486
504
action = "store_true" ,
487
- help = "Enable loading and running cwltool extensions " " to CWL spec ." ,
505
+ help = "Enable loading and running ' cwltool:' extensions to the CWL standards ." ,
488
506
default = False ,
489
507
)
490
508
@@ -505,7 +523,8 @@ def arg_parser() -> argparse.ArgumentParser:
505
523
506
524
parser .add_argument (
507
525
"--default-container" ,
508
- help = "Specify a default docker container that will be used if the workflow fails to specify one." ,
526
+ help = "Specify a default software container to use for any "
527
+ "CommandLineTool without a DockerRequirement." ,
509
528
)
510
529
parser .add_argument (
511
530
"--no-match-user" ,
@@ -515,8 +534,8 @@ def arg_parser() -> argparse.ArgumentParser:
515
534
parser .add_argument (
516
535
"--custom-net" ,
517
536
type = str ,
518
- help = "Passed to `docker run` as the '--net' "
519
- "parameter when NetworkAccess is true." ,
537
+ help = "Passed to `docker run` as the '--net' parameter when "
538
+ "NetworkAccess is true, which is its default setting ." ,
520
539
)
521
540
parser .add_argument (
522
541
"--disable-validate" ,
@@ -530,14 +549,14 @@ def arg_parser() -> argparse.ArgumentParser:
530
549
exgroup .add_argument (
531
550
"--enable-ga4gh-tool-registry" ,
532
551
action = "store_true" ,
533
- help = "Enable resolution using GA4GH tool registry API" ,
552
+ help = "Enable tool resolution using GA4GH tool registry API" ,
534
553
dest = "enable_ga4gh_tool_registry" ,
535
554
default = True ,
536
555
)
537
556
exgroup .add_argument (
538
557
"--disable-ga4gh-tool-registry" ,
539
558
action = "store_false" ,
540
- help = "Disable resolution using GA4GH tool registry API" ,
559
+ help = "Disable tool resolution using GA4GH tool registry API" ,
541
560
dest = "enable_ga4gh_tool_registry" ,
542
561
default = True ,
543
562
)
@@ -553,8 +572,9 @@ def arg_parser() -> argparse.ArgumentParser:
553
572
554
573
parser .add_argument (
555
574
"--on-error" ,
556
- help = "Desired workflow behavior when a step fails. One of 'stop' (do not submit any more steps) or "
557
- "'continue' (may submit other steps that are not downstream from the error). Default is 'stop'." ,
575
+ help = "Desired workflow behavior when a step fails. One of 'stop' (do "
576
+ "not submit any more steps) or 'continue' (may submit other steps that "
577
+ "are not downstream from the error). Default is 'stop'." ,
558
578
default = "stop" ,
559
579
choices = ("stop" , "continue" ),
560
580
)
@@ -590,14 +610,14 @@ def arg_parser() -> argparse.ArgumentParser:
590
610
"--force-docker-pull" ,
591
611
action = "store_true" ,
592
612
default = False ,
593
- help = "Pull latest docker image even if" " it is locally present" ,
613
+ help = "Pull latest software container image even if it is locally present" ,
594
614
dest = "force_docker_pull" ,
595
615
)
596
616
parser .add_argument (
597
617
"--no-read-only" ,
598
618
action = "store_true" ,
599
619
default = False ,
600
- help = "Do not set root directory in the" " container as read-only" ,
620
+ help = "Do not set root directory in the container as read-only" ,
601
621
dest = "no_read_only" ,
602
622
)
603
623
@@ -612,17 +632,17 @@ def arg_parser() -> argparse.ArgumentParser:
612
632
"--target" ,
613
633
"-t" ,
614
634
action = "append" ,
615
- help = "Only execute steps that contribute to "
616
- "listed targets (can provide more than once)." ,
635
+ help = "Only execute steps that contribute to listed targets (can be "
636
+ "provided more than once)." ,
617
637
)
618
638
619
639
parser .add_argument (
620
640
"--mpi-config-file" ,
621
641
type = str ,
622
642
default = None ,
623
- help = "Platform specific configuration for MPI (parallel "
624
- "launcher, its flag etc). See README section 'Running MPI-"
625
- "based tools' for details of the format." ,
643
+ help = "Platform specific configuration for MPI (parallel launcher, its "
644
+ "flag etc). See README section 'Running MPI-based tools' for details "
645
+ "of the format." ,
626
646
)
627
647
628
648
parser .add_argument (
@@ -634,7 +654,7 @@ def arg_parser() -> argparse.ArgumentParser:
634
654
help = "path or URL to a CWL Workflow, "
635
655
"CommandLineTool, or ExpressionTool. If the `inputs_object` has a "
636
656
"`cwl:tool` field indicating the path or URL to the cwl_document, "
637
- " then the `workflow ` argument is optional." ,
657
+ " then the `cwl_document ` argument is optional." ,
638
658
)
639
659
parser .add_argument (
640
660
"job_order" ,
0 commit comments