Skip to content

Commit 76ecf90

Browse files
docs: write down exit-code roles and the smoke coverage model
The missing convention was the defect behind #136, not exit 9. Records per-script 0/2/3+, FATAL 1, smoke 0/1/77, and that blender-smoke has no push trigger on purpose. Signed-off-by: TMHSDigital <154358121+TMHSDigital@users.noreply.github.com> Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent 13ea521 commit 76ecf90

2 files changed

Lines changed: 34 additions & 1 deletion

File tree

‎AGENTS.md‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,9 @@ way, and a one-paragraph rationale. 30 to 80 lines is the right size.
160160
5.2 LTS and 4.5 LTS for every PR. 5.1 is weekly cron, the opt-in
161161
`needs-5.1` PR label (`pull_request` types include `labeled`), or
162162
`workflow_dispatch` with a `series` input. Auto-label does not apply
163-
`needs-5.1`. Contributor-facing notes live in CONTRIBUTING.md. Examples run
163+
`needs-5.1`. Contributor-facing notes for the smoke lever, the deliberate
164+
lack of a `push` trigger, Pages path filters, and the three-role exit-code
165+
convention live in CONTRIBUTING.md. Examples run
164166
through `tests/smoke/run_example.py` (catalog: `tests/smoke/catalog.json`).
165167
SKIP is exit 77 plus a `SMOKE_SKIP:` reason, and only when `--min-version`
166168
is above this Blender; exit 0 with that marker is a vacuous pass and fails.

‎CONTRIBUTING.md‎

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,37 @@ Default PR smoke is Blender 5.2 and 4.5 (`.github/workflows/blender-smoke.yml`).
111111
pick the branch and the `series` input.
112112
- Monday 07:00 UTC cron still runs 5.2, 5.1, and 4.5. Do not treat cron as
113113
PR evidence.
114+
- **There is deliberately no `push` trigger on `blender-smoke.yml`.**
115+
Squash-merging a green PR makes `main` identical to the content already
116+
smoke-tested, so a push job would re-prove the same tree at double the
117+
CI cost. Absence of post-merge smoke is not a coverage gap.
118+
- **`pages.yml` is path-filtered.** A workflow-or-docs-only merge does not
119+
deploy Pages. Observed on `13ea521` (`ci:` #137): Validate, drift-check,
120+
and Release ran; Pages did not. Intentional, not a failed job.
121+
122+
## Exit codes
123+
124+
Three roles, not one global table. Do not copy a code from one script into
125+
another and assume it means the same thing. `9` is a valid sequential-check
126+
code; there is no rule against it.
127+
128+
**Per-script exits** (examples and headless templates). `0` success. `2`
129+
argument or usage error, matching argparse. `3` and above for that script's
130+
own sequential check failures, in the order the checks run. These codes are
131+
file-local and are not portable. `no-mesh` is `2` in
132+
`templates/headless-batch-script-template/` and `5` in
133+
`templates/ai-asset-pipeline-template/`; both are correct. Copy a template's
134+
own table from that template, not from this paragraph.
135+
136+
**FATAL wrapper.** `sys.exit(1)` on an uncaught exception in the `__main__`
137+
guard. Uniform across the examples. `1` means crashed, never a named check.
138+
139+
**Smoke protocol.** Owned by `tests/` and the runner, not by product check
140+
tables. `0` pass, `1` fail (`tests/smoke/run_example.py`,
141+
`tests/check_import_export_rules.py`), `77` skip (`tests/smoke/canary_skip.py`,
142+
and the product scripts that self-skip: `examples/gn-bundle-roundtrip/`,
143+
`examples/exit-pre-sidecar/`). A script under test prints `SMOKE_SKIP:` and
144+
exits 77; the runner records SKIP and returns 0 so the YAML step stays green.
114145

115146
## Standards-version Markers
116147

0 commit comments

Comments
 (0)