Skip to content

Commit b87b6b6

Browse files
hasweesarahmonod
authored andcommitted
Fix extra blank line in pystack output
Signed-off-by: haswee <hasweebanoth@gmail.com>
1 parent 0dc9e3d commit b87b6b6

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/pystack/traceback_formatter.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ def format_frame(frame: PyFrame) -> Iterable[str]:
3535
if line_end != line_start:
3636
col_end = len(source)
3737
a = source[:col_start]
38-
b = source[col_start:col_end]
38+
b = source[col_start:col_end].strip("\n")
3939
c = source[col_end:]
4040
final = f'{a}{colored(b, color="blue")}{c}'
4141
yield f" {final.strip()}"

0 commit comments

Comments
 (0)