These are chat archives for rust-lang/rust

26th
Dec 2017
Michal 'vorner' Vaner
@vorner
Dec 26 2017 09:04
Hello. Does crates.io have/plan to have some kind of user reviews/stars systems or so? I'm… having a conversation with an author of a crate. He obviously has unsafe API, but refuses to mark it as such, allowing his users to UB themselves in their feet. And I think the users should be warned about it upfront somehow. Xudong-Huang/may#6
Restioson
@Restioson
Dec 26 2017 12:18
eish
should make it unsafe
Hmm
Restioson
@Restioson
Dec 26 2017 14:09
@vorner xudong said they'd make it unsafe now I think
Michal 'vorner' Vaner
@vorner
Dec 26 2017 15:29
Yes, I hope. But I'm afraid one one someone will just refuse, and some kind of user feedback would help distinguish good crates from the less good.
Jeremy Lempereur
@o0Ignition0o
Dec 26 2017 16:06
@Restioson you're right https://github.com/Xudong-Huang/may/issues/6#issuecomment-353969139 I do see the point though, since anyone could create a library and "hide UBs" everywhere, which would break one of Rust's main promises
Ryan
@rnleach
Dec 26 2017 16:41
OK, I just ran a rustup update and got a warning saying I should delete my rustfmt and cargo-fmt binaries in ~/.cargo/bin/. I did that, and now I cannot get rustfmt back. I've been searching and found the issue and blog post by nrc, but I still haven't been able to get it back by running rustup component add rustfmt or any cargo commands. Any ideas?
Hans W. Uhlig
@huhlig
Dec 26 2017 16:42
delete everything and reinstall
delete ~/.cargo ~/.multirust and ~/.rustup
and then reinstall from rustup
it was a pita but that fixed it
Ryan
@rnleach
Dec 26 2017 16:43
Well, that was the next step I had in mind, but it seems a little extreme. Is this the intended upgrade path? I didn't see that documented anywhere?
Hans W. Uhlig
@huhlig
Dec 26 2017 16:44
not that I know of
I just know that's how I fixed it
Ryan
@rnleach
Dec 26 2017 17:24
@huhlig I did the re-install, and it still doesn't work. It says that the toolchain does not have that binary. I'm on nightly on mac/darwin
Ryan
@rnleach
Dec 26 2017 17:35
I had to use cargo install --force rustfmt-nightly to finally get it to work. The --force was the important missing part. Even after the clean install.
Michal 'vorner' Vaner
@vorner
Dec 26 2017 19:41
I guess I'm a bit late, but for the record, rustup self update did the trick for me (don't ask me why).