Skip to content
This repository was archived by the owner on Jan 12, 2024. It is now read-only.
This repository was archived by the owner on Jan 12, 2024. It is now read-only.

Language server does not support .NET 5 SDK #737

Open
@bamarsha

Description

@bamarsha

Describe the bug

After installing the .NET 5 SDK, the language server can't load Q# projects:

[Info - 12:15:44] workspace folder: c:\Users\samarsha\Desktop\QSharpSandbox
[Error - 12:15:45] Error on loading project 'c:\Users\samarsha\Desktop\QSharpSandbox\Library\Library.csproj': Der SDK-Resolvertyp "WorkloadSdkResolver" konnte nicht geladen werden. Could not load file or assembly 'System.Runtime, Version=5.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. Das System kann die angegebene Datei nicht finden. c:\Users\samarsha\Desktop\QSharpSandbox\Library\Library.csproj.
Ignoring non-Q# project 'c:\Users\samarsha\Desktop\QSharpSandbox\Library\Library.csproj'.
[Error - 12:15:45] Error on loading project 'c:\Users\samarsha\Desktop\QSharpSandbox\App\App.csproj': Der SDK-Resolvertyp "WorkloadSdkResolver" konnte nicht geladen werden. Could not load file or assembly 'System.Runtime, Version=5.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. Das System kann die angegebene Datei nicht finden. c:\Users\samarsha\Desktop\QSharpSandbox\App\App.csproj.
Ignoring non-Q# project 'c:\Users\samarsha\Desktop\QSharpSandbox\App\App.csproj'.
[Info - 12:15:45] The file c:\Users\samarsha\Desktop\QSharpSandbox\App\App.qs is not associated with a compilation unit. Only syntactic diagnostics are generated.

To Reproduce

Steps to reproduce the behavior:

  1. Open a Q# project in VS Code

System information

  • QDK extension v0.13.20111004 for VS Code
  • Windows 10, .NET 5.0.100
  • VS Code 1.51.1

Additional context

The Q# project file is:

<Project Sdk="Microsoft.Quantum.Sdk/0.13.20111004">
  <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>netcoreapp3.1</TargetFramework>
    <QscVerbosity>detailed</QscVerbosity>
  </PropertyGroup>
</Project>

The project builds and runs successfully from the command line.

Metadata

Metadata

Labels

area: editorExtensions for Visual Studio and Visual Studio CodebugSomething isn't workingstatus: blockedWaiting for external dependencies

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions