Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"cannot find current revision for snap rustup" on 'rustup update' #2688

Open
HarrisonHemstreet opened this issue Mar 2, 2021 · 8 comments
Open
Labels
O-linux Linux related

Comments

@HarrisonHemstreet
Copy link

$ rustup update
internal error, please report: running "rustup" failed: cannot find current revision for snap rustup: readlink /snap/rustup/current: no such file or directory

I also deleted some rust files in an attempt to delete the Rust programming language in an attempt to later reinstall because the normal rustup self uninstall was not working

@JohnTitor

This comment has been minimized.

@rbtcollins

This comment has been minimized.

@JohnTitor

This comment has been minimized.

@kinnison

This comment has been minimized.

@kennytm kennytm reopened this Mar 2, 2021
@pietroalbini pietroalbini transferred this issue from rust-lang/rust Mar 2, 2021
@rbtcollins rbtcollins changed the title When I run 'rustup update' I get this error returned: "cannot find current revision for snap rustup" on 'rustup update' Mar 5, 2021
@rbtcollins
Copy link
Contributor

I don't know snappy well enough - is there some command to query the system / interrogate what snappy thinks is the current status of the system ?

@kinnison
Copy link
Contributor

kinnison commented Mar 5, 2021

The way that @HarrisonHemstreet has reported this suggests there's a number of problems at play.

The reported "cannot find current version for snap" is likely due to an incorrect attempt to uninstall the snap. snap uninstall rustup would have likely been the right way, though having damaged the /snap/... tree I'm not sure what the fix will be.

As for rustup self uninstall wouldn't work -- there's at least a pair of things we can do to improve matters.

The first would be to permit non-standard installers (snap, distro packages, etc) to somehow provide some input on how to uninstall (e.g. a string in /etc/rustup/settings.toml perhaps). That way rustup self uninstall could display that instead of simply saying that it doesn't know how.

The second would be that rustup self uninstall should definitely remove the toolchains before reporting the above message so that at minimum the user has cleaned up their ~/.cargo and ~/.rustup which is likely the most important thing they need rid of.

@rbtcollins
Copy link
Contributor

See also #2662

@workingjubilee
Copy link
Member

@rustbot label: +O-linux

@rustbot rustbot added the O-linux Linux related label Apr 29, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
O-linux Linux related
Projects
None yet
Development

No branches or pull requests

7 participants