Ok, so I was getting the stack trace, which was still utterly useless in debugging this, When I noticed something I should have seen a long time ago. I found this in my output.
ActionMessage INFO: Invoking Action: Login.
Ok, so now I know what was making it logout, as this had no password and failed to login again. But here is the weird part. That method is on a ViewModel that has been deactivated and closed. Yet it is still firing. I did trace it to a Button that has IsDefault=
true. However, changing the IsDeafult to false after a sucessful login did not change anything.
I ended up going with a hackery fix of
public async void Login()
if (!IsActive) return;
My concern is, Why is this viewModel still around. It is composed by my ShellViewModel, which inherits from Condoctor<IScreen> and has already Activated another ViewModel in its place. OnDeactivate(true) fires, but yet, this view/viewmodel combination
seems to be sticking around to cause this headache.
Anyone have any ideas. Nothins has a reference to the viewmodel and it does not hold a reference to anything either.