diff --git a/cylc/flow/cfgspec/workflow.py b/cylc/flow/cfgspec/workflow.py index ec33c49e1db..8ad315a7b2c 100644 --- a/cylc/flow/cfgspec/workflow.py +++ b/cylc/flow/cfgspec/workflow.py @@ -802,17 +802,17 @@ def get_script_common_text(this: str, example: Optional[str] = None): :ref:`SequentialTasks`. ''') - Conf('spawn from xtriggers sequentially', VDR.V_BOOLEAN, False, + Conf('sequential xtriggers', VDR.V_BOOLEAN, False, desc=''' If ``True``, tasks that only depend on xtriggers will not spawn - until their previous (cycle point) instance is satisfied. + until the xtrigger of previous (cycle point) instance is satisfied. Otherwise, they will all spawn at once out to the runahead limit. This setting can be overridden by the reserved keyword argument ``sequential`` in individual xtrigger declarations. One sequential xtrigger on a parentless task with multiple - xtriggers will cause sequential behavior. + xtriggers will cause sequential spawning. ''') with Conf('xtriggers', desc=''' This section is for *External Trigger* function declarations - diff --git a/cylc/flow/config.py b/cylc/flow/config.py index 8a3f6df076c..ad87315c4c1 100644 --- a/cylc/flow/config.py +++ b/cylc/flow/config.py @@ -1715,7 +1715,7 @@ def generate_triggers(self, lexpression, left_nodes, right, seq, if self.xtrigger_mgr is not None: self.xtrigger_mgr.sequential_xtriggers_default = ( - self.cfg['scheduling']['spawn from xtriggers sequentially'] + self.cfg['scheduling']['sequential xtriggers'] ) for label in xtrig_labels: try: diff --git a/cylc/flow/xtrigger_mgr.py b/cylc/flow/xtrigger_mgr.py index 762d8aa5ba3..7f53b061463 100644 --- a/cylc/flow/xtrigger_mgr.py +++ b/cylc/flow/xtrigger_mgr.py @@ -204,20 +204,18 @@ class XtriggerManager: # Example: [scheduling] - sequential xtrigger default = True + sequential xtriggers = True [[xtriggers]] - clock_0 = wall_clock() # offset PT0H - clock_1 = wall_clock(offset=PT1H) - # or wall_clock(PT1H) + # "sequential=False" here overrides workflow and function default. + clock_0 = wall_clock(sequential=False) workflow_x = workflow_state( workflow=other, point=%(task_cycle_point)s, - sequential=False ):PT30S [[graph]] PT1H = ''' - @clock_1 & @workflow_x => foo & bar - @wall_clock = baz # pre-defined zero-offset clock + @workflow_x => foo & bar # spawned on workflow_x satisfaction + @clock_0 => baz # baz spawned out to RH ''' Args: @@ -259,7 +257,7 @@ def __init__( # Labels whose xtriggers are sequentially checked. self.sequential_xtrigger_labels: Set[str] = set() # Gather parentless tasks whose xtrigger(s) have been satisfied - # (these will be used to spawn the next occurance). + # (these will be used to spawn the next occurrence). self.sequential_spawn_next: Set[str] = set() self.sequential_has_spawned_next: Set[str] = set() diff --git a/tests/functional/cylc-config/00-simple/section1.stdout b/tests/functional/cylc-config/00-simple/section1.stdout index 87324cc9e97..f5ff23b77ae 100644 --- a/tests/functional/cylc-config/00-simple/section1.stdout +++ b/tests/functional/cylc-config/00-simple/section1.stdout @@ -6,7 +6,7 @@ hold after cycle point = stop after cycle point = cycling mode = integer runahead limit = P4 -spawn from xtriggers sequentially = False +sequential xtriggers = False [[queues]] [[[default]]] limit = 100 diff --git a/tests/functional/xtriggers/04-sequential.t b/tests/functional/xtriggers/04-sequential.t index f89c5454db5..211aa47277f 100644 --- a/tests/functional/xtriggers/04-sequential.t +++ b/tests/functional/xtriggers/04-sequential.t @@ -30,7 +30,7 @@ init_workflow "${TEST_NAME_BASE}" << '__FLOW_CONFIG__' [scheduling] initial cycle point = 3000 runahead limit = P5 - spawn from xtriggers sequentially = True + sequential xtriggers = True [[xtriggers]] clock_1 = wall_clock(offset=P2Y, sequential=False) clock_2 = wall_clock() diff --git a/tests/integration/test_sequential_xtriggers.py b/tests/integration/test_sequential_xtriggers.py index f7deee96eee..cbe0051d084 100644 --- a/tests/integration/test_sequential_xtriggers.py +++ b/tests/integration/test_sequential_xtriggers.py @@ -224,7 +224,7 @@ async def test_override(flow, scheduler, start): """Test that the 'sequential=False' arg can override a default of True.""" wid = flow({ 'scheduling': { - 'spawn from xtriggers sequentially': True, + 'sequential xtriggers': True, 'xtriggers': { 'xt1': 'custom_xt()', 'xt2': 'custom_xt(sequential=False)',