-
Notifications
You must be signed in to change notification settings - Fork 178
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
Update the return of update_firmware for the image not exist case #306
Merged
Conversation
This file contains 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
…ge file doesn't exist
prgeor
reviewed
Sep 6, 2022
Comment on lines
111
to
113
Returns: | ||
False if image not found. | ||
|
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.
can we have return 'False' for any failure. see the definition of install_firmware()?
Returns:
A boolean, True if install was successful, False if not
prgeor
reviewed
Sep 8, 2022
@@ -108,6 +108,10 @@ def update_firmware(self, image_path): | |||
Args: | |||
image_path: A string, path to firmware image | |||
|
|||
Returns: | |||
Boolean False if image_path doesn't exist instead of throwing an exception error | |||
None when the update is successful |
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.
how is 'None' returned if update_firmware() results in reboot?
prgeor
approved these changes
Sep 14, 2022
7 tasks
qiluo-msft
pushed a commit
that referenced
this pull request
Oct 12, 2022
* update the return for update_firmware api's failure case when the image file doesn't exist * update comments * update comment * update comment
dprital
added a commit
to dprital/sonic-buildimage
that referenced
this pull request
Oct 30, 2022
Update sonic-platform-common submodule pointer to include the following: * a2164f6 [202012] Fix issue: sff8436 does not support decoding power class 5~7 ([sonic-net#317](sonic-net/sonic-platform-common#317)) * 6722b4e Update the return of update_firmware for the image not exist case ([sonic-net#306](sonic-net/sonic-platform-common#306)) Signed-off-by: dprital <[email protected]>
7 tasks
liat-grozovik
pushed a commit
to sonic-net/sonic-buildimage
that referenced
this pull request
Oct 30, 2022
Update sonic-platform-common submodule pointer to include the following: * a2164f6 [202012] Fix issue: sff8436 does not support decoding power class 5~7 ([#317](sonic-net/sonic-platform-common#317)) * 6722b4e Update the return of update_firmware for the image not exist case ([#306](sonic-net/sonic-platform-common#306)) Signed-off-by: dprital <[email protected]>
oleksandrivantsiv
pushed a commit
to oleksandrivantsiv/sonic-platform-common
that referenced
this pull request
Oct 25, 2024
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
issue : sonic-net/sonic-mgmt#4564
Motivation and Context
When the image file path doesn't exit, returns False instead of throwing error.
How Has This Been Tested?
Additional Information (Optional)