-
Notifications
You must be signed in to change notification settings - Fork 8.4k
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
Fix a crash on settings reload #13644
Conversation
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.
Huh. This is clever
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.
Mainly blocking over the question on the removed FAILED
check. Just wanna make sure we have our bases covered.
9a59b09
to
c522cb9
Compare
@zadjii-msft @carlos-zamora With the issue Carlos found, I've chosen a new approach which should also work. This slightly changes the behavior of WT however: From now on we'll not reload any settings until after the settings.json could be successfully parsed. |
Hmm... That's not noticeable right? A user generally experiences the following behavior after updating the settings.json...
|
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.
Yeah, I think this works just fine. Thanks!
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.
huh. Another clever solution. Neato, thanks!
Hello @carlos-zamora! Because this pull request has the p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (
|
I think the only reason it's generally not very noticeable is because we call But if you check |
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.
Thanks!
🎉 Handy links: |
07d58a8 contains a regression where the settings'
Themes()
property isaccessed without checking whether it's a
nullptr
. This can happen becausethe invalid settings modal is shown with a empty settings model object.
This commit fixes the issue by deferring the update of
_settings
untilafter we ensured that the
_settings
object is valid (besides warnings).Closes #13543
Validation Steps Performed
123