Skip to content

semantic highlighting not working in vscode #3602

@DetachHead

Description

@DetachHead

Describe the Bug

according to the docs, semantic highlighting is supported in vscode but it does not seem to work for me:

Image

running Developer: Inspect Editor Tokens and Scopes in vscode reveals no semantic token info anywhere in the file:

Image

pyrefly 1.0.0

Sandbox Link

No response

(Only applicable for extension issues) IDE Information

semantic token requests do seem to appear in the trace:

[Trace - 4:51:38 PM] Received response 'textDocument/semanticTokens/full - (104)' in 1ms.
Result: {
    "data": [
        0,
        5,
        6,
        0,
        0,
        0,
        14,
        11,
        12,
        512,
        2,
        0,
        11,
        12,
        512,
        3,
        4,
        3,
        12,
        0
    ]
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    language-serverIssues specific to our IDE integration rather than type checkingneeds-triage

    Type

    No fields configured for Bug.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions