forked from NVIDIA/NeMo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lab: exit program after catching and reporting exceptions (NVIDIA#336)
* cli: use non-zero exit status for error scenarios Invoking sys.exit() with no args results in an exit status of zero, which traditionally indicates success. This is not appropriate for error scenarios. Signed-off-by: Daniel P. Berrangé <[email protected]> * lab: exit program after catching and reporting exceptions Creating the app failed with an exception raised due to a missing model file. Execution carried on, however, leading to use of an undefined 'app' variable. Fix this, and a couple of other places which also caught (unrecoverable) exceptions and forgot to exit. Signed-off-by: Daniel P. Berrangé <[email protected]> --------- Signed-off-by: Daniel P. Berrangé <[email protected]>
- Loading branch information
Showing
1 changed file
with
9 additions
and
3 deletions.
There are no files selected for viewing
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