Skip to content

Remove exit() call for python module cli usage (ESPTOOL-1125) #1114

@belezyakov

Description

@belezyakov

Is your feature request related to a problem?

While migrating from 4.x.x to 5.x.x esptool version for using as python module with basic cli integration (e.g. calling esptool.main(), espefuse.main()) I have noticed not obvious change that such usage now leads to script exiting after any esptool main(cmd) with exit() calling. So there is no bare option to use a chain of esptool cmd calls or some post-esptool call logic. To achieve that I am catching SystemExit exception for each esptool command call and just pass it on script side.

Describe the solution you'd like

No response

Describe alternatives you've considered

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions