Commit 29cec24
authored
fix: Add a hint on
Hello,
# Summary
This PR makes the error message clearer when you try to install packages
into an externally managed Python environment with the `--system` flag.
Now, instead of just failing, the error explains that you're hitting
this because you explicitly used `--system`.
This closes #15639.
# Test plan
- I added a new integration test (`install_with_system_interpreter` in
`pip_install.rs`) that checks the error message includes the hint.
- I tried to run `uv pip install --system -r requirements.txt` to see
the actual error message in action, but had permission issues.uv pip install failure if the --system flag is used to select an externally managed interpreter (#16318)1 parent ed65c24 commit 29cec24
2 files changed
+59
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
236 | 236 | | |
237 | 237 | | |
238 | 238 | | |
239 | | - | |
240 | | - | |
| 239 | + | |
| 240 | + | |
241 | 241 | | |
242 | 242 | | |
243 | 243 | | |
244 | | - | |
245 | | - | |
246 | | - | |
| 244 | + | |
| 245 | + | |
247 | 246 | | |
248 | 247 | | |
249 | | - | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
250 | 260 | | |
| 261 | + | |
| 262 | + | |
251 | 263 | | |
252 | 264 | | |
253 | 265 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12990 | 12990 | | |
12991 | 12991 | | |
12992 | 12992 | | |
| 12993 | + | |
| 12994 | + | |
| 12995 | + | |
| 12996 | + | |
| 12997 | + | |
| 12998 | + | |
| 12999 | + | |
| 13000 | + | |
| 13001 | + | |
| 13002 | + | |
| 13003 | + | |
| 13004 | + | |
| 13005 | + | |
| 13006 | + | |
| 13007 | + | |
| 13008 | + | |
| 13009 | + | |
| 13010 | + | |
| 13011 | + | |
| 13012 | + | |
| 13013 | + | |
| 13014 | + | |
| 13015 | + | |
| 13016 | + | |
| 13017 | + | |
| 13018 | + | |
| 13019 | + | |
| 13020 | + | |
| 13021 | + | |
| 13022 | + | |
| 13023 | + | |
| 13024 | + | |
| 13025 | + | |
| 13026 | + | |
| 13027 | + | |
| 13028 | + | |
| 13029 | + | |
| 13030 | + | |
| 13031 | + | |
| 13032 | + | |
| 13033 | + | |
0 commit comments