From b9b6c42d5e29a516b74c2df268d59567060ae43e Mon Sep 17 00:00:00 2001 From: Luca Colagrande Date: Sun, 11 Aug 2024 15:53:53 +0200 Subject: [PATCH] Correct linting --- util/trace/a2l.py | 2 +- util/trace/annotate.py | 3 ++- util/trace/tracevis.py | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/util/trace/a2l.py b/util/trace/a2l.py index 91cde3361..4a849e80a 100644 --- a/util/trace/a2l.py +++ b/util/trace/a2l.py @@ -53,7 +53,7 @@ def function_stack(self): # Find all matches and organize them into a list of dictionaries stack = [match.groupdict() for match in pattern.finditer(self.raw)] - + # Format stack entries def format_stack_entry(entry): func, line, col = [entry.get(key, None) for key in ['func', 'line', 'col']] diff --git a/util/trace/annotate.py b/util/trace/annotate.py index 7d0601076..dac037832 100755 --- a/util/trace/annotate.py +++ b/util/trace/annotate.py @@ -268,7 +268,8 @@ def parse_line(line, fmt='snitch'): if diff: # Compare current and previous call stacks if a2l_output: - funs, files, lines = zip(*[level.values() for level in a2l_output.function_stack()]) + funs, files, lines = zip( + *[level.values() for level in a2l_output.function_stack()]) else: funs = files = lines = [] next_call_stack = assemble_call_stack(funs, files, lines) diff --git a/util/trace/tracevis.py b/util/trace/tracevis.py index 7c21f0ba2..e31f0bff8 100755 --- a/util/trace/tracevis.py +++ b/util/trace/tracevis.py @@ -252,7 +252,7 @@ def parse_trace(filename, kwargs): events += flush(lah, buf, **kwargs) print(f' parsed {lines-fails} of {lines} lines', file=sys.stderr) - + # Assign a per-trace unique TID or PID to all events for event in events: if kwargs['collapse_call_stack']: