Skip to content

WinUI apps do not handle "win-x64" RuntimeIdentifier's correctly #20299

@BurkusCat

Description

@BurkusCat

Description

This is possibly a regression. I previously (on MAUI 8.0.3 and NET 8.0.100) was able to produce a MAUI Windows packaged app (albeit with this bug #19763 ) that was able to launch on startup. This was using RID win10-x64. I cannot get a build to produce using win10-x64, presumably due to .NET updating or MAUI updating. I have not been successful in downgrading anything to get it working again.

However, I have been able to build using RID win-x64 which I think makes sense and is probably correct. This build does not start and crashes on launch. In my reproduction, I have build the "weathertwentyone" sample app using a GitHub actions pipeline following the documentation for how to build a packaged WinUI app (https://learn.microsoft.com/en-us/dotnet/maui/windows/deployment/publish-cli?view=net-maui-8.0). In my reproduction I have attached the build artifact and included the git tag of what the source used to build it was. You can look at the other tags or in the actions branch to see more things I tried.

I think a potential cause for the issue is that something now requires win-x64 as the RID, however, something has not been updated to properly handle that RID causing the build produced not to be runnable.

Steps to Reproduce

  1. Create a MAUI application
  2. Follow the guide to produce a pipeline that builds the app for Windows https://learn.microsoft.com/en-us/dotnet/maui/windows/deployment/publish-cli?view=net-maui-8.0 NOTE: win10-x64 has been replaced with win-x64 in my reproduction.

Link to public reproduction project repository

https://github.com/BurkusCat/maui-samples/releases/tag/windows%2F1.6.1

Version with bug

8.0.6

Is this a regression from previous behavior?

Yes, this used to work in .NET MAUI

Last version that worked well

8.0.3

Affected platforms

Windows

Affected platform versions

Windows 11

Did you find any workaround?

No

Relevant log output

Log files when trying to start the app when I attach the Visual Studio debugger:
weather-twenty-one-log-packaged-self-contained.txt

Metadata

Metadata

Labels

area-publishingIssues with the app packaging/publishing process (ipk/apk/msix/trimming)platform/windowss/triagedIssue has been revieweds/verifiedVerified / Reproducible Issue ready for Engineering Triaget/bugSomething isn't working

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions