from abc import ABC, abstractmethod class MigrationABC(ABC): @abstractmethod def __init__(self): pass @abstractmethod def upgrade(self): pass @abstractmethod def downgrade(self): pass