Skip to content

🕷️ 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

fix(Parser): Change default text content to empty string instead of None

Karim shoair94909099a984
diff --git a/scrapling/parser.py b/scrapling/parser.py
index b83d867..f9e177e 100644
--- a/scrapling/parser.py
+++ b/scrapling/parser.py
@@ -71,7 +71,7 @@ class Adaptor(SelectorsGeneration):
if root is None and not body and text is None:
raise ValueError("Adaptor class needs text, body, or root arguments to work")
- self.__text = None
+ self.__text = ''
self.__raw_body = ''
if root is None:
if text is None: