Skip to content

No diagnostics for LSP client that uses different language identifier #2937

@dhruvmanila

Description

@dhruvmanila

@markhepburn Thank you for providing the logs, that's very useful and it does seem that yours might be a separate issue.

"languageId":"python-base"

Based on the logs for the open document request, it seems that the server uses python-base as the language ID while ty only recognizes python:

https://github.com/astral-sh/ruff/blob/ee277469d3bddb0d5fd59e308263059561be1e0a/crates/ty_server/src/document/text_document.rs#L39-L46

So, this might be an easy fix.

Originally posted by @dhruvmanila in #2824

But, the spec does recommend to use python: https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#textDocumentItem

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentationserverRelated to the LSP server

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions