feat: upgrade Vercel AI SDK v5 to v6#21
Open
dsfaccini wants to merge 2 commits intopydantic:mainfrom
Open
Conversation
Fixes compatibility with pydantic-ai >= 1.49.0 which sends providerMetadata in tool call responses (rejected by SDK v5). Also adds support for new v6 tool approval states in the UI. Closes pydantic#14 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The guard `if (conversationId !== '/' && messages.length === 0) return null`
causes a blank content area when the app is served at a sub-path (e.g., via
iframe proxy at /api/sessions/{id}/app/). conversationId is derived from
window.location.pathname, which is never '/' in that context, so the guard
always triggers on fresh sessions.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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
aifrom v5 to v6 (^6.0.149) and@ai-sdk/reactfrom v2 to v3 (^3.0.151)approval-requested,approval-responded,output-denied)providerMetadatain tool call responses (rejected by SDK v5)Closes #14
Test plan
pnpm run typecheck— passespnpm eslint src/— passesproviderMetadatarejection🤖 Generated with Claude Code