Skip to content

Conversation

snowsignal
Copy link
Contributor

Summary

Fixes #11534.

DocumentQuery::source_type now returns PySourceType::Stub when the document is a .pyi file.

Test Plan

I confirmed that stub-specific rule violations appeared with a build from this PR (they were not visible from a main build).

Screenshot 2024-05-24 at 2 15 38 PM

@snowsignal snowsignal added bug Something isn't working server Related to the LSP server labels May 24, 2024
Copy link
Contributor

ruff-ecosystem results

Linter (stable)

✅ ecosystem check detected no linter changes.

Linter (preview)

✅ ecosystem check detected no linter changes.

@charliermarsh charliermarsh self-assigned this May 26, 2024
@charliermarsh charliermarsh merged commit 9567fdd into main May 26, 2024
@charliermarsh charliermarsh deleted the jane/server/pyi branch May 26, 2024 17:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working server Related to the LSP server
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[ruff server] LSP treats pyi/stub files as regular python files instead of stub files. ruff-lsp does the right thing.
2 participants