🕷️ The BEST Web Scraping framework that handles everything from a single request to a full-scale crawl! Don't be shy, join here: https://discord.gg/EMgGbDceNQ and follow here for daily tips and tricks: https://x.com/Scrapling_dev
Python aiai-scrapingautomationcrawlercrawlingcrawling-pythondatadata-extractionmcpmcp-serverplaywrightpythonscrapingselectorsstealthweb-scraperweb-scrapingweb-scraping-pythonwebscrapingxpath
fix(Texthandler): Replace `get_all` with `getall` to match the `Selector` class
Karim shoair136c38978796
diff --git a/scrapling/core/custom_types.py b/scrapling/core/custom_types.pyindex d06ac29..53255be 100644--- a/scrapling/core/custom_types.py+++ b/scrapling/core/custom_types.py@@ -112,10 +112,10 @@ class TextHandler(str):def get(self, default=None): # pragma: no coverreturn self- def get_all(self): # pragma: no cover+ def getall(self): # pragma: no coverreturn self- extract = get_all+ extract = getallextract_first = getdef json(self) -> Dict:@@ -279,7 +279,7 @@ class TextHandlers(List[TextHandler]):return selfextract_first = get- get_all = extract+ getall = extractclass AttributesHandler(Mapping[str, _TextHandlerType]):diff --git a/tests/parser/test_parser_advanced.py b/tests/parser/test_parser_advanced.pyindex 969ccc3..39829bb 100644--- a/tests/parser/test_parser_advanced.py+++ b/tests/parser/test_parser_advanced.py@@ -357,7 +357,7 @@ class TestTextHandlerAdvanced:"""Test TextHandlers.extract() returns self"""handlers = TextHandlers([TextHandler("a"), TextHandler("b")])assert handlers.extract() is handlers- assert handlers.get_all() is handlers+ assert handlers.getall() is handlersclass TestSelectorsAdvanced: