BasePage补上user_agent属性

This commit is contained in:
g1879 2023-08-11 14:19:01 +08:00
parent 01a930b740
commit f97a7c80de
2 changed files with 7 additions and 0 deletions

View File

@ -428,6 +428,10 @@ class BasePage(BaseParser):
def json(self):
return
@property
def user_agent(self):
pass
@abstractmethod
def get_cookies(self, as_dict=False, all_info=False):
return {}

View File

@ -195,6 +195,9 @@ class BasePage(BaseParser):
@property
def json(self) -> dict: ...
@property
def user_agent(self) -> str: ...
@abstractmethod
def get_cookies(self, as_dict: bool = False, all_info: bool = False) -> Union[list, dict]: ...