Skip to content

Conversation

@wwwjfy
Copy link
Member

@wwwjfy wwwjfy commented Jun 20, 2020

based on #702, refs #691, a hacky fix

Honestly, Gino doesn't have to support table creation/deletion, as this can go farther, like requests of async version of Alembic, though it can be done in another package.

@wwwjfy wwwjfy marked this pull request as draft June 21, 2020 15:21
@fantix
Copy link
Member

fantix commented Sep 6, 2020

Right - the schema.py will be completely removed in GINO 1.4, replaced by a very simple bridge:

gino/src/gino/api.py

Lines 213 to 227 in 8c888bd

class GinoSchemaVisitor:
__slots__ = ("_item",)
def __init__(self, item):
self._item = item
def __getattr__(self, item):
sync_func = getattr(self._item, item)
async def _wrapper(bind=None, *args, **kwargs):
if bind is None:
bind = _bind_or_error(self._item)
return await bind.run_sync(sync_func, *args, **kwargs)
return _wrapper

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants