forgetest: the workflow_steps docstring says which list items the stray-quote rule reads

The docstring said a key with one stray quote as the first key of any
list item makes every step count as no step. The parser reads a step's
first key on its dash line and a list item outside a step, such as a
matrix entry, and does not read a list inside a step's body, so a
stray quote there leaves the step counted. The docstring now says so,
as the Testing page does.

Proof: forgetest-ci "Unit tests" step, test_manifest.py: 39 tests OK
on the committed tree (python -B -m unittest discover -s tests -p
test_manifest.py). pyflakes: clean. Coverage lint on the tree manifest:
0 uncovered, 0 empty, 0 host-tested row problems, 43 tests. The change
is a docstring; no case changes.

Acceptance: none; forgetest is dev-only and manifest.py is in no
catalog fingerprint.
This commit is contained in:
ScottW514
2026-10-17 09:27:43 -04:00
parent 7a71dd80b5
commit 79796b305b
+4 -3
View File
@@ -541,9 +541,10 @@ def workflow_steps(text):
Anything outside a step (a trigger's paths, a job's name) is not a Anything outside a step (a trigger's paths, a job's name) is not a
step. A key with one stray quote (`if":`, `"run:`) at the top level, step. A key with one stray quote (`if":`, `"run:`) at the top level,
at a job's name or a job's key, at a step's key, or as the first key of at a job's name or a job's key, at a step's key, or as the first key of
any list item (a step's first key is on its dash line: `- run": make`) a list item outside a step (a step's first key is on its dash line,
is no key the lint reads: every step of the workflow then carries `- run": make`; a matrix entry is such an item; a list inside a step's
"unread" and counts as no step.""" body is not read) is no key the lint reads: every step of the workflow
then carries "unread" and counts as no step."""
lines = _lines(text) lines = _lines(text)
steps, i = [], 0 steps, i = [], 0
in_jobs, job_at, key_at, job = False, None, None, None in_jobs, job_at, key_at, job = False, None, None, None