I'm suddenly getting a bunch of Rust errors from t...
# development
h
I'm suddenly getting a bunch of Rust errors from the pre-commit hook
cargo clippy
invocation, when making changes on a clean master that don't touch rust at all
w
which commit
h
dee363930f4d4f37438695128e082a1266253d26
Fix
--opt
options in constraints.txt files erroring (#11407)
w
i don’t repro for
./cargo clippy
… my system
rust
install is 1.48, but i’m updating to confirm that that isn’t leaking
yea, no leakage. it’s still using
1.48
for pantsbuild/pants.
what kind of errors are you seeing…?
h
output
this is just me running
./cargo clippy --all
on master
./cargo --version
reports 1.47 for me
w
weird! … the
rust-toolchain
file in the root of the repository is there?
and you’re running from the root of the repo?
h
huh just realized
rust-toolchain
says 1.48
but yes it's there
and yes running from the root of the repo
my system rust is 1.49
w
anything interesting in
env
?
h
don't think so
w
the
1.47
bit is definitely the issue. inside the repo i see
1.48
, and outside i see
1.49
(as expected)
h
no
CARGO_
env vars
w
RUSTUP_
…?
h
nope
Copy code
at 14:28:09 ➤ rustup show
Default host: x86_64-unknown-linux-gnu
rustup home:  /home/gregs/.rustup

installed toolchains
--------------------

stable-x86_64-unknown-linux-gnu (default)
1.37.0-x86_64-unknown-linux-gnu
1.38.0-x86_64-unknown-linux-gnu
1.39.0-x86_64-unknown-linux-gnu
1.42.0-x86_64-unknown-linux-gnu
1.43.1-x86_64-unknown-linux-gnu
1.44.0-x86_64-unknown-linux-gnu
1.44.1-x86_64-unknown-linux-gnu
1.45.0-x86_64-unknown-linux-gnu
1.45.2-x86_64-unknown-linux-gnu
1.46.0-x86_64-unknown-linux-gnu
1.47.0-x86_64-unknown-linux-gnu

active toolchain
----------------

1.47.0-x86_64-unknown-linux-gnu (directory override for '/home/gregs/code/pants')
rustc 1.47.0 (18bf6b4f0 2020-10-07)
w
wat…
h
Copy code
at 14:28:50 ➤ cat rust-toolchain 
1.48.0
w
is your rustup old maybe?
h
yeah no idea what's going on
Copy code
at 14:28:51 ➤ rustup --version
rustup 1.23.0 (2020-11-27)
info: This is the version for the rustup toolchain manager, not the rustc compiler.
info: The currently active `rustc` version is `rustc 1.47.0 (18bf6b4f0 2020-10-07)`
w
there was a
rustup --self update
…?
…but that’s fairly new.
oh, hey
h
yeah rustup updates from the arch linux package manger, 1.23 is the latest version
w
Copy code
active toolchain
----------------

1.48.0-x86_64-apple-darwin (overridden by '/Users/stuhood/src/pants/rust-toolchain')
rustc 1.48.0 (7eac88abb 2020-11-16)
note:
Copy code
/Users/stuhood/src/pants/rust-toolchain
so… do you have a separate override configured?
h
huh, maybe I overrode it once and forgot?
w
Copy code
To remove the override and use the default toolchain again, `rustup override unset`.
👍 1
h
yeah that was the problem
apparently I set it to 1.47 at some point
w
👍
h
removing the override forces rustup to download the 1.48 toolchain
👍 1