Say you have an optional task which has run a few times and failed. The status is modified to expired. Someone then reruns it. Should the try number be reset to 1, or should it pick up from where it last tried? At the moment, it will reset to 1.
$ grep INIT_TIME ~/cylc-run/basic-workflow/log/job/20250123T1800Z/*/0?/job.status
/home/username/cylc-run/basic-workflow/log/job/20250123T1800Z/a_0/01/job.status:CYLC_JOB_INIT_TIME=2025-06-30T01:51:36Z
/home/username/cylc-run/basic-workflow/log/job/20250123T1800Z/a_0/02/job.status:CYLC_JOB_INIT_TIME=2025-06-30T01:51:42Z
/home/username/cylc-run/basic-workflow/log/job/20250123T1800Z/a_0/03/job.status:CYLC_JOB_INIT_TIME=2025-06-30T01:51:47Z
# expire "a_0" and then retrigger it
$ grep INIT_TIME ~/cylc-run/basic-workflow/log/job/20250123T1800Z/*/0?/job.status
/home/username/cylc-run/basic-workflow/log/job/20250123T1800Z/a_0/01/job.status:CYLC_JOB_INIT_TIME=2025-06-30T01:59:46Z
/home/username/cylc-run/basic-workflow/log/job/20250123T1800Z/a_0/02/job.status:CYLC_JOB_INIT_TIME=2025-06-30T01:59:52Z
/home/username/cylc-run/basic-workflow/log/job/20250123T1800Z/a_0/03/job.status:CYLC_JOB_INIT_TIME=2025-06-30T01:59:57Z
For reference, the workflow I ran to test this was using Cylc 8.3.6 and 8.4.3. The flow.cylc file was
[scheduler]
allow implicit tasks = True
[scheduling]
initial cycle point = 20250123T18
runahead limit = P2
[[graph]]
T06, T18 = """
a_0:failed? => b_0
a_0[-PT12H]? | b_0[-PT12H] => a_0?
"""
[runtime]
[[root]]
script = false
execution retry delays = PT1S, PT1S
execution time limit = PT60S
[[b_0]]
platform = dm
[[[directives]]]
-l select=1:ncpus=1:mem=2G
I found this issue only happens for a_0 and not for b_0 if you expire and retry it, b_0 lauched try 04 instead of 01 again, so it appears to be linked to expiring optional tasks only.
Not shown here, but the platform of the task does not matter, only whether it has the optional+expired combination.
Say you have an optional task which has run a few times and failed. The status is modified to
expired. Someone then reruns it. Should the try number be reset to 1, or should it pick up from where it last tried? At the moment, it will reset to 1.For reference, the workflow I ran to test this was using Cylc 8.3.6 and 8.4.3. The flow.cylc file was
I found this issue only happens for
a_0and not forb_0if you expire and retry it,b_0lauched try 04 instead of 01 again, so it appears to be linked to expiring optional tasks only.Not shown here, but the platform of the task does not matter, only whether it has the optional+expired combination.