-
Notifications
You must be signed in to change notification settings - Fork 310
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
This version of the MVVM Toolkit requires 'Microsoft.Windows.SDK.NET.Ref' version '10.0.19041.38' or later. | [ver. 8.3.1] #951
Comments
This is not a bug and it is quite literally by design, and that error message is telling you exactly what you need to do:
That is, add this to your .csproj: <WindowsSdkPackageVersion>10.0.19041.41</WindowsSdkPackageVersion> |
@Sergio0694 The default sdk package version referenced, if not specified, is |
In one word, AOT. |
What dongle said is correct. The MVVM Toolkit 8.3 has been updated to support trimming and AOT in Windows apps (eg. WinUI 3, UWP, MAUI, etc.). in order to do this, it had to be recompiled against the new version of the Windows SDK projections, which include that support. If you tried to run an app using the MVVM Toolkit using an older version of that package, things would crash at runtime (because the old version isn't compatible). So instead I added a helpful error message to spot the issue early. |
@Sergio0694 Ok, thank you very much for the clarification. |
@Sergio0694 So here is a thing I noticed:
So I thought, what the hell, let's update to the latest version while at it. So I took 10.0.26100.0. |
You're not actually reading the message correctly. It's telling you to set the Windows SDK package version. You changed the target framework instead. That is absolutely not what the message said, and it's expected that doing so will break. |
It's not a bug that you've taken a dependency on a package that isn't released to production yet? |
The package is released to production (eg. here it is). |
Чего вы тут людям голову всякой фигнёй заливаете. Просто у тех у кого не работает ломанная винда стоит и она не обновлялась с версии 21H2. Пусть скачают 23H2 и будет им счастье. |
Стоит 23h2 лицензионная, та же проблема, но с winappsdk пакетом |
Downloaded 8.0.402 today, and running |
The application crashes when displaying canvas SkiaSharp - |
SkiaSharp requires an update, not sure which version. |
I tried it with SkiaSharp versions 2.88.8, 3.0.0preview4.1 - the application crashes the same way, without having time to output
Is this a SkiaSharp or MVVM Toolkit problem? |
the error is a little bit confusing for me too. I also looked at the target os platform. I guess the new communitytoolkit version is based on new sdk versions. i found 10.0.26100.45 which seems to be ready for .net 9. Anyway, I temporarily moved back community toolkit to version 8.2.2 to get solution being compiled |
@karmeye that's expected. 8.0.402 doesn't include the fix. You'll need .403 which comes out next month.
@alex3696 this issue is just about a build issue. For a runtime crash, please open another issue.
@FrancescoCarraro .45 is for .NET 8 as well, but also you shouldn't reference it manually. Just follow the error message notes. |
@Sergio0694 Aha, thank you. I was confused by the error message as it says: "Please update to .NET SDK 8.0.109, 8.0.305 or 8.0.402." Would that be on patch Tuesday next month? Is 403 the version that's referred to as the "next servicing update" in the note here? Thx |
Yeah the version in the message is wrong because things happened and the fix in the .NET SDK was delayed 🥲 |
Describe the bug
Any .NET MAUI project using this library ver. 8.3.1, gets the following message when the library is added.
MVVMTKCFG0003
This version of the MVVM Toolkit requires 'Microsoft.Windows.SDK.NET.Ref' version '10.0.19041.38' or later. Please update to .NET SDK 8.0.109, 8.0.305 or 8.0.402 (or later).
Alternatively, use a temporary 'Microsoft.Windows.SDK.NET.Ref' reference, which can be done by setting the 'WindowsSdkPackageVersion' property in your .csproj file.
For your project configuration, it is recommended to set the package version to '10.0.19041.41'.
Regression
No response
Steps to reproduce
Expected behavior
No error.
.NET SDK 8.0.402 is not out yet.
The package version to '10.0.19041.41' is not listed among the Windows Targets in the project.
Screenshots
No response
IDE and version
VS 2022
IDE version
No response
Nuget packages
Nuget package version(s)
8.3.1
Additional context
No response
Help us help you
No, just wanted to report this
The text was updated successfully, but these errors were encountered: