Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions crawl4ai/async_configs.py
Original file line number Diff line number Diff line change
Expand Up @@ -1685,11 +1685,11 @@ def __init__(
max_scroll_steps: Optional[int] = None,
process_iframes: bool = False,
flatten_shadow_dom: bool = False,
remove_overlay_elements: bool = False,
remove_consent_popups: bool = False,
simulate_user: bool = False,
override_navigator: bool = False,
magic: bool = False,
remove_overlay_elements: bool = None,
remove_consent_popups: bool = None,
simulate_user: bool = None,
override_navigator: bool = None,
magic: bool = None,
adjust_viewport_to_content: bool = False,
# Media Handling Parameters
screenshot: bool = False,
Expand Down Expand Up @@ -1725,7 +1725,7 @@ def __init__(
process_in_browser: bool = False, # Force browser processing for raw:/file:// URLs
url: str = None,
base_url: str = None, # Base URL for markdown link resolution (used with raw: HTML)
check_robots_txt: bool = False,
check_robots_txt: bool = None,
user_agent: str = None,
user_agent_mode: str = None,
user_agent_generator_config: dict = {},
Expand Down
4 changes: 2 additions & 2 deletions deploy/docker/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -729,7 +729,7 @@ async def handle_crawl_request(
for key, value in base_config.items():
if hasattr(cfg, key):
current_value = getattr(cfg, key)
if current_value is None or current_value == "":
if current_value is None:
setattr(cfg, key, value)
# SSRF: per-URL PDF strategies need the validator wired too
if isinstance(cfg.scraping_strategy, PDFContentScrapingStrategy):
Expand All @@ -740,7 +740,7 @@ async def handle_crawl_request(
for key, value in base_config.items():
if hasattr(crawler_config, key):
current_value = getattr(crawler_config, key)
if current_value is None or current_value == "":
if current_value is None:
setattr(crawler_config, key, value)
effective_config = crawler_config

Expand Down