-
Notifications
You must be signed in to change notification settings - Fork 389
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
Crash because of State Container #8
Comments
How are you hitting Back without a Back button? |
With the Windows key combination. |
With Windows+BackSpace and hardware keys on your keyboard? |
Sorry - I should have been more clear. [Alt][Left Arrow]. |
I take it, by the title change, that you've been able to reproduce this problem? If not, it's now even easier than before. If I download a completely clean copy of this solution (which, I'm delighted to say, now builds and doesn't appear to be missing files :-), use "Minimal" as my startup project, enter a value and go to page 2, close the app, open the app again, and click "Back", I get the crash. |
You and I are equally delighted :) That being said, yes. This is clearly a problem. There was a race condition that was occurring. It might be resolved today. The good news is, this is not a crippling bug at this moment, developers can start to investigate the template without this coming up in most use cases. I sincerely appreciate you finding this bug for us. It would have taken a while before we got around to testing this behavior. Now we can fix it right away. The fix will include a few things. The first is moving all the state logic out of the NavigationService and into the FrameFacade. This is just a logic move so that state for a frame is part of the frame. Just made sense. Then, there is the issue of the race condition. Changing the direct reference to the container to wrapped Setters is the start of the fix. The rest of the fix, honestly, is still being written so I can’t tell you more because there isn’t more yet. When it is all said and done, any developer using the template won’t even notice that we’ve made a chance :) That’s the goal. From: plettb [mailto:notifications@github.com] I take it, by the title change, that you've been able to reproduce this problem? If not, it's now even easier than before. If I download a completely clean copy of this solution (which, I'm delighted to say, now builds and doesn't appear to be missing files :-), use "Minimal" as my startup project, enter a value and go to page 2, close the app, open the app again, and click "Back", I get the crash. — |
I look forward to the fix. :-) (I'd gladly help, but I can't keep up with my OWN code, let alone help with this.) By the way, I also get an exception any time I close the "Sample" app, but I'm guessing that's unrelated and I should add another issue about it. Unfortunately, as I alluded to, I just don't have nearly as much time for this kind of thing as I'd like! |
I have noted occasional instability in the state code when exiting apps - I'll keep an eye out for the culprit (it may be a timing issue...) |
I am going to leave this issue open until we can be confident that this has been resolved. I feel it has been, but I feel it has been resolved through general refactoring that has occurred not through a deliberate fix. So it feels right, but we can confirm it if it remains stable for the next little while. |
Okay, I am confident now. I've tested your scenario and several others. |
Unfortunately, I haven't had time to go through this in detail to figure out what the problem is, but.... If I use Template10 and go through the "Navigation" session in "A Developer's Guide to Windows 10" (https://channel9.msdn.com/Series/A-Developers-Guide-to-Windows-10/18/player?format=html5#time=8m51s), I get a crash when I perform the following:
The text was updated successfully, but these errors were encountered: