Skip to content

Upgrade Pydantic AI dependency from 0.3.2 to 1.2.1#5

Merged
arnesund merged 2 commits intomasterfrom
claude/upgrade-pydantic-dependency-011CUKqCEz3aJGh9zmzvxRGc
Oct 21, 2025
Merged

Upgrade Pydantic AI dependency from 0.3.2 to 1.2.1#5
arnesund merged 2 commits intomasterfrom
claude/upgrade-pydantic-dependency-011CUKqCEz3aJGh9zmzvxRGc

Conversation

@arnesund
Copy link
Owner

  • Updated pydantic-ai and pydantic-ai-slim to latest version 1.2.1
  • Updated .python-version from 3.11.6 to 3.11 for better compatibility
  • Tested and verified application still works correctly with new version

🤖 Generated with Claude Code

- Updated pydantic-ai and pydantic-ai-slim to latest version 1.2.1
- Updated .python-version from 3.11.6 to 3.11 for better compatibility
- Tested and verified application still works correctly with new version

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Updated test mocks to properly set environment variables using patch.dict
instead of patching os.getenv, as Pydantic AI 1.2.1 models now validate
API keys during initialization using os.environ directly.

Changes:
- Use patch.dict('os.environ', {...}) to set API keys in tests
- Add GEMINI_API_KEY to test environment (was incorrectly GOOGLE_GENAI_API_KEY)
- Add GeminiModel mocking to all integration tests
- Updated test_agent_api_error to properly mock environment before MorpheusBot init

All 21 tests now pass.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@arnesund arnesund merged commit f3cf7a8 into master Oct 21, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants