Skip to content

refactor(acp): move the rest of AcpSessionHandle into owner modules - #21989

Merged
bolichen97 merged 1 commit into
mainfrom
refactor/linecap-g06-session-handle-p2
Oct 19, 2026
Merged

bolichen97 merged 1 commit into
mainfrom
refactor/linecap-g06-session-handle-p2

Conversation

@bolichen97

Copy link
Copy Markdown
Contributor

Problem / Motivation

Goal: Bring src/kiro_crew/acp/session_handle.py under the repository's 2,000-line cap by moving the rest of AcpSessionHandle (its MCP, KAS, native-child, model, steering, permission and session/update members) and the class statement into owner modules, with every behaviour, import path and patch seam unchanged.

session_handle.py is 4,873 lines after the first PR of this series (#21590), still more than twice the cap, and it is in .github/file-line-cap-baseline.txt only so it can shrink. What is left is the rest of one class: the MCP server handling, the KAS extensions, harness-native child sessions, model selection, steering, permissions and the session/update decoder, plus the class statement and its constructor.

Why it matters

Every runtime-backed Kiro Crew session (kiro-cli, KAS, codex and the other harnesses on the shared AcpRuntime) runs through this class. Until the file is under the cap it stays on the baseline, every feature PR that touches the session transport adds to it, and a reader cannot see where a responsibility lives. This PR finishes KC28 scope G06 (umbrella #20192): it moves the remaining members and deletes the file's baseline row.

Not a goal

  • No behaviour change. Every moved body is main's code with the same AST, apart from the two call sites listed under "Move audit". The other edits leave the AST unchanged: the dedent, a self annotation for type checkers, black's reflow of a few dedented lines, three comment rewords for the comment-history gate and one brand-spelling fix, all listed there.
  • No new feature, hardening or fix. Defects found along the way are reported separately, not fixed here.
  • No change to the six owners the first PR created, beyond the one member (_input_wait_status) the series plan assigned to the watchdog owner in this PR.
  • No production code change outside acp/session_handle*.py. Elsewhere only citations, path-keyed rows, the source-pin joins in tests and the baseline row change, and no caller's import path changes.

What changed (motivation → approach → change)

What is left of AcpSessionHandle still shares its state on the instance, and tests still reach that state, patch members on the class and call them unbound. So this PR uses the same binding shape as the first one (L33): each member body becomes a module-level function in an owner, and the class binds it by name.

Seven owners take the remaining members, each with one responsibility the owning spec's table names: acp/session_handle_mcp.py (the session's MCP servers), _kas.py (what KAS speaks beyond ACP, including #21907's checkpoint rewind discard_unanswered_prompt), _native_children.py (harness-native child sessions), _model_selection.py (the session's model), _steering.py (steering a live turn), _permissions.py (permission requests and in-band refusals) and _updates.py (session/update frames as AcpEvent values). The watchdog owner gains _input_wait_status, as the series plan set out.

The class statement itself moves to acp/session_handle_class.py, which sets __module__ = "kiro_crew.acp.session_handle": reprs, pickles and typing.get_type_hints keep naming the facade, and kiro_crew.acp.session_handle.AcpSessionHandle and kiro_crew.acp.runtime.AcpSessionHandle stay the same class object. session_handle.py keeps only the mirror facade and drops from 4,873 to 363 lines; its line-cap baseline row is deleted.

Backwards compatibility

Compatible: every name kiro_crew.acp.session_handle bound before is still bound or served there (test/campaign_facade_inventories/kiro_crew.acp.session_handle.json), every AcpSessionHandle member keeps its name, kind, coroutine shape and signature (frozen in test/test_session_handle_bindings.py), and the class keeps its module name.

One accepted consequence (the G03 precedent): inspect.getsource(AcpSessionHandle) raises OSError, because __module__ names the facade, which holds no class AcpSessionHandle statement. Nothing reads it; a member's source still resolves through __code__, and acp-client.md says where the class statement lives. On Python 3.13 and later, inspect would instead return the facade's lines at the class's __firstlineno__; that follow-up belongs to the Python-upgrade work.

Six public module-level functions leave the file's text. Each is re-imported by the facade, so its old import path resolves to the same function object:

Reader: src/kiro_crew/acp/liveness.py:mcp_launch_roster -- chat -- a comment names session_handle.mcp_launch_roster; the facade binds the name, and test_acp_liveness_remote_flat.py imports it from the facade
Reader: src/kiro_crew/acp/client_model_selection.py:parse_advertised_models -- chat -- the function-local from kiro_crew.acp.session_handle import parse_advertised_models resolves through the facade's re-import (test_acp_client_session_setup.py, test_acp_runtime_models.py)
Reader: src/kiro_crew/acp/client_model_selection.py:models_from_config_options -- chat -- the function-local import resolves through the facade's re-import (test_acp_codex_harness.py, test_acp_deepseek_backend_effort.py)
Reader: test/test_kas_model_select_capture.py:model_select_envelope -- chat -- imports it from the facade, which re-binds the owner's function
Reader: src/kiro_crew/acp/session_handle.py:session_models_envelope -- chat -- nothing outside the session_handle family reads it; the facade still binds it (pinned by test/campaign_facade_inventories/kiro_crew.acp.session_handle.json), and test_acp_codex_harness.py::test_both_model_readers_answer_from_one_fold exercises it through the handle's model readers
Reader: src/kiro_crew/acp/runtime.py:advertised_models_from_session -- chat -- runtime.py's module-level from kiro_crew.acp.session_handle import (... advertised_models_from_session ...) still resolves; cron and subagent sessions run on the same runtime, and client_model_selection.py's function-local import resolves the same way (test_harness_parity.py)

Tests

  • test/test_session_handle_bindings.py, regenerated for the full split:
    • the frozen 143-member inventory now spans 12 owner modules and the class home, plus the two declared fields;
    • the class keeps kiro_crew.acp.session_handle as its __module__ and pickle path;
    • every member still resident in the class resolves its type hints;
    • only the facade imports the class home, with a self-test that the scan can fail;
    • parse_advertised_models normalizes through the owner's _normalize_models, the function the class binds: a sentinel patched over it comes back from both input shapes;
    • the patch-reach scan, the logger, exception and import-inventory pins carry over from the first PR.
  • Source pins and path-keyed rows follow the moved code (see "Source pins" below); each has a mutation proof.

Manual verification

N/A. This is a structural move, and the unit floor below exercises every moved member. An installed-wheel import smoke of the new modules ran from a git archive export.

Related Issues

Part of #20192
Follow-up: #21320

Checklist

  • At most two commits (one is the norm), with a Conventional Commits title (feat|fix|docs|style|refactor|perf|test|chore|ci|build|revert: ...)
  • Existing tests pass and new tests added for new functionality
  • Self-review completed; code follows project style guidelines
  • Documentation updated (if applicable)
  • No secrets, credentials, or internal references in the diff

Move audit

src/kiro_crew/acp/session_handle.py: 4873 -> 363 lines; moved 21.82% (python-ast)
normalized (G03 R5 comparator): 187 units, 181 moved unchanged (4243 lines), 6 changed (97 lines): AcpSessionHandle._emit_tool_interrupted_sel, parse_advertised_models, <Expr@1>, the TYPE_CHECKING manifest (<If@4864>), _SERVED, _SESSION_HANDLE_OWNERS

Normalized audit, the G03 R5 comparator: docstrings via inspect.cleandoc, the self annotation dropped, a removed @staticmethod ignored. Changed units:

  • parse_advertised_models: two calls AcpSessionHandle._normalize_models(...) become _normalize_models(...), the owner's own function, which the class binds as its static method (the class is not importable from the owner at run time). Pinned by test_the_model_parsers_normalize_through_the_function_the_class_binds.
  • _emit_tool_interrupted_sel: the docstring's "KiroCrew" becomes "Kiro Crew" (brand gate on moved prose).
  • the module docstring, _SESSION_HANDLE_OWNERS, _SERVED and the TYPE_CHECKING manifest: facade glue for the new owners.

Edits that leave the AST unchanged:

  • comment-history gate: session_handle_kas._handle_kas_session_info's and session_handle_model_selection.set_model's "no longer describe" now read "do not describe"; session_handle_model_selection.store_session_config's "a previously-stored list" now reads "an already-stored list".
  • brand gate: _emit_tool_interrupted_sel's docstring "KiroCrew" now reads "Kiro Crew" (also listed above, since a docstring is part of the normalized audit).
  • black reflowed a few lines that fit in 100 columns after the dedent (for example one logger.warning call and apply_session_permission_routing's if condition).

Glue:

  • the seven owner imports and the class home's import, re-imports of moved names, and the mirror tail;
  • the facade's EntitlementRevalidating import keeps its line, and its noqa reason reads "re-exported" instead of "raised here", since the raise moved to session_handle_model_selection.

Diff alignment (L36)

git diff and git diff --minimal add the same lines in every changed file:

file default --minimal
.github/file-line-cap-baseline.txt +0/-1 +0/-1
docs/system-specs/common/injected-messages.md +1/-1 +1/-1
docs/system-specs/modules/acp-client.md +20/-6 +20/-6
docs/system-specs/modules/agent-host-contract.md +1/-1 +1/-1
docs/system-specs/modules/harness-parity.md +2/-2 +2/-2
docs/system-specs/modules/metrics.md +2/-2 +2/-2
src/kiro_crew/acp/kas_wire.py +2/-1 +2/-1
src/kiro_crew/acp/runtime.py +2/-2 +2/-2
src/kiro_crew/acp/session_handle.py +60/-4570 +60/-4570
src/kiro_crew/acp/session_handle_class.py +946/-0 +946/-0
src/kiro_crew/acp/session_handle_kas.py +398/-0 +398/-0
src/kiro_crew/acp/session_handle_mcp.py +647/-0 +647/-0
src/kiro_crew/acp/session_handle_model_selection.py +995/-0 +995/-0
src/kiro_crew/acp/session_handle_native_children.py +316/-0 +316/-0
src/kiro_crew/acp/session_handle_permissions.py +621/-0 +621/-0
src/kiro_crew/acp/session_handle_steering.py +460/-0 +460/-0
src/kiro_crew/acp/session_handle_updates.py +674/-0 +674/-0
src/kiro_crew/acp/session_handle_watchdog.py +64/-5 +64/-5
src/kiro_crew/agent_sdk/backends_mcp.py +1/-1 +1/-1
src/kiro_crew/agent_sdk/backends_turns.py +1/-1 +1/-1
src/kiro_crew/dashboard/handlers/usage.py +1/-1 +1/-1
src/kiro_crew/instances/constants.py +1/-1 +1/-1
src/kiro_crew/security_posture.py +4/-1 +4/-1
src/kiro_crew/session_compaction.py +1/-1 +1/-1
test/campaign_facade_inventories/kiro_crew.acp.session_handle.json +11/-0 +11/-0
test/test_decisions_model_route_apply.py +3/-3 +3/-3
test/test_deny_bounded_write.py +12/-4 +12/-4
test/test_fallback_row_attribution_8560.py +1/-1 +1/-1
test/test_harness_parity.py +21/-5 +21/-5
test/test_session_handle_bindings.py +271/-105 +271/-105
test/test_usage_blank_model_8531.py +1/-1 +1/-1

Source pins (L30 / L40(8)) and rows

pin change mutation planted
test_harness_parity.py deny-set readers (B2) reads the facade joined with every owner, as the client half does the permissions owner's tripwire stops reading the deny set → red
test_harness_parity.py identity rows, _RUNTIME_PATH_MODULES (C1) _build_permission_event → permissions, set_model / ensure_served_default → model selection, _handle_update → updates; the new owners and the class home join the scan re-keyed row goes stale → red; undeclared identity test in the MCP owner → red
test_deny_bounded_write.py SITES (C2) the reject/approve warning needles move to the permissions owner; empty rows for the other new owners approve_tool's floor warning loses its sanitizer → red; an unlisted id slot in the class home → red
security_posture.NON_EGRESS_REDACTION_MODULES rows for the four new owners that call a redactor; the facade row goes, since the facade calls none now (L55) row removed → red; redactor in a row-less owner → red
.github/file-line-cap-baseline.txt the facade's row is deleted (363 lines) —

Baselined growth (L56 addendum 1b)

  • src/kiro_crew/security_posture.py: main 3,413 lines (row 3,181), HEAD 3,416 (+3): four exact-path NON_EGRESS_REDACTION_MODULES rows the redactor drift guard requires, with no added comment, less the facade's row.

CI path references

None. No workflow path filter or file list names session_handle.py.

Prose citations (L29)

Comment and docstring citations of where a moved construct is defined, path or name only, in place (line numbers at the merge base):

  • src/kiro_crew/acp/runtime.py:5: AcpSessionHandle (in session_handle.py) -> (in session_handle_class.py)
  • src/kiro_crew/acp/runtime.py:9: the handle, protocol and exceptions live in session_handle.py / session_handle_runtime_contract.py -> session_handle_class.py / session_handle_runtime_contract.py
  • src/kiro_crew/acp/kas_wire.py:9: the frame handlers live in :mod:kiro_crew.acp.session_handle -> :mod:kiro_crew.acp.session_handle_kas (sub-agent frames in :mod:kiro_crew.acp.session_handle_native_children), one line longer
  • src/kiro_crew/agent_sdk/backends_mcp.py:290: (acp/runtime.py, acp/session_handle.py) -> (acp/runtime.py, acp/session_handle_class.py)
  • src/kiro_crew/agent_sdk/backends_turns.py:287: (acp/session_handle.py) -> (acp/session_handle_kas.py)
  • src/kiro_crew/session_compaction.py:615: (acp/session_handle.py) -> (acp/session_handle_kas.py)
  • src/kiro_crew/instances/constants.py:350: _READ_PATH_PROBE_DEADLINE_SECS in acp/session_handle.py -> acp/session_handle_model_selection.py
  • src/kiro_crew/dashboard/handlers/usage.py:105: session_handle.py __init__ -> session_handle_class.py __init__ (the first PR's citation, followed to the class home)
  • test/test_fallback_row_attribution_8560.py:39: session_handle.py:1379-1384 -> (session_handle_model_selection.py, set_model)
  • test/test_decisions_model_route_apply.py:753: backend default (acp/session_handle.py) -> (acp/session_handle_model_selection.py), re-wrapped within the same three docstring lines
  • test/test_usage_blank_model_8531.py:154: (session_handle.py / session_provider.py) -> (session_handle_class.py / session_provider.py)
  • Docs (SD27): acp-client.md (the owner table gains the seven owners and the class home, and the closing paragraph names where the class statement lives), harness-parity.md (H6 and H16 cells), metrics.md (two rows), injected-messages.md, agent-host-contract.md.

References not edited (cost)

  • website/playwright/chat.spec.ts:23 (_MCP_DRAIN_NO_REPORT_CEILING (6 s, src/kiro_crew/acp/session_handle.py) -> src/kiro_crew/acp/session_handle_mcp.py): a comment-only cite under website/, left for the batched docs PR (L50).

Logger names (L25)

The new owners that log bind logging.getLogger("kiro_crew.acp.session_handle"), the facade's logger, as the first PR's owners do.

Local gate

scripts/local-gate.py --base <merge-base> --dry-run selects more than 600 test files, so it was not run whole (SD14). The floor that ran instead is 706 test files: every file that imports, patches or names session_handle, AcpSessionHandle or kiro_crew.acp, plus the facade, mirror, posture, line-cap and tree-scan guards. Result on this series' PR2 tree: 32,975 passed, 75 skipped, 0 failed. After the last recipe fold (one docstring citation in runtime.py, the generated declared-field set in the guard), the guard, the facade and mirror contracts, the posture, harness-parity and deny-row tests and the edited citation files were re-run: 2,080 passed, 0 failed (17 files). Mutation proofs: 16 of 16 planted mutations turn their pin red (reports/G06/mutations-pr2.txt). After the review fold (the normalizer pin made behavioural, the kas_wire.py citation), the guard, harness parity and the mirror guards were re-run: 898 passed, 0 failed; mypy src/kiro_crew/acp/ is clean (80 files). After the rebase onto the main that carries S26's _dispatch.py split (#21554), the guard, contracts, posture, harness-parity and deny-row tests and every test main changed that names session_handle or _dispatch were re-run: 4,753 passed, 0 failed (53 files); cold mypy src/kiro_crew is clean (3,101 source files). Also run on this head: cold mypy src/kiro_crew on a git archive export, both alone (no issues in 3,030 source files) and merged with S26's _dispatch.py split head (no issues in 3,038 source files); semgrep 1.78 with the CI configs and --baseline-commit (0 findings, 0 errors, no parse errors, 23 files); an installed-wheel import of all eight new modules; docs_lint, comment-history, brand, harness-parity, black, isort, flake8, subprocess-encoding, agent-sdk boundary, line-cap, take-away (six Reader: lines) and the L52 check_inventory (197 names, none missing); and the L59 check against #21590's owners (the only lines this PR takes out of them are the planned _input_wait_status move into the watchdog owner).

session_handle.py still carries 4,873 lines after the first PR of KC28
G06 (part of #20192): the MCP, KAS, native-child, model, steering,
permission and session/update members of AcpSessionHandle, and the
class statement itself. This second PR brings the file under the
repository's 2,000-line cap and deletes its line-cap baseline row.

Seven owner modules take those members, each with one responsibility the
owning spec names: the session's MCP servers, what KAS speaks beyond
ACP, harness-native child sessions, the session's model, steering a live
turn, permission requests and in-band refusals, and session/update
frames. Bodies move as module-level functions taking self, with the same
AST apart from two listed call sites, and the class binds them by name
as in the first PR. The class statement moves to session_handle_class.py
and sets __module__ to kiro_crew.acp.session_handle, so reprs, pickles
and type hints still name the facade. session_handle.py keeps only the
compatibility facade and drops to 363 lines.
@bolichen97
bolichen97 requested review from a team and KiroCrewCaptain as code owners October 19, 2026 00:14
@bolichen97
bolichen97 requested a review from buluoray October 19, 2026 00:14
@bolichen97

Copy link
Copy Markdown
Contributor Author

Sensitive change review

  • Head commit: f74b8f1
  • What rule changed: none. src/kiro_crew/security_posture.py's NON_EGRESS_REDACTION_MODULES gains four exact-path rows (acp/session_handle_kas.py, acp/session_handle_model_selection.py, acp/session_handle_native_children.py, acp/session_handle_permissions.py) for redactor calls that moved verbatim out of acp/session_handle.py, and loses acp/session_handle.py's row because the facade calls no redactor now; no sink, classification or redactor changed.
  • Before -> after: the redactor calls in the KAS, model-selection, native-child and permission members were classified non-egress under the acp/session_handle.py row; the same calls, byte for byte, are now classified under the owner rows that hold them (L55).
  • Worst case if wrong: a redactor call in a moved module would go unclassified, or a stale facade row would make the sink check vacuous for it; test_security_posture.py's omission and drift guards turn either red; nothing at run time reads these rows.
  • Evidence checked: test_security_posture.py passes; mutation proofs (an owner row removed, a redactor planted in a row-less owner) turn it red; the moved bodies are AST-identical to main (normalized move audit).
  • Tools still work: no tool, gate or redactor code changed; the 706-file floor (32,975 passed, 0 failed) covers the moved members.
  • Backward compatible: the posture panel lists the same redaction behaviour under the modules that now hold it; no config or API changed.
  • Existing tests: unchanged and passing; the only change is the rows the drift guard requires.
  • How to undo: revert this commit; the rows go with the moved code.

@github-actions

Copy link
Copy Markdown
Contributor

Sensitive Change Review

Sensitive files changed:

  • src/kiro_crew/security_posture.py

  • @bolichen97 posted a complete reasoning template for f74b8f1.

@github-actions

Copy link
Copy Markdown
Contributor

UX Review (Opus 5.5) — ⏭️ skipped

Revision f74b8f15de4a8085a0d28b7756a6be0d69df2ee4 touches no user-facing surface (no changes under website/ or committed screenshots), so the UX review was skipped. Advisory — does not block merge.

@github-actions github-actions Bot added the readiness: checking Automated validation is still running label Oct 19, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Design Review (Opus 5.5) — ✅ PASS

Design-level review of f74b8f15de4a8085a0d28b7756a6be0d69df2ee4 — updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

Design-Verdict: PASS

parse_advertised_models now calls the owner's _normalize_models directly; confirm nothing patches AcpSessionHandle._normalize_models and expects the module-level parser to pick it up.

[DESIGN-REVIEWED] f74b8f1

Description read

[DESCRIPTION-READ] b83ac55b502a5670ca07e91b34b15d372d506e0cfda32107c59a2df88b598641

That sha256 names everything this verdict read: the PR description, plus the 1 evidence file(s) the workflow collected from it and handed this review. It covers that evidence because the media strip replaces every attachment URL with the same placeholder, so an edit swapping one attachment for another would leave the description's captured text identical while what this review judged changed. Recompute it with .github/scripts/pr-description-capture.sh over the same inputs; if it differs, the description or that evidence changed after this verdict was formed and any finding drawn from either is unproven.

@github-actions

Copy link
Copy Markdown
Contributor

First Principles Review (Opus 5.5) — ✅ PASS

Premise-level review of f74b8f15de4a8085a0d28b7756a6be0d69df2ee4 — why this exists and whether the shipped surface is the smallest honest version. Updated in place on each push. A BLOCK verdict blocks PR readiness; PASS/CONCERNS are advisory.

First-Principles-Verdict: PASS

One patch seam moved: parse_advertised_models no longer goes through AcpSessionHandle._normalize_models. Before merge, confirm nothing outside test/ patches that attribute.

What this change ships

Inventory (6 items) — 6 justified

Intent: get acp/session_handle.py under the repository's 2,000-line cap without changing any behaviour or import path. This is an ADDITION of files only, done because AGENTS.md requires the cap.

  1. session_handle.py drops from 4,873 to 363 lines and becomes a re-export facade; its row in the line-cap baseline is deleted — justified
  2. Seven new owner modules take the remaining members (MCP, KAS, native children, model selection, steering, permissions, updates) — justified
  3. The class statement moves to session_handle_class.py, and __module__ still names the facade, so reprs, pickles and import identity are unchanged — justified
  4. _input_wait_status moves into the existing watchdog owner, as the series plan set out — justified
  5. parse_advertised_models now calls its owner module's _normalize_models instead of the class attribute; this is declared in the move audit and pinned by a test — justified
  6. Docs, spec citations, source-pin tests and the facade inventory JSON now point at the new owner paths — justified

[FIRST-PRINCIPLES-REVIEWED] f74b8f1

Description read

[DESCRIPTION-READ] 734a81bb9e2125266f82c5c266adf215ac4cb8b835b9d019e88d1456fe6b20bb

That sha256 names the PR description this verdict read. Recompute it with .github/scripts/pr-description-capture.sh; if it differs, the description changed after this verdict was formed and any finding drawn from the description is unproven.

@github-actions

Copy link
Copy Markdown
Contributor

GPT 6.1 Review — ✅ no blocking findings

GPT 6.1 completed its review of f74b8f15de4a8085a0d28b7756a6be0d69df2ee4 and found no blocking issues.

This comment is updated in place on each push.

Review details

No findings.
[GPT-REVIEWED] f74b8f1

False positive or not applicable? A repository writer can comment:
/ai-review override gpt f74b8f15de4a8085a0d28b7756a6be0d69df2ee4: <one-sentence reason>

@github-actions

Copy link
Copy Markdown
Contributor

Opus 5.5 Review — ✅ no blocking findings

Reviewed f74b8f15de4a8085a0d28b7756a6be0d69df2ee4 — this comment is updated in place on each push.

Review details

No findings.

[OPUS-REVIEWED] f74b8f1

Verdict parsed from the review's SHA-scoped output markers for commit f74b8f15de4a8085a0d28b7756a6be0d69df2ee4.

False positive or not applicable? A repository writer can comment:
/ai-review override fable f74b8f15de4a8085a0d28b7756a6be0d69df2ee4: <one-sentence reason>

@bolichen97
bolichen97 enabled auto-merge (squash) October 19, 2026 00:35
@bolichen97

Copy link
Copy Markdown
Contributor Author
  • nothing patches AcpSessionHandle._normalize_models

confirmed at main 518b36d: git grep over the whole repository (src/, test/, the builtin apps) finds no patch(...), setattr or assignment that targets _normalize_models on the class, the facade or any owner. The only reader outside the session_handle family calls it: test/test_acp_runtime_client_parity.py::test_normalize_models_shape, and its call to AcpSessionHandle._normalize_models still resolves to the same function.
The seam is pinned: test_session_handle_bindings.py::test_the_model_parsers_normalize_through_the_function_the_class_binds asserts that the class binds the owner's _normalize_models, and that a sentinel patched over that function comes back from both parse_advertised_models input shapes. Mutation proofs: either call site swapped out, or a different normalizer bound in the class, turns it red.

@bolichen97

Copy link
Copy Markdown
Contributor Author
  • the parse_advertised_models normalizer seam

confirmed at main 518b36d: no file inside or outside test/ patches AcpSessionHandle._normalize_models (git grep over src/, test/ and the builtin apps finds no patch, setattr or assignment of it). Its one outside reader, test_acp_runtime_client_parity.py::test_normalize_models_shape, calls it, and that still reaches the same function.
parse_advertised_models now calls the owner's _normalize_models, the very function the class binds as its static method, so a call through either path runs the same code. test_the_model_parsers_normalize_through_the_function_the_class_binds pins that with a sentinel patch and three mutation proofs; the edit is listed under "Move audit" in the body.

@github-actions github-actions Bot added readiness: passed Eligible automated validation passed for the current revision and removed readiness: checking Automated validation is still running labels Oct 19, 2026

@KiroCrewCaptain KiroCrewCaptain left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Every review lane on the head is clean (only runner notices and PR Scope size warnings); held by the triage cron on size, path or checklist rules alone. Approved on the watch holder's request.

@bolichen97
bolichen97 merged commit f3c129f into main Oct 19, 2026
104 checks passed
@bolichen97
bolichen97 deleted the refactor/linecap-g06-session-handle-p2 branch October 19, 2026 02:49
@github-actions github-actions Bot removed the readiness: passed Eligible automated validation passed for the current revision label Oct 19, 2026
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