ruff
067c6de4 - Change `EnvironmentOptions::venv-path` to `Option<SystemPathBuf>` (#15631)

Commit
241 days ago
Change `EnvironmentOptions::venv-path` to `Option<SystemPathBuf>` (#15631) ## Summary The `Options` struct is intended to capture the user's configuration options but `EnvironmentOptions::venv_path` supports both a `SitePackages::Known` and `SitePackages::Derived`. Users should only be able to provide `SitePackages::Derived`—they specify a path to a venv, and Red Knot derives the path to the site-packages directory. We'll only use the `Known` variant once we automatically discover the Python installation. That's why this PR changes `EnvironmentOptions::venv_path` from `Option<SitePackages>` to `Option<SystemPathBuf>`. This requires making some changes to the file watcher test, and I decided to use `extra_paths` over venv path because our venv validation is annoyingly correct -- making mocking a venv rather involved. ## Test Plan `cargo test`
Author
Parents
Loading