Repository navigation
Conversation
…h the intake and checked per instance gui.repeating learns an add-another group from a demonstration (the add control, the instance's container kind and its fields), adds instances until the count matches the intake, fills them in document order and reads each one back by the container it was written into. It stops before writing on a prefilled instance, more instances than items, an add that did not add exactly one blank instance, or an add that wrote. judge_instances is a registered verdict site; location_rows exports the checks in the effect-location shape.
…he fail-closed list
Independent adversarial review: APPROVEFrom: Gemini Gemini run on 1b628b0 (model BlockersNone. Non-blockingNone. |
…lank nor a pass From Gemini's review of #2512: an unread checkbox read as unticked, so an item expecting unticked passed on missing evidence.
Independent adversarial review: REQUEST CHANGESFrom: Gemini Gemini run on f77fcdd (model Blockers
Non-blockingNone. |
Independent adversarial review: APPROVEFrom: Gemini Gemini run on 5c43e62 (model BlockersNone. Non-blockingNone. |
What this adds
Repeating rows caused most of the false stops in the Set 4 v2 held-out run (#2464). Each case had a control such as "add another traveller":
This change makes repeating structures a general capability in the core engine.
learn_repeatsfinds a group in a demonstration. It looks for a click after which a new block of editable controls appeared in a new container of one kind (a fieldset, a table row, a list item), where the block repeats the fields of an instance already on the screen. A list that starts empty is learned from its second add.map_slotsproposes the item key behind each slot from the values the demo typed, and reports slots that do not map. It is a proposal for the pack author.find_instancesreads each container of the declared kind that holds every slot exactly once, in document order. A slot control outside any instance, or an instance with a missing or repeated slot, makes the read unusable.fill_instancesfixes the obligations from the intake first, every item and every slot. It then adds instances until the count matches, fills them in document order and reads them back. It stops before writing on any of these:judge_instances(@verdict_site) settles item-by-slot obligations against a fresh read. Each item is checked in the instance it was written into, by its container handle bound at fill time, so two identical rows are never told apart by a guessed position.location_rowsexports the per-instance checks as rows shaped like the effect-location record from feat(flow): effect-location record and evaluator #2500 (id,keys,start,locator,expected,expected_count). This PR doesn't import that package: feat(flow): effect-location record and evaluator #2500 is still open, and its files belong to another change. Once it merges, these rows can becomeEffectLocations, andevaluate_allcan take over the read-back.Tests
tests/gui/test_gui_repeating.pyhas 16 tests (10 functions, some parametrized):The fail-open harness runs its generic mutations on
judge_instances. A hand-made fail-open copy that matches values by slot anywhere on the screen, ignoring the binding and extra instances, fails M3, M5, M7, M8, M10, M15 and P0. The fold ratchet is unchanged.Everything is synthetic, headless Chromium on the Mac, single-process. No fixture copies a held-out portal.
Base and adoption
The base is #2502 (hub pages), which sits on #2501, #2499 and #2476. This PR doesn't wire up the
form_txreconciler. A pack would replace itstraveller_N_*bindings and its popup workaround with oneRepeatSpec, and the intake would carry the list.