Skip to content

fix: validate gap generation values - #233

Open
HaoZeke wants to merge 1 commit into
fix/from-commit-version-valuefrom
fix/gap-generation-value
Open

HaoZeke wants to merge 1 commit into
fix/from-commit-version-valuefrom
fix/gap-generation-value

Conversation

@HaoZeke

@HaoZeke HaoZeke commented Nov 19, 2026

Copy link
Copy Markdown
Contributor

With a configured gap stub,
eb-pipeline check --site site.toml --gap-out gap --generation $'2026.1\n2026.2'
exits 0 on main. It writes INFO [check] repro: site file is valid to
standard error and passes the control character to eb-stack.

cmd_check validates --generation before loading the site. The
reproducer exits 2 and writes
ERROR [main] -: --generation must be non-empty and contain no control characters
to standard error.

The new test empty_or_control_generations_fail_before_site_loading in
tests/gap.rs checks invalid --generation values before site loading
or output creation.

With a configured gap stub,
`eb-pipeline check --site site.toml --gap-out gap --generation $'2026.1\n2026.2'`
exits 0 on main. It writes `INFO [check] repro: site file is valid` to
standard error and passes the control character to `eb-stack`.

`cmd_check` validates `--generation` before loading the site. The
reproducer exits 2 and writes
`ERROR [main] -: --generation must be non-empty and contain no control characters`
to standard error.

The new test `empty_or_control_generations_fail_before_site_loading` in
`tests/gap.rs` checks invalid `--generation` values before site loading
or output creation.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant