ai 4.2.1 → 4.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +16 -0
- package/dist/index.js +9 -9
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -2
- package/dist/index.mjs.map +1 -1
- package/mcp-stdio/create-child-process.test.ts +92 -0
- package/mcp-stdio/create-child-process.ts +2 -37
- package/mcp-stdio/dist/index.js +17 -13
- package/mcp-stdio/dist/index.js.map +1 -1
- package/mcp-stdio/dist/index.mjs +17 -13
- package/mcp-stdio/dist/index.mjs.map +1 -1
- package/mcp-stdio/get-environment.ts +43 -0
- package/package.json +4 -5
package/dist/index.mjs
CHANGED
@@ -6816,7 +6816,7 @@ function tool(tool2) {
|
|
6816
6816
|
}
|
6817
6817
|
|
6818
6818
|
// core/tool/mcp/mcp-sse-transport.ts
|
6819
|
-
import {
|
6819
|
+
import { createEventSourceParserStream } from "@ai-sdk/provider-utils";
|
6820
6820
|
|
6821
6821
|
// core/tool/mcp/json-rpc-message.ts
|
6822
6822
|
import { z as z9 } from "zod";
|
@@ -6987,7 +6987,7 @@ var SseMCPTransport = class {
|
|
6987
6987
|
(_b = this.onerror) == null ? void 0 : _b.call(this, error);
|
6988
6988
|
return reject(error);
|
6989
6989
|
}
|
6990
|
-
const stream = response.body.pipeThrough(new TextDecoderStream()).pipeThrough(
|
6990
|
+
const stream = response.body.pipeThrough(new TextDecoderStream()).pipeThrough(createEventSourceParserStream());
|
6991
6991
|
const reader = stream.getReader();
|
6992
6992
|
const processEvents = async () => {
|
6993
6993
|
var _a18, _b2, _c2;
|