reactivemarbles / DynamicData

Reactive collections based on Rx.Net
http://dynamic-data.org
MIT License
1.73k stars 183 forks source link

UWP and DynamicData question #161

Closed byrialsen closed 6 years ago

byrialsen commented 6 years ago

Hi.

I am a UWP developer and just discovered DynamicData when looking into frameworks as Reative Extensions/ReactivateUI. DynamicData looks very promising, but my problem is that I target Windows 10 LTSB 2016. Even though LTSB 2016 is the newest LTSB version it is build on a rather old version of Windows 10 (Anniversary Update = 14393).

Anniversary Update only supports .Net Standard 1.4, thus I can't use DynamicData latest version as you upgraded to .Net Standard 2.0. You have made a comment that this is done as Reactive Rx only supports .Net Standard 2.0+, but actually Rx 4.1 seems to target UWP directly, so I can actually use RX 4.1 in my UWP apps targeting Anniversary Update.

Do you see any way for me at this point to be able to use DynamicData in an UWP with targets Anniversary Update? Could it be an idea in the future to be able to let DynamicData target UWP the same way as Rx does?

I know I can wait until Windows 10 LTSB 2019 is released as this version might support .Net Standard 2.0, but the problem could be the same over and over again as LTSB versions of Windows 10 are realeased with 2-3 years in between.

RolandPheasant commented 6 years ago

My gut instinct is dynamicdata should target frameworks exactly as system.reactive does.

In theory this is easily done by changing the csproj files to target the appropriate uwp frameworks. In practice it may be complicated by the need to install uwp frameworks as part of the build.

@glennawatson are you knowledgeable on this topic? If so I would like to hear your view

glennawatson commented 6 years ago

System.Reactive/ReactiveUI uses a package called MsBuild.Sdk.Extras to allow for UWP support. https://github.com/onovotny/MSBuildSdkExtras

https://github.com/dotnet/reactive/blob/master/Rx.NET/Source/src/System.Reactive/System.Reactive.csproj

As you can see in the TargetFrameworks it lists the UWP targets there which allows it to be crossed compiled.

It targets .net standard 2.0 as well instead of .net standard 1.4

RolandPheasant commented 6 years ago

I'll follow suit and hopefully can solve this one quickly

RolandPheasant commented 6 years ago

@byrialsen as per the advice of @glennawatson I have updated Dynamic Data to use MSBuildSdkExtras in order to support UWP.

I have built and published a branch and would like you to test the generated packages here on appveyor build. Please try the DynamicData package only as the ReactiveUI package will soon be removed from the solution. If this fixes the issue for you I will merge the changes into the main branch and publish a new version to Nuget.

Please ignore the build failure which is due to issues finding the test assemblies. I will fix this soon.

Update: The tests run now

byrialsen commented 6 years ago

Hi @RolandPheasant

I have installed the Nuget package with success into a blank UWP project targeting only Anniversary Update (14393). As I don't know much about how reactive programming works yet, I have copied some example from one of your snippets and it works, so I guess this is proof enough.

Let me know if you want to check further before merging the changes.

RolandPheasant commented 6 years ago

That's enough for me thanks. I'll merge it tomorrow

byrialsen commented 6 years ago

I am the one saying thanks. Really nice/quick work. Thanks a lot.

byrialsen commented 6 years ago

@RolandPheasant . FYI, For the last couple of days I have worked with the nuget package you gave me. Just VERY basic stuff as I am a completely rookie at reactive coding, but I had no problems at all with the package itself.:-) Is there any estimate when the adjustments will be public available? (you asking politely)

RolandPheasant commented 6 years ago

I meant to do it last night but had a late work night. I should be able to publish it by Monday evening

RolandPheasant commented 6 years ago

Btw feel free to join the slack forum. Link is on dynamic data GitHub readme

RolandPheasant commented 6 years ago

v6.6.0 has been deployed to Nuget. Any issues, please let me know

Feroks commented 6 years ago

I started to have following error in Runtime, when i provide ParallelisationOptions to Transform method. Could not load type 'DynamicData.PLinq.ParallelisationOptions' from assembly 'DynamicData, Version=6.6.0.2492, Culture=neutral, PublicKeyToken=null'.

I am building UWP application with Xmaarin.Forms. UWP version: 10.0.16299.0 XF version: 3.2.0.871581

RolandPheasant commented 6 years ago

I think I know what the issue is. I will take a look

RolandPheasant commented 6 years ago

@Feroks would you mind grabbing the artefacts from here Appveyor build

It looks like it works for me, but I would like you to test it before I publish

Feroks commented 5 years ago

@RolandPheasant tried it. Works for me as well.