Repository navigation
Let existing owners dispatch inbox inputs and encode compact JSON - #2692
Merged
3 commits merged intoOct 23, 2026
Merged
3 commits merged into
3 commits merged into
Conversation
trissim
marked this pull request as ready for review
October 23, 2026 08:41
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.
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.
|
debt-tools at 1696857, every finding: |
|
debt-src at 1696857, every finding: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Inbox records previously called forwarding methods that called back into InputForwarding. TurnInboxReceiver and all six inbox/prompt
deliver_toimplementations are deleted. InputForwarding now declares the operations through existing MroDispatch; it consumes the most-specific handler because PreparedSession inherits UnwrittenPrompt and must prepare an idle session without sending a prompt. PreparedSession now lives with the prompt states rather than the native preparation launcher. TurnInbox declares its admitted item type.FieldCodec.compact owns compact JSON layout. All 34 existing compact dumps/dump calls across 26 files use it, preserving each caller's encoded value, Unicode, key-order and NaN settings. It serializes the already encoded value; it does not walk the value through declaration encoding again. The one stdout dump becomes stdout.write(compact(...)), retaining its newline and flush. No store schema changes.
Removed forwarding sites at base f966a53: agent_backend.py:139 (receiver protocol), :189 (abstract delivery), :207 (InputRequest), :221 (SendNow), :236 (UseSettings), :246 (ClearQueue); prompt_state.py:67 (UnwrittenPrompt); native_session_prepare.py:35 (PreparedSession). The send/preparation algorithms now belong to InputForwarding.original_prompt and prepare_session. Single-operation selection at turn_inputs.py:95 uses the existing MroDispatch.handlers_for lookup directly; no narrowed consume_handlers override or second dispatch registry remains.
Removed compact-layout copies at base f966a53: working_memory_labels.py:47; selected_write_plan.py:223,:273; context_store.py:189; typed_table.py:275; acp_extension.py:402,:574; response_acknowledgement.py:20; cli_bridges/shared.py:802; connector_store.py:69; fresh_private_session.py:36; retained_task_facts.py:249; goal_attempts.py:601; selected_source_batch.py:88; assignment_states.py:366; context_segments/optional_awareness.py:182; audience_manifest.py:46; context_segments/wake.py:97,:102,:120,:151; turn_context.py:821,:1009,:1120; context_segments/awareness.py:23; context_segments/partner_activity.py:60; context_segments/relationships.py:26; pi_helper.py:98; threads.py:336; exporting.py:45; nk_foreground.py:119; private_sidecar.py:221,:370; goals.py:474. The single implementation is field_codec.py:1356. OwnedDispatchPhase now allows that canonical implementation and rejects compact-layout copies elsewhere, including single-quoted spellings missed by the old pattern.
Source ownership was traced with the existing NRA original class/consumer inventory (762 Core/paired-Toad/dependency modules; 6410 original classes; 8 local/conditional classes unprojected). The compact edits used NRA's original module syntax index on the selected files. The fleet integrator owns the combined touched-test run.
Shared hunks with #2667: agent_backend.py removes only inbox delivery and types its queue; turn_inputs.py changes dispatch and moves the send/preparation algorithms; private_sidecar.py changes only compact layout. Keep #2667's BusyInputPolicy and typed Pi streaming behavior when combining. plan_phases.py changes only OwnedDispatch evidence. The commander owns the separate WireOrigin.matches_sql fix in the merge batch.
Assumed: inbox inputs satisfy TurnInboxItem; the pinned native request contract stays unchanged; the integrator combines the shared hunks with #2667.
Latest source fixes: TurnInboxItem is declared before TurnInbox, so the queue names its actual type rather than a quoted spelling. Forwarding directly selects its most-specific declared handler, deleting the incompatible consume_handlers override. Compact JSON calls and imports in audience_manifest.py/response_acknowledgement.py are wrapped. The saved hosted findings at 9c517cf included tools/cutover/carry_dead_turns.py from the combined base; this branch does not edit that owner. The integrator runs the batch checks.