toil.wdl.wdl_analysis

Module Contents

Classes

AnalyzeWDL

An interface to analyze a WDL file. Each version corresponds to a subclass that

Attributes

logger

toil.wdl.wdl_analysis.logger
class toil.wdl.wdl_analysis.AnalyzeWDL(wdl_file)[source]

An interface to analyze a WDL file. Each version corresponds to a subclass that restructures the WDL document into 2 intermediate data structures (python dictionaries):

“workflows_dictionary”: containing the parsed workflow information. “tasks_dictionary”: containing the parsed task information.

These are then fed into wdl_synthesis.py which uses them to write a native python script for use with Toil.

Requires a WDL file. The WDL file contains ordered commands.

Parameters

wdl_file (str) –

abstract property version: str

Returns the version of the WDL document as a string.

Return type

str

primitive_types
compound_types
analyze()[source]

Analyzes the WDL file passed into the constructor and generates the two intermediate data structures: self.workflows_dictionary and self.tasks_dictionary.

Returns

Returns nothing.

write_AST(out_dir)[source]

Writes a file with the AST for a wdl file in the out_dir.

create_wdl_primitive_type(key, optional=False)[source]

Returns an instance of WDLType.

Parameters
  • key (str) –

  • optional (bool) –

create_wdl_compound_type(key, elements, optional=False)[source]

Returns an instance of WDLCompoundType.

Parameters
  • key (str) –

  • elements (list) –

  • optional (bool) –