Closed rasjani closed 7 months ago
I propose using subprocess and --version
argument for detecting browser versions. It is a bit ugly but it will work on all operating systems. https://github.com/rasjani/webdrivermanager/pull/43 contains an implementation for Chrome.
For each operating system we need to define a way to detect the installed version of a given browser. On Windows, for example, this involves reading the registry to identify the location of the executable. I would not know how to do this on linux/mac. Once we have the executable's path, we can use pefile to read the version number on any os.
For each browser, we need to define a method for querying the matching driver version for a given browser version. download_and_install(version) will take over from there.