Replies: 3 comments
-
It's been GA and fully supported for over two months now (since Visual Studio 17.13), the blog post is a bit outdated 🙂
To clarify, that only applies to legacy UWP apps. UWP .NET 9 apps use the normal .NET SDK and
I probably wouldn't recommend adding support for legacy UWP now, if you didn't already support it before.
You shouldn't have added any other UI frameworks to the same NuGet package either, as it's an endless source of issues. In the Microsoft Store I ended up having to crack the
That was an unrelated issue with the .NET SDK or something, and yeah it was affecting everyone. Should be fixed in .NET 10 Preview 5.
Unfortunately, yes. See the hack I had to do for the Microsoft Store as well, for the same reason.
The API surface should be identical between the two, as far as "UWP APIs" go.
Ideally:
Love seeing some interest here by the way, this is great! 😄 |
Beta Was this translation helpful? Give feedback.
-
Huh. So I tried to install it on my non-preview VS install, and it didn't show up as an option in the installer. I had to go to my preview VM to see it. That's why I was under the impression that it was still in preview. Must be something busted on my machine...
I can't express how much I would like legacy UWP not already to be baked into the main But we've had support in there for years, so unfortunately v.next of
I didn't! It was like that when we took over. I've just been trying to work out how to fix that mess we inherited, so I'm painfully awre of what a bad idea that was.
Yes - once we decide on how we're going to back out the aspect of the 'great unification' that led to all the UI stuff going into So I think fixing the great over-unification by separating out the UI framework support will probably do what you want. |
Beta Was this translation helpful? Give feedback.
-
To clarify, there's no top level "UWP workload" anymore. You'll get the UWP tooling if you select the "WinUI development workload", and then go to the additional components tab, and select "Universal Windows Platform Tools". That will include all the new stuff (and templates). Make sure to also check the 10.0.26100.0 SDK, as that's the one that bundles the updated XAML compiler for UWP .NET 9 apps 🙂
To clarify I didn't mean you specifically, I meant [generic you, whoever originally setup the repo] 😄
Yup, sounds like it! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm now looking at the preview .NET 9.0-on-UWP support currently in preview, I wanted to pull out a discussion from #2177 (reply in thread) into its own thread.
There are two issues:
Unfortunately, it looks like the answer to 1 is: no. The big problem we have is that the main
System.Reactive
package includes auap10.0.18362
TFM, and the .NET SDK does not support building for that TFM. UWP uses old-style projects (the kind we had before .NET Core was a thing). You can't simply includeuap10.0.18362
in the<TargetFrameworks>
because the .NET SDK doesn't know how to build for that target.Currently, we use the
MSBuild.Sdk.Extras
project to enable us to use this TFM. However, that is no longer maintained. We have a solution for this in the branch that would update the project to use the .NET 9.0 SDK. (Essentially, we do some of the same things thatMSBuild.Sdk.Extras
does, enabling us to drop that dependency.) I've not yet merged that because I was hoping that maybe the new UWP support would provide a better alternative.But as far as I can tell, there is not and never will be built-in support for specifying a
uap10.0
TFM in a modern-style .NET project. We basically need to use all the hacks on that branch to move forward; the new UWP support in the .NET 9.0 SDK appears not to help us at all.If anyone knows better, please chip in!
So this leaves the question of whether to add direct support for the new style of UWP app, in which you can use the modern .NET runtime, and not the weird old special version of .NET that UWP has used up until now.
@Sergio0694 initially wrote in another discussion:
My current view on this is that this would belong in a completely separate NuGet package. About the worst thing we could do at this point is add support for yet another UI framework into
System.Reactive
. Since UWP on .NET 9 is a new thing, there's no binary backwards compatibility constraint here. So we could do this, but right now the tooling still seems to be in preview—you need to install the VS 2022 preview. So I suspect it will be .NET 10.0 before this is properly in place.But before we get to that, there's the question of what actually happens if you try to use the current version of Rx.NET on this kind of project. Unfortunately, this new UWP preview feature appears to be broken in .NET 10.0 preview 4/VS 17.4.3 preview 0. (The title in that issue mentions MAUI, but the same bug also afflicts UWP.) So I can't actually try it at all at this point.
However, looking at the
project.assets.json
you get after adding Rx to a newly-created .NET-9/UWP app, it looks like it resolves to this:This suggests that this new kind of UWP app is going to be the latest victim of the same problem that drove Avalonia to abandon Rx. (You get an implicit dependency on WPF and Windows Forms even though you're using a completely different UI framework.) However, hopefully whatever we eventually do to fix that will work for UWP.
The next observation, then, is that since UWP on .NET 9.0 seems to present a
Windows.UI.Core.Dispatcher
, the existingObserveOn
overload in Rx 6'sCoreDispatcherObservable
is already available to this new kind of UWP app. Likewise,CoreDispatcherScheduler
is available in thisnet6.0-windows10.0.19041
target of Rx.As far as I can tell, everything we offer for UWP in the
uap10.0.18362
is also present in thenet6.0-windows10.0.19041
.So my question for @Sergio0694 (and anyone else interested in Rx on this new form of UWP) is: what UWP support would we provide that isn't already available today in the
net6.0-windows10.0.19041
TFM?Beta Was this translation helpful? Give feedback.
All reactions