One function

_position_children in fasouto/termaid

The author described this change as fix: render blocks nested two groups deep. It counts as a record because the check below fails on the code as it stood at 189ed5fb7 and passes on 053aa19df, with nothing else changed between the two runs.

Fix saved2026-06-11
Sharing licenceMIT · LICENSE
Change size+4 0

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

Position children of a group block within its bounds.

The change

4141 bh = row_heights[ri]
4242 sizes[block.id] = (bw, bh)
4343 positions[block.id] = (bx, by)
44+
45+ # Recurse into nested groups
46+ if block.children:
47+ _position_children(block, bx, by, bw, bh, sizes, positions, col_gap=col_gap)

The check that tells the two apart

failpass·tests/test_blockdiagram.py::TestNestedGroups::test_doubly_nested_blocks_are_rendered

Check file tests/test_blockdiagram.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 it189ed5fb75ed217679032993eb2237bcd99216ed
Broken version dated2026-06-11
Moduletermaid.renderer.blockdiagram
Units changed_position_children
Fingerprint1834518a4636a3c9
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 fasouto/termaid