circleci config validate: Error: All Workflows have been filtered from this Pipeline with workflow-level...

Running circleci config validate on a config where every workflow is gated by a when condition (e.g. when: <[pipeline.parameters.go]> defaulting to false) failed with the confusing message: Error: All Workflows have been filtered from this Pipeline. The config was actually fine; the legacy CLI validated without supplying local pipeline values, so all workflows were filtered out and validation reported them as missing rather than as conditionally skipped.

This was fixed in the rewritten CircleCI CLI v1: the new CLI supplies a complete set of local pipeline values when validating, so a config whose workflows are all conditionally skipped now validates as valid instead of erroring. A maintainer re-ran the exact reproduction case (circleci config validate -c config.yml) on v1 and confirmed it prints Config file at "config.yml" is valid. with no All Workflows have been filtered from this Pipeline error. Upgrade to CLI v1 to get the fix.

Source: https://github.com/CircleCI-Public/circleci-cli/issues/577

Source: https://github.com/CircleCI-Public/circleci-cli/issues/577