1.83.1 (2026-05-06)
Full Changelog: v1.83.0...v1.83.1
Chores
- internal: fix MCP cloudflare worker initialization (bf0d42d)
This pull request is managed by Stainless's GitHub App.
The semver version number is based on included commit messages. Alternatively, you can manually set the version number in the title of this pull request.
For a better experience, it is recommended to use either rebase-merge or squash-merge when merging this pull request.
🔗 Stainless website
📚 Read the docs
🙋 Reach out for help or questions
Greptile Summary
This patch release fixes the MCP Cloudflare Worker Durable Object initialization by replacing a bare newMcpServer({}) assignment with a deferred-promise pattern that resolves inside init(), adding a 5-second timeout with a spec-compliant fallback server, and wiring in structured logging.
- Cloudflare Worker init overhaul (
cloudflare-worker/src/index.ts):serveris now a manually-resolvedPromise<McpServer>;init()callsbuildMcpServer(with timeout + fallback) before resolving it, preventing the Durable Object from hanging or crashing on upstream fetch failures. - Version bump (
package.json,packages/mcp-server/package.json,manifest.json,src/version.ts,server.ts): all version strings advanced from1.83.0to1.83.1consistently — except thefallbackMcpServerconstructor which still hardcodes1.83.0.
Confidence Score: 4/5
The initialization fix is correct and well-structured; the only concrete defect is the stale version string in the fallback constructor, which causes misidentification in the MCP initialize response when the Stainless API is slow or unavailable.
The fallback server in cloudflare-worker/src/index.ts identifies itself as version '1.83.0' rather than '1.83.1', so any client session that lands on the fallback path reports the wrong server version in its initialize handshake. The rest of the change is clean: the deferred-promise pattern, timeout logic, and error propagation are all sound.
packages/mcp-server/cloudflare-worker/src/index.ts — specifically the fallbackMcpServer function's hardcoded version string.
Important Files Changed
| Filename | Overview |
|---|---|
| packages/mcp-server/cloudflare-worker/src/index.ts | Core fix for Durable Object initialization — adds a deferred-promise pattern, a timeout-guarded server build, and a fallback server, but the fallback hardcodes version '1.83.0' instead of '1.83.1' and the timeout path emits no warning log. |
| packages/mcp-server/src/server.ts | Version string bumped from '1.83.0' to '1.83.1' in the McpServer constructor — straightforward and correct. |
| src/version.ts | VERSION constant bumped to '1.83.1' — correct version bump. |
| package.json | Package version bumped to 1.83.1 — routine release change. |
| packages/mcp-server/package.json | MCP server package version bumped to 1.83.1 — routine release change. |
| packages/mcp-server/manifest.json | Manifest version bumped to 1.83.1 — routine release change. |
| .release-please-manifest.json | Release-please manifest updated to 1.83.1 — routine release tracking change. |
| CHANGELOG.md | Changelog entry added for 1.83.1 describing the Cloudflare worker init fix. |
Sequence Diagram
sequenceDiagram
participant Client as MCP Client
participant DO as MyMCP (Durable Object)
participant Build as buildMcpServer()
participant Stainless as Stainless API
participant Fallback as fallbackMcpServer()
Client->>DO: HTTP request
DO->>DO: init()
DO->>Build: buildMcpServer(stainlessApiKey)
Build->>Stainless: newMcpServer({ stainlessApiKey })
alt Stainless responds within 5s
Stainless-->>Build: McpServer (with instructions)
Build-->>DO: McpServer
else Timeout (5000ms) or error
Build->>Fallback: fallbackMcpServer()
Fallback-->>Build: McpServer (no instructions, version '1.83.0' stale)
Build-->>DO: fallback McpServer
end
DO->>DO: initMcpServer(server, clientOptions)
DO->>DO: resolveServer(server)
DO-->>Client: MCP initialize response
Prompt To Fix All With AI
Fix the following 2 code review issues. Work through them one at a time, proposing concise fixes.