diff --git a/crawl4ai/async_webcrawler.py b/crawl4ai/async_webcrawler.py index 2ff7ce0f..b8be6f35 100644 --- a/crawl4ai/async_webcrawler.py +++ b/crawl4ai/async_webcrawler.py @@ -477,7 +477,7 @@ class AsyncWebCrawler: word_count_threshold=word_count_threshold, css_selector=css_selector, only_text=kwargs.pop("only_text", False), - image_description_min_word_threshold=kwargs.get( + image_description_min_word_threshold=kwargs.pop( "image_description_min_word_threshold", IMAGE_DESCRIPTION_MIN_WORD_THRESHOLD ), content_filter = content_filter, diff --git a/crawl4ai/crawler_strategy.py b/crawl4ai/crawler_strategy.py index ce802e49..898dcfa8 100644 --- a/crawl4ai/crawler_strategy.py +++ b/crawl4ai/crawler_strategy.py @@ -283,7 +283,7 @@ class LocalSeleniumCrawlerStrategy(CrawlerStrategy): print(f"[LOG] ✅ Crawled {url} successfully!") return html - except InvalidArgumentException: + except InvalidArgumentException as e: if not hasattr(e, 'msg'): e.msg = sanitize_input_encode(str(e)) raise InvalidArgumentException(f"Failed to crawl {url}: {e.msg}")