Repository navigation
Conversation
…ction from the hub gui.hub classifies an open dialog by what is in it: one that holds an editable control is a form, never a confirmation, and only a declared section's dialog may be filled. run_section opens a section, fills and saves it, and requires the dialog to close with the demonstrated writes and the card to show done on a fresh read. learn_hub derives each section's opener, dialog, save control and done tokens from a demonstration. judge_hub settles the planned sections and is a registered verdict site.
…nting its own held result From Gemini's review of #2502. Only judge_hub, a registered verdict site, can say a section held; run_section now carries its status and verdict.
Independent adversarial review: REQUEST CHANGESFrom: Gemini Gemini run on a0646e1 (model Blockers
Non-blockingNone. |
Independent adversarial review: APPROVEFrom: Gemini Gemini run on c992c1f (model BlockersNone. Non-blockingNone. |
Independent adversarial review: APPROVEFrom: Gemini Gemini run on 8925471 (model BlockersNone. Non-blockingNone. |
What this adds
Some held-out portals in the Set 4 v2 run (#2464) put the record behind a hub, a page of cards where each card's Edit button opens a dialog. Two things went wrong on those pages:
This change handles hubs as their own shape in the core engine.
classify_dialog. It sorts an open dialog by its contents, never its words:SectionSpec(pack data). It holds the section's opener on the hub, the dialog it opens, the save control inside the dialog, the card that shows its status, and the card tokens that mean done or pending.learn_hub. It finds each open, fill and save cycle in a demonstration. The done tokens are those the card gained on save, minus every token of a value typed in the dialog, so case data never becomes a completion marker. A section whose card gained nothing is reported, not guessed.run_section. It runs one section and stops when any of these checks fails:judge_hub(@verdict_site). It settles the planned sections, fixed before any is opened, against a fresh read of the hub:expected_writes. It gives the planned sections' total save writes, so a caller whose write budget defaults to one commit can size it to the sections instead.Tests
tests/gui/test_gui_hub.pyhas 10 tests:The fail-open harness runs its generic mutations on
judge_hub. A hand-made fail-open copy that foldsall()over the cards it found fails M1, M3, M5, 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
The base is #2501 (attestations), which sits on #2499 and #2476. The
form_txreconciler is not wired up here. To adopt this, its modal step would callclassify_dialogfirst, so it never treats a form dialog as a confirmation. A pack's hub would becomeSectionSpecdata walked withrun_section, andmax_commit_mutationswould come fromexpected_writes.