Skip to content

Codelense and lang server errors (Code: -32000 [object Object]) #8186

Open
@damikun

Description

@damikun

After restarting VSCode, I started getting errors in a loop, which makes VSCode unusable for C#.
The errors keep popping up repeatedly as notifications.

I updated VScode.. No result.. i updated all extensions.. no results.. Is this related to recent licens changed for lang serer C# extension ?

Image

Environment data

dotnet --info output:

  6.0.421 [/usr/local/share/dotnet/sdk]
  7.0.408 [/usr/local/share/dotnet/sdk]
  8.0.406 [/usr/local/share/dotnet/sdk]
  9.0.201 [/usr/local/share/dotnet/sdk]

Im on OSx..15.2 (24C101)
VS Code version: Version: 1.99.2 (Universal)
C# Extension version:
2.72.27

C# logs

C# output window contents:

 Resolve version '2025-04-14T06:35:39.5510880Z-12143-0' does not match current version '2025-04-14T06:35:42.4780840Z-12170-0'
   at Microsoft.CodeAnalysis.LanguageServer.Handler.CodeLens.CodeLensResolveHandler.HandleRequestAsync(CodeLens request, RequestContext context, CancellationToken cancellationToken) in /_/src/LanguageServer/Protocol/Handler/CodeLens/CodeLensResolveHandler.cs:line 56
   at Microsoft.CommonLanguageServerProtocol.Framework.QueueItem`1.StartRequestAsync[TRequest,TResponse](TRequest request, TRequestContext context, IMethodHandler handler, String language, CancellationToken cancellationToken)
 at Microsoft.CodeAnalysis.Document.GetSemanticModelHelperAsync(Boolean disableNullableAnalysis, CancellationToken cancellationToken) in /_/src/Workspaces/Core/Portable/Workspace/Solution/Document.cs:line 331
   at Microsoft.CodeAnalysis.Document.GetSemanticModelAsync(SemanticModelOptions options, CancellationToken cancellationToken) in /_/src/Workspaces/Core/Portable/Workspace/Solution/Document.cs:line 286
   at Microsoft.CodeAnalysis.Document.GetRequiredNullableDisabledSemanticModelAsync(CancellationToken cancellationToken) in /_/src/Workspaces/Core/Portable/Workspace/Solution/Document.cs:line 300
   at Microsoft.CodeAnalysis.DocumentHighlighting.AbstractDocumentHighlightsService.GetDocumentHighlightsInCurrentProcessAsync(Document document, Int32 position, IImmutableSet`1 documentsToSearch, HighlightingOptions options, CancellationToken cancellationToken) in /_/src/Features/Core/Portable/DocumentHighlighting/AbstractDocumentHighlightsService.cs:line 68
   at Microsoft.CodeAnalysis.DocumentHighlighting.AbstractDocumentHighlightsService.GetDocumentHighlightsAsync(Document document, Int32 position, IImmutableSet`1 documentsToSearch, HighlightingOptions options, CancellationToken cancellationToken) in /_/src/Features/Core/Portable/DocumentHighlighting/AbstractDocumentHighlightsService.cs:line 59
   at Microsoft.CodeAnalysis.LanguageServer.Handler.DocumentHighlightsHandler.GetReferenceHighlightsAsync(IGlobalOptionService globalOptions, Document document, SourceText text, Int32 position, CancellationToken cancellationToken) in /_/src/LanguageServer/Protocol/Handler/Highlights/DocumentHighlightHandler.cs:line 94
   at Microsoft.CodeAnalysis.LanguageServer.Handler.DocumentHighlightsHandler.GetHighlightsAsync(IGlobalOptionService globalOptions, IHighlightingService highlightingService, Document document, LinePosition linePosition, CancellationToken cancellationToken) in /_/src/LanguageServer/Protocol/Handler/Highlights/DocumentHighlightHandler.cs:line 66
   at Microsoft.CommonLanguageServerProtocol.Framework.QueueItem`1.StartRequestAsync[TRequest,TResponse](TRequest request, TRequestContext context, IMethodHandler handler, String language, CancellationToken cancellationToken)

Steps to reproduce

Just opening c# project

Expected behavior

No errors..

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions