Defining a new suite

Designing a new workflow encompases two closely tied steps:

  1. Define the suite, which will eventually be composed of tasks, potentially organized in families. The outcome of this step is the suite definition file.

  2. Create the task scripts, that will eventually become job file to be executed.

This section describes how to perform first of these steps.

There are several approaches to defining the suite definition - the two most common are:

  1. Using a plain text file, with a specific syntax.

  2. Using the ecFlow Python API.

This tutorial will give examples for both the plain text and Python methods.

A test-based suite definition is just a plain file, that uses a specific syntax to define the components of a suite (or sets of suites).

To define a simple suite, use a text editor to create a file named test.def, with the following contents:

Listing 1 $HOME/course/test.def
1# A simple example suite
2
3suite test
4  edit ECF_HOME "{{HOME}}/course"
5  task t1
6endsuite

Warning

Please replace {{HOME}} so that path {{HOME}}/course is correct and exists.

This file contains the suite definition of a suite named test. The suite test contains a single task called t1. A line by line explanation of the file above is as follows:

  • Line 1 is a comment line. All characters after the symbol # ignored.

  • Line 2 is empty.

  • Line 3 defines a suite named test.

  • Line 4 defines a variable called ECF_HOME, which defines the directory where all the files that will be used by the suite test will reside.

  • Line 5 defines a task named t1

  • Line 6 indicates the end of the suite definition.

Important

This tutorial will consider the {{HOME}}/course path throughout, and all other file paths will be relative to this base path.

What to do:

  1. Manually create the text-based suite definition file, placing the file at $HOME/course/test.def.

  2. (Optional) Use the Python-based approach to create suite definition file.