Catch all exceptions by default if removing scratch directory is not
successful. This prevents further confusion about NFS permissions as
this is not the root cause of script failure.
Change-Id: I0f775bb38e98cf69b4ce277b6e0dda4dad0a8732
Signed-off-by: Peter Mikus <pmikus@cisco.com>
auth=(args.username, args.password))
try:
shutil.rmtree(scratch_directory)
auth=(args.username, args.password))
try:
shutil.rmtree(scratch_directory)
print_to_stderr("ERROR: Removing scratch directory")
print "{}".format(session_id)
sys.exit(1)
print_to_stderr("ERROR: Removing scratch directory")
print "{}".format(session_id)
sys.exit(1)
auth=(args.username, args.password))
try:
shutil.rmtree(scratch_directory)
auth=(args.username, args.password))
try:
shutil.rmtree(scratch_directory)
print_to_stderr("ERROR: Removing scratch directory")
print "{}".format(session_id)
sys.exit(1)
print_to_stderr("ERROR: Removing scratch directory")
print "{}".format(session_id)
sys.exit(1)
auth=(args.username, args.password))
try:
shutil.rmtree(scratch_directory)
auth=(args.username, args.password))
try:
shutil.rmtree(scratch_directory)
print_to_stderr("ERROR: Removing scratch directory")
print "{}".format(session_id)
sys.exit(1)
print_to_stderr("ERROR: Removing scratch directory")
print "{}".format(session_id)
sys.exit(1)