-
Notifications
You must be signed in to change notification settings - Fork 116
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
Add erase-flash
, erase-region
, and erase-parts
subcommands
#462
Conversation
Whoops, I didn't mean to close this PR. I landed the branch in our fork, but shouldn't have deleted the branch. |
I rebased this on top of #465. That should land first before this one. |
erase-flash
and erase-parts
subcommands. For #460erase-flash
, erase-region
, and erase-parts
subcommands. For #460
erase-flash
, erase-region
, and erase-parts
subcommands. For #460erase-flash
, erase-region
, and erase-parts
subcommands
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 for the comments here and in #461. I'll make these changes to avoid the need for the SemVer bump. |
Ok, I think I've resolved the concerns here. This PR now proposes no changes to |
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.
I left some minor comments and also have a few suggestions:
- Can we implement the subcommands also for
cargo-espflash
?- Note that we don't require
partition_table
forerase-parts
incargo-espflash
as it can be obtained from the package metadada, or it will result in a similar issue to #390
- Note that we don't require
- EraseFlash and EraseRegion are only available when using stub
- It would be great if we could check if we are using a stub, if not, throw an informative error
- esptool does not have such check or I haven't found it
- This might not be possible to do without breaking semver. If that's the case we can just open an issue for the future
- At the moment, if you flash with no-stub and then do an
erase-flash
and you getinvalid header: 0xffffffff
- It would be great if we could check if we are using a stub, if not, throw an informative error
Thanks @SergioGasquez for taking a detailed look and for these great suggestions. I'll work them into my branch. |
@SergioGasquez : In this PR as originally authored, there were changes to |
@SergioGasquez : I adopted all of your suggestions. Then I went about adding support for these subcommands to I'd ask that you take a close look at the |
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.
Just a small comment to avoid using bail!
and use a defined Error that we can reuse
@SergioGasquez: Thanks for catching that, you're quite right I should have defined a single error for these cases. Fixed in 22d792a |
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 for the quick fixes! One last detail!
Co-authored-by: Sergio Gasquez Arcos <sergio.gasquez@gmail.com>
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.
LGTM! Thanks for the contribution and for addressing all the changes!
Thanks for your stewardship and excellent suggestions here. I'm happy to see these changes get integrated. |
No description provided.