CLI tool flag or command changed between versions
April 30, 2026 · View on GitHub
Playbook ID: cli-flag-changed
Category: build
Severity: medium
Tags: cli, flags, breaking-change, tool-version, argument
What this failure means
A CI script or Makefile invokes a CLI tool with a flag or subcommand that no longer exists in the installed version. A tool upgrade introduced a breaking change to its command-line interface, or the local and CI environments have different tool versions.
Common log signals
unknown flag
unknown option
unrecognized option
invalid flag
flag provided but not defined
no such option
option.*not recognized
unexpected argument
Diagnosis
CLI interface changes commonly occur when:
- A tool is upgraded in CI (via
latesttag or unpinned install) and the new version deprecates or removes a flag - A developer upgrades locally and updates scripts without noticing CI uses an older version
- A flag is renamed (e.g.,
--no-color→--color=never)
Identify the version mismatch:
# Check what version CI is using
tool --version
# Compare against what the script expects
grep -r "tool --flag" . --include="*.sh" --include="Makefile" -l
Look for recent changelog entries describing the change:
# For npm packages
npx tool --help 2>&1 | grep -A2 "removed\|deprecated"
Fix steps
-
Update the script to use the new flag syntax:
# Before (deprecated flag) tool --old-flag value # After tool --new-flag value -
If the change is accidental (a CI upgrade broke things), pin the tool version:
# GitHub Actions - uses: actions/setup-node@v4 with: node-version: '20.11.0' # pin, not '20' or 'lts/*' # Generic - run: npm install -g tool@2.1.0 # pin major+minor+patch -
For tools installed via
apt, pin the version:apt-get install -y tool=2.1.0-1ubuntu1 -
Align local and CI tool versions using a
.tool-versionsfile (asdf) ormise.toml:[tools] mytool = "2.1.0" -
Add a
--versioncheck at the start of CI to surface version mismatches early.
Validation
- Run the updated command locally with the CI tool version.
- Push and confirm the CI step passes.
Likely files to inspect
(Not specified.)
Run Faultline
faultline analyze build.log
faultline explain cli-flag-changed
faultline workflow build.log --json --mode agent
Search phrases this page answers
- CLI tool flag or command changed between versions
- Build: cli tool flag or command changed between versions
- flag provided but not defined
- GitHub Actions cli tool flag or command changed between versions
- faultline explain cli-flag-changed
Generated from playbooks/bundled/log/build/cli-flag-changed.yaml. Do not edit directly — run make docs-generate.