Closed TheOnlylight closed 4 years ago
Thanks for the report, @TheOnlylight! I'll go on and transfer this to the qsharp-compiler repo where we track extension issues, but in the meantime, would you be willing to share the contents of the Q# Language Extension tab of the Output pane? You can get to this pane by going to View → Output, then selecting "Q# Language Extension":
That additional information will be really helpful in diagnosing the issue that you encountered. Thanks!
Hi. I too am facing this issue. The program works even though I get errors stating that the namespaces could not be found. I am using vs code with .net 3.1.300. The version of the windows OS that I am using is 6.1.7601. The screenshot below shows the contents of the Q# Language Extension tab of the Output pane.
Yes, the output clarifies what the issue is! Thanks, @valdaarhun! It looks like the package that we are using for the design time build is older than the dotnet version you are using. We can update that with our next release. Thanks for pointing it out! @ricardo-espinoza It would be good if we could find a more permanent solution than having to explicitly reference and update the NuGet.Frameworks package.
Same namespace issue occurs in mac version as well. Below are the details
Mac version : 10.15.5
VS code version : 1.45.1
dotnet core version : 3.1.300
Q# extension version: 0.11.20042825
Error Message from the output window(Q# Language Extension)
[Error - 5:42:29 PM] MSBuild error in /usr/local/share/dotnet/sdk/3.1.300/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.FrameworkReferenceResolution.targets(59,5): The "ProcessFrameworkReferences" task failed unexpectedly.
System.IO.FileNotFoundException: Could not load file or assembly 'NuGet.Frameworks, Version=5.6.0.5, Culture=neutral, PublicKeyToken=31bf3856ad364e35'. The system cannot find the file specified.
File name: 'NuGet.Frameworks, Version=5.6.0.5, Culture=neutral, PublicKeyToken=31bf3856ad364e35'
at System.Linq.Enumerable.WhereEnumerableIterator`1.ToList()
at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
at Microsoft.NET.Build.Tasks.ProcessFrameworkReferences.ExecuteCore()
at Microsoft.NET.Build.Tasks.TaskBase.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask)
Is there any work arround for this issue, until this get patched ? Thanks.
@venkyms I believe this issue should indeed be fixed with the June 4th release. Unfortunately it might temporarily reoccur until this is fixed or we find an alternative. The workaround in the case of reoccurrence would be to not use the latest dotnet version until we've had a chance to update the package as part of our release.
Hi. I would like to point out that after updating vscode the errors no longer appear and the program runs properly.
Hello everyone, I think this might be happening again, but with a new version of NuGet.Frameworks. I am experiencing the same issue while following the steps of the tutorial: Exercise - Install the QDK for Visual Studio Code (https://docs.microsoft.com/en-us/learn/modules/qsharp-create-first-quantum-development-kit/2-install-quantum-development-kit-code).
I am using MacOS Mojave 10.14.6
with dotnet version 3.1.401
.
Here is the log (with the paths to the project edited out)
[Info - 8:46:39 PM] workspace folder: [edited]
[Error - 8:46:40 PM] MSBuild error in /usr/local/share/dotnet/sdk/3.1.401/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.FrameworkReferenceResolution.targets(59,5): The "ProcessFrameworkReferences" task failed unexpectedly.
System.IO.FileNotFoundException: Could not load file or assembly 'NuGet.Frameworks, Version=5.7.0.7, Culture=neutral, PublicKeyToken=31bf3856ad364e35'. The system cannot find the file specified.
File name: 'NuGet.Frameworks, Version=5.7.0.7, Culture=neutral, PublicKeyToken=31bf3856ad364e35'
at System.Linq.Enumerable.WhereEnumerableIterator`1.ToList()
at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
at Microsoft.NET.Build.Tasks.ProcessFrameworkReferences.ExecuteCore()
at Microsoft.NET.Build.Tasks.TaskBase.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask)
[Error - 8:46:40 PM] Failed to restore project [edited]
[Error - 8:46:40 PM] MSBuild error in /usr/local/share/dotnet/sdk/3.1.401/Sdks/Microsoft.NET.Sdk/targets/Microsoft.NET.Sdk.FrameworkReferenceResolution.targets(59,5): The "ProcessFrameworkReferences" task failed unexpectedly.
System.IO.FileNotFoundException: Could not load file or assembly 'NuGet.Frameworks, Version=5.7.0.7, Culture=neutral, PublicKeyToken=31bf3856ad364e35'. The system cannot find the file specified.
File name: 'NuGet.Frameworks, Version=5.7.0.7, Culture=neutral, PublicKeyToken=31bf3856ad364e35'
at System.Linq.Enumerable.WhereEnumerableIterator`1.ToList()
at System.Linq.Enumerable.ToList[TSource](IEnumerable`1 source)
at Microsoft.NET.Build.Tasks.ProcessFrameworkReferences.ExecuteCore()
at Microsoft.NET.Build.Tasks.TaskBase.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask)
[Error - 8:46:40 PM] Failed to resolve assembly references for project [edited]
Discovered Q# project [edited]
Loading project [edited]
Done loading project [edited]
Hi @abidart, that looks like the same problem as #558. It should be fixed in the next release sometime this week. :) Hopefully, the fix is permanent this time and should continue to work with newer .NET Core versions.
Hi, any update on this?. I'm on Quantum Dev Kit 0.14.2011.120240 with .net core sdk 3.1.405 and getting exactly same issue
Hi @alfogo, this issue was fixed in August, and QDK 0.14.2011120240 should work with .NET Core 3.1.405 SDK. I'm not sure what's causing the problem you're seeing, unfortunately. Could you create a new GitHub issue for it?
I use the vscode on Win10, with .net 3.1.4 the VScode reported red on the namespaces fro Q#, however the program managed to build and run properly ,this is so werid