-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Configuration merge doesn't make sense for credential-provider #14906
Copy link
Copy link
Closed
Labels
A-configurationArea: cargo config files and env varsArea: cargo config files and env varsA-credential-providerArea: credential provider for storing and retreiving credentialsArea: credential provider for storing and retreiving credentialsC-bugCategory: bugCategory: bugS-acceptedStatus: Issue or feature is accepted, and has a team member available to help mentor or reviewStatus: Issue or feature is accepted, and has a team member available to help mentor or reviewS-needs-team-inputStatus: Needs input from team on whether/how to proceed.Status: Needs input from team on whether/how to proceed.
Metadata
Metadata
Assignees
Labels
A-configurationArea: cargo config files and env varsArea: cargo config files and env varsA-credential-providerArea: credential provider for storing and retreiving credentialsArea: credential provider for storing and retreiving credentialsC-bugCategory: bugCategory: bugS-acceptedStatus: Issue or feature is accepted, and has a team member available to help mentor or reviewStatus: Issue or feature is accepted, and has a team member available to help mentor or reviewS-needs-team-inputStatus: Needs input from team on whether/how to proceed.Status: Needs input from team on whether/how to proceed.
Type
Fields
Give feedbackNo fields configured for issues without a type.
Problem
When merging multiple
config.tomlfiles, Cargo concatenates arrays. For theregistries.….credential-providersetting this merging is counter-productive, because it constructs an invalid command.Steps
When there's more than one applicable
cargo.tomlfile that contains:after merging, it becomes:
and results in Cargo running
command arguments cargo:token-from-stdout command arguments, which contains wrong arguments, and can fail in very confusing ways.It's particularly easy to end up with exact duplicates of a custom registry configuration when configs are injected by build tools or projects have their own copy in addition to per-user or per-host configs.
Possible Solution(s)
The
credential-providerfield should be replaced, not concatenated, when merging config files.Notes
No response
Version