-
Notifications
You must be signed in to change notification settings - Fork 0
chore(deps): update dependency @ai-sdk/react to v3 #1039
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No issues found across 2 files
d85e409 to
a3e5647
Compare
| "generate-sdk-docs": "bun scripts/generate-sdk-docs.ts", | ||
| "docker": "bash -c \"docker buildx build . --provenance true --sbom true --platform=linux/amd64,linux/arm64 -t ghcr.io/settlemint/btp-docs:${VERSION:-7.0.0-dev.$(date +%s)} --push --progress=plain\"" | ||
| }, | ||
| "dependencies": { |
This comment was marked as outdated.
This comment was marked as outdated.
Sorry, something went wrong.
|
|
||
| "@ai-sdk/provider-utils": ["@ai-sdk/provider-utils@3.0.19", "", { "dependencies": { "@ai-sdk/provider": "2.0.0", "@standard-schema/spec": "^1.0.0", "eventsource-parser": "^3.0.6" }, "peerDependencies": { "zod": "^3.25.76 || ^4.1.8" } }, "sha512-W41Wc9/jbUVXVwCN/7bWa4IKe8MtxO3EyA0Hfhx6grnmiYlCvpI8neSYWFE0zScXJkgA/YK3BRybzgyiXuu6JA=="], | ||
|
|
||
| "@ai-sdk/react": ["@ai-sdk/react@2.0.118", "", { "dependencies": { "@ai-sdk/provider-utils": "3.0.19", "ai": "5.0.116", "swr": "^2.2.5", "throttleit": "2.1.0" }, "peerDependencies": { "react": "^18 || ~19.0.1 || ~19.1.2 || ^19.2.1", "zod": "^3.25.76 || ^4.1.8" }, "optionalPeers": ["zod"] }, "sha512-K/5VVEGTIu9SWrdQ0s/11OldFU8IjprDzeE6TaC2fOcQWhG7dGVGl9H8Z32QBHzdfJyMhFUxEyFKSOgA2j9+VQ=="], | ||
| "@ai-sdk/react": ["@ai-sdk/react@3.0.1", "", { "dependencies": { "@ai-sdk/provider-utils": "4.0.0", "ai": "6.0.1", "swr": "^2.2.5", "throttleit": "2.1.0" }, "peerDependencies": { "react": "^18 || ~19.0.1 || ~19.1.2 || ^19.2.1" } }, "sha512-XUPDMFgalNtqBQg+Q3UiiEmWE3PC5pAoc+Drs5Z1Mxqe57za+hKCEwViYADuqeZrc0q6PXTzbcFlQb3pjyGjcQ=="], | ||
|
|
||
| "@alloc/quick-lru": ["@alloc/quick-lru@5.2.0", "", {}, "sha512-UrcABB+4bUrFABwbluTIBErXwvbsU/V7TZWfmbgJfbkwiBuziS9gxdODUyuiecfdGQ85jglMW6juS3+z5TsKLw=="], | ||
|
|
This comment was marked as outdated.
This comment was marked as outdated.
Sorry, something went wrong.
a3e5647 to
2669bcb
Compare
Signed-off-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2669bcb to
ae32a47
Compare
| "@ai-sdk/openai": "2.0.88", | ||
| "@ai-sdk/react": "2.0.118", | ||
| "@ai-sdk/react": "3.0.3", | ||
| "@next/third-parties": "16.1.1", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: The ai package version in package.json is outdated, causing a synchronous call to the now-asynchronous convertToModelMessages() function. This will lead to a runtime error.
Severity: CRITICAL | Confidence: High
🔍 Detailed Analysis
The update of @ai-sdk/react to v3.0.3 introduces a transitive dependency on ai@6.0.3. However, package.json still specifies ai: "5.0.116". The newer version of the ai package includes a breaking change where convertToModelMessages() is now an asynchronous function. The code in src/app/api/chat/route.ts calls this function synchronously. This will cause streamText() to receive a Promise instead of the expected message array, leading to a runtime failure when a POST request is made to the /api/chat endpoint.
💡 Suggested Fix
Update the ai package version in package.json to ^6.0.3 to match the dependency of @ai-sdk/react. Then, modify the call to convertToModelMessages() in src/app/api/chat/route.ts to be asynchronous by adding await.
🤖 Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.
Location: package.json#L21
Potential issue: The update of `@ai-sdk/react` to `v3.0.3` introduces a transitive
dependency on `ai@6.0.3`. However, `package.json` still specifies `ai: "5.0.116"`. The
newer version of the `ai` package includes a breaking change where
`convertToModelMessages()` is now an asynchronous function. The code in
`src/app/api/chat/route.ts` calls this function synchronously. This will cause
`streamText()` to receive a `Promise` instead of the expected message array, leading to
a runtime failure when a POST request is made to the `/api/chat` endpoint.
Did we get this right? 👍 / 👎 to inform future reviews.
Reference ID: 7883508
This PR contains the following updates:
2.0.118->3.0.3Release Notes
vercel/ai (@ai-sdk/react)
v3.0.3Compare Source
Patch Changes
29264a3]v3.0.2Compare Source
Patch Changes
129ff26]v3.0.1Compare Source
Patch Changes
29264a3]v3.0.0Compare Source
Major Changes
dee8b05: ai SDK 6 betaMinor Changes
78928cb: release: start 5.1 betaPatch Changes
0c3b58b: fix(provider): add specificationVersion to ProviderV30adc679: feat(provider): shared spec v350b70d6: feat(anthropic): add programmatic tool callingb8ea36e: feat(provider/anthropic): Anthropic-native structured outputsed537e1: Add support for pdf file in tool result in anthropic2109385: 'fix(anthropic): Opus 4.5maxOutputTokensbump32000->64000'7c4328e: Adds url-based pdf and image support for anthropic tool results8d9e8ad: chore(provider): remove generics from EmbeddingModelV3Before
After
f33a018: chore: add model ID for Haiku 4.5b2dbfbf: add context_management for anthropicdce03c4: feat: tool input examples2625a04: feat(openai); update spec for mcp approval11e4abe: feat(provider/anthropic): web search tool updatesf13958c: chore(antropic): allow custom names for provider-defined toolsafb00e3: feat(provider/anthropic): add text_editor_20250728 tool supportAdd text_editor_20250728 tool for Claude 4 models (Sonnet 4, Opus 4, Opus 4.1) with optional max_characters parameter and no undo_edit command support.
95f65c2: chore: use import * from zod/v4954c356: feat(openai): allow custom names for provider-defined tools9e35785: fix(anthropic): send {} as tool input when streaming tool calls without arguments544d4e8: chore(specification): rename v3 provider defined tool to provider toola5f77a6: fix(anthropic): remove outdated tool name docsca07285: feat(anthropic): add prompt caching validationa5a8db4: chore: add model ID for Sonnet 4.51742445: Support for custom provider name in google and anthropic providerse8109d3: feat: tool execution approval87db851: fix(vertex/anthropic): passing beta header only for structured outputsf6603b7: fix(provider/anthropic): correct raw usage informationed329cb: feat:Provider-V33bd2689: feat: extended token usage1cad0ab: feat: add provider version to user-agent header2049c5b: Fix handling of error in web fetch tool in anthropic4c5a6be: feat(provider/anthropic): default and limit maxTokens based on model9e1e758: fix(anthropic): use default thinking budget when unspecified589a4ee: fix(anthropic): simplify pulling first chunk8dac895: feat:LanguageModelV36f845b4: Add support for 2025-08-25 code execution tool9354297: feat(provider/anthropic): add support for Agent Skills03849b0: throw 500 error when the first stream chunk is an error0ae783e: feat(anthropic): add the new tool search tools457318b: chore(provider,ai): switch to SharedV3Warning and unified warningseb56fc6: fix(anthropic): pull first chunk without async IIFEfa35e95: feat(provider/anthropic): add web fetch tool80894b3: add returnfile_idproperty for anthropic code-execution-20250825 to download output files.366f50b: chore(provider): add deprecated textEmbeddingModel and textEmbedding aliases81d4308: feat(provider/anthropic): mcp connector support6fc35cb: Retain user-supplied betas.f4db7b5: feat(provider/anthropic): expose container from response in provider metadata6c38080: fix(anthropic): support pdf responses in web_fetch_tool_result schema validation4616b86: chore: update zod peer depenedency versiondedf206: feat(provider/anthropic): expose stop_sequence in provider metadata983e394: chore(provider/anthropic): add missing provider options jsdoc0e38a79: support ANTHROPIC_BASE_URLcf4e2a9: Add support for tool calling with structured outputf4e4a95: feat(provider/anthropic): enable fine grained tool streaming by default21f378c: fix(provider/anthropic): do not limit maxTokens when model id is unknownc5440c5: chore(provider/anthropic): update anthropic model ids1d15673: fix(provider/anthropic): clamp temperature to valid 0-1 range with warnings9cff587: chore(provider/anthropic): lazy schema loadingd129d89: chore(anthropic): remove unnecessary doc3794514: feat: flexible tool output content supporte1e2821: fix(provider/anthropic): support null title in web fetch toolcbf52cd: feat: expose raw finish reason10c1322: fix: moved dependency@ai-sdk/test-serverto devDependenciesd08308b: feat(provider/anthropic): memory tool05d5b9a: fix(anthropic): make title field nullable in web_fetch and web_search tool output schemas1bd7d32: feat: tool-specific strict mode83aaad8: Opus 4.5 andeffortprovider optionUpdated dependencies [
0c3b58b]Updated dependencies [
0adc679]Updated dependencies [
50b70d6]Updated dependencies [
d1bdadb]Updated dependencies [
dee8b05]Updated dependencies [
046aa3b]Updated dependencies [
8d9e8ad]Updated dependencies [
78928cb]Updated dependencies [
dce03c4]Updated dependencies [
2625a04]Updated dependencies [
37c58a0]Updated dependencies [
3b1d015]Updated dependencies [
2b0caef]Updated dependencies [
95f65c2]Updated dependencies [
016b111]Updated dependencies [
58920e0]Updated dependencies [
954c356]Updated dependencies [
544d4e8]Updated dependencies [
0c4822d]Updated dependencies [
521c537]Updated dependencies [
4c44a5b]Updated dependencies [
e8109d3]Updated dependencies [
03849b0]Updated dependencies [
ed329cb]Updated dependencies [
e06565c]Updated dependencies [
32d8dbb]Updated dependencies [
53f3368]Updated dependencies [
d116b4b]Updated dependencies [
3bd2689]Updated dependencies [
293a6b7]Updated dependencies [
703459a]Updated dependencies [
bb36798]Updated dependencies [
83e5744]Updated dependencies [
7e32fea]Updated dependencies [
3ed5519]Updated dependencies [
8dac895]Updated dependencies [
a755db5]Updated dependencies [
cbb1d35]Updated dependencies [
475189e]Updated dependencies [
457318b]Updated dependencies [
b681d7d]Updated dependencies [
db913bd]Updated dependencies [
9061dc0]Updated dependencies [
32223c8]Updated dependencies [
c1efac4]Updated dependencies [
366f50b]Updated dependencies [
4616b86]Updated dependencies [
81d4308]Updated dependencies [
9549c9e]Updated dependencies [
af3780b]Updated dependencies [
4f16c37]Updated dependencies [
81e29ab]Updated dependencies [
522f6b8]Updated dependencies [
6306603]Updated dependencies [
fca786b]Updated dependencies [
763d04a]Updated dependencies [
10d819b]Updated dependencies [
3794514]Updated dependencies [
cbf52cd]Updated dependencies [
e9e157f]Updated dependencies [
960ec8f]Updated dependencies [
1bd7d32]Updated dependencies [
f0b2157]Updated dependencies [
95f65c2]Configuration
📅 Schedule: Branch creation - At 12:00 AM through 04:59 AM and 10:00 PM through 11:59 PM, Monday through Friday ( * 0-4,22-23 * * 1-5 ), Only on Sunday and Saturday ( * * * * 0,6 ) (UTC), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.