mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
gh-101517: fix line number propagation in code generated for except* (#103550)
This commit is contained in:
parent
518050ced1
commit
1c01f8d797
5 changed files with 27 additions and 15 deletions
|
@ -574,6 +574,8 @@ class Bdb:
|
|||
line = linecache.getline(filename, lineno, frame.f_globals)
|
||||
if line:
|
||||
s += lprefix + line.strip()
|
||||
else:
|
||||
s += f'{lprefix}Warning: lineno is None'
|
||||
return s
|
||||
|
||||
# The following methods can be called by clients to use
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue