from sqlalchemy import create_engine
from sqlalchemy.orm import scoped_session, sessionmaker
from sqlalchemy.schema import MetaData
from sqlalchemy.ext.declarative import declarative_base

convention = {
    "ix": "ix_%(column_0_label)s",
    "uq": "uq_%(table_name)s_%(column_0_name)s",
    "ck": "ck_%(table_name)s_%(constraint_name)s",
    "fk": "fk_%(table_name)s_%(column_0_name)s_%(referred_table_name)s",
    "pk": "pk_%(table_name)s",
}

metadata = MetaData(naming_convention=convention)

Base = declarative_base(metadata=metadata)
from upcase_booklist_app.models.book import Book
from upcase_booklist_app.models.author import Author
from upcase_booklist_app.models.user import User
from upcase_booklist_app.models.category import Category

engine = create_engine(
    "postgresql+psycopg2://postgres:postgres@localhost/curious_programmer", echo=True
)

db_session = scoped_session(
    sessionmaker(autocommit=False, autoflush=False, bind=engine)
)

aa4a4afb099a0dd18da694a32b9233eed497c473
<mask token>

<mask token>
convention = {'ix': 'ix_%(column_0_label)s', 'uq':
    'uq_%(table_name)s_%(column_0_name)s', 'ck':
    'ck_%(table_name)s_%(constraint_name)s', 'fk':
    'fk_%(table_name)s_%(column_0_name)s_%(referred_table_name)s', 'pk':
    'pk_%(table_name)s'}
metadata = MetaData(naming_convention=convention)
Base = declarative_base(metadata=metadata)
<mask token>
engine = create_engine(
    'postgresql+psycopg2://postgres:postgres@localhost/curious_programmer',
    echo=True)
db_session = scoped_session(sessionmaker(autocommit=False, autoflush=False,
    bind=engine))

from sqlalchemy import create_engine
from sqlalchemy.orm import scoped_session, sessionmaker
from sqlalchemy.schema import MetaData
from sqlalchemy.ext.declarative import declarative_base
convention = {'ix': 'ix_%(column_0_label)s', 'uq':
    'uq_%(table_name)s_%(column_0_name)s', 'ck':
    'ck_%(table_name)s_%(constraint_name)s', 'fk':
    'fk_%(table_name)s_%(column_0_name)s_%(referred_table_name)s', 'pk':
    'pk_%(table_name)s'}
metadata = MetaData(naming_convention=convention)
Base = declarative_base(metadata=metadata)
from upcase_booklist_app.models.book import Book
from upcase_booklist_app.models.author import Author
from upcase_booklist_app.models.user import User
from upcase_booklist_app.models.category import Category
engine = create_engine(
    'postgresql+psycopg2://postgres:postgres@localhost/curious_programmer',
    echo=True)
db_session = scoped_session(sessionmaker(autocommit=False, autoflush=False,
    bind=engine))

from sqlalchemy import create_engine
from sqlalchemy.orm import scoped_session, sessionmaker
from sqlalchemy.schema import MetaData
from sqlalchemy.ext.declarative import declarative_base

convention = {
    "ix": "ix_%(column_0_label)s",
    "uq": "uq_%(table_name)s_%(column_0_name)s",
    "ck": "ck_%(table_name)s_%(constraint_name)s",
    "fk": "fk_%(table_name)s_%(column_0_name)s_%(referred_table_name)s",
    "pk": "pk_%(table_name)s",
}

metadata = MetaData(naming_convention=convention)

Base = declarative_base(metadata=metadata)
from upcase_booklist_app.models.book import Book
from upcase_booklist_app.models.author import Author
from upcase_booklist_app.models.user import User
from upcase_booklist_app.models.category import Category

engine = create_engine(
    "postgresql+psycopg2://postgres:postgres@localhost/curious_programmer", echo=True
)

db_session = scoped_session(
    sessionmaker(autocommit=False, autoflush=False, bind=engine)
)
