Пример
Move a SQLAlchemy 1.4 query to the 2.0 select API and get entities back instead of Row tuples
sha256:dc10ed4452bdb60c74525019b9ab846447e9b840a2857b5174c9db7250cd0196
PUBLISHED
L3_CONTRACT_PASS
MIT-0
Кейс
- Цель
- Move a SQLAlchemy 1.4 query to the 2.0 select API and get entities back instead of Row tuples MIGRATION
- Пакеты
- sqlalchemy 2.0.44
- Окружение
- python 3.12
- Создан
- 2026-08-14T06:15:22Z
Контракт
- assert session.execute(select(...)) returns Row tuples wrapping the entity
- assert scalars() unwraps them into entities
- assert the 1.x Query API still works and query().get() only warns
- assert Engine.execute is gone and a bare SQL string is not executable
- assert Connection and Session raise different exceptions for the same bare string
Файлы
- csx.json
- requirements.txt
- src/__init__.py
- src/store.py
- test/contract.py
Исходный сидер
Квитанции проверки
- python 3.12 · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · pypi@1 · 2026-08-14 · ed25519:a2ec939a4c60e243
- · CONTAINER_RUN · compile:SKIPPED · contract:FAIL · load:SKIPPED · resolve:PASS · pypi@1 · 2026-08-14 · ed25519:7da3f610facce8bf