Repository navigation
feat!: retire legacy connection APIs and clean up package builds - #294
Merged
Merged
Conversation
Use app builders, typed handlers, and peer contexts for all protocol bindings. Preserve terminal handles and raw extension fallbacks, remove compatibility-only generation rules, and verify production package contents in CI and publishing. BREAKING CHANGE: AgentSideConnection, ClientSideConnection, Agent, Client, LegacyAgentFactory, createLegacyAgent, and their extension aliases and connector helper have been removed. Use agent()/client() apps and peer-context request()/notify() calls. Compiled tests, fixtures, and examples are no longer published. See MIGRATION_STABLE_UNSTABLE.md for migration instructions.
benbrandt
enabled auto-merge (squash)
October 19, 2026 17:19
8 tasks done
This was referenced Oct 19, 2026
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.
Summary
Finish retiring the deprecated v1 API before the 2.0 release: one supported integration model—app builders, typed handlers, and peer contexts—across the stable and unstable profiles. The four protocol entrypoints and wire schemas are unchanged by this PR.
API cleanup and migration parity
AgentSideConnection,ClientSideConnection, theAgent/Clientimplementation interfaces, outbound extension aliases, and compatibility-only adapters.LegacyAgentFactory,createLegacyAgent, and the connection-class connector helper. Removed server options fail explicitly, including per-request and WebSocket-upgrade overrides.AgentContext.createTerminal(...)and the existingTerminalHandle, including async disposal.onRequest("*", handler)andonNotification("*", handler). Fallback params areunknown; exact and dynamic handlers take precedence, and v2 initialization guards still apply. Handler contexts expose the actualmethod.Production build and package boundaries
typecheckfrom clean, production-only emission withtsconfig.build.json.Updates the migration guide and README. The migration guide remains included in npm. Version metadata is intentionally unchanged; Release Please owns the release bump.
Related: #233. This refreshes the package-boundary work for the four-entrypoint layout; it does not close that PR automatically. Rebased onto current
main, including #291.Review and validation
npm run checkafter rebasing: 488 tests across 20 source files, generation verification, lint, formatting, spellcheck, whole-project typechecking, clean production build, package verification, and all four TypeDoc verification passes.npm run docs:ts:build: all four references build without warnings.skipLibCheck, plus downstream consumption of the emitted declarations with both Zod versions.git diff --check; clean working tree.The prior 976 executions included compiled duplicates; the unique source-test count remains 488. No new repository test cases were added. Live third-party-agent interoperability was not exercised.
GitHub reports three existing high-severity dependency alerts on the default branch. Dependency versions are not changed here; those alerts need separate triage before the release.
BREAKING CHANGE: The legacy v1 connection classes, implementation interfaces, extension aliases, legacy server factory, and connector helper are removed. Use
agent()/client()apps and peer-contextrequest()/notify()calls. Compiled tests, fixtures, and examples are no longer shipped. SeeMIGRATION_STABLE_UNSTABLE.mdfor migration instructions.