ConfigEditor: Show error dialog when set variable failed#574
Merged
apop5 merged 1 commit intomicrosoft:mainfrom Mar 19, 2026
Merged
ConfigEditor: Show error dialog when set variable failed#574apop5 merged 1 commit intomicrosoft:mainfrom
apop5 merged 1 commit intomicrosoft:mainfrom
Conversation
os-d
approved these changes
Mar 16, 2026
apop5
approved these changes
Mar 16, 2026
kuqin12
approved these changes
Mar 16, 2026
72f321d to
9eb89eb
Compare
Contributor
Author
|
Amened commit to fix linter error. |
Update `set_variable_from_file` api and display a error dialog when the function call fails. Originally the `set_variable_from_file` function does not provide any return value nor raise any exception when set variable operation fails. This change adds a return value indicating the result of the operation, and provide an optional parameter `abort_when_failure`, which when set to true will cause the function return immediately. The parameter is set to optional and default to `False` to remain compatibility. Signed-off-by: Paddy Deng <paddydeng@ami.com>
9eb89eb to
f9bfd66
Compare
Contributor
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Update
set_variable_from_fileapi and display a error dialog when the function call fails.Originally the
set_variable_from_filefunction does not provide any return value nor raise any exception when set variable operation fails. This change adds a return value indicating the result of the operation, and provide an optional parameterabort_when_failure, which when set to true will cause the function return immediately. The parameter is set to optional and default toFalseto remain compatibility.How This Was Tested
Tested on MU system, originally when bios flash is locked (e.g. during out-of-band flashing), the set variable operation fails silently when there is a RuntimeVar.vl produced by previous load variable or set variable operation.

After the change, ConfigEditor will display a error dialog to notify the user that set variable failed.
Integration Instructions
N/A