mirror of
https://github.com/EstrellaXD/Auto_Bangumi.git
synced 2026-04-09 05:29:51 +08:00
@@ -8,11 +8,11 @@ class BangumiData(BaseModel):
|
||||
year: int | None = Field(None, alias="year", title="番剧年份")
|
||||
title_raw: str = Field(..., alias="title_raw", title="番剧原名")
|
||||
season: int = Field(..., alias="season", title="番剧季度")
|
||||
season_raw: str = Field(..., alias="season_raw", title="番剧季度原名")
|
||||
group: str = Field(..., alias="group", title="字幕组")
|
||||
dpi: str = Field(..., alias="dpi", title="分辨率")
|
||||
source: str = Field(..., alias="source", title="来源")
|
||||
subtitle: str = Field(..., alias="subtitle", title="字幕")
|
||||
season_raw: str | None = Field(None, alias="season_raw", title="番剧季度原名")
|
||||
group: str | None = Field(None, alias="group", title="字幕组")
|
||||
dpi: str | None = Field(None, alias="dpi", title="分辨率")
|
||||
source: str | None = Field(None, alias="source", title="来源")
|
||||
subtitle: str | None = Field(None, alias="subtitle", title="字幕")
|
||||
added: bool = Field(False, alias="added", title="是否已添加")
|
||||
eps_collect: bool = Field(False, alias="eps_collect", title="是否已收集")
|
||||
offset: int = Field(0, alias="offset", title="番剧偏移量")
|
||||
|
||||
@@ -36,7 +36,7 @@ class TelegramNotification:
|
||||
|
||||
def send_msg(self, title: str, desp: str):
|
||||
data = {
|
||||
"chat_id": settings.notification_chat_id,
|
||||
"chat_id": settings.notification.chat_id,
|
||||
"text": f"{title}\n{desp}",
|
||||
"disable_notification": True,
|
||||
}
|
||||
|
||||
@@ -11,7 +11,7 @@ class TMDBInfo:
|
||||
id: int
|
||||
title_jp: str
|
||||
title_zh: str
|
||||
season: dict
|
||||
season: list[dict]
|
||||
last_season: int
|
||||
year_number: int
|
||||
|
||||
|
||||
@@ -36,7 +36,8 @@ class TitleParser:
|
||||
logger.debug(f"TMDB Matched, official title is {tmdb_info.title_zh}")
|
||||
except Exception as e:
|
||||
logger.debug(e)
|
||||
logger.warning("Not Matched with TMDB")
|
||||
logger.warning(f"{title} can not Matched with TMDB")
|
||||
logger.info("Please change the bangumi info in webui")
|
||||
return title, season
|
||||
if LANGUAGE == "zh":
|
||||
official_title = f"{tmdb_info.title_zh} ({tmdb_info.year_number})"
|
||||
@@ -75,3 +76,4 @@ class TitleParser:
|
||||
return data
|
||||
except Exception as e:
|
||||
logger.debug(e)
|
||||
print(e)
|
||||
|
||||
Reference in New Issue
Block a user