This commit is contained in:
2024-11-06 19:57:07 +01:00
parent 06ba8bec34
commit 87a2f5964b
3 changed files with 12 additions and 10 deletions

View File

@@ -4,7 +4,7 @@ from typing import Literal
from httpx import AsyncClient
from config import config, StreamerConfig
from services.twitch import State
from services.twitch_state import State
logger = logging.getLogger(__name__)

View File

@@ -11,22 +11,14 @@ from twitchAPI.object.eventsub import StreamOnlineEvent, ChannelUpdateEvent
import aiofiles
from pydantic import BaseModel
from config import config, StreamerConfig
from services.notification import notify
from services.twitch_state import State
logger = logging.getLogger(__name__)
class State(BaseModel):
title: str
category: str
last_live_at: datetime
class TokenStorage:
lock = Lock()

View File

@@ -0,0 +1,10 @@
from datetime import datetime
from pydantic import BaseModel
class State(BaseModel):
title: str
category: str
last_live_at: datetime