From 6497b1b5598b6b096d53b339b522798b76a118ab Mon Sep 17 00:00:00 2001 From: Karim shoair Date: Wed, 6 Nov 2024 02:20:33 +0200 Subject: [PATCH] Type correction --- scrapling/engines/pw.py | 2 +- scrapling/fetchers.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scrapling/engines/pw.py b/scrapling/engines/pw.py index ef493dd..a62a691 100644 --- a/scrapling/engines/pw.py +++ b/scrapling/engines/pw.py @@ -18,7 +18,7 @@ from scrapling.engines.toolbelt import ( class PlaywrightEngine: def __init__( self, headless: Union[bool, str] = True, - disable_resources: Optional[bool] = False, + disable_resources: bool = False, useragent: Optional[str] = None, network_idle: Optional[bool] = False, timeout: Optional[float] = 30000, diff --git a/scrapling/fetchers.py b/scrapling/fetchers.py index 6f569ee..f0fa432 100644 --- a/scrapling/fetchers.py +++ b/scrapling/fetchers.py @@ -125,7 +125,7 @@ class PlayWrightFetcher(BaseFetcher): > Note that these are the main options with PlayWright but it can be mixed together. """ def fetch( - self, url: str, headless: Union[bool, str] = True, disable_resources: Optional[List] = None, + self, url: str, headless: Union[bool, str] = True, disable_resources: bool = None, useragent: Optional[str] = None, network_idle: Optional[bool] = False, timeout: Optional[float] = 30000, page_action: Callable = do_nothing, wait_selector: Optional[str] = None, wait_selector_state: Optional[str] = 'attached', hide_canvas: bool = True, disable_webgl: bool = False,