From 74a7c6dbb65ec01cbb2e719f9e8071526163a66d Mon Sep 17 00:00:00 2001 From: UncleCode Date: Wed, 1 Jan 2025 16:10:08 +0800 Subject: [PATCH] feat(install): specify chrome and chromium for playwright - Install Chrome and Chromium browsers explicitly - Split browser installation into separate commands --- crawl4ai/install.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/crawl4ai/install.py b/crawl4ai/install.py index 2725efbb..251a3199 100644 --- a/crawl4ai/install.py +++ b/crawl4ai/install.py @@ -16,7 +16,8 @@ def post_install(): def install_playwright(): logger.info("Installing Playwright browsers...", tag="INIT") try: - subprocess.check_call([sys.executable, "-m", "playwright", "install", "--with-deps"]) + subprocess.check_call([sys.executable, "-m", "playwright", "install", "--with-deps", "chrome"]) + subprocess.check_call([sys.executable, "-m", "playwright", "install", "--with-deps", "chromium"]) logger.success("Playwright installation completed successfully.", tag="COMPLETE") except subprocess.CalledProcessError as e: # logger.error(f"Error during Playwright installation: {e}", tag="ERROR")