Skip to content

Carry Toad's retired prompt preferences; track formbridge main in the stack - #3568

Closed
trissim wants to merge 8 commits into
mainfrom
work/toad-input-settings-carry
Closed

trissim wants to merge 8 commits into
mainfrom
work/toad-input-settings-carry

Conversation

@trissim

@trissim trissim commented Oct 28, 2026 •

Copy link
Copy Markdown
Contributor

Summary

2 files, +97/-9 against current fetched main. Correction 64512ff deletes 23 lines and adds 8 in the carry. Continue the original carry and PR; no rewritten history, duplicate PR, runtime fallback or compatibility reader.

The original accidental main change (1e5b565) was reverted by #3567. This is its reviewed publication path. The Toad prerequisite #1304 is merged; the former draft hold no longer applies.

Structure and behavior

Before: saved ui.compact-input and ui.prompt_message are unknown to the new strict Toad settings decoder.
After: ToadInputSettings(ToadSettingsCarry) implements only rewrite(document) -> int. The existing parent at carry_toad_key_mode.py:29 owns SavedSettings confinement/read, rewriting every settings family member before validation, atomic write and reporting. Removed this child's opened_files/writer_owned/carry and imports. It decodes only its retired fields at the carry boundary, deriving current field names and box serialization through FieldCodec and Toad declarations. IMPL-12 was present in the earlier head: I copied the owner instead of inheriting it (paper1 Theorems 4.6/4.7).

  • True compact-input becomes FlushInputBox; false drops the retired default flag.
  • Prompt text becomes InputSettings.placeholder.
  • Old keys alongside current ui.input fail explicitly with RelationViolationError rather than guessing precedence.
  • Inherited ToadSettingsCarry validates the complete family result before AtomicFile writes it.
  • No runtime legacy reader, alias, or second preference authority is added. No existing parent/family was removed.

Integration

  • Adopted the PR's actual remote head e3201a1 into allocated P1041 checkout, detached because older worktrees still hold local branch names. Those trees were not edited.
  • Merged origin/main as 3791e4c, no conflicts.
  • Commit bff6f6f refreshes stack/uv.lock: Toad main 35770a0c → 1d853113; Textual main e9f681e4 → 76f9ef77.
  • Ran /home/ts/.local/state/agent-comms/upgrade-bus/uv lock --project stack --upgrade successfully. Plain uv was absent from PATH (exit127); the declared installer executable succeeded.
  • No uv sync: order step 2 requests it, but the same order explicitly says never uv sync / never create a venv. Took the narrower prohibition as ordered.

Latest correction and proof

Head 64512ff follows the conflict-free main refresh and deletes the copied settings lifecycle. NRA parser inventory covered 955 modules across Core src/tools and installed Toad production: no parse failures; dynamic resolution remains outside this syntactic evidence. Read the resulting Carry, CarryChain, ToadSettingsCarry, key-mode, arrow-key and SavedSettings sites semantically. Siblings now share one lifecycle; only the input rewrite differs.

Actual CarryChain worker on a selected PracticeCopy:22 declarations, only toad_input_settings unfinished. Two inputs used simultaneous retired vim-keys: true plus compact true/false and prompt text. Each dry/apply reported changed=2 (input plus key-mode rewrites); both real WriterOwnedOpeningProbe calls passed; each rerun changed=0. True produced flush layout, false omitted the default layout. Typed decode proved VimNormal and exact placeholder. Conflicting old/current prompt forms raised before write, bytes unchanged. Original live settings hash unchanged. Exit0 in p1041-owner-proof.log. This proof supersedes the earlier copied-lifecycle run below; dependency/install limitations still apply.

True before/after:

{"ui":{"compact-input":true,"prompt_message":"Keep this text","vim-keys":true}}
{"ui":{"key-mode":"vim_normal","input":{"box":"flush","placeholder":"Keep this text"}}}

False before/after:

{"ui":{"compact-input":false,"prompt_message":"Keep this text","vim-keys":true}}
{"ui":{"key-mode":"vim_normal","input":{"placeholder":"Keep this text"}}}

Earlier proof and setup history

git archive HEAD extracted into owned scratch; initialized its index so NativeBuildInputs can enumerate the archived tracked source, then ran NativeBuildInputs(root).require_pinned(root / 'stack/pi-native.sha256'): ARCHIVE_PIN_OK, exit0. The manifest did not need a change. An initial archive check failed because GitLaunch deliberately removes GIT_DIR/GIT_WORK_TREE; that failure did not establish the pin.

Used the shared /home/ts/code/projects/agent-comms/.venv/bin/python, checkout src and tools, and already-installed stack dependencies. No author pytest/full suite/local NRA gate, package installation, or live install.

Real CarryChain.at(checkout) discovered 22 ordered declarations. The live root's copied FinishedCarryStore left exactly toad_input_settings unfinished. PracticeCopy copied 125 declared files (registry/runtime/finished carries/referenced turns/writer-owned settings), not the full 16GiB bus. Seeded the retired preferences only in the copied writer-owned settings. Actual InstallCommands interpreter worker ran CarryProbe/MigrateOperation, followed by WriterOwnedOpeningProbe using SavedSettings's real decoder.

Before:

{"ui":{"compact-input":true,"prompt_message":"Carry this prompt","key-mode":"standard"}}

After:

{"ui":{"key-mode":"standard","input":{"box":"flush","placeholder":"Carry this prompt"}}}
  • Dry run changed=1, original copied bytes preserved.
  • Apply changed=1, rewritten=writer-owned/saved_settings.
  • WriterOwnedOpeningProbe passed.
  • Apply rerun changed=0.
  • Typed settings decode confirmed FlushInputBox and exact placeholder text.
  • Original live settings SHA-256 unchanged; no apply operation targeted the live root.
  • Exit0. Log: /home/ts/.cache/agent-scratch/allocation-repair/p1041-carry-proof2.log.
  • Initial worker attempt failed before apply because TargetStack replaced PYTHONPATH and the shared interpreter lacked Textual; supplied explicit source/dependency import roots through existing InstallCommands.probe API. The failed attempt is not counted as proof.

Scope of proof: actual carry worker and saved-settings opening on a selected scratch root copy using existing dependencies. Not a fresh install of the newly relocked Toad/Textual revisions, not full installer reconcile/readback, not live/UI acceptance. Those remain integration acceptance debt; the sync prohibition prevented constructing that runtime here.

Assumed

  • The original persisted wire keys are compact-input and prompt_message (the order's compact_input describes the field, not its WireName).
  • Completed carries stay skipped through FinishedCarryStore; this proof does not rerun them.
  • The explicit no-sync/no-venv restriction takes precedence over contradictory uv-sync step.
  • Existing PR Carry Toad's retired prompt preferences; track formbridge main in the stack #3568 is the sole publication; generic order-pr wording does not authorize a duplicate.
  • Integration owner owes exact relocked-runtime installation and affected real UI acceptance.

22 carry declarations, one unfinished: the old preference finally gets a forwarding address, not a second apartment.

Tristan Simas and others added 2 commits October 28, 2026 11:34
…the stack

Toad's settings menu PR replaces ui.compact-input (a flag every prompt part
branched on) with the ui.input.box choice and moves ui.prompt_message
(declared, never read) to ui.input.placeholder. Settings decoding refuses
unknown keys, so a saved file holding either retired key must cross once:
compact-input true becomes the Flush layout, false is the default and is
dropped, and the message becomes the placeholder.

formbridge now owns the declared-field semantics Toad's forms read, so the
stack overrides it to main like the other OpenHCSDev packages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RnH6dR85kyFKcc2tQAJLhK
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XbFMSoWgC3ZwKzjT4SwMDu
@github-actions

github-actions Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

debt-src at 010ce48, every finding:

concurrent.futures.process._RemoteTraceback: 
"""
Traceback (most recent call last):
  File "/opt/hostedtoolcache/Python/3.14.9/x64/lib/python3.14/concurrent/futures/process.py", line 255, in _process_worker
    r = call_item.fn(*call_item.args, **call_item.kwargs)
  File "/home/runner/work/agent-comms/agent-comms/src/agent_comms/child_process.py", line 2529, in _work
    return work()
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/nominal_refactor_advisor/audit/project_measures.py", line 53, in counted
    carried = repo.carried(base, head)
  File "/home/runner/work/agent-comms/agent-comms/tools/agent_comms_project.py", line 168, in carried
    families = self.carry_family()
  File "/home/runner/work/agent-comms/agent-comms/tools/agent_comms_project.py", line 184, in carry_family
    base for member in Carry.members_with(Carry)
                       ~~~~~~~~~~~~~~~~~~^^^^^^^
  File "/home/runner/work/agent-comms/agent-comms/src/agent_comms/declared_family.py", line 262, in members_with
    for member in cls._member_declarations()
                  ~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/home/runner/work/agent-comms/agent-comms/src/agent_comms/declared_family.py", line 242, in _member_declarations
    return tuple(cls.__registry__.values())
                 ~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/metaclass_registry/core.py", line 422, in values
    self._discover()
    ~~~~~~~~~~~~~~^^
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/metaclass_registry/core.py", line 364, in _discover
    discover(paths, f"{config.discovery_package}.", cast(type, self._base_class))
    ~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/metaclass_registry/discovery.py", line 133, in discover_registry_classes
    module = import_module_preserving_root_logging(module_name)
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/metaclass_registry/discovery.py", line 56, in import_module_preserving_root_logging
    return importlib.import_module(module_name, package)
           ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/hostedtoolcache/Python/3.14.9/x64/lib/python3.14/importlib/__init__.py", line 88, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1406, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1371, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1342, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 938, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 763, in exec_module
  File "<frozen importlib._bootstrap>", line 491, in _call_with_frames_removed
  File "/home/runner/work/agent-comms/agent-comms/tools/cutover/carry_toad_arrow_keys.py", line 17, in <module>
    from cutover.carry_toad_key_mode import ToadSettingsCarry
  File "/home/runner/work/agent-comms/agent-comms/tools/cutover/carry_toad_key_mode.py", line 15, in <module>
    from toad.preferences import SavedSettings, ToadSettings, UiSettings
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/toad/preferences.py", line 29, in <module>
    from toad import setting_effects as effects
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/toad/setting_effects.py", line 7, in <module>
    from toad.widgets.history_anchor import HistoryWindow
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/toad/widgets/history_anchor.py", line 18, in <module>
    from toad.widget_actions import NativeMethodKeys
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/toad/widget_actions.py", line 29, in <module>
    class Action(KeyDeclaration[Context], Command, DeclaredFamily, Generic[Context], affix="Action"):
    ...<118 lines>...
        def apply(self, context: Context) -> object: ...
TypeError: metaclass conflict: the metaclass of a derived class must be a (non-strict) subclass of the metaclasses of all its bases
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/runner/work/agent-comms/agent-comms/tools/nra_gate.py", line 14, in <module>
    raise SystemExit(audit.gate.main(AgentCommsProject(Path.cwd())))
                     ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/nominal_refactor_advisor/audit/gate.py", line 1061, in main
    return gate(project, args.base, args.head, args.root, args.workers)
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/nominal_refactor_advisor/audit/gate.py", line 1034, in gate
    result = compare(repo, base, head, root, workers, Compared.members())
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/nominal_refactor_advisor/audit/gate.py", line 1001, in compare
    results[measure] = [part.result() for part in parts[measure]]
                        ~~~~~~~~~~~^^
  File "/opt/hostedtoolcache/Python/3.14.9/x64/lib/python3.14/concurrent/futures/_base.py", line 447, in result
    return self.__get_result()
           ~~~~~~~~~~~~~~~~~^^
  File "/opt/hostedtoolcache/Python/3.14.9/x64/lib/python3.14/concurrent/futures/_base.py", line 396, in __get_result
    raise self._exception
TypeError: metaclass conflict: the metaclass of a derived class must be a (non-strict) subclass of the metaclasses of all its bases

@github-actions

github-actions Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

debt-tools at 010ce48, every finding:

concurrent.futures.process._RemoteTraceback: 
"""
Traceback (most recent call last):
  File "/opt/hostedtoolcache/Python/3.14.9/x64/lib/python3.14/concurrent/futures/process.py", line 255, in _process_worker
    r = call_item.fn(*call_item.args, **call_item.kwargs)
  File "/home/runner/work/agent-comms/agent-comms/src/agent_comms/child_process.py", line 2529, in _work
    return work()
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/nominal_refactor_advisor/audit/project_measures.py", line 53, in counted
    carried = repo.carried(base, head)
  File "/home/runner/work/agent-comms/agent-comms/tools/agent_comms_project.py", line 168, in carried
    families = self.carry_family()
  File "/home/runner/work/agent-comms/agent-comms/tools/agent_comms_project.py", line 184, in carry_family
    base for member in Carry.members_with(Carry)
                       ~~~~~~~~~~~~~~~~~~^^^^^^^
  File "/home/runner/work/agent-comms/agent-comms/src/agent_comms/declared_family.py", line 262, in members_with
    for member in cls._member_declarations()
                  ~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/home/runner/work/agent-comms/agent-comms/src/agent_comms/declared_family.py", line 242, in _member_declarations
    return tuple(cls.__registry__.values())
                 ~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/metaclass_registry/core.py", line 422, in values
    self._discover()
    ~~~~~~~~~~~~~~^^
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/metaclass_registry/core.py", line 364, in _discover
    discover(paths, f"{config.discovery_package}.", cast(type, self._base_class))
    ~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/metaclass_registry/discovery.py", line 133, in discover_registry_classes
    module = import_module_preserving_root_logging(module_name)
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/metaclass_registry/discovery.py", line 56, in import_module_preserving_root_logging
    return importlib.import_module(module_name, package)
           ~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/hostedtoolcache/Python/3.14.9/x64/lib/python3.14/importlib/__init__.py", line 88, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
           ~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "<frozen importlib._bootstrap>", line 1406, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1371, in _find_and_load
  File "<frozen importlib._bootstrap>", line 1342, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 938, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 763, in exec_module
  File "<frozen importlib._bootstrap>", line 491, in _call_with_frames_removed
  File "/home/runner/work/agent-comms/agent-comms/tools/cutover/carry_toad_arrow_keys.py", line 17, in <module>
    from cutover.carry_toad_key_mode import ToadSettingsCarry
  File "/home/runner/work/agent-comms/agent-comms/tools/cutover/carry_toad_key_mode.py", line 15, in <module>
    from toad.preferences import SavedSettings, ToadSettings, UiSettings
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/toad/preferences.py", line 29, in <module>
    from toad import setting_effects as effects
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/toad/setting_effects.py", line 7, in <module>
    from toad.widgets.history_anchor import HistoryWindow
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/toad/widgets/history_anchor.py", line 18, in <module>
    from toad.widget_actions import NativeMethodKeys
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/toad/widget_actions.py", line 29, in <module>
    class Action(KeyDeclaration[Context], Command, DeclaredFamily, Generic[Context], affix="Action"):
    ...<118 lines>...
        def apply(self, context: Context) -> object: ...
TypeError: metaclass conflict: the metaclass of a derived class must be a (non-strict) subclass of the metaclasses of all its bases
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/runner/work/agent-comms/agent-comms/tools/nra_gate.py", line 14, in <module>
    raise SystemExit(audit.gate.main(AgentCommsProject(Path.cwd())))
                     ~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/nominal_refactor_advisor/audit/gate.py", line 1061, in main
    return gate(project, args.base, args.head, args.root, args.workers)
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/nominal_refactor_advisor/audit/gate.py", line 1034, in gate
    result = compare(repo, base, head, root, workers, Compared.members())
  File "/home/runner/work/agent-comms/agent-comms/.venv/lib/python3.14/site-packages/nominal_refactor_advisor/audit/gate.py", line 1001, in compare
    results[measure] = [part.result() for part in parts[measure]]
                        ~~~~~~~~~~~^^
  File "/opt/hostedtoolcache/Python/3.14.9/x64/lib/python3.14/concurrent/futures/_base.py", line 447, in result
    return self.__get_result()
           ~~~~~~~~~~~~~~~~~^^
  File "/opt/hostedtoolcache/Python/3.14.9/x64/lib/python3.14/concurrent/futures/_base.py", line 396, in __get_result
    raise self._exception
TypeError: metaclass conflict: the metaclass of a derived class must be a (non-strict) subclass of the metaclasses of all its bases

trissim and others added 2 commits October 30, 2026 06:52
…#1304, 35770a0c2)

batrachian-toad 35770a0c, formbridge b67c97e5; the carry's toad.preferences
InputSettings and toad.setting_choices FlushInputBox now resolve, and every
cutover module imports against this lock.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01XbFMSoWgC3ZwKzjT4SwMDu
@trissim
trissim marked this pull request as ready for review October 30, 2026 10:54
@trissim
trissim enabled auto-merge October 30, 2026 10:54
Copilot AI balanced review requested due to automatic review settings October 30, 2026 10:54

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

@trissim
trissim added this pull request to the merge queue Oct 30, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Oct 30, 2026
@trissim
trissim enabled auto-merge October 30, 2026 17:53
@trissim

trissim commented Nov 1, 2026

Copy link
Copy Markdown
Contributor Author

Closing after the requested live-reader check (claude-ai, #comms53577). The actual running Toad frontend uses /home/ts/.config/toad/toad.json; installed SavedSettings.path declares that path through XDG config. Read-only inspection found neither ui.compact-input nor ui.prompt_message (and neither literal dotted top-level spelling). File was stable across the read: 3092 bytes, SHA256 830e32d711ee64b5d2eaf52f6d091cbc22a17c286929820e8355ae4951a4a9dd. The current frontend incarnation was checked before/after; settings and process were unchanged. This exact head only adds that retired-input carry plus an old stack lock refresh. No actual live preference needs the carry, so no migration, backup or carry execution is justified. Original branch/commits are retained; no application or carry success is claimed. Evidence: pi-publication-carry/shared-board/3568-live-preference-presence.json.

@trissim trissim closed this Nov 1, 2026
auto-merge was automatically disabled November 1, 2026 21:39

Pull request was closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants