From 5b16c81e01f612d583713631399917bd10f11d1c Mon Sep 17 00:00:00 2001 From: Alexander Lakhin Date: Fri, 7 Jul 2023 08:18:36 +0300 Subject: [PATCH] Don't check for instance features in absence of the attribute --- run-benchmarks.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/run-benchmarks.py b/run-benchmarks.py index 56c0b53..20598d6 100755 --- a/run-benchmarks.py +++ b/run-benchmarks.py @@ -249,7 +249,8 @@ def main(configfile, instances, benchmarks, resultsfile, resultsdir): 'see benchmark-results/.)') instance_features = instance.get('features') - if re.match(r'\bperf\b', instance_features): + if instance_features is not None and \ + re.match(r'\bperf\b', instance_features): res = run(f'docker exec -t {container_id} bash -c ' f'pg_ctl_stop', shell=True, check=False, stdout=subprocess.PIPE)