diff --git a/base/base_crawler.py b/base/base_crawler.py index 6817c69..2ddf626 100644 --- a/base/base_crawler.py +++ b/base/base_crawler.py @@ -63,7 +63,7 @@ class AbstractStoreImage(ABC): async def store_image(self, image_content_item: Dict): pass -class AbstactApiClient(ABC): +class AbstractApiClient(ABC): @abstractmethod async def request(self, method, url, **kwargs): pass diff --git a/media_platform/bilibili/client.py b/media_platform/bilibili/client.py index f2a33a0..c92cb27 100644 --- a/media_platform/bilibili/client.py +++ b/media_platform/bilibili/client.py @@ -10,7 +10,7 @@ from urllib.parse import urlencode import httpx from playwright.async_api import BrowserContext, Page -from base.base_crawler import AbstactApiClient +from base.base_crawler import AbstractApiClient from tools import utils from .exception import DataFetchError @@ -18,7 +18,7 @@ from .field import CommentOrderType, SearchOrderType from .help import BilibiliSign -class BilibiliClient(AbstactApiClient): +class BilibiliClient(AbstractApiClient): def __init__( self, timeout=10, diff --git a/media_platform/douyin/client.py b/media_platform/douyin/client.py index b7c1da9..486b2f9 100644 --- a/media_platform/douyin/client.py +++ b/media_platform/douyin/client.py @@ -7,7 +7,7 @@ import execjs import httpx from playwright.async_api import BrowserContext, Page -from base.base_crawler import AbstactApiClient +from base.base_crawler import AbstractApiClient from tools import utils from var import request_keyword_var @@ -15,7 +15,7 @@ from .exception import * from .field import * -class DOUYINClient(AbstactApiClient): +class DOUYINClient(AbstractApiClient): def __init__( self, timeout=30, diff --git a/media_platform/kuaishou/client.py b/media_platform/kuaishou/client.py index c30959f..8ad2155 100644 --- a/media_platform/kuaishou/client.py +++ b/media_platform/kuaishou/client.py @@ -8,14 +8,14 @@ import httpx from playwright.async_api import BrowserContext, Page import config -from base.base_crawler import AbstactApiClient +from base.base_crawler import AbstractApiClient from tools import utils from .exception import DataFetchError from .graphql import KuaiShouGraphQL -class KuaiShouClient(AbstactApiClient): +class KuaiShouClient(AbstractApiClient): def __init__( self, timeout=10, diff --git a/media_platform/xhs/client.py b/media_platform/xhs/client.py index b682b11..e8248fc 100644 --- a/media_platform/xhs/client.py +++ b/media_platform/xhs/client.py @@ -8,7 +8,7 @@ import httpx from playwright.async_api import BrowserContext, Page import config -from base.base_crawler import AbstactApiClient +from base.base_crawler import AbstractApiClient from tools import utils from .exception import DataFetchError, IPBlockError @@ -16,7 +16,7 @@ from .field import SearchNoteType, SearchSortType from .help import get_search_id, sign -class XiaoHongShuClient(AbstactApiClient): +class XiaoHongShuClient(AbstractApiClient): def __init__( self, timeout=10,