Skip to content

🌟 The Multi-Agent Framework: First AI Software Company, Towards Natural Language Programming

selenium config better performance

paulaand196bd0cc947
diff --git a/metagpt/tools/web_browser_engine_selenium.py b/metagpt/tools/web_browser_engine_selenium.py
index d727709b8..80b60a93c 100644
--- a/metagpt/tools/web_browser_engine_selenium.py
+++ b/metagpt/tools/web_browser_engine_selenium.py
@@ -104,6 +104,9 @@ def _gen_get_driver_func(browser_type, *args, executable_path=None):
def _get_driver():
options = Options()
options.add_argument("--headless")
+ options.add_argument("--no-sandbox") # This flag is important for running in a Docker container
+ options.add_argument("--disable-gpu") # This flag can help avoid renderer issue
+ options.add_argument("--disable-dev-shm-usage") # Overcome limited resource problems
options.add_argument("--enable-javascript")
if browser_type == "chrome":
options.add_argument("--no-sandbox")