-
-
Notifications
You must be signed in to change notification settings - Fork 118
build(deps): update pydantic-ai requirement from ==0.2.* to ==1.39.* #752
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
PR Review: pydantic-ai v0.2.* → v1.39.* UpgradeSummaryThis PR upgrades pydantic-ai from v0.2.* to v1.39.*, representing a major version jump that includes the v1.0 release. This is a significant dependency update that requires careful validation. Critical Analysis🔴 Major Version Jump RiskThis upgrade skips from v0.2 directly to v1.39, crossing the v1.0 stability boundary. According to pydantic-ai's version policy, v1.0+ commits to API stability until v2.0, but the path from v0.2 → v1.0 included several breaking changes. Key Breaking Changes to WatchBased on the pydantic-ai changelog, breaking changes occurred in: v1.0.0 (2025-09-04):
v0.8.0:
v0.7.6:
v0.7.0:
Code Impact AssessmentCurrent Usage AuditI examined how pydantic-ai is used in the codebase: Core Files:
Key Imports: from pydantic_ai.agent import Agent, CallToolsNode, End, ModelRequestNode, UserPromptNode
from pydantic_ai.messages import ModelMessage, ModelRequest, ModelResponse, ...
from pydantic_ai.tools import RunContext
from pydantic_ai.models.test import TestModel
from pydantic_ai import capture_run_messages🟡 Potential Compatibility Issues
New Features in v1.39.0The PR description highlights:
Testing Requirements🔴 CRITICAL: Must Run Before MergePer
Security Considerations✅ No security concerns identified
Performance Considerations
RecommendationsBefore Merging:
After Merging:
Changelog Update RequiredPer ## [Unreleased] - 2025-12-29
### Changed
- Updated pydantic-ai from v0.2.* to v1.39.* (`requirements/base.txt:53`)
- Major version upgrade crossing v1.0 stability boundary
- Includes new embedding models support, metadata tracking, and MCP improvements
- Breaking change: ModelRequest/ModelResponse.parts now Sequence (was list)
- See: https://github.com/pydantic/pydantic-ai/blob/main/docs/changelog.mdOverall AssessmentRisk Level: 🟡 MEDIUM This is a necessary update to get pydantic-ai's v1.x stability guarantees and new features, but the major version jump warrants thorough testing. Recommendation: ✅ APPROVE pending successful test runs The codebase appears to use pydantic-ai's stable APIs (Agent, RunContext, messages) that should be compatible with v1.39, but the Action Items
|
Updates the requirements on [pydantic-ai](https://github.com/pydantic/pydantic-ai) to permit the latest version. - [Release notes](https://github.com/pydantic/pydantic-ai/releases) - [Changelog](https://github.com/pydantic/pydantic-ai/blob/main/docs/changelog.md) - [Commits](pydantic/pydantic-ai@v0.2.0...v1.39.0) --- updated-dependencies: - dependency-name: pydantic-ai dependency-version: 1.39.0 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com>
f00173b to
59e0838
Compare
Pull Request Review: Pydantic-AI Version Bump (v0.2.* → v1.39.*)SummaryThis PR updates pydantic-ai from version 0.2.* to 1.39.*, a major version jump (79 minor versions) that spans the library's transition to v1.0 and beyond. This is a Dependabot-generated dependency update that requires careful review and testing. Risk Assessment: HIGH RISKWhy this is high risk:
Key Breaking Changes (v0.2 → v1.39)Based on the pydantic-ai changelog, the following breaking changes are relevant to this codebase: v1.0.0 Breaking Changes:
v0.8.0 Breaking Changes: v0.7.6 Breaking Changes: v0.7.0 Breaking Changes: Code Impact AnalysisI analyzed the codebase usage of pydantic-ai and found the following critical files:
Required TestingBefore merging, run these critical tests: docker compose -f test.yml run django pytest opencontractserver/tests/test_pydantic_ai_agents.py -n 4 --dist loadscope Or run all tests: docker compose -f test.yml run django pytest -n auto --dist loadscope RecommendationsBefore Merging:
If Tests Pass:
If Tests Fail:
Security ConsiderationsNo security concerns identified - This is a legitimate dependency update from the official pydantic-ai repository. Performance ConsiderationsAccording to the v1.39.0 release notes, this version includes:
Monitor: Data extraction task execution times and WebSocket message processing latency Final VerdictRecommendation: CONDITIONAL APPROVAL This PR should be merged IF AND ONLY IF:
Reviewed by: Claude Code |
Updates the requirements on pydantic-ai to permit the latest version.
Release notes
Sourced from pydantic-ai's releases.
Changelog
Sourced from pydantic-ai's changelog.
... (truncated)
Commits
92a2bb2Fix embeddings coverage (#3839)3717d20Support embeddings models (#3252)ff15594Add pydantic-deep + toolsets to docs (#3837)6e444a3fix: support none system prompts (#3834)c535275hotfix: Register audio/aac mimetype (#3829)673e18dtests: usepyyaml.CSafeLoaderfor faster cassette read (#3830)ba58e3ctests: drop unusedtest_run_sync_multiple(#3825)38f4facDrop image size in the test suite (#3827)dbd92b3Add Agent and agent run metadata and expose it on result objects and span att...baaf3fdHandle ThinkingPart in MCP Sampling (#3823)Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
@dependabot rebasewill rebase this PR@dependabot recreatewill recreate this PR, overwriting any edits that have been made to it@dependabot mergewill merge this PR after your CI passes on it@dependabot squash and mergewill squash and merge this PR after your CI passes on it@dependabot cancel mergewill cancel a previously requested merge and block automerging@dependabot reopenwill reopen this PR if it is closed@dependabot closewill close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually@dependabot show <dependency name> ignore conditionswill show all of the ignore conditions of the specified dependency@dependabot ignore this major versionwill close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this minor versionwill close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)@dependabot ignore this dependencywill close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)