Skip to content
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

reactiveui-events not working for platform projects possibly related to PackageReference style projects #1526

Closed
PureWeen opened this issue Oct 19, 2017 · 4 comments

Comments

@PureWeen
Copy link
Contributor

PureWeen commented Oct 19, 2017

Do you want to request a feature or report a bug?
bug

What is the current behavior?
I converted my projects all over to sdk style for shared projects and PackageReference for platform projects. After this was done (and compiling) I upgraded to the latest alpha bits of ReactiveUI and then all my ".events()" code stopped working

If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
https://github.com/PureWeen/ReactiveUiEvents

Compile the SLN and see the errors

What is the expected behavior?
.Events() works in platform projects

What is the motivation / use case for changing the behavior?
.Events() works in platform projects

Which versions of ReactiveUI, and which platform / OS are affected by this issue? Did this work in previous versions of ReativeUI? Please also test with the latest stable and development snapshot

Does not work in 8.0.0-alpha0105
Works in 7.4.0

Other information (e.g. stacktraces, related issues, suggestions how to fix)

@ghuntley
Copy link
Member

ghuntley commented Oct 19, 2017

reactiveui-events-xamforms

All good!

image

image

image

image

reactiveui-events w/Xamarin.Android (Your csproj)

I can repro the problem

image

Strangely enough the actual assembly contains the right stuff but visual studio isn't referencing it.

image

image

reactiveui-events w/Xamarin.Android (Xamarin packages.config template)

Using File -> New Android Application and then installing reactiveui-v8 -pre works

image

However using your packageref project does not. This suggests something wrong either with Xamarin toolchain (you're doing something that isn't supported/implemented yet) or something was missed when you converted the csproj (maybe a property isn't set right)

@ghuntley
Copy link
Member

ghuntley commented Oct 19, 2017

@PureWeen Xamarin are working on official templates that use PackageReference; checking via backchannels if they are available for private preview and if so; I can share insights from them. Once I have these I'll be able to troubleshoot this further. For now - how did you convert your csproj? Was their a guide you followed? Link please.

@PureWeen
Copy link
Contributor Author

  • The included project wasn't created by me converting anything from the old format. I have VS set to use Package Reference by default (Tools => options => Nuget Package Manager => General => Default package management format: PackageReference) so what you see here is just what VS creates

  • I did a bad job of filling out questions when creating the ticket 👎 This all works fine in v7 but does not work in v8

  • The issue specifically happens if you reference a second project that has the reactiveui-xamforms-events nuget in it as well. In my included sample if you remove the reference to the netstandard project then the platform project compiles fine or if you uninstall the reactiveui-xamforms-events package from the netstandard project then it all compiles fine as well.

I pushed up another revision of my sample and you'll see a project called "FreshLonelyAndroidProject" that compiles fine

Then if you add the "AzureDeviceClient" as a project reference to it it no longer compiles

in v7 the dll was named ReactiveUI.Events_XamForms.dll where as v8 it's ReactiveUI.Events.dll which is the same name as the platform one.

Are they colliding because of this?

@ghuntley
Copy link
Member

ghuntley commented Nov 7, 2017

@PureWeen thx for the repro project. Confirming this was a bug which was caused by different event packages using the name assembly name. Resolved and new packages pushed to NuGet.

@ghuntley ghuntley closed this as completed Nov 7, 2017
@lock lock bot added the outdated label Jun 25, 2019
@lock lock bot locked and limited conversation to collaborators Jun 25, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants