Skip to content

Upgrade TypeScript libraries to newer versions - #198

Merged
olaservo merged 1 commit into
modelcontextprotocol:mainfrom
a-akimov:chore/ts-deps-upgrade-sep10
Sep 15, 2026
Merged

olaservo merged 1 commit into
modelcontextprotocol:mainfrom
a-akimov:chore/ts-deps-upgrade-sep10

Conversation

@a-akimov

Copy link
Copy Markdown
Contributor

Motivation and Context

Updating to the latest versions of @anthropic-ai/sdk (0.124.0), typescript (7.0.2) and @types/node (24.13.4), as well as other dependencies to keep the repo up-to-date.

Code changes required by the new versions:

  • mcp-client-typescript/index.ts: the Anthropic types were imported from a deep resources/messages/messages.mjs path, which is not a supported entry point. They now come from the Anthropic namespace, the idiom the SDK documents.
  • dotenv 17 logs an "injecting env" line to stdout by default. The client now passes quiet: true.
  • TypeScript 7 adopts the TypeScript 6 defaults and turns its deprecations into hard errors. The one that bit this repo is types defaulting to empty instead of every package under node_modules/@types. The two samples happened to compile because their imports pull in the Node globals transitively, but the test helpers did not and failed on process. All three tsconfigs now set types: ["node"] explicitly, which is what the TypeScript team recommends.
  • tests/helpers got the same package bumps so the whole TypeScript surface of the repo is on one toolchain.

How Has This Been Tested?

Locally.

Breaking Changes

N/a.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update

Checklist

  • I have read the MCP Documentation
  • My code follows the repository's style guidelines
  • New and existing tests pass locally
  • I have added appropriate error handling
  • I have added or updated documentation as needed

Additional context

N/a

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.

🟢 Approval recommended

No unresolved blocking issues were identified.

Pull request overview

This pull request upgrades TypeScript dependencies and updates compatibility with the Anthropic SDK and dotenv.

Changes:

  • Upgrades TypeScript, Node types, Zod, dotenv, and Anthropic SDK dependencies.
  • Enables explicit Node typings in all TypeScript configurations.
  • Updates Anthropic type usage and quiets dotenv startup logging.
File summaries
File Summary
weather-server-typescript/tsconfig.json Enables Node typings.
weather-server-typescript/package.json Updates dependencies.
weather-server-typescript/package-lock.json Locks updated dependencies.
tests/helpers/tsconfig.json Enables Node typings.
tests/helpers/package.json Updates helper dependencies.
tests/helpers/package-lock.json Locks updated helper dependencies.
mcp-client-typescript/tsconfig.json Enables Node typings.
mcp-client-typescript/package.json Updates client dependencies.
mcp-client-typescript/package-lock.json Locks updated dependencies.
mcp-client-typescript/index.ts Uses supported Anthropic types and quiet dotenv loading.
Review details

Files not reviewed (3)

  • mcp-client-typescript/package-lock.json: Generated file
  • tests/helpers/package-lock.json: Generated file
  • weather-server-typescript/package-lock.json: Generated file
  • Files reviewed: 7/10 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@olaservo
olaservo merged commit 5eb3b64 into modelcontextprotocol:main Sep 15, 2026
2 checks passed
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.

3 participants