headspinio / appium-lg-webos-driver

An Appium 2.x driver for LG WebOS apps
Apache License 2.0
9 stars 5 forks source link

feat: add chromedriverExecutableDir and autodownload support #48

Closed KazuCocoa closed 8 months ago

KazuCocoa commented 8 months ago

Closes https://github.com/headspinio/appium-lg-webos-driver/issues/43 cc @jlipps

KazuCocoa commented 8 months ago

@jlipps maybe we could create 0.3.0 with this.

jlipps commented 8 months ago

it's now published.

Jiyvn commented 8 months ago

@KazuCocoa @jlipps autodownload not work on my side

image image

appium server --allow-insecure chromedriver_autodownload lgtv2019.log

KazuCocoa commented 8 months ago

Because the embedded browser did not respond what chrome version the device needed. This implementation cares https://github.com/headspinio/appium-lg-webos-driver/pull/48/files#diff-9dd24cf3101d02ce31204899de7beaa39759860d491e54541dcc55c10ec2ae32R37-R117 cases, but not sure what chromedriver should be used for your device case.

WebKit-Version":"537.36 is very common value as the device so it does not help to guess necessary chromedriver. What we could do here is return better error message for this "User-Agent":"" case.

[WebOSDriver] Waiting for app launch to take effect
[WebOSDriver] Waiting for app launch to take effect
[WebOSDriver] The response of http://192.168.10.187:9998/json/version was {"Browser":"","Protocol-Version":"1.1","User-Agent":"","WebKit-Version":"537.36 (@fa89da905405aab455e0f0d4ec7f49631c7ca70b)"}
[Chromedriver@b2fd] Changed state to 'starting'
[Chromedriver@b2fd] Using the static Chromedriver->Chrome mapping
[Chromedriver@b2fd] The most recent known Chrome version: 123.0.6312
[Chromedriver@b2fd] Found 0 executables in '/Users/jiyvn/aviu/apps/lgtv/chromedriver/'
KazuCocoa commented 8 months ago

https://github.com/headspinio/appium-lg-webos-driver/issues/50 to return better error message as no info to guess necessary chromedriver version