From 05c6eeb3870a6fb4750faa1f41fcdd5761c6c8f6 Mon Sep 17 00:00:00 2001 From: Karim shoair Date: Mon, 16 Dec 2024 12:37:29 +0200 Subject: [PATCH] fix: add AsyncFetcher to top-level shortcuts --- scrapling/__init__.py | 6 +++--- scrapling/defaults.py | 3 ++- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/scrapling/__init__.py b/scrapling/__init__.py index 081d7ea..b8c7396 100644 --- a/scrapling/__init__.py +++ b/scrapling/__init__.py @@ -1,7 +1,7 @@ # Declare top-level shortcuts from scrapling.core.custom_types import AttributesHandler, TextHandler -from scrapling.fetchers import (CustomFetcher, Fetcher, PlayWrightFetcher, - StealthyFetcher) +from scrapling.fetchers import (AsyncFetcher, CustomFetcher, Fetcher, + PlayWrightFetcher, StealthyFetcher) from scrapling.parser import Adaptor, Adaptors __author__ = "Karim Shoair (karim.shoair@pm.me)" @@ -9,4 +9,4 @@ __version__ = "0.2.9" __copyright__ = "Copyright (c) 2024 Karim Shoair" -__all__ = ['Adaptor', 'Fetcher', 'StealthyFetcher', 'PlayWrightFetcher'] +__all__ = ['Adaptor', 'Fetcher', 'AsyncFetcher', 'StealthyFetcher', 'PlayWrightFetcher'] diff --git a/scrapling/defaults.py b/scrapling/defaults.py index 73618a4..64fd1b7 100644 --- a/scrapling/defaults.py +++ b/scrapling/defaults.py @@ -1,6 +1,7 @@ -from .fetchers import Fetcher, PlayWrightFetcher, StealthyFetcher +from .fetchers import AsyncFetcher, Fetcher, PlayWrightFetcher, StealthyFetcher # If you are going to use Fetchers with the default settings, import them from this file instead for a cleaner looking code Fetcher = Fetcher() +AsyncFetcher = AsyncFetcher() StealthyFetcher = StealthyFetcher() PlayWrightFetcher = PlayWrightFetcher()