@error.context_aware
def lv_revert_with_snapshot(vg_name, lv_name, lv_snapshot_name, lv_snapshot_size):
 error.context('Reverting to snapshot and taking a new one', logging.info)
 lv_revert(vg_name, lv_name, lv_snapshot_name)
 lv_take_snapshot(vg_name, lv_name, lv_snapshot_name, lv_snapshot_size)

@ error . context_aware def lv_revert_with_snapshot ( vg_name , lv_name , lv_snapshot_name , lv_snapshot_size ) : error . context ( 'Reverting to snapshot and taking a new one' , logging . info ) lv_revert ( vg_name , lv_name , lv_snapshot_name ) lv_take_snapshot ( vg_name , lv_name , lv_snapshot_name , lv_snapshot_size )
perform logical volume merge with snapshot and take a new snapshot .