Skip to content

Migrated to py 3.13+ and fixed discrepancy of the protocol spec of having flawed for the prices.#44

Open
itsklimov wants to merge 2 commits intoextrawest:mainfrom
itsklimov:main
Open

Migrated to py 3.13+ and fixed discrepancy of the protocol spec of having flawed for the prices.#44
itsklimov wants to merge 2 commits intoextrawest:mainfrom
itsklimov:main

Conversation

@itsklimov
Copy link

Changing Price string to the float is a breaking change. See MIGRATION.md

Major migration to support Python 3.13 and 3.14 with full Pydantic v2 compatibility.

Core Changes:
- Migrate from Pydantic v1.10.12 to v2.12.4
- Update FastAPI (0.101.1 → 0.121.2) and httpx (0.24.1 → 0.28.1)
- Add pydantic-settings for BaseSettings
- Migrate 7 custom validators to Pydantic v2 core schema API
- Fix all Optional fields to include default values (Pydantic v2 requirement)
- Replace deprecated .dict() with .model_dump() across 38 files
- Switch from pipenv to uv for faster dependency management

Testing:
- Add 27 unit tests for core validators (100% passing)
- Add pytest-asyncio for async test support
- Add pytest-cov for coverage measurement
- Fix httpx AsyncClient API for v0.28 (ASGITransport)
- All 207 tests passing (100% pass rate)

Infrastructure:
- Update CI/CD to test on Python 3.13 & 3.14
- Update Python requirement: >=3.10 → >=3.13
- Update pyproject.toml configurations
- Add MIGRATION.md documentation

Note: Number validation is now stricter per OCPI spec (rejects string numbers).
See MIGRATION.md for complete details.
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.

1 participant