cwltool.builder
Command line builder.
Attributes
Classes
Helper class to construct a command line from a CWL CommandLineTool. |
Functions
Read a file as bytes, respecting the |
|
Read a file as a string, respecting the |
|
|
Perform CWL SecondaryFilesDSL style substitution. |
Module Contents
- cwltool.builder.content_limit_respected_read_bytes(f)
Read a file as bytes, respecting the
CONTENT_LIMIT
.
- cwltool.builder.content_limit_respected_read(f)
Read a file as a string, respecting the
CONTENT_LIMIT
.
- cwltool.builder.substitute(value, replace)
Perform CWL SecondaryFilesDSL style substitution.
- class cwltool.builder.Builder(job, files, bindings, schemaDefs, names, requirements, hints, resources, mutation_manager, formatgraph, make_fs_access, fs_access, job_script_provider, timeout, debug, js_console, force_docker_pull, loadListing, outdir, tmpdir, stagedir, cwlVersion, container_engine)
Bases:
cwltool.utils.HasReqsHints
Helper class to construct a command line from a CWL CommandLineTool.
- Parameters:
job (cwltool.utils.CWLObjectType)
files (list[cwltool.utils.CWLObjectType])
bindings (list[cwltool.utils.CWLObjectType])
schemaDefs (collections.abc.MutableMapping[str, cwltool.utils.CWLObjectType])
names (schema_salad.avro.schema.Names)
requirements (list[cwltool.utils.CWLObjectType])
hints (list[cwltool.utils.CWLObjectType])
mutation_manager (Optional[cwltool.mutation.MutationManager])
formatgraph (Optional[rdflib.Graph])
make_fs_access (type[cwltool.stdfsaccess.StdFsAccess])
fs_access (cwltool.stdfsaccess.StdFsAccess)
job_script_provider (Optional[cwltool.software_requirements.DependenciesConfiguration])
timeout (float)
debug (bool)
js_console (bool)
force_docker_pull (bool)
loadListing (cwltool.utils.LoadListingType)
outdir (str)
tmpdir (str)
stagedir (str)
cwlVersion (str)
container_engine (str)
- job
- files
- bindings
- schemaDefs
- names
- requirements
- hints
- resources
- mutation_manager
- formatgraph
- make_fs_access
- fs_access
- job_script_provider
- timeout
- debug
- js_console
- force_docker_pull
- loadListing
- outdir
- tmpdir
- stagedir
- cwlVersion
- pathmapper: cwltool.pathmapper.PathMapper | None = None
- prov_obj: cwltool.cwlprov.provenance_profile.ProvenanceProfile | None = None
- container_engine
- build_job_script(commands)
Use the job_script_provider to turn the commands into a job script.
- bind_input(schema, datum, discover_secondaryFiles, lead_pos=None, tail_pos=None)
Bind an input object to the command line.
- Raises:
ValidationException – in the event of an invalid type union
WorkflowException – if a CWL Expression (“position”, “required”, “pattern”, “format”) evaluates to the wrong type or if a required secondary file is missing
- Parameters:
- Return type:
list[collections.abc.MutableMapping[str, Union[str, list[int]]]]
- tostr(value)
Represent an input parameter as a string.
- Raises:
WorkflowException – if the item is a File or Directory and the “path” is missing.
- Parameters:
value (Union[collections.abc.MutableMapping[str, str], Any])
- Return type:
- generate_arg(binding)
Convert an input binding to a list of command line arguments.