weaver.processes.wps_workflow

Module Contents

weaver.processes.wps_workflow.MonitorFunction[source]
weaver.processes.wps_workflow.LOGGER[source]
weaver.processes.wps_workflow.DEFAULT_TMP_PREFIX = tmp[source]
weaver.processes.wps_workflow.default_make_tool(toolpath_object: Ellipsis, loading_context: cwltool.context.LoadingContext, get_job_process_definition: weaver.typedefs.JobProcessDefinitionCallback) cwltool.process.Process[source]

Generate the tool class object from the CWL definition to handle its execution.

Warning

Package cwltool introduces explicit typing definitions with mypy_extensions. This can cause TypeError("interpreted classes cannot inherit from compiled") when using cwltool.process.Process as base class for our custom definitions below. To avoid the error, we must enforce the type using cast().

class weaver.processes.wps_workflow.WpsWorkflow(toolpath_object: weaver.typedefs.CWL_ToolPathObject, loading_context: cwltool.context.LoadingContext, get_job_process_definition: weaver.typedefs.JobProcessDefinitionCallback)[source]

Definition of a CWL workflow that can execute WPS application packages as intermediate job steps.

Steps are expected to be defined as individual weaver.processes.wps_package.WpsPackage references.

Initialize this CommandLineTool.

job(job_order: Ellipsis, output_callbacks: Callable[[Any, Any], Any], runtime_context: cwltool.context.RuntimeContext) cwltool.utils.JobsGeneratorType[source]

Workflow job generator.

Parameters
  • job_order – inputs of the job submission

  • output_callbacks – method to fetch step outputs and corresponding step details

  • runtime_context – configs about execution environment

Returns

collect_output(schema: Ellipsis, builder: cwltool.builder.Builder, outdir: str, fs_access: cwltool.stdfsaccess.StdFsAccess, compute_checksum: bool = True) Optional[cwltool.utils.CWLOutputType][source]

Collect outputs from the step Process following its execution.

class weaver.processes.wps_workflow.WpsWorkflowJob(builder: Ellipsis, job_order: cwltool.utils.CWLObjectType, make_path_mapper: Callable[Ellipsis, cwltool.pathmapper.PathMapper], requirements: weaver.typedefs.CWL_RequirementsList, hints: weaver.typedefs.CWL_RequirementsList, name: str, wps_process: weaver.processes.wps_process_base.WpsProcessInterface, expected_outputs: List[weaver.typedefs.CWL_Output_Type])[source]

Base class for get_requirement().

Initialize the job object.

_execute(runtime: Ellipsis, env: MutableMapping[str, str], runtime_context: cwltool.context.RuntimeContext, monitor_function: MonitorFunction = None) None[source]

Execute the WPS Process defined as Workflow step and chains their intermediate results.