question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Recognize the override file `rust-toolchain`

See original GitHub issue

rustup show automatically installs an overridden toolchain if you have an override file rust-toolchain (Is it a bug? or a feature?).

This unexpected feature(?) of rust show makes toolchain action installs toolchains twice for the example in the README.md if you have the override file. An overridden toolchain is installed on rustup show and an nightly toolchain is installed after that.

It take 35 seconds per toolchain. I know it is not a large amount of time, but it bothers me when there’s a short task like rustfmt (It takes < 3 seconds for my project). CHANGE: I found that it doesn’t call 'rustup show` anymore on the master branch.

Also, I think it is duplicated to put toolchain in the workflow’s input when you have the override file.

Can we automatically recognize the override file to fix this?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:2
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

4reactions
svartalfcommented, Dec 10, 2019

@thomaseizinger of course! I’m a bit short on a time right now, so any PRs would be really appreciated! Your flow of rust-toolchain -> toolchain input -> error seems to be best option here and it will also maintain the backwards compatibility, which is great.

4reactions
phil-oppcommented, Nov 18, 2019

@svartalf How about making the toolchain argument optional and falling back to the rust-toolchain file if it is not given? There should be no breakage this way.

Also, we could default to stable if neither a toolchain argument nor a rust-toolchain file is given.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Overrides - The rustup book
Directories can be assigned their own Rust toolchain with rustup override . When a directory has an override then any time rustc or...
Read more >
Why is my rustup rust-toolchain file not overriding the default?
I'm having a similar issue. $ cat rust-toolchain.toml [toolchain] channel = "nightly" $ rustup show Default host: aarch64-apple-darwin ...
Read more >
Developers - Recognize the override file `rust-toolchain` -
rustup show automatically installs an overridden toolchain if you have an override file rust-toolchain (Is it a bug? or a feature?)
Read more >
Priority of directory override and rust-toolchain file
Create a rust project under ' ~/develop/test/ ' and change to that directory. Set a directory override with ' rustup override set "stable"...
Read more >
rust_toolchain_file - Rust - Docs.rs
... at: https://rust-lang.github.io/rustup/overrides.html#the-toolchain-file. ... Variants which may be used to identify supported rust-toolchain variants.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found