Read the page-map chord's progress from its key faces, not the key line's text - #159
Read the page-map chord's progress from its key faces, not the key line's text#159leaf-agent wants to merge 1 commit into
Conversation
|
This and #157 are the same fix, opened twelve minutes apart by two ci-fix runs, and neither references the other — so whichever lands second conflicts rather than becoming a no-op. Only one should merge. I was dispatched for run 33344080789 (21332fc), derived this same change a third time, and am dropping it rather than opening a fourth. Both edit the same two Both are correct as tests: the row's text is unchanged by the Verification
|
|
Closing this as the duplicate, in favour of #157 — the comment above established that only one should merge, and nothing since has picked one, so the second to land would conflict rather than no-op. #157 is the one to keep on three counts: it was opened twelve minutes earlier, its The one thing worth keeping from here is Diagnosed while handling run 33346442884 (6d68a1b), whose five failures resolve to #157's two margin cases, #156's catalog digest, and two |
Problem
cion aa41f7a ("Keep chord hints stable through progress") failed with 33 nightly tests red. Most have since been fixed onmain(#134, #137, #145, #148, #149, #150, #151, #152, #153) or are carried by an open PR (#155's ring walk, #156's catalog digest). The two still failing onmainatc0a5b65aretest_render_margin.py::test_g_addresses_the_page_map_prefix_in_its_announced_orderandtest_one_margin_item_owns_a_targets_controls_information_and_more_actions, which #154's body already named asaa41f7a's and left for this run.Both are stale readings of the key line, not a regression. They pressed
g, asserted the line containedm page-map items, pressedm, then asserted it contained1–9 page-map items— a text read that only distinguished the two stages while the line dropped the keys the chord had consumed.aa41f7ais the change that stopped it doing that:keyline.jsnow draws every destination's complete route (completeChordSteps) and marks progress withdata-lf-key-state, so the row readsgm1–9page-map itemsboth before and afterm— which is the behavior the commit was for. That commit updated the same assertions intest_render_navigation.pyandtest_render_anchors.py;test_render_margin.pyspelled them differently and was missed.Solution
Assert what now carries the distinction: the row's keycaps and their faces. After
gthe page-map row readsg m 1–9with the list key neutral; aftermthe same three keys, with that keypressed. This is the idiomaa41f7aestablished intest_render_navigation.py, and it proves more than the old read did — the route's identity and its stability under progress, not just that some substring moved.The selector for one binding's keycaps is now
key_line_routeintests/render_harness.pybesidekey_line, so the next change to this shape has one name to grep rather than a per-file spelling. The five existing sites intest_render_navigation.pyare left as they are: three of them also need the enclosing.lf-key-sequenceelement forsequence_geometry, so converting them is a refactor of green tests rather than part of this fix.Testing
On this branch at
c0a5b65, with Playwright driving the real headless shell:uv run pytest tests/test_render_margin.py --run-nightly -n0— 22 passed. Before the change, on the same checkout, both tests fail withActual value: gTThreads panelgAAsks panelgMPage mapgm1–4page-map itemsgg / Gtop / bottomesccancel?more, which is where the1–Nbetweenmand the word comes from.uv run pytest tests/test_render_navigation.py tests/test_render_margin.py --run-nightly -n2— 84 passed. The navigation file is included because it owns the assertions this one is being brought into line with, and because the new helper lives in the shared harness.uv run pytest tests— 740 passed, 6 skipped. That is the gate CI runs on this PR.ruff check tests/andruff formatover the changed files — clean.Seventeen of the run's other failures were re-run here to place them rather than assume the merges cleared them:
tests/test_render_drafts.py --run-nightly -n2— 50 passed, so all fourteenLocator.filltimeouts are gone, and the three navigation failures (test_a_questions_digits_are_drawn_whole,test_c_in_a_seated_conversation_reaches_the_thread_it_is_in,test_the_ring_holds_on_a_seat_the_agent_has_still_to_answer) passed in the navigation run above. The rest sit intest_render_controls.py,test_render_options.py,test_render_projection.py,test_render_gate.py,test_render_conversations.py, andtest_render_anchors.py; #155 already owns the one known to survive there.Automated fix for failed run