Whole file

r1chardj0n3s/parse

The author described this change as Fix handling of unused alignment (#132). It counts as a record because the checks below fail on the code as it stood at 9a4a5558f and pass on 421c19919, with nothing else changed between the two runs.

Fix saved2021-06-04
Sharing licenceMIT · LICENSE
Change size+2 2

What the code was meant to do, written into the code itself as a save note

Fix handling of unused alignment (#132)

The change

12641264
12651265 # align "=" has been handled
12661266 if align == '<':
1267- s = '%s%s+' % (s, fill)
1267+ s = '%s%s*' % (s, fill)
12681268 elif align == '>':
12691269 s = '%s*%s' % (fill, s)
12701270 elif align == '^':
1271- s = '%s*%s%s+' % (fill, s, fill)
1271+ s = '%s*%s%s*' % (fill, s, fill)
12721272
12731273 return s
12741274

The check that tells the two apart

failpass·test_parse.py::TestBugs::test_unused_centered_alignment_bug
failpass·test_parse.py::TestBugs::test_unused_left_alignment_bug

Check file test_parse.py, taken without changes from the fix and copied onto the older code, so the exact same check runs against both versions.

Origin and history

The code before it9a4a5558fe314effb47d17bc64ada56221ec9a66
Broken version dated2021-06-04
Moduleparse
Units changedParser
Fingerprintd9db63b1830dd380
Checked2026-08-18 by goldset/0.1

Every field above is generated by our program. None of it is written by hand.

Other bugs found in r1chardj0n3s/parse