Revert switching to @as_declarative for SQLAlchemy base class

This reverts commit 1da1133934 and a part of 2cf9dcafd9
This commit is contained in:
Tulir Asokan
2019-03-21 13:48:06 +02:00
parent 1da1133934
commit fecf068455
2 changed files with 5 additions and 3 deletions
@@ -23,6 +23,7 @@ def log(message, end="\n"):
def connect(to):
import mautrix_telegram.db.base as base
base.Base = declarative_base(cls=base.BaseBase)
from mautrix_telegram.db import (Portal, Message, UserPortal, User, RoomState, UserProfile,
Contact, Puppet, BotChat, TelegramFile)
db_engine = sql.create_engine(to)