rust-lang / rust-lang/rustup

Stop setting CARGO_HOME on Cargo

Open
#4,502 12 comments 6 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Rust
Stars
7k
Forks
1.1k
Avg merge
22h 40m
Merged PRs (30d)
46

Description

Problem you are trying to solve

Cargo would like to detect when the user has set CARGO_HOME and act on that appropriately for https://github.com/rust-lang/cargo/issues/1734 but rustup always sets it

Solution you'd like

At the All Hands, we talked about rustup not setting this anymore. It is set to ensure rustup and cargo are in-sync, particularly when they had different definitions of CARGO_HOME. The first step will be to qualify the versions and platforms for which CARGO_HOME diverged between the two programs so we can evaluate how bad the problem is and what we can do to mitigate it.

Possible mitigations include:

  • Have the users manually set CARGO_HOME when running an old version of Cargo
  • Have the proxy determine whether it needs to set CARGO_HOME, at the risk of impacting performance
Notes

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing where rustup sets CARGO_HOME, then compare the behavior across the Cargo versions and platforms mentioned in the issue. Document where the definitions diverge and evaluate the proposed manual-setting or proxy-detection mitigations; done means the affected combinations and an agreed mitigation are clearly established.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
cli, tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.