Describe the bug
When running in release mode I get this exception:
at System.IO.Path.Combine(String path1, String path2) in f:\dd\ndp\fxcore\CoreRT\src\System.Private.CoreLib\shared\System\IO\Path.cs:line 303
at ReactiveUI.DependencyResolverMixins.GetNamespaceExists(String namespaceName) in d:\a\1\s\src\ReactiveUI\Mixins\DependencyResolverMixins.cs:line 128
at System.Func`2.InvokeOpenStaticThunk(T arg)
at System.Func`2.Invoke(T arg)
at System.Linq.Enumerable.WhereArrayIterator`1.MoveNext() in E:\A\_work\288\s\corefx\src\System.Linq\src\System\Linq\Where.cs:line 170
at ReactiveUI.CompatMixins.ForEach[T](IEnumerable`1 this, Action`1 block) in d:\a\1\s\src\ReactiveUI\Mixins\CompatMixins.cs:line 16
at ReactiveUI.DependencyResolverMixins.InitializeReactiveUI(IMutableDependencyResolver resolver) in d:\a\1\s\src\ReactiveUI\Mixins\DependencyResolverMixins.cs:line 48
at ReactiveUI.RxApp.<>c.<.cctor>b__10_0() in d:\a\1\s\src\ReactiveUI\RxApp.cs:line 87
at System.Func`1.Invoke()
at Splat.InternalLocator.RegisterResolverCallbackChanged(Action callback) in d:\a\1\s\src\Splat\ServiceLocation\InternalLocator.cs:line 117
at Splat.Locator.RegisterResolverCallbackChanged(Action callback) in d:\a\1\s\src\Splat\ServiceLocation\Locator.cs:line 80
at ReactiveUI.RxApp..cctor() in d:\a\1\s\src\ReactiveUI\RxApp.cs:line 80
at System.Runtime.CompilerServices.ClassConstructorRunner.EnsureClassConstructorRun(StaticClassConstructionContext* pContext) in f:\dd\ndp\fxcore\CoreRT\src\System.Private.CoreLib\src\System\Runtime\CompilerServices\ClassConstructorRunner.cs:line 92
With the following message:
System.ArgumentNullException: 'Value cannot be null.' Parameter name: path1
10.5.30 works as expected
Seems like it has something to do with the following code added in PR: https://github.com/reactiveui/ReactiveUI/pull/2253
Steps To Reproduce
Expected behavior
App runs without crash
Environment
Greetings,
Eddy
Hey @DevEddy :wave:,
Thank you for opening an issue. We will get back to you as soon as we can. Also, check out our Open Collective and consider contributing financially.
https://opencollective.com/reactiveui
PS.: We offer
prioritysupport for all financial contributors. Don't forget to addprioritylabel once you start contributing :smile:
An advanced, composable, functional reactive model-view-viewmodel framework for all .NET platforms!
Hello from the .NET team. This looks very similar to a UWP issue with the grpc library. You can find the discussion here in case that's helpful. The short answer is that Assembly.Location returns the empty string for .NET Native (aka RELEASE for UWP).
Thanks @MattWhilden -- this was just a fix for some users who were getting exceptions when ReactiveUI attempts to load plugins for the various NuGet packages and users were getting confused by the caught exception. I will just revert to the old functionality. thanks for providing the link.
I sort of almost wish there was a "Assembly.TryLoadFrom"
Thanks!
Glad to be helpful. Certainly let me know if there's other UWP related issues that crop up. Happy to take a look.
Most helpful comment
Thanks @MattWhilden -- this was just a fix for some users who were getting exceptions when ReactiveUI attempts to load plugins for the various NuGet packages and users were getting confused by the caught exception. I will just revert to the old functionality. thanks for providing the link.
I sort of almost wish there was a "Assembly.TryLoadFrom"