Using sys.exit(main()) instead of main()
TrivialFix: Similar [1] in Kolla project As we known, Exceptions are raised by the sys.exit() function. When they are not handled, no stack traceback is printed in the Python interpreter. Therefore, when using sys.exit(main()) instead of main() may be more readable and reasonable. [1] https://review.openstack.org/#/c/349353/ Change-Id: Ie4654b75892de025be73a17a76cdeac1f357ebbd
This commit is contained in:
parent
f44eae1735
commit
fd6c52d5ef
|
@ -182,4 +182,4 @@ def main():
|
|||
|
||||
|
||||
if __name__ == '__main__':
|
||||
main()
|
||||
sys.exit(main())
|
||||
|
|
Loading…
Reference in New Issue