From 46eed410f0e5a86cb40c10c26980bb2eebf2c9e1 Mon Sep 17 00:00:00 2001 From: Fredrik Eriksson Date: Mon, 21 Dec 2020 18:36:20 +0100 Subject: [PATCH] fixed regex matching of stderr --- setup.py | 2 +- zsnaplib/__init__.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 627ebbd..0b88239 100644 --- a/setup.py +++ b/setup.py @@ -6,7 +6,7 @@ try: except ImportError: from distutils import setup -version = '0.3.3' +version = '0.3.4' setup( name='zsnapper', diff --git a/zsnaplib/__init__.py b/zsnaplib/__init__.py index 62b3367..653695c 100644 --- a/zsnaplib/__init__.py +++ b/zsnaplib/__init__.py @@ -37,7 +37,7 @@ def do_zfs_command(args, zfs_cmd, pipecmd=None): # check if we try to create a snapshot that already exists. This can happen # if the script is run every minute and it takes more time than that to # create all snapshots - if ctrl_proc.returncode == 1 and re_match(re_err_ok, err): + if ctrl_proc.returncode == 1 and re.match(re_err_ok, err): pass elif ctrl_proc.returncode != 0: raise ZFSSnapshotError('Failed to execute {}: {}'.format(cmd, err))