investfly.models.marketdata.MarketHours

Regular trading-session hours for a market.

@dataclass(frozen=True)
class MarketHours:

Opening and closing times for one market session.

def sessionOpenDateTime(self, asOf: datetime.datetime) -> Optional[datetime.datetime]:

Return the open datetime of the regular session containing asOf, or None if outside session.