-
Notifications
You must be signed in to change notification settings - Fork 344
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[.NET 8 RC1] Error NETSDK1083 "The specified RuntimeIdentifier 'win10-x86' is not recognized" displays in error list after creating a WinUI project #3842
Comments
In the release notes for 1.4 stable they recommend you set UseRidGraph to true. |
@eduardobragaxz Thanks for the workaround, setting |
@XamlTest you're welcome 😀 |
Out of curiosity: The linked guide mentions to add
to the csproj file. Thanks to your comment (which I discovered very late :/ ) I recognized I actually had to add
to my csproj file. At least now one of my Maui 8 RC1 app can be built again without dotnet restore|publish crashing on me.
|
That's interesting. Mine works with the suggested one. |
Workaround for microsoft/WindowsAppSDK#3842
Please update documentation for this new requirement. Or make it not mandatory for final release of .NET 8. Ref: |
This is being addressed, the older non-portable RIDs found in the project templates and publish profiles will be replaced with generic portable RIDs. The NuGet package will also no longer contain or reference non-portable RIDs in its use of runtime libraries. These changes are scheduled for the 1.5 Experimental release. |
Same issue faced on MAUI with .NET 8. |
Having the same issue on .NET 8 MAUI. How to fix this? |
What exactly is the problem are you having? Did you guys add Although... might be different for MAUI, I'm not sure. |
Maui should be setting UseRidGraph for you |
The UseRidGraph needs to be set for every single dependency class library? The problem we are having is that the code doesn't compile. It gives the error |
I don't know if the folder structure is the same with MAUI, but assuming it's the same, what I did was, using file explorer, I went to my project's folder then Properties > PublishProfiles and in the files in this folder I edited the RuntimeIdentifier property from, for example, win10-x64 to win-x64. |
We are not using publish profiles we are using dotnet publish from command. Tried a lot of different options but cannot get this to work in .NET 8. Getting this error: Getting this despite setting |
Oh my bad. |
Why would we set use RID graph to true - isn't the point of this to remove the use of RID graphs? This is a horrible situation. Why should we have to do <arcane manipulations> to make our projects work? I do expect to be able to switch to .net 8 and my projects 'just work'. |
@Gavin-Williams the .NET team made a breaking change on purpose. Not all libraries have had a chance to accommodate this yet, including windows app sdk. But the .net team was clever enough to provide a compatibility switch to use until all libraries in the ecosystem has caught up. So that is why you need to do this. I don't really see the big issue here (albeit I'd like to have seen all the Microsoft sdks being ready for this change but I get that might not be so easy to coordinate). If anything you should take it up in the dotnet/runtime repo, but at this point net8 shipped so the boat has sailed. |
How we go forward with this right now? We cannot build our project for .NET 8 due to this error. Should we set |
Yes. Or set in once in your Directory.build.props file |
I used this workaround in a cross-platform class library. It shut off the initial error but now I receive another:
|
The Windows Community Toolkit is running into this issue when adding a
It's notable that we aren't defining
There was no change in behavior when updating to the latest stable version of Single-project binlog: CommunityToolkit.WinUI.Converters_Debug_AnyCPU_Build_2024-01-10T18_40_33.4371927-06_00.zip Can be reproduced at commit |
@Arlodotexe @bpulliam A potential cause is that dependencies work their runtime targets into WinUI 3 library Microsoft.Graphics.Win2D/1.0.0.30": {
"runtime": {
"lib/net5.0-windows10.0.18362.0/Microsoft.Graphics.Canvas.Interop.dll": {
"assemblyVersion": "1.0.26.0",
"fileVersion": "1.0.26.0"
}
},
"runtimeTargets": {
"runtimes/win10-arm64/native/Microsoft.Graphics.Canvas.dll": {
"rid": "win10-arm64",
"assetType": "native",
"fileVersion": "1.0.0.0"
},
"runtimes/win10-x64/native/Microsoft.Graphics.Canvas.dll": {
"rid": "win10-x64",
"assetType": "native",
"fileVersion": "1.0.0.0"
},
"runtimes/win10-x86/native/Microsoft.Graphics.Canvas.dll": {
"rid": "win10-x86",
"assetType": "native",
"fileVersion": "1.0.0.0"
}
}
},
...
Microsoft.WindowsAppSDK/1.4.231115000": {
"dependencies": {
"Microsoft.Windows.SDK.BuildTools": "10.0.22621.2428"
},
"runtime": {
...
},
"runtimeTargets": {
"runtimes/win10-arm64/native/Microsoft.WindowsAppRuntime.Bootstrap.dll": {
"rid": "win10-arm64",
"assetType": "native",
"fileVersion": "1.4.0.0"
},
"runtimes/win10-x64/native/Microsoft.WindowsAppRuntime.Bootstrap.dll": {
"rid": "win10-x64",
"assetType": "native",
"fileVersion": "1.4.0.0"
},
"runtimes/win10-x86/native/Microsoft.WindowsAppRuntime.Bootstrap.dll": {
"rid": "win10-x86",
"assetType": "native",
"fileVersion": "1.4.0.0"
}
}
}, This is causing the following warning for me on build:
So even the WASDK package isn't setup or being consumed correctly during build yet. |
The reason we have retained the older non-portable RIDs in the current version is to avoid introducing a breaking change in a servicing release for users who are simply upgrading their NuGet package version. In an upcoming minor release we will be aligning more closely with the .NET 8 standards. This means that the older, non-portable RIDs will be phased out in favor of the more general, portable RIDs as per the .NET 8 guidelines |
It really shouldn't be a breaking change, since for instance a However, I can understand wanting to keep changes at a minimum in a patch release, and if it was between this quick-fix or waiting for 1.5.0 which it was initially promised for, I'm more than happy with the current temporary quick-fix. |
This is in 1.5 and can be confirmed in preview 1 |
I'm having also this error, but in this case, the error happens at dependabot when tries to update a project with |
Hmm, so how to resolve this? |
No issue found on last release Visual Studio 2022 17.10.0, .NET SDK 8.0.300
Be aware that If someone is looking for more information, it can be found here. |
I get
using
Do I have to wait for this to be fixed in WinAppSDK? @kmgallahan |
@karmeye can you provide a repro if possible? What version of the Windows App SDK are you using in your project? |
I'm using 1.6.0. Here are the references used: <ItemGroup>
<PackageReference Include="CommunityToolkit.Mvvm" Version="8.3.2" />
<PackageReference Include="CommunityToolkit.WinUI" Version="7.1.2" />
<PackageReference Include="CommunityToolkit.WinUI.Behaviors" Version="8.1.240916" />
<PackageReference Include="CommunityToolkit.WinUI.Controls.Primitives" Version="8.1.240916" />
<PackageReference Include="CommunityToolkit.WinUI.Controls.SettingsControls" Version="8.1.240916" />
<PackageReference Include="CommunityToolkit.WinUI.Controls.TokenizingTextBox" Version="8.1.240916" />
<PackageReference Include="CommunityToolkit.WinUI.Converters" Version="8.1.240916" />
<PackageReference Include="CommunityToolkit.WinUI.Extensions" Version="8.1.240916" />
<PackageReference Include="CommunityToolkit.WinUI.UI.Controls" Version="7.1.2" />
<PackageReference Include="Microsoft.Windows.CsWin32" Version="0.3.106">
<PrivateAssets>all</PrivateAssets>
<!--
https://github.com/Microsoft/CsWin32#usage
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
-->
</PackageReference>
<PackageReference Include="Microsoft.Windows.CsWinRT" Version="2.1.3" />
<PackageReference Include="Microsoft.WindowsAppSDK" Version="1.6.240829007" />
<PackageReference Include="Microsoft.Windows.SDK.BuildTools" Version="10.0.26100.1" />
<PackageReference Include="Microsoft.Xaml.Behaviors.WinUI.Managed" Version="2.0.9" />
<PackageReference Include="NPOI" Version="2.7.0" />
</ItemGroup>
<ItemGroup>
<COMReference Include="Microsoft.Office.Core">
<WrapperTool>tlbimp</WrapperTool>
<VersionMinor>8</VersionMinor>
<VersionMajor>2</VersionMajor>
<Guid>2df8d04c-5bfa-101b-bde5-00aa0044de52</Guid>
<Lcid>0</Lcid>
<Isolated>false</Isolated>
<EmbedInteropTypes>true</EmbedInteropTypes>
</COMReference>
<COMReference Include="Microsoft.Office.Interop.Word">
<WrapperTool>tlbimp</WrapperTool>
<VersionMinor>7</VersionMinor>
<VersionMajor>8</VersionMajor>
<Guid>00020905-0000-0000-c000-000000000046</Guid>
<Lcid>0</Lcid>
<Isolated>false</Isolated>
<EmbedInteropTypes>true</EmbedInteropTypes>
</COMReference>
</ItemGroup> |
@karmeye Your first comment points out which library is causing the issue: |
@kmgallahan Ok, I see. Should one open an issue about it? I mean, it's just a warning now. Unless it affects building and the different publishing options, I guess it's not high prio. |
Describe the bug
There are 3 errors in error list after creating C# WinUI project with .NET 8 RC1.
Errors:
Error NETSDK1083: The specified RuntimeIdentifier 'win10-x86' is not recognized.
Error NETSDK1083: The specified RuntimeIdentifier 'win10-x64' is not recognized.
Error NETSDK1083: The specified RuntimeIdentifier 'win10-arm64' is not recognized.
From the dotnet/docs#36527, we try to update the

<RuntimeIdentifiers>win10-x86;win10-x64;win10-arm64</RuntimeIdentifiers>
to<RuntimeIdentifiers>win-x86;win-x64;win-arm64</RuntimeIdentifiers>
, there still an error: The specified RuntimeIdentifier 'win10-x86' is not recognized.Steps to reproduce the bug
Steps:
Actual Result:

There are 3 errors.
Expected behavior
No errors and warnings.
Screenshots
No response
NuGet package version
None
Windows version
Windows 11 (22H2): Build 22621
Additional context
Environment:
VS version: 17.8.0 Preview 2.0 [34029.95.main]
Windows App SDK version: 1.3.230602002
The text was updated successfully, but these errors were encountered: