From 87eb7e4c28e91dfd668c12f7e3cca3c613b4a33e Mon Sep 17 00:00:00 2001 From: Gianna Paulin Date: Mon, 31 Jul 2023 14:59:36 +0200 Subject: [PATCH] ci: Fix lint issue with newer flake8 version (6.1.0) --- util/trace/layout_events.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/util/trace/layout_events.py b/util/trace/layout_events.py index 4c6fe65ec9..a17fa504da 100755 --- a/util/trace/layout_events.py +++ b/util/trace/layout_events.py @@ -88,7 +88,7 @@ def main(): expr = row[0] code = compile(expr, "", "eval") tids = eval(code) - if type(tids) == int: + if isinstance(tids, int): tids = [tids] # Iterate hart IDs @@ -108,7 +108,7 @@ def main(): row_idx = tid col_idx = 1 + reg_idx * 2 assert row_idx < df.shape[0], f'Hart ID {row_idx} out of bounds' - assert (col_idx + 1) < df.shape[1],\ + assert (col_idx + 1) < df.shape[1], \ f'Region index {reg_idx} out of bounds' orow.append(int(df.iat[row_idx, col_idx])) orow.append(int(df.iat[row_idx, col_idx + 1]))