Skip to content

C# prerelease version of C# extension errors with .NET 6 #5836

@johnnyreilly

Description

@johnnyreilly

Environment data

dotnet --info output:

dotnet --info
.NET SDK (reflecting any global.json):
 Version:   6.0.408
 Commit:    0c3669d367

Runtime Environment:
 OS Name:     Mac OS X
 OS Version:  13.3
 OS Platform: Darwin
 RID:         osx.13-x64
 Base Path:   /usr/local/share/dotnet/sdk/6.0.408/

global.json file:
  Not found

Host:
  Version:      6.0.16
  Architecture: x64
  Commit:       1e620a42e7

.NET SDKs installed:
  6.0.408 [/usr/local/share/dotnet/sdk]

.NET runtimes installed:
  Microsoft.AspNetCore.App 6.0.16 [/usr/local/share/dotnet/shared/Microsoft.AspNetCore.App]
  Microsoft.NETCore.App 6.0.16 [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]

Download .NET:
  https://aka.ms/dotnet-download

Learn about .NET Runtimes and SDKs:
  https://aka.ms/dotnet/runtimes-sdk-info

VS Code version:

Version: 1.79.2
Commit: 695af097c7bd098fbf017ce3ac85e09bbc5dda06
Date: 2023-06-14T08:58:52.392Z (5 days ago)
Electron: 22.5.7
Chromium: 108.0.5359.215
Node.js: 16.17.1
V8: 10.8.168.25-electron.0
OS: Darwin x64 22.4.0

C# Extension version: v2.0.212

OmniSharp log

Activating C# + C# Dev Kit + C# IntelliCode...
You must install or update .NET to run this application.

App: /Users/jreilly/.vscode/extensions/ms-dotnettools.csharp-2.0.212-darwin-x64/.roslyn/Microsoft.CodeAnalysis.LanguageServer.dll
Architecture: x64
Framework: 'Microsoft.NETCore.App', version '7.0.0-preview.7.22362.8' (x64)
.NET location: /usr/local/share/dotnet/

The following frameworks were found:
  6.0.16 at [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]

Learn about framework resolution:
https://aka.ms/dotnet/app-launch-failed

To install missing framework, download:
https://aka.ms/dotnet-core-applaunch?framework=Microsoft.NETCore.App&framework_version=7.0.0-preview.7.22362.8&arch=x64&rid=osx.13-x64
[Info  - 08:15:31] Connection to server got closed. Server will restart.
[Error - 08:15:31] Server initialization failed.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 08:15:31] Microsoft.CodeAnalysis.LanguageServer client: couldn't create connection to server.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
Dotnet path: /Users/jreilly/Library/Application Support/Code/User/globalStorage/ms-dotnettools.vscode-dotnet-runtime/.dotnet/7.0.7/dotnet
Activating C# + C# Dev Kit + C# IntelliCode...
You must install or update .NET to run this application.

App: /Users/jreilly/.vscode/extensions/ms-dotnettools.csharp-2.0.212-darwin-x64/.roslyn/Microsoft.CodeAnalysis.LanguageServer.dll
Architecture: x64
Framework: 'Microsoft.NETCore.App', version '7.0.0-preview.7.22362.8' (x64)
.NET location: /usr/local/share/dotnet/

The following frameworks were found:
  6.0.16 at [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]

Learn about framework resolution:
https://aka.ms/dotnet/app-launch-failed

To install missing framework, download:
https://aka.ms/dotnet-core-applaunch?framework=Microsoft.NETCore.App&framework_version=7.0.0-preview.7.22362.8&arch=x64&rid=osx.13-x64
[Info  - 08:15:31] Connection to server got closed. Server will restart.
[Error - 08:15:31] Server initialization failed.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 08:15:31] Microsoft.CodeAnalysis.LanguageServer client: couldn't create connection to server.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
Dotnet path: /Users/jreilly/Library/Application Support/Code/User/globalStorage/ms-dotnettools.vscode-dotnet-runtime/.dotnet/7.0.7/dotnet
Activating C# + C# Dev Kit + C# IntelliCode...
You must install or update .NET to run this application.

App: /Users/jreilly/.vscode/extensions/ms-dotnettools.csharp-2.0.212-darwin-x64/.roslyn/Microsoft.CodeAnalysis.LanguageServer.dll
Architecture: x64
Framework: 'Microsoft.NETCore.App', version '7.0.0-preview.7.22362.8' (x64)
.NET location: /usr/local/share/dotnet/

The following frameworks were found:
  6.0.16 at [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]

Learn about framework resolution:
https://aka.ms/dotnet/app-launch-failed

To install missing framework, download:
https://aka.ms/dotnet-core-applaunch?framework=Microsoft.NETCore.App&framework_version=7.0.0-preview.7.22362.8&arch=x64&rid=osx.13-x64
[Info  - 08:15:31] Connection to server got closed. Server will restart.
[Error - 08:15:31] Server initialization failed.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 08:15:31] Microsoft.CodeAnalysis.LanguageServer client: couldn't create connection to server.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 08:15:31] Restarting server failed
  Message: Pending response rejected since connection got disposed
  Code: -32097 
Dotnet path: /Users/jreilly/Library/Application Support/Code/User/globalStorage/ms-dotnettools.vscode-dotnet-runtime/.dotnet/7.0.7/dotnet
Activating C# + C# Dev Kit + C# IntelliCode...
You must install or update .NET to run this application.

App: /Users/jreilly/.vscode/extensions/ms-dotnettools.csharp-2.0.212-darwin-x64/.roslyn/Microsoft.CodeAnalysis.LanguageServer.dll
Architecture: x64
Framework: 'Microsoft.NETCore.App', version '7.0.0-preview.7.22362.8' (x64)
.NET location: /usr/local/share/dotnet/

The following frameworks were found:
  6.0.16 at [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]

Learn about framework resolution:
https://aka.ms/dotnet/app-launch-failed

To install missing framework, download:
https://aka.ms/dotnet-core-applaunch?framework=Microsoft.NETCore.App&framework_version=7.0.0-preview.7.22362.8&arch=x64&rid=osx.13-x64
[Info  - 08:15:31] Connection to server got closed. Server will restart.
[Error - 08:15:31] Server initialization failed.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 08:15:31] Microsoft.CodeAnalysis.LanguageServer client: couldn't create connection to server.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 08:15:31] Restarting server failed
  Message: Pending response rejected since connection got disposed
  Code: -32097 
Dotnet path: /Users/jreilly/Library/Application Support/Code/User/globalStorage/ms-dotnettools.vscode-dotnet-runtime/.dotnet/7.0.7/dotnet
Activating C# + C# Dev Kit + C# IntelliCode...
You must install or update .NET to run this application.

App: /Users/jreilly/.vscode/extensions/ms-dotnettools.csharp-2.0.212-darwin-x64/.roslyn/Microsoft.CodeAnalysis.LanguageServer.dll
Architecture: x64
Framework: 'Microsoft.NETCore.App', version '7.0.0-preview.7.22362.8' (x64)
.NET location: /usr/local/share/dotnet/

The following frameworks were found:
  6.0.16 at [/usr/local/share/dotnet/shared/Microsoft.NETCore.App]

Learn about framework resolution:
https://aka.ms/dotnet/app-launch-failed

To install missing framework, download:
https://aka.ms/dotnet-core-applaunch?framework=Microsoft.NETCore.App&framework_version=7.0.0-preview.7.22362.8&arch=x64&rid=osx.13-x64
[Error - 08:15:31] The Microsoft.CodeAnalysis.LanguageServer server crashed 5 times in the last 3 minutes. The server will not be restarted. See the output for more information.
[Error - 08:15:31] Server initialization failed.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 08:15:31] Microsoft.CodeAnalysis.LanguageServer client: couldn't create connection to server.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 08:15:31] Restarting server failed
  Message: Pending response rejected since connection got disposed
  Code: -32097 

Steps to reproduce

  1. Install the C# plugin with .NET 6 installed locally
  2. See errors

Expected behavior

C# plugin works.

Actual behavior

C# plugin doesn't work.

Additional context

Add any other context about the problem here.

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions