Skip to content
This repository has been archived by the owner on Jan 22, 2025. It is now read-only.

Improve error message for MSRV error #31428

Closed
acheroncrypto opened this issue May 1, 2023 · 2 comments · Fixed by anza-xyz/cargo#4
Closed

Improve error message for MSRV error #31428

acheroncrypto opened this issue May 1, 2023 · 2 comments · Fixed by anza-xyz/cargo#4
Labels
community Community contribution

Comments

@acheroncrypto
Copy link
Contributor

Problem

The error message for MSRV is misleading because the error results from the version of rustc that ships with solana platform-tools and not the system's rustc.

error: package `winnow v0.4.4` cannot be built because it requires rustc 1.64.0 or newer, while the currently active rustc version is 1.62.0-dev

This is confusing and people rightfully think they should update rust when the actual problem is that solana build tools are outdated.

Proposed Solution

Show a better error message.

error: package `winnow v0.4.4` cannot be built because it requires rustc 1.64.0 or newer, while the currently active rustc version is 1.62.0-dev

Note that this is the rustc version that ships with solana and not your system's rustc version.

Use `solana-install update` or head over to https://docs.solana.com/cli/install-solana-cli-tools to install a newer version.
@pindaroso
Copy link

pindaroso commented May 5, 2023

How did you end up fixing this? Should the Solana version be updated? I ran solana-install update to no avail. On MacOS 3.8 GHz 8-Core Intel Core i7.

@acheroncrypto
Copy link
Contributor Author

How did you end up fixing this? Should the Solana version be updated? I ran solana-install update to no avail. On MacOS 3.8 GHz 8-Core Intel Core i7.

We essentially need a new Solana release to fully solve this problem but in the short term you can either fix this by using a fixed version for problematic crates like this or building the master branch from source since it's not yet released.

The v1.14 branch seems to be getting updated still so I think we'll get 1.14.18 release soon but that's still using rustc 1.62.0-dev. There's PR #31418 to update it on v1.14 branch but it has no traction yet.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
community Community contribution
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants