ChromeDriver ERR_SSL_PROTOCOL_ERROR despite --ignore-certificate-errors

前端 未结 3 1210
粉色の甜心
粉色の甜心 2020-12-17 19:13

I\'m trying to run integration tests on a local host (with no HTTPS) using selenium with ChromeDriver.

Chrome requires an https certificate, but from this question i

3条回答
  •  清酒与你
    2020-12-17 20:00

    You are requesting the page through HTTP and not HTTPS. Chrome will not connect to an insecure HTTP server.

    This is causing the TLS/SSL negotiation to fail.

    You need to make sure your server is running HTTPS on TCP port 8000.

    With the --ignore-certificate-errors option you can generate a self-signed certificate and apply that to the web server.

    Then change the url line to use HTTPS.

    app_login_url = 'https://app:8000/accounts/login/'
    

提交回复
热议问题