Skip to content

Env var configuration errors may not always report the env var #7781

@alexcrichton

Description

@alexcrichton

Playing around a bit today, I manage to get a good error (yay!)

$ CARGO_BUILD_PIPELINING=not-a-bool cargo +nightly build
error: error in environment variable `CARGO_BUILD_PIPELINING`: provided string was not `true` or `false` 

but then playing some more I got a different error:

$ CARGO_BUILD_RUSTFLAGS=true cargo +nightly build
error: failed to deserialize, expected a string or array of strings: data did not match any variant of untagged enum Target

Note that the error in the latter one may be attributable to #7780, but despite that maybe being a bug it's probably also a bug that the env var isn't mentioned!

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-configurationArea: cargo config files and env vars

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions