Skip to content

Commit

Permalink
EC2 script should exit with non-zero code on UsageError
Browse files Browse the repository at this point in the history
This is specially import because some ssh errors are raised as UsageError, preventing an automated usage of the script from detecting the failure.

Author: Allan Douglas R. de Oliveira <allan@chaordicsystems.com>

Closes apache#638 from douglaz/ec2_exit_code_fix and squashes the following commits:

5915e6d [Allan Douglas R. de Oliveira] EC2 script should exit with non-zero code on UsageError
  • Loading branch information
Allan Douglas R. de Oliveira authored and pdeyhim committed Jun 25, 2014
1 parent 0564861 commit 049a69f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions ec2/spark_ec2.py
Original file line number Diff line number Diff line change
Expand Up @@ -814,6 +814,7 @@ def main():
real_main()
except UsageError, e:
print >> stderr, "\nError:\n", e
sys.exit(1)


if __name__ == "__main__":
Expand Down

0 comments on commit 049a69f

Please sign in to comment.