Respect file exclusions in ruff server (#11590)

## Summary

Closes https://github.com/astral-sh/ruff/issues/11587.

## Test Plan

- Added a lint error to `test_server.py` in `vscode-ruff`.
- Validated that, prior to this change, diagnostics appeared in the
file.
- Validated that, with this change, no diagnostics were shown.
- Validated that, with this change, no diagnostics were fixed on-save.
This commit is contained in:
Charlie Marsh 2024-05-28 22:58:36 -04:00 committed by GitHub
parent 531ae5227c
commit 204c59e353
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
11 changed files with 235 additions and 43 deletions

View file

@ -10,6 +10,7 @@ pub(super) fn generate_diagnostics(snapshot: &DocumentSnapshot) -> Diagnostics {
if snapshot.client_settings().lint() {
crate::lint::check(
snapshot.query(),
snapshot.query().settings().file_resolver(),
snapshot.query().settings().linter(),
snapshot.encoding(),
)