aurweb/aurweb/models/__init__.py
Kevin Morris 6d59a97955
feat(fastapi): include all models in aurweb.models package
This gives developers the ability to import models without importing
them directly from their module:

    from aurweb.models import Ban, AccountType

This provides more conciseness:

    from aurweb import models

    def some_func(ban: models.Ban):
        pass

    def some_other_func(user: models.User):
        pass

This more aligns with a Django-style of core model bases.

NOTE: Docker images must be rebuilt with this change, as setup.cfg
has changed. Old Docker images will cause flake8 violation reports.

Signed-off-by: Kevin Morris <kevr@0cost.org>
2021-10-16 19:35:20 -07:00

31 lines
1.2 KiB
Python

""" Collection of all aurweb SQLAlchemy declarative models. """
from .accepted_term import AcceptedTerm
from .account_type import AccountType
from .api_rate_limit import ApiRateLimit
from .ban import Ban
from .dependency_type import DependencyType
from .group import Group
from .license import License
from .official_provider import OfficialProvider
from .package import Package
from .package_base import PackageBase
from .package_blacklist import PackageBlacklist
from .package_comaintainer import PackageComaintainer
from .package_comment import PackageComment
from .package_dependency import PackageDependency
from .package_group import PackageGroup
from .package_keyword import PackageKeyword
from .package_license import PackageLicense
from .package_notification import PackageNotification
from .package_relation import PackageRelation
from .package_request import PackageRequest
from .package_source import PackageSource
from .package_vote import PackageVote
from .relation_type import RelationType
from .request_type import RequestType
from .session import Session
from .ssh_pub_key import SSHPubKey
from .term import Term
from .tu_vote import TUVote
from .tu_voteinfo import TUVoteInfo
from .user import User