Closed as not planned
Description
Currently the user experience for publishing crates that have invalid or non-conformant keywords is less than ideal.
- the crate is compiled and errors only come from the server after compilation. i.e. it must be fully recompiled for each attempt
- the error for keywords containing spaces comes from the server and is not very clear:
error: api errors: invalid upload request: invalid value: string "static compress", expected a valid keyword specifier at line 1 column 8372
- the error for too many keywords is unnecessarily technical:
error: api errors: invalid upload request: invalid length 9, expected at most 5 keywords per crate at line 1 column 8440
;
cargo publish
should probably do some basic linting on the keywords parameter of the toml, and throw more user-friendly errors than what is currently done. The errors returned by the server are useful for someone hacking away at cargo, not for a developer using cargo (since they refer to the payload generated by the cargo publish
command and sent to the server; i.e. those line and column numbers have no meaning to the end user).