CircleCi上的WebDriverException selenium python测试

CircleCi上的WebDriverException selenium python测试,python,python-3.x,selenium-webdriver,pytest,circleci-2.0,Python,Python 3.x,Selenium Webdriver,Pytest,Circleci 2.0,我正在使用selenium和pytest设置python自动化测试,我的目标是在Circleci 2.0上运行它 本地测试已启动并正在运行,但此错误发生在CircleCi服务器上,不知道原因 我试图更新项目模块(但事实并非如此) 我遇到以下错误: venv/lib/python3.6/site-packages/selenium/webdriver/chrome/webdriver.py:73: in __init__ self.service.start() venv/lib/pyth

我正在使用selenium和pytest设置python自动化测试,我的目标是在Circleci 2.0上运行它

本地测试已启动并正在运行,但此错误发生在CircleCi服务器上,不知道原因 我试图更新项目模块(但事实并非如此)

我遇到以下错误:

venv/lib/python3.6/site-packages/selenium/webdriver/chrome/webdriver.py:73: in __init__
    self.service.start()
venv/lib/python3.6/site-packages/selenium/webdriver/common/service.py:98: in start
    self.assert_process_still_running()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <selenium.webdriver.chrome.service.Service object at 0x7f52e8a66a90>

    def assert_process_still_running(self):
        return_code = self.process.poll()
        if return_code is not None:
            raise WebDriverException(
                'Service %s unexpectedly exited. Status code was: %s'
>               % (self.path, return_code)
            )
E           selenium.common.exceptions.WebDriverException: Message: Service /home/circleci/.wdm/chromedriver/75.0.3770.8/linux64/chromedriver unexpectedly exited. Status code was: 127

venv/lib/python3.6/site-packages/selenium/webdriver/common/service.py:111: WebDriverException
---------------------------- Captured stdout setup -----------------------------

Checking for linux64 chromedriver:75.0.3770.8 in cache
There is no cached driver. Downloading new one...
Trying to download new driver from http://chromedriver.storage.googleapis.com/75.0.3770.8/chromedriver_linux64.zip
Unpack archive /home/circleci/.wdm/chromedriver/75.0.3770.8/linux64/chromedriver.zip
________ ERROR at setup of TestExperiment.test_search_tutors_from_genf ```


>E selenium.common.exceptions.SessionNotCreatedException: Message: >Unable to find a matching set of capabilities

>venv/lib/python3.6/site->packages/selenium/webdriver/remote/errorhandler.py:242: >SessionNotCreatedException
venv/lib/python3.6/site packages/selenium/webdriver/chrome/webdriver.py:73:in\uu init__
self.service.start()
venv/lib/python3.6/site-packages/selenium/webdriver/common/service.py:98:in-start
self.assert\u进程\u仍在运行()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
自我=
def assert_进程仍在运行(自):
return\u code=self.process.poll()
如果返回代码不是无:
引发WebDriverException(
'服务%s意外退出。状态代码为:%s'
>%(self.path,返回\u代码)
)
E selenium.common.exceptions.WebDriverException:Message:Service/home/circleci/.wdm/chromedriver/75.0.3770.8/linux64/chromedriver意外退出。状态代码为:127
venv/lib/python3.6/site-packages/selenium/webdriver/common/service.py:111:WebDriverException
----------------------------捕获的标准输出设置-----------------------------
正在检查缓存中的linux64 chromedriver:75.0.3770.8
没有缓存的驱动程序。正在下载新的。。。
正在尝试从下载新驱动程序http://chromedriver.storage.googleapis.com/75.0.3770.8/chromedriver_linux64.zip
解包归档文件/home/circleci/.wdm/chromedriver/75.0.3770.8/linux64/chromedriver.zip
________设置TestExperiment.test\u search\u tutors\u from\u genf时出错```
>E selenium.common.exceptions.SessionNotCreatedException:消息:>找不到匹配的功能集
>venv/lib/python3.6/site->packages/selenium/webdriver/remote/errorhandler.py:242:>SessionNotCreatedException

案例已结案事实证明,CircleCi配置文件存在问题。为了运行这些测试,我被迫在docker img上安装Chrome,方法是向config.yml文件添加适当的依赖项

venv/lib/python3.6/site-packages/selenium/webdriver/chrome/webdriver.py:73: in __init__
    self.service.start()
venv/lib/python3.6/site-packages/selenium/webdriver/common/service.py:98: in start
    self.assert_process_still_running()
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

self = <selenium.webdriver.chrome.service.Service object at 0x7f52e8a66a90>

    def assert_process_still_running(self):
        return_code = self.process.poll()
        if return_code is not None:
            raise WebDriverException(
                'Service %s unexpectedly exited. Status code was: %s'
>               % (self.path, return_code)
            )
E           selenium.common.exceptions.WebDriverException: Message: Service /home/circleci/.wdm/chromedriver/75.0.3770.8/linux64/chromedriver unexpectedly exited. Status code was: 127

venv/lib/python3.6/site-packages/selenium/webdriver/common/service.py:111: WebDriverException
---------------------------- Captured stdout setup -----------------------------

Checking for linux64 chromedriver:75.0.3770.8 in cache
There is no cached driver. Downloading new one...
Trying to download new driver from http://chromedriver.storage.googleapis.com/75.0.3770.8/chromedriver_linux64.zip
Unpack archive /home/circleci/.wdm/chromedriver/75.0.3770.8/linux64/chromedriver.zip
________ ERROR at setup of TestExperiment.test_search_tutors_from_genf ```


>E selenium.common.exceptions.SessionNotCreatedException: Message: >Unable to find a matching set of capabilities

>venv/lib/python3.6/site->packages/selenium/webdriver/remote/errorhandler.py:242: >SessionNotCreatedException