logging.info('Time start [%s] - Time end [%s]' % (start, end))
print('Done with [%s][%d]---- Time start [%s] - Time end [%s]' % (PART_NAME, MEM_REQ, start, end))
- except:
+ except Exception as exc:
logging.error('Usage: {} <Update_Type> <Part_Name> <OLD_Base> <NEW_Base> <OUT_DIR>'.format(os.path.basename(sys.argv[0])))
- raise
+ raise exc
def SS_update_cfg(DELTA_BIN, UPDATE_CFG_PATH):
f = open(UPDATE_CFG_PATH, 'r')
if not os.path.isdir(destdir):
try:
os.makedirs(destdir)
- except:
+ except Exception as exc:
logging.critical('Error in NEW files DIR entry -%s' % destdir)
- raise
+ raise exc
try:
if not stat.S_ISFIFO(os.stat(dst_file).st_mode):
shutil.copy2(dst_file, destpath)
logging.debug('New files copied from- %s to- %s' % (dst_file, destpath))
- except:
+ except Exception as exc:
logging.critical('Error in NEW files entry -%s -%s' % (dst_file, destpath))
- raise
+ raise exc
for elt in Dir_Added:
newfiles_dest_path = 'run/upgrade-sysroot/'