Closed NeoSoft99 closed 2 weeks ago
It looks like you're using the old .NET based version of the QDK. We shipped a complete re-write at the start of the year (see https://devblogs.microsoft.com/qsharp/announcing-v1-0-of-the-azure-quantum-development-kit/), and recently deprecated the old version.
Do you have an existing project you need to use the old QDK for? If there are scenarios where the new QDK isn't suitable, we'd love to understand why and hopefully fill that gap.
If not, any other reason you are still trying to use the old QDK? For details on installing the latest QDK, see https://learn.microsoft.com/en-us/azure/quantum/install-overview-qdk
Closing. Please comment back if I misunderstood and you're having issues with the current QDK.
Describe the bug
I am trying to build the very basic "hello world" on MacBook M3 and getting exception during the build:
admin@MacBook-Pro-4 QuantumProject % dotnet build
Determining projects to restore... All projects are up-to-date for restore. Determining projects to restore... All projects are up-to-date for restore. Unhandled exception. System.BadImageFormatException: Could not load file or assembly '/Users/admin/.nuget/packages/microsoft.quantum.sdk/0.28.302812/tools/utils/Microsoft.Quantum.Sdk.BuildConfiguration.dll'. An attempt was made to load a program with an incorrect format.
File name: '/Users/admin/.nuget/packages/microsoft.quantum.sdk/0.28.302812/tools/utils/Microsoft.Quantum.Sdk.BuildConfiguration.dll' /var/folders/5p/9jp2chgd0436fmfw51n79nqm0000gn/T/MSBuildTempadmin/tmp43af1a52c80b480d9af64c44f73fd91f.exec.cmd: line 2: 59043 Abort trap: 6 dotnet "/Users/admin/.nuget/packages/microsoft.quantum.sdk/0.28.302812/DefaultItems/../tools/utils/Microsoft.Quantum.Sdk.BuildConfiguration.dll" -v Normal --output "obj/qsharp/config/qsc.config" --QscReferences "(/Users/admin/.nuget/packages/microsoft.quantum.csharpgeneration/0.28.302812/build//../lib/net6.0/Microsoft.Quantum.CSharpGeneration.dll, -1)" /Users/admin/.nuget/packages/microsoft.quantum.sdk/0.28.302812/Sdk/Sdk.targets(68,5): error MSB3073: The command "dotnet "/Users/admin/.nuget/packages/microsoft.quantum.sdk/0.28.302812/DefaultItems/../tools/utils/Microsoft.Quantum.Sdk.BuildConfiguration.dll" -v Normal --output "obj/qsharp/config/qsc.config" --QscReferences "(/Users/admin/.nuget/packages/microsoft.quantum.csharpgeneration/0.28.302812/build//../lib/net6.0/Microsoft.Quantum.CSharpGeneration.dll, -1)"" exited with code 134. [/Users/admin/Projects/QuantumProject/QuantumProject.csproj]
Build FAILED.
I have all the prerequisites installed, and I am able to build successfully c# code on the same machine. The Microsoft.Quantum.Sdk.BuildConfiguration.dll file exists in the specified locataion.
To Reproduce
Steps to reproduce the behavior:
System information
Version of the package or extension for which the problem occurs microsoft.quantum.sdk 0.28.302812
Your operating system Mac OS Sonoma 14.6
For issues with extensions, the version of the IDE for which the problem occurs VS Code Version: 1.92.1 (Universal) Commit: eaa41d57266683296de7d118f574d0c2652e1fc4 Date: 2024-08-07T20:16:39.455Z (6 days ago) Electron: 30.1.2 ElectronBuildId: 9870757 Chromium: 124.0.6367.243 Node.js: 20.14.0 V8: 12.4.254.20-electron.0 OS: Darwin arm64 23.6.0