mirror of
https://github.com/astral-sh/uv.git
synced 2025-11-01 20:31:12 +00:00
## Summary This PR addresses an issue on Windows where `std::fs::canonicalize` can fail or panic when resolving paths on mapped network drives. By replacing it with `Simplified::simple_canonicalize`, we aim to improve the robustness and cross-platform compatibility of path resolution. ### Changes * Updated `CANONICAL_CWD` in `path.rs` to use `Simplified::simple_canonicalize` instead of `std::fs::canonicalize`. ### Why * `std::fs::canonicalize` has known issues with resolving paths on mapped network drives on Windows, which can lead to panics or incorrect path resolution. * `Simplified::simple_canonicalize` internally uses `dunce::canonicalize`, which handles these cases more gracefully, ensuring better stability and reliability. ## Test Plan Since `simple_canonicalize` has already been tested in a prior PR, this change is expected to work without introducing any new issues. No additional tests are necessary beyond ensuring existing tests pass, which will confirm the correctness of the change. |
||
|---|---|---|
| .. | ||
| src | ||
| Cargo.toml | ||