在使用selenium+phantomjs的时候在Windows平台下能够正常工作,在Linux下却不能,并得到错误信息:

selenium.common.exceptions.TimeoutException: Message: 
Screenshot: available via screen

在ST上找到答案:http://stackoverflow.com/a/36159299/4447404

driver = webdriver.PhantomJS(service_args=['--ignore-ssl-errors=true', '--ssl-protocol=TLSv1'])

在初始化driver时传入参数"service_args=['--ignore-ssl-errors=true', '--ssl-protocol=TLSv1']"即可。



 

相关文章:

  • 2021-04-01
  • 2022-12-23
  • 2022-12-23
  • 2021-11-22
  • 2021-12-03
  • 2021-04-27
  • 2021-07-04
  • 2021-09-12
猜你喜欢
  • 2022-12-23
  • 2021-07-18
  • 2021-12-10
  • 2021-05-04
  • 2022-12-23
  • 2022-12-23
  • 2022-01-02
相关资源
相似解决方案