sqlc-dev / sqlc-gen-python

MIT License
154 stars 19 forks source link

Support Session and AsyncSession #52

Open Goldziher opened 4 months ago

Goldziher commented 4 months ago

The Querier and AsyncQuerier class being generated expect an SqlAlchemy Connection / AsyncConnection types respectively. They should though also accept Session / AsyncSession. This is simply a matter of typing - they already work with Session and AsyncSession because the interface is the same as far as the querier operations are concerned.