-
Notifications
You must be signed in to change notification settings - Fork 220
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
EnsureSettingsUpdated returning null for Task #1299
Conversation
I also don't see how this is possible. But I would probably instead recomend:
Refers to: src/MIDebugEngine/Engine.Impl/ExceptionManager.cs:382 in b67c1eb. [](commit_id = b67c1eb, deletion_comment = False) |
Do we have a way to reproduce the problem? |
Yes, but I haven't found a good way to get a debug session to investigate it. Instructions:
I've built MIEngine in WSL, published it and docker cp to the container to get debug info. Attaching a debugger messes up the test suite and we get exceptions in random places. The validation of this fix was, there was no more |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Assuming this really is somehow because null is being returned from EnsureSettingsUpdated, LGTM.
I think I figured out what is going -- I think |
Tests are known to be flaky at the moment. Looking into disabling / resolving issues in another PR. |
This is probably not the correct fix, but this solves #1297 issue.
Although we have a null check on line 382, we are still returning
null
for_updateTask
.All instances of
_updateTask
are guarded by_updateLock
so I am not exactly sure why this is needed.The issue is we get a setExceptions command and most likely a background thread is going to process
FlushSettingsUpdates
. At the same time, we get a continue command which firesEnsureSettingsUpdated
but a null is returned instead of a Task which gets awaited atMIEngine/src/MIDebugEngine/Engine.Impl/DebuggedProcess.cs
Line 1674 in 8d70a37