mirror of
https://github.com/jxxghp/MoviePilot.git
synced 2026-07-06 23:31:28 +08:00
fix cython type error
This commit is contained in:
@@ -47,7 +47,7 @@ class SiteParserBase(metaclass=ABCMeta):
|
||||
apikey: str,
|
||||
token: str,
|
||||
session: Session = None,
|
||||
ua: str = None,
|
||||
ua: Optional[str] = None,
|
||||
emulate: bool = False,
|
||||
proxy: bool = None):
|
||||
super().__init__()
|
||||
|
||||
@@ -74,7 +74,7 @@ class FileListSiteUserInfo(SiteParserBase):
|
||||
self.bonus = StringUtils.str_float(bonus_html[0].xpath("string(.)").strip())
|
||||
pass
|
||||
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: bool = False) -> Optional[str]:
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: Optional[bool] = False) -> Optional[str]:
|
||||
"""
|
||||
做种相关信息
|
||||
:param html_text:
|
||||
|
||||
@@ -87,7 +87,7 @@ class GazelleSiteUserInfo(SiteParserBase):
|
||||
if join_at_text:
|
||||
self.join_at = StringUtils.unify_datetime_str(join_at_text[0].strip())
|
||||
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: bool = False) -> Optional[str]:
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: Optional[bool] = False) -> Optional[str]:
|
||||
"""
|
||||
做种相关信息
|
||||
:param html_text:
|
||||
|
||||
@@ -121,7 +121,7 @@ class HDDolbySiteUserInfo(SiteParserBase):
|
||||
"""
|
||||
pass
|
||||
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: bool = False) -> Optional[str]:
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: Optional[bool] = False) -> Optional[str]:
|
||||
"""
|
||||
解析用户做种信息
|
||||
"""
|
||||
|
||||
@@ -111,7 +111,7 @@ class MTorrentSiteUserInfo(SiteParserBase):
|
||||
"""
|
||||
pass
|
||||
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: bool = False) -> Optional[str]:
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: Optional[bool] = False) -> Optional[str]:
|
||||
"""
|
||||
解析用户做种信息
|
||||
"""
|
||||
|
||||
@@ -147,7 +147,7 @@ class NexusPhpSiteUserInfo(SiteParserBase):
|
||||
return True, gold * 100 * 100 + silver * 100 + copper
|
||||
return False, 0.0
|
||||
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: bool = False) -> Optional[str]:
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: Optional[bool] = False) -> Optional[str]:
|
||||
"""
|
||||
做种相关信息
|
||||
:param html_text:
|
||||
|
||||
@@ -66,7 +66,7 @@ class NexusRabbitSiteUserInfo(SiteParserBase):
|
||||
torrents = json.loads(html_text).get("data", [])
|
||||
except Exception as e:
|
||||
logger.error(f"解析做种信息失败: {str(e)}")
|
||||
return
|
||||
return None
|
||||
|
||||
seeding_size = 0
|
||||
seeding_info = []
|
||||
@@ -89,7 +89,7 @@ class NexusRabbitSiteUserInfo(SiteParserBase):
|
||||
messages = json.loads(html_text).get("data", [])
|
||||
except Exception as e:
|
||||
logger.error(f"解析未读消息失败: {e}")
|
||||
return
|
||||
return None
|
||||
for msg in messages:
|
||||
msg_id, msg_unread = msg.get("id"), msg.get("unread")
|
||||
if not (msg_id and msg_unread) or msg_unread == "no":
|
||||
|
||||
@@ -55,7 +55,7 @@ class SmallHorseSiteUserInfo(SiteParserBase):
|
||||
def _parse_user_detail_info(self, html_text: str):
|
||||
pass
|
||||
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: bool = False) -> Optional[str]:
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: Optional[bool] = False) -> Optional[str]:
|
||||
"""
|
||||
做种相关信息
|
||||
:param html_text:
|
||||
|
||||
@@ -59,7 +59,7 @@ class TNodeSiteUserInfo(SiteParserBase):
|
||||
"unreadSystem", 0)
|
||||
pass
|
||||
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: bool = False) -> Optional[str]:
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: Optional[bool] = False) -> Optional[str]:
|
||||
"""
|
||||
解析用户做种信息
|
||||
"""
|
||||
|
||||
@@ -59,7 +59,7 @@ class TorrentLeechSiteUserInfo(SiteParserBase):
|
||||
def _parse_user_detail_info(self, html_text: str):
|
||||
pass
|
||||
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: bool = False) -> Optional[str]:
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: Optional[bool] = False) -> Optional[str]:
|
||||
"""
|
||||
做种相关信息
|
||||
:param html_text:
|
||||
|
||||
@@ -56,7 +56,7 @@ class Unit3dSiteUserInfo(SiteParserBase):
|
||||
self.join_at = StringUtils.unify_datetime_str(
|
||||
join_at_text[0].replace('注册日期', '').replace('註冊日期', '').replace('Registration date', ''))
|
||||
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: bool = False) -> Optional[str]:
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: Optional[bool] = False) -> Optional[str]:
|
||||
"""
|
||||
做种相关信息
|
||||
:param html_text:
|
||||
|
||||
@@ -73,7 +73,7 @@ class TYemaSiteUserInfo(SiteParserBase):
|
||||
"""
|
||||
pass
|
||||
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: bool = False) -> Optional[str]:
|
||||
def _parse_user_torrent_seeding_info(self, html_text: str, multi_page: Optional[bool] = False) -> Optional[str]:
|
||||
"""
|
||||
解析用户做种信息
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user