from abc import ABC, abstractmethod from overview.brokerage_types import BrokerageSnapshot from overview.models import BrokerageConnection class BrokerageAdapterError(Exception): pass class BaseBrokerageAdapter(ABC): provider = "" def __init__(self, connection: BrokerageConnection): self.connection = connection @abstractmethod def fetch_snapshot(self) -> BrokerageSnapshot: raise NotImplementedError