There is relatively new Python 3 aiohttp library that contains client/server. Does it contain ORM? If not - is it possible to use it with 3-rd party ORM? If not possible - for which purpose it could be used? I don't mean that app could not be written without ORM, but major waste of Python Frameworks support it and developers are used to such style of programming.
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
Short answer -- aiohttp has no ORM yet.
You can use SQLAlchemy-like queries for aiopg driver, see example
The same is available for aiomysql.
The support is not full-fledged Object-Relational Mapping but only helpers for making SQL queries easier.
回答2:
Update in 2018: there is GINO now, built on top of SQLAlchemy core and asyncpg for asyncio.