diff --git a/scripts/benchmark_durations.py b/scripts/benchmark_durations.py index 017328efa77a..8985b4da6651 100755 --- a/scripts/benchmark_durations.py +++ b/scripts/benchmark_durations.py @@ -118,7 +118,7 @@ def main(args: argparse.Namespace): logging.info("fetching benchmarks...") cur.execute(BENCHMARKS_DURATION_QUERY, (percentile, interval_days)) rows = cur.fetchall() - except psycopg2.OperationalError as exc: + except psycopg2.OperationalError: logging.error("cannot fetch benchmarks duration from the DB due to an error") rows = [] res = FALLBACK_DURATION diff --git a/scripts/flaky_tests.py b/scripts/flaky_tests.py index 6acc4f5fc821..76bc4b279a42 100755 --- a/scripts/flaky_tests.py +++ b/scripts/flaky_tests.py @@ -43,7 +43,7 @@ def main(args: argparse.Namespace): logging.info("fetching flaky tests...") cur.execute(FLAKY_TESTS_QUERY, (interval_days,)) rows = cur.fetchall() - except psycopg2.OperationalError as exc: + except psycopg2.OperationalError: logging.error("cannot fetch flaky tests from the DB due to an error") rows = []