You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Name the Single-Line If Requirement in the Schedule Concurrency Drift Message #2889
concurrency_caller_findings in spec/audit.py reports a publisher that gives a schedule run its own concurrency group but whose schedule it cannot read as never publishing. The DRIFT message names what it needs as "a dispatch test in each build-release-task.yml job's if:".
_schedule_never_publishes reads only a single-line job-level if:. A block scalar such as if: >- reduces to an empty condition there, so a release job folding a long condition that way fails the check even when the dispatch conjunct is present.
Impact
An adopter whose release job carries github.event_name == 'workflow_dispatch' inside an if: >- block gets a DRIFT message that names a requirement the job already meets, with no hint that the folded form is the cause.
Suggested fix
Name the single-line requirement in the DRIFT message, matching WORKFLOW.md D4.1, or teach _schedule_never_publishes to read a folded or literal block scalar.
Found while: the local review of the D4.1 dispatch-guard documentation change.
The premise here does not hold on develop. _schedule_never_publishes does not reduce a block-scalar if: to an empty condition. It reads the folded form in full.
_code_view in spec/audit.py keeps a block-scalar if: body and folds it onto the key line. Its docstring says so: "A block-scalar if: body, the form the Workflow YAML convention sets for a multi-line condition, is kept", and "It is folded onto the key line, so a token the condition wraps across two lines still matches whole."
The --selftest concurrency cases include "a folded dispatch gate" (if: >- with github.event_name == 'workflow_dispatch' && on the next line) and "a folded dispatch gate with a comment on its key line". Both expect 0 findings, and both pass.
So the current DRIFT message ("a dispatch test in each build-release-task.yml job's if:") is accurate. Naming a single-line requirement there would make it false.
The real defect was in WORKFLOW.md D4.1. It required the guard in "a single-line if:", which contradicts the if: >- form D9.3 and GOVERNANCE.md "Workflow YAML Conventions" set for a multi-line condition. The fix aligns D4.1 with the parser instead of the message: D4.1 now reads "an && term of its job-level if: holding no || or negated group". The audit message stays unchanged. That change lands in the pull request closing this issue.
Activity
Document the Dispatch Guard for a Schedule That Never Publishes (#2890)
ptr727 commentedon Oct 12, 2026
The premise here does not hold on
develop._schedule_never_publishesdoes not reduce a block-scalarif:to an empty condition. It reads the folded form in full._code_viewinspec/audit.pykeeps a block-scalarif:body and folds it onto the key line. Its docstring says so: "A block-scalarif:body, the form the Workflow YAML convention sets for a multi-line condition, is kept", and "It is folded onto the key line, so a token the condition wraps across two lines still matches whole."--selftestconcurrency cases include "a folded dispatch gate" (if: >-withgithub.event_name == 'workflow_dispatch' &&on the next line) and "a folded dispatch gate with a comment on its key line". Both expect 0 findings, and both pass.So the current DRIFT message ("a dispatch test in each build-release-task.yml job's if:") is accurate. Naming a single-line requirement there would make it false.
The real defect was in WORKFLOW.md D4.1. It required the guard in "a single-line
if:", which contradicts theif: >-form D9.3 and GOVERNANCE.md "Workflow YAML Conventions" set for a multi-line condition. The fix aligns D4.1 with the parser instead of the message: D4.1 now reads "an&&term of its job-levelif:holding no||or negated group". The audit message stays unchanged. That change lands in the pull request closing this issue.Accept a Folded Dispatch Guard in D4.1 and Extend the 5B N/A Rule (#2905