umihico / docker-selenium-lambda

The simplest demo of chrome automation by python and selenium in AWS Lambda
MIT License
535 stars 127 forks source link

Using new Service object instead of deprecated execution_path #188

Closed filipopo closed 1 year ago

filipopo commented 1 year ago

In selenium 4.9.1 which this repo is using at the moment, a message pops up about execution_path being deprecated: DeprecationWarning: executable_path has been deprecated, please pass in a Service object

In newer versions of selenium this code doesn't work at all so it should be changed to using the new syntax

filipopo commented 1 year ago

I think you must bump the selenium version in the Dockerfile now to 4.11.0 at least😅, 4.11.2 is the latest

umihico commented 1 year ago

Maybe you're right. It was wrong and didn't work on CI. I misunderstood my CI. Reverted.

filipopo commented 1 year ago

May I ask is there something keeping you from upgrading the selenium version? in my tests this syntax works with selenium >=4.11.0

But if you need to keep this version I can rewrite the commit using webdriver.chrome.service.Service instead of webdriver.ChromeService

umihico commented 1 year ago

@filipopo It was because https://github.com/umihico/docker-selenium-lambda/pull/175, and just now I realized you are fixing this!

So I created #192. Thank you again.