With RUSTC=rustc, client-side mode skips RUSTC_WORKSPACE_WRAPPER, and server-side mode passes a compile without one as if wrapped
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 56/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Attiva
- Stack tecnologico
- rust
- Ambito
- build-system, tooling
Direzione di ricerca
Start by running the linked gist reproducer with a fresh sccache server in both client-side and server-side modes. Trace how sccache handles RUSTC_WORKSPACE_WRAPPER when RUSTC=rustc, and compare those paths with Cargo's behavior in the reproducer. Done means all four sccache checks match Cargo alone: the wrapper enables the compile, and omitting it produces the expected compile error.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
I found this when cargo dylint, which sets its lint driver as RUSTC_WORKSPACE_WRAPPER, printed none of its lint warnings once RUSTC_WRAPPER=sccache was set.
Steps
Reproducer: https://gist.github.com/YevheniiKotyrlo/3a1d15d595b2c113c559d9ad0587633a
git clone https://gist.github.com/YevheniiKotyrlo/3a1d15d595b2c113c559d9ad0587633a sccache-workspace-wrapper
cd sccache-workspace-wrapper
bash repro.sh /path/to/sccache
repro.sh builds wrapper.rs, a stand-in for a lint driver such as dylint-driver that runs the toolchain's rustc with --cfg wrapped added. It then runs cargo check with RUSTC=rustc on a crate whose lib.rs is
#[cfg(not(wrapped))]
compile_error!("RUSTC_WORKSPACE_WRAPPER did not run");
with and without RUSTC_WORKSPACE_WRAPPER: first without sccache, then with RUSTC_WRAPPER=sccache under SCCACHE_CLIENT_SIDE=1 and under SCCACHE_CLIENT_SIDE=0, each mode on a new server and an empty cache.
Expected
Each cargo check through sccache ends as it does without sccache: exit 0 with the wrapper, and error: RUSTC_WORKSPACE_WRAPPER did not run without it.
Actual
In client-side mode the cargo check with the wrapper fails as if no wrapper were set, and in server-side mode the cargo check without the wrapper passes, which only the wrapper's --cfg wrapped allows:
[…]
summary (sccache 0.20.1):
cargo alone, wrapper: exit 0, the wrapper ran
cargo alone, no wrapper: exit 101, RUSTC_WORKSPACE_WRAPPER did not run
sccache client-side, wrapper: exit 101, RUSTC_WORKSPACE_WRAPPER did not run, where cargo alone ends exit 0, the wrapper ran
sccache client-side, no wrapper: exit 101, RUSTC_WORKSPACE_WRAPPER did not run, as cargo alone
sccache server-side, wrapper: exit 0, the wrapper ran, as cargo alone
sccache server-side, no wrapper: exit 0, the wrapper ran, where cargo alone ends exit 101, RUSTC_WORKSPACE_WRAPPER did not run
verdict: 2 of 4 compiles through sccache end otherwise than cargo alone (exit 1)
Versions
- sccache built from main at 9f8aff3 (it reports
sccache 0.20.1); the v0.20.1 release binary prints the same summary - rustc and cargo 1.100.0 through rustup, run from Git Bash on Windows; the run's first line:
system: MINGW64_NT-10.0-26300 3.6.10-5a1665c8.x86_64 x86_64; sccache 0.20.1; cargo 1.100.0 (3acc79c0c 2026-11-05); rustc 1.100.0 (0ef1bc386 2026-11-09); host x86_64-pc-windows-msvc
[…]
- Lingua principale
- Rust
- Stelle
- 8k
- Fork
- 835
- Merge medio
- 3g 6h
- PR unite (30g)
- 60
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di mozilla/sccache
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
sccache-dist: Docker builder hangs indefinitely — `docker cp -` is never sent EOFForse già presa @oguzhanmeteozturk l’ha presa 114 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
mozilla/sccache#437 · 3 reazioni ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
mozilla/sccache#3082 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di mozilla/sccache
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
Commit lockfileAperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
rust-lang/socket2#703 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
infra
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
available bug good first issue tooling
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
Nixitov/Riptide-Native#817 ·
I maintainer di solito rispondono entro 1 giorno