Skip to content

Bad non-descriptive error message in src/error.rs in invalid_cargo_config function #933

@Rx1513

Description

@Rx1513

I'm currently packaging cargo upgrade and bumped into "Invalid cargo config" error during running tests. And it created like ton of questions: What is this even supposed to mean? Like what one of multiple cargo configs is invalid? What is considered "invalid"? Is it broken symbols? Is it broken paths? What do I do to fix this error?

So, you got the point, this error does not provide the user with almost any useful information to correct the error. It would be better if this error provided the user with information such as "what config", "why is it invalid" and "how to fix it".

Actually, the problem was that I was using .cargo/config.toml for vendoring, which doesn't really match the common build configuration.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions