mirror of
https://github.com/astral-sh/ruff.git
synced 2025-10-01 14:21:53 +00:00
[red-knot] Support files outside of any workspace (#13041)
## Summary This PR adds basic support for files outside of any workspace in the red knot server. This also limits the red knot server to only work in a single workspace. The server will not start if there are multiple workspaces. ## Test Plan https://github.com/user-attachments/assets/de601387-0ad5-433c-9d2c-7b6ae5137654
This commit is contained in:
parent
4f6accb5c6
commit
c73a7bb929
11 changed files with 56 additions and 39 deletions
|
@ -99,6 +99,11 @@ impl Server {
|
|||
anyhow::anyhow!("Failed to get the current working directory while creating a default workspace.")
|
||||
})?;
|
||||
|
||||
if workspaces.len() > 1 {
|
||||
// TODO(dhruvmanila): Support multi-root workspaces
|
||||
anyhow::bail!("Multi-root workspaces are not supported yet");
|
||||
}
|
||||
|
||||
Ok(Self {
|
||||
connection,
|
||||
worker_threads,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue