Skip to content

Retire the unprefixed env aliases (VERBOSE, COVERAGE, PARALLEL_RUN, …) #866

Description

@Chemaclass

Every setting in src/env.sh resolves as:

: "${BASHUNIT_X:=${X:=$_BASHUNIT_DEFAULT_X}}"

so roughly 36 bare names still configure bashunit: DEFAULT_PATH, VERBOSE, COVERAGE, PROFILE, STRICT_MODE, SIMPLE_OUTPUT, PARALLEL_RUN, TEST_TIMEOUT, and more.

The BASHUNIT_ prefix landed in 0.15.0 (~23 months ago). .env.example documents only the prefixed names; so does docs/configuration.md. The bare forms are undocumented back-compat.

This is an active hazard, not just cruft. The := form assigns the bare name as a side effect, and the names are extremely generic — a CI job that exports VERBOSE=true or COVERAGE=true for an unrelated tool silently reconfigures bashunit.

The codebase already agrees the pattern is wrong: src/env.sh documents exactly this reasoning as the justification for not adding bare aliases for RETRY, RANDOM_ORDER, SEED and SHARD_*. It simply hasn't retired the existing ones.

Precedent for breaking here exists (the 0.29.0 namespace break, the 0.30.0 --preserve-env rename).

Suggested path: emit a deprecation warning when a bare name is what supplied the value, for one minor; then drop them.

Found during the #862 audit; left alone there because it is a breaking change and the maintainer's call.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

Status
No status

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions