Skip to content

main is red: test_spec_page tie-break test predates #120's p-suffix rendering #123

Description

@espg

🤖 from Claude

Pre-existing failure on main (@ 4b57a1f), surfaced during PR #122's fold (evidence: Tests run 29787103143 red on 3.10 + 3.12 with the identical failure; #122's own diff is disjoint and its 23 new tests pass).

mortie/tests/test_spec_page.py::TestDecimalParseTieBreak::test_order29_string_parses_to_area_word fails with ValueError: invalid literal for int() with base 10: 'p' — issue #120's "delegate point suffix to kernel" made decimal_repr() render the terminal p kind-suffix on point words (spec §2: the render form MAY carry p on point ids), but the test at line ~87 still constructs its probe via int(dec[-1]) on a repr that is now p-terminated.

Likely fix is test-only (the behavior matches the spec): build the unmarked order-29 probe string deliberately — e.g. dec.rstrip('p') (or render an area order-29 word instead of a point) — so the test exercises what it means to pin: the unmarked string parses to the AREA word per the §4 tie-break. Worth one check while there: that the tie-break assertion itself still passes once the probe is well-formed, and that a p-marked string round-trips to the point word (which #120's own tests may already cover).

Why it matters beyond hygiene: it blocks PR #122's test matrix from going green (and therefore the release moczarr#8 adoption waits on). Not fixed inside #122 per the pre-existing-failure discipline; flagged there with the same diagnosis.

Refs: #120, #62 (the spec page + drift-pin), PR #122 (where it surfaced), espg/moczarr#8 (downstream).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions