From: Alexis Lothoré <alexis.lothore@...>
is_non_release_version has an inverted logic which makes its reuse quite
confusing
Transform it as is_release_version and let caller do the negation if needed
Signed-off-by: Alexis Lothoré <alexis.lothore@...>
---
scripts/send_qa_email.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/scripts/send_qa_email.py b/scripts/send_qa_email.py
index 96225a8..320ff24 100755
--- a/scripts/send_qa_email.py
+++ b/scripts/send_qa_email.py
@@ -14,15 +14,15 @@ import re
import utils
-def is_non_release_version(version):
+def is_release_version(version):
p = re.compile('\d{8}-\d+')
- return p.match(version) is not None
+ return p.match(version) is None
def get_previous_tag(targetrepodir, version):
previousversion = None
previousmilestone = None
if version:
- if is_non_release_version(version):
+ if not is_release_version(version):
return subprocess.check_output(["git", "describe", "--abbrev=0"], cwd=targetrepodir).decode('utf-8').strip()
compareversion, comparemilestone, _ = utils.get_version_from_string(version)
compareversionminor = compareversion[-1]
--
2.39.2