mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
gh-93010: InvalidHeaderError used but nonexistent (GH-93015)
* fix issue 93010
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
(cherry picked from commit 71abeb0895
)
Co-authored-by: oda-gitso <105083118+oda-gitso@users.noreply.github.com>
This commit is contained in:
parent
fc31e2de3c
commit
a509d2674a
3 changed files with 17 additions and 10 deletions
|
@ -2379,7 +2379,7 @@ def get_section(value):
|
|||
digits += value[0]
|
||||
value = value[1:]
|
||||
if digits[0] == '0' and digits != '0':
|
||||
section.defects.append(errors.InvalidHeaderError(
|
||||
section.defects.append(errors.InvalidHeaderDefect(
|
||||
"section number has an invalid leading 0"))
|
||||
section.number = int(digits)
|
||||
section.append(ValueTerminal(digits, 'digits'))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue