Exit codes
b8e follows the grep/eslint convention: 0 clean, 1 findings, 2+ operational error — so a
CI step can swallow findings without swallowing a crash. Generated from the CLI_EXIT constant.
| Name | Code | Meaning |
|---|---|---|
clean | 0 | Ran to completion; nothing gated. |
findings | 1 | Ran, and produced gating findings. This is the code a continue-on-error: true step is meant to swallow when you want findings reported but not blocking. |
crash | 2 | The tool failed to run to a valid result — an unresolvable --base, a broken baseline, a failure to emit valid SARIF, or an unexpected error. Distinct from findings so a crash is never mistaken for a clean or advisory run. |
run | 3 | b8e audit only: the command ran, but produced no usable result — no reports came back, or every journey failed. Never returned by b8e scan: a scan that completed keeps its own exit code even when the upload to the dashboard fails, which is reported on stderr instead. |
config | 4 | The invocation was invalid: no organization context, a missing --project / --journeys / --group in a non-interactive run, or an unrecognised value for an enumerated flag such as ci --format or ci --fail-on. |
environment | 5 | The browser or host environment is not ready to launch a browser. |
empty | 6 | A whole-tree scan found zero files to analyze. Distinct from clean, because “I checked everything and it is fine” and “I checked nothing” would otherwise both exit 0 — a misconfigured scan must not read as health. Not returned for a --base diff scope, where analyzing nothing is legitimate (a pull request touching only .md). |
auth | 7 | Not authenticated: no credential the command accepts was present, so it did not run. Every command needs one except --help, --version, the auth group and doctor — either a b8e auth login session, or BINCLUSIVE_API_KEY for a non-interactive run. |