From c61a6ff9bd210a7d3a6a7456b34f83beed15dd3f Mon Sep 17 00:00:00 2001 From: Hongming Wang Date: Fri, 1 May 2026 16:11:09 -0700 Subject: [PATCH] chore(mcp): drop unused module-level _CHANNEL_INSTRUCTIONS MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The frozen copy was a self-justification — the comment claimed "tests + tooling rely on import-time identity" but no test or tooling code path actually references the binding. _build_initialize_result() calls _build_channel_instructions() fresh per call so env changes take effect, which is the documented runtime contract. github-code-quality flagged it; resolving the unused-variable thread so the staging branch protection's all-conversations-resolved gate clears. Co-Authored-By: Claude Opus 4.7 (1M context) --- workspace/a2a_mcp_server.py | 7 ------- 1 file changed, 7 deletions(-) diff --git a/workspace/a2a_mcp_server.py b/workspace/a2a_mcp_server.py index e1f300d7..d428431c 100644 --- a/workspace/a2a_mcp_server.py +++ b/workspace/a2a_mcp_server.py @@ -248,13 +248,6 @@ def _build_channel_instructions() -> str: ) -# Module-level frozen copy preserves the import-time-stable identity -# tests + tooling rely on (e.g. wheel-smoke import probes). The function -# above is the source of truth at runtime — `_build_initialize_result` -# always calls it fresh so env changes between launches take effect. -_CHANNEL_INSTRUCTIONS = _build_channel_instructions() - - def _build_initialize_result() -> dict: """MCP initialize handshake result.