mirror of
https://github.com/astral-sh/ruff.git
synced 2025-08-03 18:28:56 +00:00
[red-knot] Log sys-prefix origin for easier debugging (#16921)
## Summary Log the origin of the sys path prefix. This should help with debugging if someone doesn't understand why Red Knot picks up a certain venv. ## Test Plan Ran the CLI and tested that it logs the origin
This commit is contained in:
parent
0360c6b219
commit
7fb765d9b6
1 changed files with 3 additions and 0 deletions
|
@ -224,6 +224,9 @@ impl SearchPaths {
|
|||
|
||||
let site_packages_paths = match python_path {
|
||||
PythonPath::SysPrefix(sys_prefix, origin) => {
|
||||
tracing::debug!(
|
||||
"Discovering site-packages paths from sys-prefix `{sys_prefix}` ({origin}')"
|
||||
);
|
||||
// TODO: We may want to warn here if the venv's python version is older
|
||||
// than the one resolved in the program settings because it indicates
|
||||
// that the `target-version` is incorrectly configured or that the
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue