From f133559c2affab0130b845d6ad38fc91586c9cf0 Mon Sep 17 00:00:00 2001 From: laggardkernel Date: Fri, 10 Jul 2020 16:29:27 +0800 Subject: [PATCH] Fix default value for SELENIUM_DRIVER_ARGUMENTS as empty list --- scrapy_selenium/middlewares.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scrapy_selenium/middlewares.py b/scrapy_selenium/middlewares.py index 201db2c..ada0644 100644 --- a/scrapy_selenium/middlewares.py +++ b/scrapy_selenium/middlewares.py @@ -73,7 +73,7 @@ def from_crawler(cls, crawler): driver_executable_path = crawler.settings.get('SELENIUM_DRIVER_EXECUTABLE_PATH') browser_executable_path = crawler.settings.get('SELENIUM_BROWSER_EXECUTABLE_PATH') command_executor = crawler.settings.get('SELENIUM_COMMAND_EXECUTOR') - driver_arguments = crawler.settings.get('SELENIUM_DRIVER_ARGUMENTS') + driver_arguments = crawler.settings.getlist('SELENIUM_DRIVER_ARGUMENTS') if driver_name is None: raise NotConfigured('SELENIUM_DRIVER_NAME must be set')