appium / python-client

Python language bindings for Appium
Apache License 2.0
1.68k stars 563 forks source link

bug: <title>After upgrading Appium-Python-Client 2.11.1, webview execution scrollIntoView reported an error, 'selenium. common. exceptions. JavascriptException: Message: JavaScript error: arguments [0]. scrollIntoView is not a function #924

Open tianyao1111 opened 1 year ago

tianyao1111 commented 1 year ago

Do I have the most recent component updates?

Is the component officially supported by the Appium team?

Is there an existing issue for this?

Current Behavior

After upgrading selenium 4, webview execution scrollIntoView reported an error, 'selenium. common. exceptions. JavascriptException: Message: JavaScript error: arguments [0]. scrollIntoView is not a function

Expected Behavior

Realize sliding

Minimal Reproducible Example

caps = {}
caps["platformName"] = "Android"
caps["appPackage"] = "com.picc.mcp"
caps["appActivity"] = "com.picc.mcp.IndexVideoActivity"
caps["noReset"] = True
caps["unicodeKeyboard"] = True
caps["resetKeyboard"] = True
caps["newCommandTimeout"] = 180
caps["adbExecTimeout"] = 180000
caps["logcatFormat"] = "time"
caps["logcatFilterSpecs"] = ['*:E']
caps["clearDeviceLogsOnStart"] = True
caps["chromeOptions"] = {"w3c": False}
driver = webdriver.Remote(host, caps)
driver.implicitly_wait(global_wait)
driver.switch_to.context('WEBVIEW_com.picc.mcp')
driver.implicitly_wait(global_wait)
ele = get_element(driver, 'xpath', '//a[contains(@href,"com.picc.mcp/files/mcph5/login.html")]')
str1 = 'return arguments[0].scrollIntoView();'
driver.execute_script(str1, ele)

Environment

Link to Appium Logs

No response

Further Information

Traceback (most recent call last): File "D:\YR\UITestAND_PICC_LP_APP01\UITestAND_PICC_LP_APP15\public\MyTestCase.py", line 27, in testPartExecutor yield File "D:\YR\UITestAND_PICC_LP_APP01\UITestAND_PICC_LP_APP15\public\MyTestCase.py", line 196, in run self.setUp() File "D:\YR\UITestAND_PICC_LP_APP01\UITestAND_PICC_LP_APP15\test_case\LP_CDYT_case_NEW\LP_CDYT_case_NEW_S_04.py", line 79, in setUp LPLoginPage(self.logging).login_collection(self.driver, self.data['app_user'], self.data['app_pwd'], File "D:\YR\UITestAND_PICC_LP_APP01\UITestAND_PICC_LP_APP15\test_page\LPLoginPage_app01.py", line 174, in login_collection self.click_back_login(driver,type1=type1) File "D:\YR\UITestAND_PICC_LP_APP01\UITestAND_PICC_LP_APP15\test_page\LPLoginPage_app01.py", line 157, in click_back_login scroll_into_view(driver,ele) File "D:\YR\UITestAND_PICC_LP_APP01\UITestAND_PICC_LP_APP15\public\common.py", line 650, in scroll_into_view driver.execute_script(str1, e) File "C:\yurui\Python\Python39\lib\site-packages\selenium\webdriver\remote\webdriver.py", line 405, in execute_script return self.execute(command, {"script": script, "args": converted_args})["value"] File "C:\yurui\Python\Python39\lib\site-packages\selenium\webdriver\remote\webdriver.py", line 345, in execute self.error_handler.check_response(response) File "C:\yurui\Python\Python39\lib\site-packages\appium\webdriver\errorhandler.py", line 122, in check_response raise exception_class(msg=message, stacktrace=format_stacktrace(stacktrace)) selenium.common.exceptions.JavascriptException: Message: javascript error: arguments[0].scrollIntoView is not a function (Session info: chrome=78.0.3904.108) (Driver info: chromedriver=78.0.3904.105 (60e2d8774a8151efa6a00b1f358371b1e0e07ee2-refs/branch-heads/3904@{#877}),platform=Windows NT 10.0.19045 x86_64) Stacktrace: JavaScriptError: javascript error: arguments[0].scrollIntoView is not a function (Session info: chrome=78.0.3904.108) (Driver info: chromedriver=78.0.3904.105 (60e2d8774a8151efa6a00b1f358371b1e0e07ee2-refs/branch-heads/3904@{#877}),platform=Windows NT 10.0.19045 x86_64) at errorFromMJSONWPStatusCode (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:764:12) at ProxyRequestError.getActualError (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:661:14) at JWProxy.command (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\jsonwp-proxy\proxy.js:272:19) at processTicksAndRejections (internal/process/task_queues.js:93:5) at AndroidUiautomator2Driver.execute (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-android-driver\lib\commands\execute.js:19:10)

KazuCocoa commented 1 year ago

https://stackoverflow.com/questions/55492695/javascript-error-arguments0-scrollintoview-is-not-a-function-using-selenium-o ? Could you share the full appium server log as well?

tianyao1111 commented 1 year ago

https://stackoverflow.com/questions/55492695/javascript-error-arguments0-scrollintoview-is-not-a-function-using-selenium-o ? Could you share the full appium server log as well? I have also read this article and I used find_ Element. And everything was normal before I upgraded。Here is the log:


[Appium] Welcome to Appium v1.22.0
[Appium] Non-default server args:
[Appium]   sessionOverride: true
[Appium]   loglevel: info
[Appium]   chromedriverExecutable: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe
[Appium]   relaxedSecurityEnabled: true
[Appium] Appium REST http interface listener started on 0.0.0.0:4723
[HTTP] --> POST /wd/hub/session
[HTTP] {"capabilities":{"firstMatch":[{}],"alwaysMatch":{"platformName":"Android","appium:appPackage":"com.picc.mcp","appium:appActivity":"com.picc.mcp.IndexVideoActivity","appium:noReset":true,"appium:unicodeKeyboard":true,"appium:resetKeyboard":true,"appium:newCommandTimeout":180,"appium:adbExecTimeout":180000,"appium:logcatFormat":"time","appium:logcatFilterSpecs":["*:E"],"appium:clearDeviceLogsOnStart":true,"appium:chromeOptions":{"w3c":false}}}}
[Appium] 

[Appium] ======================================================================

[Appium] DEPRECATION WARNING:

[Appium]

[Appium] The 'automationName' capability was not provided in the desired [Appium] capabilities for this Android session

[Appium]

[Appium] Setting 'automationName=UiAutomator2' by default and using the [Appium] UiAutomator2 Driver

[Appium]

[Appium] The next major version of Appium (2.x) will require the [Appium] 'automationName' capability to be set for all sessions on all [Appium] platforms

[Appium]

[Appium] In previous versions (Appium <= 1.13.x), the default was [Appium] 'automationName=UiAutomator1'

[Appium]

[Appium] If you wish to use that automation instead of UiAutomator2, please [Appium] add 'automationName=UiAutomator1' to your desired capabilities

[Appium]

[Appium] For more information about drivers, please visit [Appium] http://appium.io/docs/en/about-appium/intro/ and explore the [Appium] 'Drivers' menu

[Appium]

[Appium] ======================================================================

[Appium] [Appium] Appium v1.22.0 creating new AndroidUiautomator2Driver (v1.69.0) session [Appium] Applying relaxed security to 'AndroidUiautomator2Driver' as per server command line argument. All insecure features will be enabled unless explicitly disabled by --deny-insecure [BaseDriver] Session created with session id: e54aee2a-3b19-4ee6-928d-6e5f5e02b614 [UiAutomator2] Starting 'com.picc.mcp' directly on the device [ADB] Found 1 'build-tools' folders under 'D:\aa\SDK' (newest first): [ADB] D:/aa/SDK/build-tools/30.0.3 [ADB] Using 'adb.exe' from 'D:\aa\SDK\platform-tools\adb.exe' [AndroidDriver] Retrieving device list [AndroidDriver] Using device: GPG4C19619002744 [ADB] Using 'adb.exe' from 'D:\aa\SDK\platform-tools\adb.exe' [ADB] Getting device platform version [UiAutomator2] Relaxing hidden api policy [AndroidDriver] No app sent in, not parsing package/activity [ADB] Using 'apksigner.jar' from 'D:\aa\SDK\build-tools\30.0.3\lib\apksigner.jar' [ADB] 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.24.0.apk' is signed with the default certificate [ADB] 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk' is signed with the default certificate [UiAutomator2] Server packages are not going to be (re)installed [ADB] Adding packages ["io.appium.settings","io.appium.uiautomator2.server","io.appium.uiautomator2.server.test"] to Doze whitelist [UiAutomator2] Starting UIAutomator2 server 4.24.0 [UiAutomator2] Using UIAutomator2 server from 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.24.0.apk' and test from 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk' [UiAutomator2] Waiting up to 30000ms for UiAutomator2 to be online... [WD Proxy] socket hang up [WD Proxy] socket hang up [WD Proxy] socket hang up [WD Proxy] Determined the downstream protocol as 'W3C' [AndroidDriver] Screen already unlocked, doing nothing [UiAutomator2] Starting 'com.picc.mcp/com.picc.mcp.IndexVideoActivity and waiting for 'com.picc.mcp/com.picc.mcp.IndexVideoActivity' [Appium] New AndroidUiautomator2Driver session created successfully, session e54aee2a-3b19-4ee6-928d-6e5f5e02b614 added to master session list [HTTP] <-- POST /wd/hub/session 200 35878 ms - 1238 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/timeouts [HTTP] {"implicit":20000} [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/timeouts 200 6 ms - 14 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element [HTTP] {"using":"xpath","value":"//android.view.View[@text=\"parameterSettings.html?returnUrl=login\"]"} [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element 200 1640 ms - 137 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/00000000-0000-000e-0000-002500000012/click [HTTP] {"id":"00000000-0000-000e-0000-002500000012"} [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/00000000-0000-000e-0000-002500000012/click 200 748 ms - 14 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/context [HTTP] {"name":"WEBVIEW_com.picc.mcp"} [Chromedriver] Set chromedriver binary as: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe [Chromedriver] Spawning chromedriver with: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe --url-base=wd/hub --port=8000 --adb-port=5037 --verbose [Chromedriver] Chromedriver v. 81.0.4044.138 supports W3C protocol, but MJSONWP one has been explicitly requested [WD Proxy] connect ECONNREFUSED 127.0.0.1:8000 [Chromedriver] Starting MJSONWP Chromedriver session with capabilities: { [Chromedriver] "desiredCapabilities": { [Chromedriver] "chromeOptions": { [Chromedriver] "androidPackage": "com.picc.mcp", [Chromedriver] "androidUseRunningApp": true, [Chromedriver] "androidProcess": "com.picc.mcp", [Chromedriver] "androidDeviceSerial": "GPG4C19619002744", [Chromedriver] "w3c": false [Chromedriver] }, [Chromedriver] "loggingPrefs": { [Chromedriver] "browser": "ALL" [Chromedriver] } [Chromedriver] } [Chromedriver] } [WD Proxy] Determined the downstream protocol as 'MJSONWP' [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/context 200 6731 ms - 14 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/timeouts [HTTP] {"implicit":20000} [W3C (e54aee2a)] Driver proxy active, passing request on via HTTP proxy [WD Proxy] Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614 [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/timeouts 200 6 ms - 65 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element [HTTP] {"using":"id","value":"masterServer1"} [W3C (e54aee2a)] Driver proxy active, passing request on via HTTP proxy [WD Proxy] Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614 [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element 200 135 ms - 156 [HTTP]  [HTTP] --> GET /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/attribute/value [HTTP] {} [W3C (e54aee2a)] Driver proxy active, passing request on via HTTP proxy [WD Proxy] Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614 [HTTP] <-- GET /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/attribute/value 200 59 ms - 75 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value [HTTP] {"text":"a","value":["","a"],"id":"0.8451682828008877-1"} [W3C (e54aee2a)] Driver proxy active, passing request on via HTTP proxy [WD Proxy] Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614 [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value 200 591 ms - 65 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value [HTTP] {"text":"x","value":["","x"],"id":"0.8451682828008877-1"} [W3C (e54aee2a)] Driver proxy active, passing request on via HTTP proxy [WD Proxy] Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614 [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value 200 256 ms - 65 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value [HTTP] {"text":"10.22.64.243","value":["1","0",".","2","2",".","6","4",".","2","4","3"],"id":"0.8451682828008877-1"} [W3C (e54aee2a)] Driver proxy active, passing request on via HTTP proxy [WD Proxy] Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614 [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value 200 2138 ms - 65 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element [HTTP] {"using":"id","value":"port"} [W3C (e54aee2a)] Driver proxy active, passing request on via HTTP proxy [WD Proxy] Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614 [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element 200 86 ms - 156 [HTTP]  [HTTP] --> GET /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-3/attribute/value [HTTP] {} [W3C (e54aee2a)] Driver proxy active, passing request on via HTTP proxy [WD Proxy] Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614 [HTTP] <-- GET /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-3/attribute/value 200 62 ms - 67 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element [HTTP] {"using":"xpath","value":"//a[contains(@href,\"com.picc.mcp/files/mcph5/login.html\")]"} [W3C (e54aee2a)] Driver proxy active, passing request on via HTTP proxy [WD Proxy] Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614 [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element 200 60 ms - 156 [HTTP]  [HTTP] --> POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/execute/sync [HTTP] {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.8451682828008877-4"}]} [HTTP] <-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/execute/sync 500 142 ms - 1383 [HTTP] 

tianyao1111 commented 1 year ago

https://stackoverflow.com/questions/55492695/javascript-error-arguments0-scrollintoview-is-not-a-function-using-selenium-o ? Could you share the full appium server log as well? I have also read this article and I used find_ Element. And everything was normal before I upgraded。Here is the log:

�[35m[Appium]�[39m Welcome to Appium v1.22.0
�[35m[Appium]�[39m Non-default server args:
�[35m[Appium]�[39m   sessionOverride: true
�[35m[Appium]�[39m   loglevel: info
�[35m[Appium]�[39m   chromedriverExecutable: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe
�[35m[Appium]�[39m   relaxedSecurityEnabled: true
�[35m[Appium]�[39m Appium REST http interface listener started on 0.0.0.0:4723
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session�[39m
�[35m[HTTP]�[39m �[90m{"capabilities":{"firstMatch":[{}],"alwaysMatch":{"platformName":"Android","appium:appPackage":"com.picc.mcp","appium:appActivity":"com.picc.mcp.IndexVideoActivity","appium:noReset":true,"appium:unicodeKeyboard":true,"appium:resetKeyboard":true,"appium:newCommandTimeout":180,"appium:adbExecTimeout":180000,"appium:logcatFormat":"time","appium:logcatFilterSpecs":["*:E"],"appium:clearDeviceLogsOnStart":true,"appium:chromeOptions":{"w3c":false}}}}�[39m
�[35m[Appium]�[39m 

�[35m[Appium]�[39m ======================================================================

�[35m[Appium]�[39m   DEPRECATION WARNING:

�[35m[Appium]�[39m 

�[35m[Appium]�[39m   The 'automationName' capability was not provided in the desired 
�[35m[Appium]�[39m   capabilities for this Android session

�[35m[Appium]�[39m 

�[35m[Appium]�[39m   Setting 'automationName=UiAutomator2' by default and using the 
�[35m[Appium]�[39m   UiAutomator2 Driver

�[35m[Appium]�[39m 

�[35m[Appium]�[39m   The next major version of Appium (2.x) will **require** the 
�[35m[Appium]�[39m   'automationName' capability to be set for all sessions on all 
�[35m[Appium]�[39m   platforms

�[35m[Appium]�[39m 

�[35m[Appium]�[39m   In previous versions (Appium <= 1.13.x), the default was 
�[35m[Appium]�[39m   'automationName=UiAutomator1'

�[35m[Appium]�[39m 

�[35m[Appium]�[39m   If you wish to use that automation instead of UiAutomator2, please 
�[35m[Appium]�[39m   add 'automationName=UiAutomator1' to your desired capabilities

�[35m[Appium]�[39m 

�[35m[Appium]�[39m   For more information about drivers, please visit 
�[35m[Appium]�[39m   http://appium.io/docs/en/about-appium/intro/ and explore the 
�[35m[Appium]�[39m   'Drivers' menu

�[35m[Appium]�[39m 

�[35m[Appium]�[39m ======================================================================

�[35m[Appium]�[39m 
�[35m[Appium]�[39m Appium v1.22.0 creating new AndroidUiautomator2Driver (v1.69.0) session
�[35m[Appium]�[39m Applying relaxed security to 'AndroidUiautomator2Driver' as per server command line argument. All insecure features will be enabled unless explicitly disabled by --deny-insecure
�[35m[BaseDriver]�[39m Session created with session id: e54aee2a-3b19-4ee6-928d-6e5f5e02b614
�[35m[UiAutomator2]�[39m Starting 'com.picc.mcp' directly on the device
�[35m[ADB]�[39m Found 1 'build-tools' folders under 'D:\aa\SDK' (newest first):
�[35m[ADB]�[39m     D:/aa/SDK/build-tools/30.0.3
�[35m[ADB]�[39m Using 'adb.exe' from 'D:\aa\SDK\platform-tools\adb.exe'
�[35m[AndroidDriver]�[39m Retrieving device list
�[35m[AndroidDriver]�[39m Using device: GPG4C19619002744
�[35m[ADB]�[39m Using 'adb.exe' from 'D:\aa\SDK\platform-tools\adb.exe'
�[35m[ADB]�[39m Getting device platform version
�[35m[UiAutomator2]�[39m Relaxing hidden api policy
�[35m[AndroidDriver]�[39m No app sent in, not parsing package/activity
�[35m[ADB]�[39m Using 'apksigner.jar' from 'D:\aa\SDK\build-tools\30.0.3\lib\apksigner.jar'
�[35m[ADB]�[39m 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.24.0.apk' is signed with the default certificate
�[35m[ADB]�[39m 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk' is signed with the default certificate
�[35m[UiAutomator2]�[39m Server packages are not going to be (re)installed
�[35m[ADB]�[39m Adding packages ["io.appium.settings","io.appium.uiautomator2.server","io.appium.uiautomator2.server.test"] to Doze whitelist
�[35m[UiAutomator2]�[39m Starting UIAutomator2 server 4.24.0
�[35m[UiAutomator2]�[39m Using UIAutomator2 server from 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.24.0.apk' and test from 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk'
�[35m[UiAutomator2]�[39m Waiting up to 30000ms for UiAutomator2 to be online...
�[35m[WD Proxy]�[39m socket hang up
�[35m[WD Proxy]�[39m socket hang up
�[35m[WD Proxy]�[39m socket hang up
�[35m[WD Proxy]�[39m Determined the downstream protocol as 'W3C'
�[35m[AndroidDriver]�[39m Screen already unlocked, doing nothing
�[35m[UiAutomator2]�[39m Starting 'com.picc.mcp/com.picc.mcp.IndexVideoActivity and waiting for 'com.picc.mcp/com.picc.mcp.IndexVideoActivity'
�[35m[Appium]�[39m New AndroidUiautomator2Driver session created successfully, session e54aee2a-3b19-4ee6-928d-6e5f5e02b614 added to master session list
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session �[39m�[32m200�[39m �[90m35878 ms - 1238�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/timeouts�[39m
�[35m[HTTP]�[39m �[90m{"implicit":20000}�[39m
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/timeouts �[39m�[32m200�[39m �[90m6 ms - 14�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element�[39m
�[35m[HTTP]�[39m �[90m{"using":"xpath","value":"//android.view.View[@text=\"parameterSettings.html?returnUrl=login\"]"}�[39m
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element �[39m�[32m200�[39m �[90m1640 ms - 137�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/00000000-0000-000e-0000-002500000012/click�[39m
�[35m[HTTP]�[39m �[90m{"id":"00000000-0000-000e-0000-002500000012"}�[39m
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/00000000-0000-000e-0000-002500000012/click �[39m�[32m200�[39m �[90m748 ms - 14�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/context�[39m
�[35m[HTTP]�[39m �[90m{"name":"WEBVIEW_com.picc.mcp"}�[39m
�[35m[Chromedriver]�[39m Set chromedriver binary as: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe
�[35m[Chromedriver]�[39m Spawning chromedriver with: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe --url-base=wd/hub --port=8000 --adb-port=5037 --verbose
�[35m[Chromedriver]�[39m Chromedriver v. 81.0.4044.138 supports W3C protocol, but MJSONWP one has been explicitly requested
�[35m[WD Proxy]�[39m connect ECONNREFUSED 127.0.0.1:8000
�[35m[Chromedriver]�[39m Starting MJSONWP Chromedriver session with capabilities: {
�[35m[Chromedriver]�[39m   "desiredCapabilities": {
�[35m[Chromedriver]�[39m     "chromeOptions": {
�[35m[Chromedriver]�[39m       "androidPackage": "com.picc.mcp",
�[35m[Chromedriver]�[39m       "androidUseRunningApp": true,
�[35m[Chromedriver]�[39m       "androidProcess": "com.picc.mcp",
�[35m[Chromedriver]�[39m       "androidDeviceSerial": "GPG4C19619002744",
�[35m[Chromedriver]�[39m       "w3c": false
�[35m[Chromedriver]�[39m     },
�[35m[Chromedriver]�[39m     "loggingPrefs": {
�[35m[Chromedriver]�[39m       "browser": "ALL"
�[35m[Chromedriver]�[39m     }
�[35m[Chromedriver]�[39m   }
�[35m[Chromedriver]�[39m }
�[35m[WD Proxy]�[39m Determined the downstream protocol as 'MJSONWP'
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/context �[39m�[32m200�[39m �[90m6731 ms - 14�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/timeouts�[39m
�[35m[HTTP]�[39m �[90m{"implicit":20000}�[39m
�[35m[W3C (e54aee2a)]�[39m Driver proxy active, passing request on via HTTP proxy
�[35m[WD Proxy]�[39m Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/timeouts �[39m�[32m200�[39m �[90m6 ms - 65�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element�[39m
�[35m[HTTP]�[39m �[90m{"using":"id","value":"masterServer1"}�[39m
�[35m[W3C (e54aee2a)]�[39m Driver proxy active, passing request on via HTTP proxy
�[35m[WD Proxy]�[39m Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element �[39m�[32m200�[39m �[90m135 ms - 156�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mGET�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/attribute/value�[39m
�[35m[HTTP]�[39m �[90m{}�[39m
�[35m[W3C (e54aee2a)]�[39m Driver proxy active, passing request on via HTTP proxy
�[35m[WD Proxy]�[39m Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614
�[35m[HTTP]�[39m �[37m<-- GET /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/attribute/value �[39m�[32m200�[39m �[90m59 ms - 75�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value�[39m
�[35m[HTTP]�[39m �[90m{"text":"a","value":["","a"],"id":"0.8451682828008877-1"}�[39m
�[35m[W3C (e54aee2a)]�[39m Driver proxy active, passing request on via HTTP proxy
�[35m[WD Proxy]�[39m Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value �[39m�[32m200�[39m �[90m591 ms - 65�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value�[39m
�[35m[HTTP]�[39m �[90m{"text":"x","value":["","x"],"id":"0.8451682828008877-1"}�[39m
�[35m[W3C (e54aee2a)]�[39m Driver proxy active, passing request on via HTTP proxy
�[35m[WD Proxy]�[39m Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value �[39m�[32m200�[39m �[90m256 ms - 65�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value�[39m
�[35m[HTTP]�[39m �[90m{"text":"10.22.64.243","value":["1","0",".","2","2",".","6","4",".","2","4","3"],"id":"0.8451682828008877-1"}�[39m
�[35m[W3C (e54aee2a)]�[39m Driver proxy active, passing request on via HTTP proxy
�[35m[WD Proxy]�[39m Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-1/value �[39m�[32m200�[39m �[90m2138 ms - 65�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element�[39m
�[35m[HTTP]�[39m �[90m{"using":"id","value":"port"}�[39m
�[35m[W3C (e54aee2a)]�[39m Driver proxy active, passing request on via HTTP proxy
�[35m[WD Proxy]�[39m Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element �[39m�[32m200�[39m �[90m86 ms - 156�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mGET�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-3/attribute/value�[39m
�[35m[HTTP]�[39m �[90m{}�[39m
�[35m[W3C (e54aee2a)]�[39m Driver proxy active, passing request on via HTTP proxy
�[35m[WD Proxy]�[39m Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614
�[35m[HTTP]�[39m �[37m<-- GET /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element/0.8451682828008877-3/attribute/value �[39m�[32m200�[39m �[90m62 ms - 67�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element�[39m
�[35m[HTTP]�[39m �[90m{"using":"xpath","value":"//a[contains(@href,\"com.picc.mcp/files/mcph5/login.html\")]"}�[39m
�[35m[W3C (e54aee2a)]�[39m Driver proxy active, passing request on via HTTP proxy
�[35m[WD Proxy]�[39m Replacing sessionId 3fb31c7ca399ca17a3279d716ff44428 with e54aee2a-3b19-4ee6-928d-6e5f5e02b614
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/element �[39m�[32m200�[39m �[90m60 ms - 156�[39m
�[35m[HTTP]�[39m �[90m�[39m
�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/execute/sync�[39m
�[35m[HTTP]�[39m �[90m{"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.8451682828008877-4"}]}�[39m
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/execute/sync �[39m�[31m500�[39m �[90m142 ms - 1383�[39m
�[35m[HTTP]�[39m �[90m�[39m

If this is not a bug, why does scrollIntoView not report this error when running in selenium, but when executing in appium.

KazuCocoa commented 1 year ago

Possibly chromedriver knows the reason. loglevel debug may show more info. appium:showChromedriverLog capability is also.

Basically the response came from chromedriver because your log had set context as below. Then, basically Appium proxies request to the chromedriver without any changes in this case.

> �[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/context�[39m
> �[35m[HTTP]�[39m �[90m{"name":"WEBVIEW_com.picc.mcp"}�[39m
> �[35m[Chromedriver]�[39m Set chromedriver binary as: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe
> �[35m[Chromedriver]�[39m Spawning chromedriver with: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe --url-base=wd/hub --port=8000 --adb-port=5037 --verbose
> �[35m[Chromedriver]�[39m Chromedriver v. 81.0.4044.138 supports W3C protocol, but MJSONWP one has been explicitly requested
> �[35m[WD Proxy]�[39m connect ECONNREFUSED 127.0.0.1:8000
> �[35m[Chromedriver]�[39m Starting MJSONWP Chromedriver session with capabilities: {
> �[35m[Chromedriver]�[39m   "desiredCapabilities": {
> �[35m[Chromedriver]�[39m     "chromeOptions": {
> �[35m[Chromedriver]�[39m       "androidPackage": "com.picc.mcp",
> �[35m[Chromedriver]�[39m       "androidUseRunningApp": true,
> �[35m[Chromedriver]�[39m       "androidProcess": "com.picc.mcp",
> �[35m[Chromedriver]�[39m       "androidDeviceSerial": "GPG4C19619002744",
> �[35m[Chromedriver]�[39m       "w3c": false
> �[35m[Chromedriver]�[39m     },
> �[35m[Chromedriver]�[39m     "loggingPrefs": {
> �[35m[Chromedriver]�[39m       "browser": "ALL"
> �[35m[Chromedriver]�[39m     }
> �[35m[Chromedriver]�[39m   }
> �[35m[Chromedriver]�[39m }
> �[35m[WD Proxy]�[39m Determined the downstream protocol as 'MJSONWP'
> �[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/context �[39m�[32m200�[39m �[90m6731 ms - 14�[39m
> �[35m[HTTP]�[39m �[90m�[39m
tianyao1111 commented 1 year ago

Possibly chromedriver knows the reason. loglevel debug may show more info. appium:showChromedriverLog capability is also.

Basically the response came from chromedriver because your log had set context as below. Then, basically Appium proxies request to the chromedriver without any changes in this case.

> �[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/context�[39m
> �[35m[HTTP]�[39m �[90m{"name":"WEBVIEW_com.picc.mcp"}�[39m
> �[35m[Chromedriver]�[39m Set chromedriver binary as: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe
> �[35m[Chromedriver]�[39m Spawning chromedriver with: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe --url-base=wd/hub --port=8000 --adb-port=5037 --verbose
> �[35m[Chromedriver]�[39m Chromedriver v. 81.0.4044.138 supports W3C protocol, but MJSONWP one has been explicitly requested
> �[35m[WD Proxy]�[39m connect ECONNREFUSED 127.0.0.1:8000
> �[35m[Chromedriver]�[39m Starting MJSONWP Chromedriver session with capabilities: {
> �[35m[Chromedriver]�[39m   "desiredCapabilities": {
> �[35m[Chromedriver]�[39m     "chromeOptions": {
> �[35m[Chromedriver]�[39m       "androidPackage": "com.picc.mcp",
> �[35m[Chromedriver]�[39m       "androidUseRunningApp": true,
> �[35m[Chromedriver]�[39m       "androidProcess": "com.picc.mcp",
> �[35m[Chromedriver]�[39m       "androidDeviceSerial": "GPG4C19619002744",
> �[35m[Chromedriver]�[39m       "w3c": false
> �[35m[Chromedriver]�[39m     },
> �[35m[Chromedriver]�[39m     "loggingPrefs": {
> �[35m[Chromedriver]�[39m       "browser": "ALL"
> �[35m[Chromedriver]�[39m     }
> �[35m[Chromedriver]�[39m   }
> �[35m[Chromedriver]�[39m }
> �[35m[WD Proxy]�[39m Determined the downstream protocol as 'MJSONWP'
> �[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/e54aee2a-3b19-4ee6-928d-6e5f5e02b614/context �[39m�[32m200�[39m �[90m6731 ms - 14�[39m
> �[35m[HTTP]�[39m �[90m�[39m

here is debug loglevel log:

[Appium] Welcome to Appium v1.22.0
[Appium] Non-default server args:
[Appium]   sessionOverride: true
[Appium]   chromedriverExecutable: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe
[Appium]   relaxedSecurityEnabled: true
[Appium] Appium REST http interface listener started on 0.0.0.0:4723
[debug] [HTTP] Request idempotency key: d3ce0e6e-b176-4950-af19-48d88253ffef
[HTTP] --> POST /wd/hub/session
[HTTP] {"capabilities":{"firstMatch":[{}],"alwaysMatch":{"platformName":"Android","appium:appPackage":"com.picc.mcp","appium:appActivity":"com.picc.mcp.IndexVideoActivity","appium:noReset":true,"appium:unicodeKeyboard":true,"appium:resetKeyboard":true,"appium:newCommandTimeout":180,"appium:adbExecTimeout":180000,"appium:logcatFormat":"time","appium:logcatFilterSpecs":["*:E"],"appium:clearDeviceLogsOnStart":true,"appium:chromeOptions":{"w3c":false}}}}
[debug] [W3C] Calling AppiumDriver.createSession() with args: [null,null,{"firstMatch":[{}],"alwaysMatch":{"platformName":"Android","appium:appPackage":"com.picc.mcp","appium:appActivity":"com.picc.mcp.IndexVideoActivity","appium:noReset":true,"appium:unicodeKeyboard":true,"appium:resetKeyboard":true,"appium:newCommandTimeout":180,"appium:adbExecTimeout":180000,"appium:logcatFormat":"time","appium:logcatFilterSpecs":["*:E"],"appium:clearDeviceLogsOnStart":true,"appium:chromeOptions":{"w3c":false}}}]
[debug] [BaseDriver] Event 'newSessionRequested' logged at 1698114241595 (10:24:01 GMT+0800 (中国标准时间))
[Appium] 

[Appium] ======================================================================

[Appium]   DEPRECATION WARNING:

[Appium] 

[Appium]   The 'automationName' capability was not provided in the desired 
[Appium]   capabilities for this Android session

[Appium] 

[Appium]   Setting 'automationName=UiAutomator2' by default and using the 
[Appium]   UiAutomator2 Driver

[Appium] 

[Appium]   The next major version of Appium (2.x) will **require** the 
[Appium]   'automationName' capability to be set for all sessions on all 
[Appium]   platforms

[Appium] 

[Appium]   In previous versions (Appium <= 1.13.x), the default was 
[Appium]   'automationName=UiAutomator1'

[Appium] 

[Appium]   If you wish to use that automation instead of UiAutomator2, please 
[Appium]   add 'automationName=UiAutomator1' to your desired capabilities

[Appium] 

[Appium]   For more information about drivers, please visit 
[Appium]   http://appium.io/docs/en/about-appium/intro/ and explore the 
[Appium]   'Drivers' menu

[Appium] 

[Appium] ======================================================================

[Appium] 
[Appium] Appium v1.22.0 creating new AndroidUiautomator2Driver (v1.69.0) session
[debug] [Appium] There are no active sessions for cleanup
[Appium] Applying relaxed security to 'AndroidUiautomator2Driver' as per server command line argument. All insecure features will be enabled unless explicitly disabled by --deny-insecure
[debug] [BaseDriver] Creating session with W3C capabilities: {
[debug] [BaseDriver]   "alwaysMatch": {
[debug] [BaseDriver]     "platformName": "Android",
[debug] [BaseDriver]     "appium:appPackage": "com.picc.mcp",
[debug] [BaseDriver]     "appium:appActivity": "com.picc.mcp.IndexVideoActivity",
[debug] [BaseDriver]     "appium:noReset": true,
[debug] [BaseDriver]     "appium:unicodeKeyboard": true,
[debug] [BaseDriver]     "appium:resetKeyboard": true,
[debug] [BaseDriver]     "appium:newCommandTimeout": 180,
[debug] [BaseDriver]     "appium:adbExecTimeout": 180000,
[debug] [BaseDriver]     "appium:logcatFormat": "time",
[debug] [BaseDriver]     "appium:logcatFilterSpecs": [
[debug] [BaseDriver]       "*:E"
[debug] [BaseDriver]     ],
[debug] [BaseDriver]     "appium:clearDeviceLogsOnStart": true,
[debug] [BaseDriver]     "appium:chromeOptions": {
[debug] [BaseDriver]       "w3c": false
[debug] [BaseDriver]     }
[debug] [BaseDriver]   },
[debug] [BaseDriver]   "firstMatch": [
[debug] [BaseDriver]     {}
[debug] [BaseDriver]   ]
[debug] [BaseDriver] }
[BaseDriver] Session created with session id: 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[UiAutomator2] Starting 'com.picc.mcp' directly on the device
[ADB] Found 1 'build-tools' folders under 'D:\aa\SDK' (newest first):
[ADB]     D:/aa/SDK/build-tools/30.0.3
[ADB] Using 'adb.exe' from 'D:\aa\SDK\platform-tools\adb.exe'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 start-server'
[AndroidDriver] Retrieving device list
[debug] [ADB] Trying to find a connected android device
[debug] [ADB] Getting connected devices
[debug] [ADB] Connected devices: [{"udid":"GPG4C19619002744","state":"device"}]
[AndroidDriver] Using device: GPG4C19619002744
[ADB] Using 'adb.exe' from 'D:\aa\SDK\platform-tools\adb.exe'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 start-server'
[debug] [ADB] Setting device id to GPG4C19619002744
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell getprop ro.build.version.sdk'
[debug] [ADB] Current device property 'ro.build.version.sdk': 29
[ADB] Getting device platform version
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell getprop ro.build.version.release'
[debug] [ADB] Current device property 'ro.build.version.release': 10
[debug] [ADB] Device API level: 29
[UiAutomator2] Relaxing hidden api policy
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell 'settings put global hidden_api_policy_pre_p_apps 1;settings put global hidden_api_policy_p_apps 1;settings put global hidden_api_policy 1''
[AndroidDriver] No app sent in, not parsing package/activity
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 wait-for-device'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell echo ping'
[debug] [AndroidDriver] Pushing settings apk to device...
[debug] [ADB] Getting install status for io.appium.settings
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys package io.appium.settings'
[debug] [ADB] 'io.appium.settings' is installed
[debug] [ADB] Getting package info for 'io.appium.settings'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys package io.appium.settings'
[debug] [ADB] The version name of the installed 'io.appium.settings' is greater or equal to the application version name ('3.4.0' >= '3.4.0')
[debug] [ADB] There is no need to install/upgrade 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\io.appium.settings\apks\settings_apk-debug.apk'
[debug] [ADB] Getting IDs of all 'io.appium.settings' processes
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell 'pgrep --help; echo $?''
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell pgrep -f \(\[\[:blank:\]\]\|\^\)io\.appium\.settings\(\[\[:blank:\]\]\|\$\)'
[debug] [AndroidDriver] io.appium.settings is already running. There is no need to reset its permissions.
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell appops set io.appium.settings android:mock_location allow'
[debug] [Logcat] Clearing logcat logs from device
[debug] [Logcat] Starting logs capture with command: D:\\aa\\SDK\\platform-tools\\adb.exe -P 5037 -s GPG4C19619002744 logcat -v time \*\:E
[debug] [AndroidDriver] Enabling Unicode keyboard support
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell settings get secure default_input_method'
[debug] [AndroidDriver] Unsetting previous IME io.appium.settings/.UnicodeIME
[debug] [AndroidDriver] Setting IME to 'io.appium.settings/.UnicodeIME'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell ime enable io.appium.settings/.UnicodeIME'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell ime set io.appium.settings/.UnicodeIME'
[debug] [UiAutomator2] Forwarding UiAutomator2 Server port 6790 to local port 8200
[debug] [ADB] Forwarding system: 8200 to device: 6790
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 forward tcp:8200 tcp:6790'
[debug] [ADB] Getting install status for io.appium.uiautomator2.server
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys package io.appium.uiautomator2.server'
[debug] [ADB] 'io.appium.uiautomator2.server' is installed
[debug] [ADB] Getting package info for 'io.appium.uiautomator2.server'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys package io.appium.uiautomator2.server'
[debug] [ADB] The version name of the installed 'io.appium.uiautomator2.server' is greater or equal to the application version name ('4.24.0' >= '4.24.0')
[debug] [UiAutomator2] io.appium.uiautomator2.server installation state: sameVersionInstalled
[debug] [ADB] Checking app cert for C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.24.0.apk
[ADB] Using 'apksigner.jar' from 'D:\aa\SDK\build-tools\30.0.3\lib\apksigner.jar'
[debug] [ADB] Starting apksigner: 'C:\\Program Files\\Java\\jdk1.8.0_201\\bin\\java.exe' -Xmx1024M -Xss1m -jar D:\\aa\\SDK\\build-tools\\30.0.3\\lib\\apksigner.jar verify --print-certs C:\\Users\\admin\\AppData\\Roaming\\npm\\node_modules\\appium\\node_modules\\appium-uiautomator2-server\\apks\\appium-uiautomator2-server-v4.24.0.apk
[debug] [ADB] apksigner stdout: Signer #1 certificate DN: EMAILADDRESS=android@android.com, CN=Android, OU=Android, O=Android, L=Mountain View, ST=California, C=US

[debug] [ADB] Signer #1 certificate SHA-256 digest: a40da80a59d170caa950cf15c18c454d47a39b26989d8b640ecd745ba71bf5dc

[debug] [ADB] Signer #1 certificate SHA-1 digest: 61ed377e85d386a8dfee6b864bd85b0bfaa5af81

[debug] [ADB] Signer #1 certificate MD5 digest: e89b158e4bcf988ebd09eb83f5378e87

[debug] [ADB] 
[debug] [ADB] sha256 hash did match for 'appium-uiautomator2-server-v4.24.0.apk'
[ADB] 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.24.0.apk' is signed with the default certificate
[debug] [ADB] Getting install status for io.appium.uiautomator2.server.test
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys package io.appium.uiautomator2.server.test'
[debug] [ADB] 'io.appium.uiautomator2.server.test' is installed
[debug] [ADB] Checking app cert for C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk
[debug] [ADB] Starting apksigner: 'C:\\Program Files\\Java\\jdk1.8.0_201\\bin\\java.exe' -Xmx1024M -Xss1m -jar D:\\aa\\SDK\\build-tools\\30.0.3\\lib\\apksigner.jar verify --print-certs C:\\Users\\admin\\AppData\\Roaming\\npm\\node_modules\\appium\\node_modules\\appium-uiautomator2-server\\apks\\appium-uiautomator2-server-debug-androidTest.apk
[debug] [ADB] apksigner stdout: Signer #1 certificate DN: EMAILADDRESS=android@android.com, CN=Android, OU=Android, O=Android, L=Mountain View, ST=California, C=US

[debug] [ADB] Signer #1 certificate SHA-256 digest: a40da80a59d170caa950cf15c18c454d47a39b26989d8b640ecd745ba71bf5dc

[debug] [ADB] Signer #1 certificate SHA-1 digest: 61ed377e85d386a8dfee6b864bd85b0bfaa5af81

[debug] [ADB] Signer #1 certificate MD5 digest: e89b158e4bcf988ebd09eb83f5378e87

[debug] [ADB] 
[debug] [ADB] sha256 hash did match for 'appium-uiautomator2-server-debug-androidTest.apk'
[ADB] 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk' is signed with the default certificate
[UiAutomator2] Server packages are not going to be (re)installed
[debug] [UiAutomator2] Waiting up to 30000ms for services to be available
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell pm list instrumentation'
[debug] [UiAutomator2] Instrumentation target 'io.appium.uiautomator2.server.test/androidx.test.runner.AndroidJUnitRunner' is available
[ADB] Adding packages ["io.appium.settings","io.appium.uiautomator2.server","io.appium.uiautomator2.server.test"] to Doze whitelist
[debug] [ADB] Got the following command chunks to execute: [["dumpsys","deviceidle","whitelist","+io.appium.settings",";","dumpsys","deviceidle","whitelist","+io.appium.uiautomator2.server",";","dumpsys","deviceidle","whitelist","+io.appium.uiautomator2.server.test",";"]]
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys deviceidle whitelist +io.appium.settings ; dumpsys deviceidle whitelist +io.appium.uiautomator2.server ; dumpsys deviceidle whitelist +io.appium.uiautomator2.server.test ;'
[debug] [UiAutomator2] No app capability. Assuming it is already on the device
[debug] [UiAutomator2] Performing shallow cleanup of automation leftovers
[debug] [UiAutomator2] No obsolete sessions have been detected (socket hang up)
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell am force-stop io.appium.uiautomator2.server.test'
[UiAutomator2] Starting UIAutomator2 server 4.24.0
[UiAutomator2] Using UIAutomator2 server from 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.24.0.apk' and test from 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk'
[UiAutomator2] Waiting up to 30000ms for UiAutomator2 to be online...
[debug] [ADB] Creating ADB subprocess with args: ["-P",5037,"-s","GPG4C19619002744","shell","am","instrument","-w","-e","disableAnalytics",true,"io.appium.uiautomator2.server.test/androidx.test.runner.AndroidJUnitRunner"]
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8200/wd/hub/status] with no body
[WD Proxy] socket hang up
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8200/wd/hub/status] with no body
[WD Proxy] socket hang up
[debug] [Instrumentation] io.appium.uiautomator2.server.test.AppiumUiAutomator2Server:
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8200/wd/hub/status] with no body
[WD Proxy] socket hang up
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8200/wd/hub/status] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"None","value":{"message":"UiAutomator2 Server is ready to accept commands","ready":true}}
[debug] [UiAutomator2] The initialization of the instrumentation process took 3362ms
[debug] [WD Proxy] Matched '/session' to command name 'createSession'
[debug] [WD Proxy] Proxying [POST /session] to [POST http://127.0.0.1:8200/wd/hub/session] with body: {"capabilities":{"firstMatch":[{"platform":"LINUX","webStorageEnabled":false,"takesScreenshot":true,"javascriptEnabled":true,"databaseEnabled":false,"networkConnectionEnabled":true,"locationContextEnabled":false,"warnings":{},"desired":{"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"chromeOptions":{"w3c":false}},"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"chromeOptions":{"w3c":false},"deviceName":"GPG4C19619002744","deviceUDID":"GPG4C19619002744"}],"alwaysMatch":{}}}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"f450ed95-7fa7-43ed-8edd-78203bb78429","value":{"capabilities":{"firstMatch":[{"platform":"LINUX","webStorageEnabled":false,"takesScreenshot":true,"javascriptEnabled":true,"databaseEnabled":false,"networkConnectionEnabled":true,"locationContextEnabled":false,"warnings":{},"desired":{"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"chromeOptions":{"w3c":false}},"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"chromeOptions":{"w3c":false},"deviceName":"GPG4C19619002744","deviceUDID":"GPG4C19619002744"}],"alwaysMatch":{}},"se...
[WD Proxy] Determined the downstream protocol as 'W3C'
[debug] [WD Proxy] Proxying [GET /appium/device/info] to [GET http://127.0.0.1:8200/wd/hub/session/f450ed95-7fa7-43ed-8edd-78203bb78429/appium/device/info] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"f450ed95-7fa7-43ed-8edd-78203bb78429","value":{"androidId":"6e49637b773bd7af","apiVersion":"29","bluetooth":{"state":"OFF"},"brand":"HUAWEI","carrierName":"中国电信","displayDensity":480,"locale":"zh_CN_#Hans","manufacturer":"HUAWEI","model":"VCE-AL00","networks":[{"capabilities":{"SSID":null,"linkDownBandwidthKbps":1048576,"linkUpstreamBandwidthKbps":1048576,"networkCapabilities":"NET_CAPABILITY_NOT_METERED,NET_CAPABILITY_INTERNET,NET_CAPABILITY_NOT_RESTRICTED,NET_CAPABILITY_TRUSTED,NET_CAPABILITY_NOT_VPN,NET_CAPABILITY_NOT_ROAMING,NET_CAPABILITY_FOREGROUND,NET_CAPABILITY_NOT_CONGESTED,NET_CAPABILITY_NOT_SUSPENDED","signalStrength":-39,"transportTypes":"TRANSPORT_WIFI"},"detailedState":"CONNECTED","extraInfo":null,"isAvailable":true,"isConnected":true,"isFailover":false,"isRoaming":false,"state":"CONNECTED","subtype":0,"subtypeName":"","type":1,"typeName":"WIFI"}],"platformVersion":"10","realDisplaySize":"1080x2310","timeZone":"Asia/Shanghai"}}
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys window'
[AndroidDriver] Screen already unlocked, doing nothing
[UiAutomator2] Starting 'com.picc.mcp/com.picc.mcp.IndexVideoActivity and waiting for 'com.picc.mcp/com.picc.mcp.IndexVideoActivity'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell am start -W -n com.picc.mcp/com.picc.mcp.IndexVideoActivity -S -a android.intent.action.MAIN -c android.intent.category.LAUNCHER -f 0x10200000'
[debug] [WD Proxy] Proxying [GET /appium/device/pixel_ratio] to [GET http://127.0.0.1:8200/wd/hub/session/f450ed95-7fa7-43ed-8edd-78203bb78429/appium/device/pixel_ratio] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"f450ed95-7fa7-43ed-8edd-78203bb78429","value":3}
[debug] [WD Proxy] Matched '/appium/device/system_bars' to command name 'getSystemBars'
[debug] [WD Proxy] Proxying [GET /appium/device/system_bars] to [GET http://127.0.0.1:8200/wd/hub/session/f450ed95-7fa7-43ed-8edd-78203bb78429/appium/device/system_bars] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"f450ed95-7fa7-43ed-8edd-78203bb78429","value":{"statusBar":102}}
[debug] [WD Proxy] Matched '/window/current/size' to command name 'getWindowSize'
[debug] [WD Proxy] Proxying [GET /window/current/size] to [GET http://127.0.0.1:8200/wd/hub/session/f450ed95-7fa7-43ed-8edd-78203bb78429/window/current/size] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"f450ed95-7fa7-43ed-8edd-78203bb78429","value":{"height":2090,"width":1080}}
[Appium] New AndroidUiautomator2Driver session created successfully, session 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652 added to master session list
[debug] [BaseDriver] Event 'newSessionStarted' logged at 1698114261631 (10:24:21 GMT+0800 (中国标准时间))
[debug] [W3C (8bd0f92e)] Cached the protocol value 'W3C' for the new session 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[debug] [W3C (8bd0f92e)] Responding to client with driver.createSession() result: {"capabilities":{"platform":"LINUX","webStorageEnabled":false,"takesScreenshot":true,"javascriptEnabled":true,"databaseEnabled":false,"networkConnectionEnabled":true,"locationContextEnabled":false,"warnings":{},"desired":{"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"chromeOptions":{"w3c":false}},"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"chromeOptions":{"w3c":false},"deviceName":"GPG4C19619002744","deviceUDID":"GPG4C19619002744","deviceApiLevel":29,"platformVersion":"10","deviceScreenSize":"1080x2310","deviceScreenDensity":48...
[HTTP] <-- POST /wd/hub/session 200 20060 ms - 1238
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/timeouts
[HTTP] {"implicit":20000}
[debug] [W3C (8bd0f92e)] Calling AppiumDriver.timeouts() with args: [null,null,null,null,20000,"8bd0f92e-2a52-47f7-a7a7-a4634d0ea652"]
[debug] [BaseDriver] W3C timeout argument: {"implicit":20000}}
[debug] [BaseDriver] Set implicit wait to 20000ms
[debug] [W3C (8bd0f92e)] Responding to client with driver.timeouts() result: null
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/timeouts 200 9 ms - 14
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element
[HTTP] {"using":"xpath","value":"//android.view.View[@text=\"parameterSettings.html?returnUrl=login\"]"}
[debug] [W3C (8bd0f92e)] Calling AppiumDriver.findElement() with args: ["xpath","//android.view.View[@text=\"parameterSettings.html?returnUrl=login\"]","8bd0f92e-2a52-47f7-a7a7-a4634d0ea652"]
[debug] [BaseDriver] Valid locator strategies for this request: xpath, id, class name, accessibility id, css selector, -android uiautomator
[debug] [BaseDriver] Waiting up to 20000 ms for condition
[debug] [WD Proxy] Matched '/element' to command name 'findElement'
[debug] [WD Proxy] Proxying [POST /element] to [POST http://127.0.0.1:8200/wd/hub/session/f450ed95-7fa7-43ed-8edd-78203bb78429/element] with body: {"strategy":"xpath","selector":"//android.view.View[@text=\"parameterSettings.html?returnUrl=login\"]","context":"","multiple":false}
[WD Proxy] Got response with status 404: {"sessionId":"f450ed95-7fa7-43ed-8edd-78203bb78429","value":{"error":"no such element","message":"An element could not be located on the page using the given search parameters","stacktrace":"io.appium.uiautomator2.common.exceptions.ElementNotFoundException: An element could not be located on the page using the given search parameters\n\tat io.appium.uiautomator2.handler.FindElement.findElement(FindElement.java:90)\n\tat io.appium.uiautomator2.handler.FindElement.safeHandle(FindElement.java:67)\n\tat io.appium.uiautomator2.handler.request.SafeRequestHandler.handle(SafeRequestHandler.java:59)\n\tat io.appium.uiautomator2.server.AppiumServlet.handleRequest(AppiumServlet.java:264)\n\tat io.appium.uiautomator2.server.AppiumServlet.handleHttpRequest(AppiumServlet.java:258)\n\tat io.appium.uiautomator2.http.ServerHandler.channelRead(ServerHandler.java:68)\n\tat io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:366)\n\tat io.netty.channel.AbstractChannelHandlerCont...
[debug] [W3C] Matched W3C error code 'no such element' to NoSuchElementError
[debug] [BaseDriver] Waited for 443 ms so far
[debug] [WD Proxy] Matched '/element' to command name 'findElement'
[debug] [WD Proxy] Proxying [POST /element] to [POST http://127.0.0.1:8200/wd/hub/session/f450ed95-7fa7-43ed-8edd-78203bb78429/element] with body: {"strategy":"xpath","selector":"//android.view.View[@text=\"parameterSettings.html?returnUrl=login\"]","context":"","multiple":false}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"f450ed95-7fa7-43ed-8edd-78203bb78429","value":{"ELEMENT":"00000000-0000-0197-0000-002500000012","element-6066-11e4-a52e-4f735466cecf":"00000000-0000-0197-0000-002500000012"}}
[debug] [W3C (8bd0f92e)] Responding to client with driver.findElement() result: {"element-6066-11e4-a52e-4f735466cecf":"00000000-0000-0197-0000-002500000012","ELEMENT":"00000000-0000-0197-0000-002500000012"}
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element 200 1509 ms - 137
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/00000000-0000-0197-0000-002500000012/click
[HTTP] {"id":"00000000-0000-0197-0000-002500000012"}
[debug] [W3C (8bd0f92e)] Calling AppiumDriver.click() with args: ["00000000-0000-0197-0000-002500000012","8bd0f92e-2a52-47f7-a7a7-a4634d0ea652"]
[debug] [WD Proxy] Matched '/element/00000000-0000-0197-0000-002500000012/click' to command name 'click'
[debug] [WD Proxy] Proxying [POST /element/00000000-0000-0197-0000-002500000012/click] to [POST http://127.0.0.1:8200/wd/hub/session/f450ed95-7fa7-43ed-8edd-78203bb78429/element/00000000-0000-0197-0000-002500000012/click] with body: {"element":"00000000-0000-0197-0000-002500000012"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"f450ed95-7fa7-43ed-8edd-78203bb78429","value":null}
[debug] [W3C (8bd0f92e)] Responding to client with driver.click() result: null
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/00000000-0000-0197-0000-002500000012/click 200 537 ms - 14
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/context
[HTTP] {"name":"WEBVIEW_com.picc.mcp"}
[debug] [W3C (8bd0f92e)] Calling AppiumDriver.setContext() with args: ["WEBVIEW_com.picc.mcp","8bd0f92e-2a52-47f7-a7a7-a4634d0ea652"]
[debug] [AndroidDriver] Getting a list of available webviews
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell cat /proc/net/unix'
[debug] [AndroidDriver] Parsed 1 active devtools socket: ["@webview_devtools_remote_15186"]
[debug] [AndroidDriver] Collecting CDP data of 1 webview
[debug] [AndroidDriver] Forwarding remote port webview_devtools_remote_15186 to a local port in range 10900..11000
[debug] [AndroidDriver] You could use the 'webviewDevtoolsPort' capability to customize the starting port number
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 forward tcp:10900 localabstract:webview_devtools_remote_15186'
[debug] [ADB] Removing forwarded port socket connection: 10900 
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 forward --remove tcp:10900'
[debug] [AndroidDriver] CDP data collection completed
[debug] [AndroidDriver] WEBVIEW_15186 mapped to pid 15186
[debug] [AndroidDriver] Getting process name for webview 'WEBVIEW_15186'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell ps --help'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell ps -A'
[debug] [AndroidDriver] Got process name: 'com.picc.mcp'
[debug] [AndroidDriver] Found 1 webview: ["WEBVIEW_com.picc.mcp"]
[debug] [AndroidDriver] Available contexts: ["NATIVE_APP","WEBVIEW_com.picc.mcp"]
[debug] [AndroidDriver] Connecting to chrome-backed webview context 'WEBVIEW_com.picc.mcp'
[debug] [AndroidDriver] A port was not given, using random free port: 8000
[debug] [AndroidDriver] Passing web view details to the Chromedriver constructor: {
[debug] [AndroidDriver]   "info": {
[debug] [AndroidDriver]     "Android-Package": "com.picc.mcp",
[debug] [AndroidDriver]     "Browser": "Chrome/81.0.4044.138",
[debug] [AndroidDriver]     "Protocol-Version": "1.3",
[debug] [AndroidDriver]     "User-Agent": "Mozilla/5.0 (Linux; Android 10; VCE-AL00 Build/HUAWEIVCE-AL00; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/81.0.4044.138 Mobile Safari/537.36",
[debug] [AndroidDriver]     "V8-Version": "8.1.307.32",
[debug] [AndroidDriver]     "WebKit-Version": "537.36 (@8c6c7ba89cc9453625af54f11fd83179e23450fa)",
[debug] [AndroidDriver]     "webSocketDebuggerUrl": "ws://127.0.0.1:10900/devtools/browser"
[debug] [AndroidDriver]   },
[debug] [AndroidDriver]   "process": {
[debug] [AndroidDriver]     "name": "com.picc.mcp",
[debug] [AndroidDriver]     "id": "15186"
[debug] [AndroidDriver]   }
[debug] [AndroidDriver] }
[debug] [AndroidDriver] Precalculated Chromedriver capabilities: {
[debug] [AndroidDriver]   "androidPackage": "com.picc.mcp",
[debug] [AndroidDriver]   "androidUseRunningApp": true,
[debug] [AndroidDriver]   "androidProcess": "com.picc.mcp",
[debug] [AndroidDriver]   "androidDeviceSerial": "GPG4C19619002744"
[debug] [AndroidDriver] }
[debug] [AndroidDriver] Before starting chromedriver, androidPackage is 'com.picc.mcp'
[debug] [Chromedriver] Changed state to 'starting'
[Chromedriver] Set chromedriver binary as: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe
[debug] [Chromedriver] Killing any old chromedrivers, running: wmic process where "commandline like '%chromedriver.exe%--port=8000%'" delete
[debug] [Chromedriver] Successfully cleaned up old chromedrivers
[debug] [Chromedriver] Cleaning this device's adb forwarded port socket connections: GPG4C19619002744
[debug] [ADB] List forwarding ports
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 forward --list'
[debug] [ADB] Removing forwarded port socket connection: 50782 
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 forward --remove tcp:50782'
[Chromedriver] Spawning chromedriver with: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe --url-base=wd/hub --port=8000 --adb-port=5037 --verbose
[debug] [Chromedriver] Chromedriver version: '81.0.4044.138'
[Chromedriver] Chromedriver v. 81.0.4044.138 supports W3C protocol, but MJSONWP one has been explicitly requested
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8000/wd/hub/status] with no body
[WD Proxy] connect ECONNREFUSED 127.0.0.1:8000
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8000/wd/hub/status] with no body
[debug] [WD Proxy] Got response with status 200: {"value":{"build":{"version":"81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999})"},"message":"ChromeDriver ready for new sessions.","os":{"arch":"x86_64","name":"Windows NT","version":"10.0.19045"},"ready":true}}
[Chromedriver] Starting MJSONWP Chromedriver session with capabilities: {
[Chromedriver]   "desiredCapabilities": {
[Chromedriver]     "chromeOptions": {
[Chromedriver]       "androidPackage": "com.picc.mcp",
[Chromedriver]       "androidUseRunningApp": true,
[Chromedriver]       "androidProcess": "com.picc.mcp",
[Chromedriver]       "androidDeviceSerial": "GPG4C19619002744",
[Chromedriver]       "w3c": false
[Chromedriver]     },
[Chromedriver]     "loggingPrefs": {
[Chromedriver]       "browser": "ALL"
[Chromedriver]     }
[Chromedriver]   }
[Chromedriver] }
[debug] [WD Proxy] Matched '/session' to command name 'createSession'
[debug] [WD Proxy] Proxying [POST /session] to [POST http://127.0.0.1:8000/wd/hub/session] with body: {"desiredCapabilities":{"chromeOptions":{"androidPackage":"com.picc.mcp","androidUseRunningApp":true,"androidProcess":"com.picc.mcp","androidDeviceSerial":"GPG4C19619002744","w3c":false},"loggingPrefs":{"browser":"ALL"}}}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":0,"value":{"acceptInsecureCerts":false,"acceptSslCerts":false,"applicationCacheEnabled":false,"browserConnectionEnabled":false,"browserName":"chrome","chrome":{"chromedriverVersion":"81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999})"},"cssSelectorsEnabled":true,"databaseEnabled":false,"goog:chromeOptions":{"debuggerAddress":"localhost:50994"},"handlesAlerts":true,"hasTouchScreen":true,"javascriptEnabled":true,"locationContextEnabled":true,"mobileEmulationEnabled":false,"nativeEvents":true,"pageLoadStrategy":"normal","platform":"ANDROID","proxy":{},"rotatable":false,"setWindowRect":false,"strictFileInteractability":false,"takesHeapSnapshot":true,"takesScreenshot":true,"timeouts":{"implicit":0,"pageLoad":300000,"script":30000},"unexpectedAlertBehaviour":"ignore","version":"81.0.4044.138","webStorageEnabled":true,"webauthn:virtualAuthenticators":false}}
[WD Proxy] Determined the downstream protocol as 'MJSONWP'
[debug] [Chromedriver] Changed state to 'online'
[debug] [W3C (8bd0f92e)] Responding to client with driver.setContext() result: null
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/context 200 6229 ms - 14
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/timeouts
[HTTP] {"implicit":20000}
[W3C (8bd0f92e)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/timeouts' to command name 'timeouts'
[debug] [Protocol Converter] Will send the following request bodies to /timeouts: [{"type":"implicit","ms":20000}]
[debug] [WD Proxy] Proxying [POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/timeouts] to [POST http://127.0.0.1:8000/wd/hub/session/fb6630a8fe8378e023b6bfebb6cbaf59/timeouts] with body: {"type":"implicit","ms":20000}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":0,"value":null}
[WD Proxy] Replacing sessionId fb6630a8fe8378e023b6bfebb6cbaf59 with 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/timeouts 200 7 ms - 65
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element
[HTTP] {"using":"id","value":"masterServer1"}
[W3C (8bd0f92e)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element' to command name 'findElement'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element] to [POST http://127.0.0.1:8000/wd/hub/session/fb6630a8fe8378e023b6bfebb6cbaf59/element] with body: {"using":"id","value":"masterServer1"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":0,"value":{"ELEMENT":"0.8821732653336454-1"}}
[WD Proxy] Replacing sessionId fb6630a8fe8378e023b6bfebb6cbaf59 with 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element 200 135 ms - 156
[HTTP] 
[HTTP] --> GET /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/attribute/value
[HTTP] {}
[W3C (8bd0f92e)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/attribute/value' to command name 'getAttribute'
[debug] [WD Proxy] Proxying [GET /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/attribute/value] to [GET http://127.0.0.1:8000/wd/hub/session/fb6630a8fe8378e023b6bfebb6cbaf59/element/0.8821732653336454-1/attribute/value] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":0,"value":"10.22.64.173"}
[WD Proxy] Replacing sessionId fb6630a8fe8378e023b6bfebb6cbaf59 with 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[HTTP] <-- GET /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/attribute/value 200 111 ms - 75
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value
[HTTP] {"text":"a","value":["","a"],"id":"0.8821732653336454-1"}
[W3C (8bd0f92e)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value' to command name 'setValue'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value] to [POST http://127.0.0.1:8000/wd/hub/session/fb6630a8fe8378e023b6bfebb6cbaf59/element/0.8821732653336454-1/value] with body: {"text":"a","value":["","a"],"id":"0.8821732653336454-1"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":0,"value":null}
[WD Proxy] Replacing sessionId fb6630a8fe8378e023b6bfebb6cbaf59 with 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value 200 518 ms - 65
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value
[HTTP] {"text":"x","value":["","x"],"id":"0.8821732653336454-1"}
[W3C (8bd0f92e)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value' to command name 'setValue'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value] to [POST http://127.0.0.1:8000/wd/hub/session/fb6630a8fe8378e023b6bfebb6cbaf59/element/0.8821732653336454-1/value] with body: {"text":"x","value":["","x"],"id":"0.8821732653336454-1"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":0,"value":null}
[WD Proxy] Replacing sessionId fb6630a8fe8378e023b6bfebb6cbaf59 with 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value 200 615 ms - 65
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value
[HTTP] {"text":"10.22.64.243","value":["1","0",".","2","2",".","6","4",".","2","4","3"],"id":"0.8821732653336454-1"}
[W3C (8bd0f92e)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value' to command name 'setValue'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value] to [POST http://127.0.0.1:8000/wd/hub/session/fb6630a8fe8378e023b6bfebb6cbaf59/element/0.8821732653336454-1/value] with body: {"text":"10.22.64.243","value":["1","0",".","2","2",".","6","4",".","2","4","3"],"id":"0.8821732653336454-1"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":0,"value":null}
[WD Proxy] Replacing sessionId fb6630a8fe8378e023b6bfebb6cbaf59 with 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-1/value 200 1707 ms - 65
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element
[HTTP] {"using":"id","value":"port"}
[W3C (8bd0f92e)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element' to command name 'findElement'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element] to [POST http://127.0.0.1:8000/wd/hub/session/fb6630a8fe8378e023b6bfebb6cbaf59/element] with body: {"using":"id","value":"port"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":0,"value":{"ELEMENT":"0.8821732653336454-3"}}
[WD Proxy] Replacing sessionId fb6630a8fe8378e023b6bfebb6cbaf59 with 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element 200 90 ms - 156
[HTTP] 
[HTTP] --> GET /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-3/attribute/value
[HTTP] {}
[W3C (8bd0f92e)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-3/attribute/value' to command name 'getAttribute'
[debug] [WD Proxy] Proxying [GET /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-3/attribute/value] to [GET http://127.0.0.1:8000/wd/hub/session/fb6630a8fe8378e023b6bfebb6cbaf59/element/0.8821732653336454-3/attribute/value] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":0,"value":"8005"}
[WD Proxy] Replacing sessionId fb6630a8fe8378e023b6bfebb6cbaf59 with 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[HTTP] <-- GET /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element/0.8821732653336454-3/attribute/value 200 41 ms - 67
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element
[HTTP] {"using":"xpath","value":"//a[contains(@href,\"com.picc.mcp/files/mcph5/login.html\")]"}
[W3C (8bd0f92e)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element' to command name 'findElement'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element] to [POST http://127.0.0.1:8000/wd/hub/session/fb6630a8fe8378e023b6bfebb6cbaf59/element] with body: {"using":"xpath","value":"//a[contains(@href,\"com.picc.mcp/files/mcph5/login.html\")]"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":0,"value":{"ELEMENT":"0.8821732653336454-4"}}
[WD Proxy] Replacing sessionId fb6630a8fe8378e023b6bfebb6cbaf59 with 8bd0f92e-2a52-47f7-a7a7-a4634d0ea652
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/element 200 62 ms - 156
[HTTP] 
[HTTP] --> POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/execute/sync
[HTTP] {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.8821732653336454-4"}]}
[debug] [W3C (8bd0f92e)] Calling AppiumDriver.execute() with args: ["return arguments[0].scrollIntoView(true);",[{"element-6066-11e4-a52e-4f735466cecf":"0.8821732653336454-4"}],"8bd0f92e-2a52-47f7-a7a7-a4634d0ea652"]
[debug] [WD Proxy] Matched '/execute' to command name 'execute'
[debug] [Protocol Converter] Did not know how to rewrite the original URL '/execute' for MJSONWP protocol
[debug] [WD Proxy] Proxying [POST /execute] to [POST http://127.0.0.1:8000/wd/hub/session/fb6630a8fe8378e023b6bfebb6cbaf59/execute] with body: {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.8821732653336454-4"}]}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"fb6630a8fe8378e023b6bfebb6cbaf59","status":17,"value":{"message":"javascript error: arguments[0].scrollIntoView is not a function\n  (Session info: chrome=81.0.4044.138)\n  (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)"}}
[debug] [MJSONWP] Matched JSONWP error code 17 to JavaScriptError
[debug] [W3C (8bd0f92e)] Encountered internal error running command: JavaScriptError: javascript error: arguments[0].scrollIntoView is not a function
[debug] [W3C (8bd0f92e)]   (Session info: chrome=81.0.4044.138)
[debug] [W3C (8bd0f92e)]   (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)
[debug] [W3C (8bd0f92e)]     at errorFromMJSONWPStatusCode (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:764:12)
[debug] [W3C (8bd0f92e)]     at ProxyRequestError.getActualError (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:661:14)
[debug] [W3C (8bd0f92e)]     at JWProxy.command (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\jsonwp-proxy\proxy.js:272:19)
[debug] [W3C (8bd0f92e)]     at runMicrotasks (<anonymous>)
[debug] [W3C (8bd0f92e)]     at processTicksAndRejections (internal/process/task_queues.js:93:5)
[debug] [W3C (8bd0f92e)]     at AndroidUiautomator2Driver.execute (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-android-driver\lib\commands\execute.js:19:10)
[HTTP] <-- POST /wd/hub/session/8bd0f92e-2a52-47f7-a7a7-a4634d0ea652/execute/sync 500 96 ms - 1383
[HTTP] 
KazuCocoa commented 1 year ago

Please add appium:showChromedriverLog to print chromedriver logs

tianyao1111 commented 1 year ago

Please add appium:showChromedriverLog to print chromedriver logs

This is the log after opening appium: showChromedriverLog

[Appium] Welcome to Appium v1.22.0
[Appium] Non-default server args:
[Appium]   sessionOverride: true
[Appium]   chromedriverExecutable: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe
[Appium]   defaultCapabilities: {
[Appium]     chromeOptions: {
[Appium]       args: {
[Appium]         0: --log-level=DEBUG
[Appium]         1: --enable-logging
[Appium]       }
[Appium]       perfLoggingPrefs: {
[Appium]         enableNetwork: true
[Appium]         enablePage: true
[Appium]       }
[Appium]     }
[Appium]   }
[Appium]   relaxedSecurityEnabled: true
[Appium] Default capabilities, which will be added to each request unless overridden by desired capabilities:
[Appium]   chromeOptions: {
[Appium]     args: {
[Appium]       0: --log-level=DEBUG
[Appium]       1: --enable-logging
[Appium]     }
[Appium]     perfLoggingPrefs: {
[Appium]       enableNetwork: true
[Appium]       enablePage: true
[Appium]     }
[Appium]   }
[Appium] Appium REST http interface listener started on 0.0.0.0:4723
[debug] [HTTP] Request idempotency key: be468656-b9cd-42f8-89a6-1d60efc662ef
[HTTP] --> POST /wd/hub/session
[HTTP] {"capabilities":{"firstMatch":[{}],"alwaysMatch":{"platformName":"Android","appium:appPackage":"com.picc.mcp","appium:appActivity":"com.picc.mcp.IndexVideoActivity","appium:noReset":true,"appium:unicodeKeyboard":true,"appium:resetKeyboard":true,"appium:newCommandTimeout":180,"appium:adbExecTimeout":180000,"appium:logcatFormat":"time","appium:logcatFilterSpecs":["*:E"],"appium:clearDeviceLogsOnStart":true,"appium:showChromedriverLog":true,"appium:chromeOptions":{"w3c":false}}}}
[debug] [W3C] Calling AppiumDriver.createSession() with args: [null,null,{"firstMatch":[{}],"alwaysMatch":{"platformName":"Android","appium:appPackage":"com.picc.mcp","appium:appActivity":"com.picc.mcp.IndexVideoActivity","appium:noReset":true,"appium:unicodeKeyboard":true,"appium:resetKeyboard":true,"appium:newCommandTimeout":180,"appium:adbExecTimeout":180000,"appium:logcatFormat":"time","appium:logcatFilterSpecs":["*:E"],"appium:clearDeviceLogsOnStart":true,"appium:showChromedriverLog":true,"appium:chromeOptions":{"w3c":false}}}]
[debug] [BaseDriver] Event 'newSessionRequested' logged at 1698371962840 (09:59:22 GMT+0800 (中国标准时间))
[Appium] 

[Appium] ======================================================================

[Appium]   DEPRECATION WARNING:

[Appium] 

[Appium]   The 'automationName' capability was not provided in the desired 
[Appium]   capabilities for this Android session

[Appium] 

[Appium]   Setting 'automationName=UiAutomator2' by default and using the 
[Appium]   UiAutomator2 Driver

[Appium] 

[Appium]   The next major version of Appium (2.x) will **require** the 
[Appium]   'automationName' capability to be set for all sessions on all 
[Appium]   platforms

[Appium] 

[Appium]   In previous versions (Appium <= 1.13.x), the default was 
[Appium]   'automationName=UiAutomator1'

[Appium] 

[Appium]   If you wish to use that automation instead of UiAutomator2, please 
[Appium]   add 'automationName=UiAutomator1' to your desired capabilities

[Appium] 

[Appium]   For more information about drivers, please visit 
[Appium]   http://appium.io/docs/en/about-appium/intro/ and explore the 
[Appium]   'Drivers' menu

[Appium] 

[Appium] ======================================================================

[Appium] 
[Appium] Appium v1.22.0 creating new AndroidUiautomator2Driver (v1.69.0) session
[debug] [Appium] There are no active sessions for cleanup
[Appium] Applying relaxed security to 'AndroidUiautomator2Driver' as per server command line argument. All insecure features will be enabled unless explicitly disabled by --deny-insecure
[debug] [BaseDriver] Creating session with W3C capabilities: {
[debug] [BaseDriver]   "alwaysMatch": {
[debug] [BaseDriver]     "platformName": "Android",
[debug] [BaseDriver]     "appium:appPackage": "com.picc.mcp",
[debug] [BaseDriver]     "appium:appActivity": "com.picc.mcp.IndexVideoActivity",
[debug] [BaseDriver]     "appium:noReset": true,
[debug] [BaseDriver]     "appium:unicodeKeyboard": true,
[debug] [BaseDriver]     "appium:resetKeyboard": true,
[debug] [BaseDriver]     "appium:newCommandTimeout": 180,
[debug] [BaseDriver]     "appium:adbExecTimeout": 180000,
[debug] [BaseDriver]     "appium:logcatFormat": "time",
[debug] [BaseDriver]     "appium:logcatFilterSpecs": [
[debug] [BaseDriver]       "*:E"
[debug] [BaseDriver]     ],
[debug] [BaseDriver]     "appium:clearDeviceLogsOnStart": true,
[debug] [BaseDriver]     "appium:showChromedriverLog": true,
[debug] [BaseDriver]     "appium:chromeOptions": {
[debug] [BaseDriver]       "w3c": false
[debug] [BaseDriver]     }
[debug] [BaseDriver]   },
[debug] [BaseDriver]   "firstMatch": [
[debug] [BaseDriver]     {}
[debug] [BaseDriver]   ]
[debug] [BaseDriver] }
[BaseDriver] Session created with session id: 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[UiAutomator2] Starting 'com.picc.mcp' directly on the device
[ADB] Found 1 'build-tools' folders under 'D:\aa\SDK' (newest first):
[ADB]     D:/aa/SDK/build-tools/30.0.3
[ADB] Using 'adb.exe' from 'D:\aa\SDK\platform-tools\adb.exe'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 start-server'
[AndroidDriver] Retrieving device list
[debug] [ADB] Trying to find a connected android device
[debug] [ADB] Getting connected devices
[debug] [ADB] Connected devices: [{"udid":"GPG4C19619002744","state":"device"}]
[AndroidDriver] Using device: GPG4C19619002744
[ADB] Using 'adb.exe' from 'D:\aa\SDK\platform-tools\adb.exe'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 start-server'
[debug] [ADB] Setting device id to GPG4C19619002744
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell getprop ro.build.version.sdk'
[debug] [ADB] Current device property 'ro.build.version.sdk': 29
[ADB] Getting device platform version
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell getprop ro.build.version.release'
[debug] [ADB] Current device property 'ro.build.version.release': 10
[debug] [ADB] Device API level: 29
[UiAutomator2] Relaxing hidden api policy
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell 'settings put global hidden_api_policy_pre_p_apps 1;settings put global hidden_api_policy_p_apps 1;settings put global hidden_api_policy 1''
[AndroidDriver] No app sent in, not parsing package/activity
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 wait-for-device'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell echo ping'
[debug] [AndroidDriver] Pushing settings apk to device...
[debug] [ADB] Getting install status for io.appium.settings
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys package io.appium.settings'
[debug] [ADB] 'io.appium.settings' is installed
[debug] [ADB] Getting package info for 'io.appium.settings'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys package io.appium.settings'
[debug] [ADB] The version name of the installed 'io.appium.settings' is greater or equal to the application version name ('3.4.0' >= '3.4.0')
[debug] [ADB] There is no need to install/upgrade 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\io.appium.settings\apks\settings_apk-debug.apk'
[debug] [ADB] Getting IDs of all 'io.appium.settings' processes
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell 'pgrep --help; echo $?''
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell pgrep -f \(\[\[:blank:\]\]\|\^\)io\.appium\.settings\(\[\[:blank:\]\]\|\$\)'
[debug] [AndroidDriver] io.appium.settings is already running. There is no need to reset its permissions.
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell appops set io.appium.settings android:mock_location allow'
[debug] [Logcat] Clearing logcat logs from device
[debug] [Logcat] Starting logs capture with command: D:\\aa\\SDK\\platform-tools\\adb.exe -P 5037 -s GPG4C19619002744 logcat -v time \*\:E
[debug] [AndroidDriver] Enabling Unicode keyboard support
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell settings get secure default_input_method'
[debug] [AndroidDriver] Unsetting previous IME io.appium.settings/.UnicodeIME
[debug] [AndroidDriver] Setting IME to 'io.appium.settings/.UnicodeIME'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell ime enable io.appium.settings/.UnicodeIME'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell ime set io.appium.settings/.UnicodeIME'
[debug] [UiAutomator2] Forwarding UiAutomator2 Server port 6790 to local port 8200
[debug] [ADB] Forwarding system: 8200 to device: 6790
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 forward tcp:8200 tcp:6790'
[debug] [ADB] Getting install status for io.appium.uiautomator2.server
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys package io.appium.uiautomator2.server'
[debug] [ADB] 'io.appium.uiautomator2.server' is installed
[debug] [ADB] Getting package info for 'io.appium.uiautomator2.server'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys package io.appium.uiautomator2.server'
[debug] [ADB] The version name of the installed 'io.appium.uiautomator2.server' is greater or equal to the application version name ('4.24.0' >= '4.24.0')
[debug] [UiAutomator2] io.appium.uiautomator2.server installation state: sameVersionInstalled
[debug] [ADB] Checking app cert for C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.24.0.apk
[ADB] Using 'apksigner.jar' from 'D:\aa\SDK\build-tools\30.0.3\lib\apksigner.jar'
[debug] [ADB] Starting apksigner: 'C:\\Program Files\\Java\\jdk1.8.0_201\\bin\\java.exe' -Xmx1024M -Xss1m -jar D:\\aa\\SDK\\build-tools\\30.0.3\\lib\\apksigner.jar verify --print-certs C:\\Users\\admin\\AppData\\Roaming\\npm\\node_modules\\appium\\node_modules\\appium-uiautomator2-server\\apks\\appium-uiautomator2-server-v4.24.0.apk
[debug] [ADB] apksigner stdout: Signer #1 certificate DN: EMAILADDRESS=android@android.com, CN=Android, OU=Android, O=Android, L=Mountain View, ST=California, C=US

[debug] [ADB] Signer #1 certificate SHA-256 digest: a40da80a59d170caa950cf15c18c454d47a39b26989d8b640ecd745ba71bf5dc

[debug] [ADB] Signer #1 certificate SHA-1 digest: 61ed377e85d386a8dfee6b864bd85b0bfaa5af81

[debug] [ADB] Signer #1 certificate MD5 digest: e89b158e4bcf988ebd09eb83f5378e87

[debug] [ADB] 
[debug] [ADB] sha256 hash did match for 'appium-uiautomator2-server-v4.24.0.apk'
[ADB] 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.24.0.apk' is signed with the default certificate
[debug] [ADB] Getting install status for io.appium.uiautomator2.server.test
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys package io.appium.uiautomator2.server.test'
[debug] [ADB] 'io.appium.uiautomator2.server.test' is installed
[debug] [ADB] Checking app cert for C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk
[debug] [ADB] Starting apksigner: 'C:\\Program Files\\Java\\jdk1.8.0_201\\bin\\java.exe' -Xmx1024M -Xss1m -jar D:\\aa\\SDK\\build-tools\\30.0.3\\lib\\apksigner.jar verify --print-certs C:\\Users\\admin\\AppData\\Roaming\\npm\\node_modules\\appium\\node_modules\\appium-uiautomator2-server\\apks\\appium-uiautomator2-server-debug-androidTest.apk
[debug] [ADB] apksigner stdout: Signer #1 certificate DN: EMAILADDRESS=android@android.com, CN=Android, OU=Android, O=Android, L=Mountain View, ST=California, C=US

[debug] [ADB] Signer #1 certificate SHA-256 digest: a40da80a59d170caa950cf15c18c454d47a39b26989d8b640ecd745ba71bf5dc

[debug] [ADB] Signer #1 certificate SHA-1 digest: 61ed377e85d386a8dfee6b864bd85b0bfaa5af81

[debug] [ADB] Signer #1 certificate MD5 digest: e89b158e4bcf988ebd09eb83f5378e87

[debug] [ADB] 
[debug] [ADB] sha256 hash did match for 'appium-uiautomator2-server-debug-androidTest.apk'
[ADB] 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk' is signed with the default certificate
[UiAutomator2] Server packages are not going to be (re)installed
[debug] [UiAutomator2] Waiting up to 30000ms for services to be available
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell pm list instrumentation'
[debug] [UiAutomator2] Instrumentation target 'io.appium.uiautomator2.server.test/androidx.test.runner.AndroidJUnitRunner' is available
[ADB] Adding packages ["io.appium.settings","io.appium.uiautomator2.server","io.appium.uiautomator2.server.test"] to Doze whitelist
[debug] [ADB] Got the following command chunks to execute: [["dumpsys","deviceidle","whitelist","+io.appium.settings",";","dumpsys","deviceidle","whitelist","+io.appium.uiautomator2.server",";","dumpsys","deviceidle","whitelist","+io.appium.uiautomator2.server.test",";"]]
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys deviceidle whitelist +io.appium.settings ; dumpsys deviceidle whitelist +io.appium.uiautomator2.server ; dumpsys deviceidle whitelist +io.appium.uiautomator2.server.test ;'
[debug] [UiAutomator2] No app capability. Assuming it is already on the device
[debug] [UiAutomator2] Performing shallow cleanup of automation leftovers
[debug] [UiAutomator2] No obsolete sessions have been detected (socket hang up)
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell am force-stop io.appium.uiautomator2.server.test'
[UiAutomator2] Starting UIAutomator2 server 4.24.0
[UiAutomator2] Using UIAutomator2 server from 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.24.0.apk' and test from 'C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk'
[UiAutomator2] Waiting up to 30000ms for UiAutomator2 to be online...
[debug] [ADB] Creating ADB subprocess with args: ["-P",5037,"-s","GPG4C19619002744","shell","am","instrument","-w","-e","disableAnalytics",true,"io.appium.uiautomator2.server.test/androidx.test.runner.AndroidJUnitRunner"]
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8200/wd/hub/status] with no body
[WD Proxy] socket hang up
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8200/wd/hub/status] with no body
[WD Proxy] socket hang up
[debug] [Instrumentation] io.appium.uiautomator2.server.test.AppiumUiAutomator2Server:
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8200/wd/hub/status] with no body
[WD Proxy] socket hang up
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8200/wd/hub/status] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"None","value":{"message":"UiAutomator2 Server is ready to accept commands","ready":true}}
[debug] [UiAutomator2] The initialization of the instrumentation process took 3298ms
[debug] [WD Proxy] Matched '/session' to command name 'createSession'
[debug] [WD Proxy] Proxying [POST /session] to [POST http://127.0.0.1:8200/wd/hub/session] with body: {"capabilities":{"firstMatch":[{"platform":"LINUX","webStorageEnabled":false,"takesScreenshot":true,"javascriptEnabled":true,"databaseEnabled":false,"networkConnectionEnabled":true,"locationContextEnabled":false,"warnings":{},"desired":{"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"showChromedriverLog":true,"chromeOptions":{"w3c":false}},"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"showChromedriverLog":true,"chromeOptions":{"w3c":false},"deviceName":"GPG4C19619002744","deviceUDID":"GPG4C19619002744"}],"alwaysMatch":{}}}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"1b78bcae-293e-44c8-a79f-84a2318220c3","value":{"capabilities":{"firstMatch":[{"platform":"LINUX","webStorageEnabled":false,"takesScreenshot":true,"javascriptEnabled":true,"databaseEnabled":false,"networkConnectionEnabled":true,"locationContextEnabled":false,"warnings":{},"desired":{"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"showChromedriverLog":true,"chromeOptions":{"w3c":false}},"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"showChromedriverLog":true,"chromeOptions":{"w3c":false},"deviceName":"GPG4C19619002744","...
[WD Proxy] Determined the downstream protocol as 'W3C'
[debug] [WD Proxy] Proxying [GET /appium/device/info] to [GET http://127.0.0.1:8200/wd/hub/session/1b78bcae-293e-44c8-a79f-84a2318220c3/appium/device/info] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"1b78bcae-293e-44c8-a79f-84a2318220c3","value":{"androidId":"6e49637b773bd7af","apiVersion":"29","bluetooth":{"state":"OFF"},"brand":"HUAWEI","carrierName":"中国电信","displayDensity":480,"locale":"zh_CN_#Hans","manufacturer":"HUAWEI","model":"VCE-AL00","networks":[{"capabilities":{"SSID":null,"linkDownBandwidthKbps":1048576,"linkUpstreamBandwidthKbps":1048576,"networkCapabilities":"NET_CAPABILITY_NOT_METERED,NET_CAPABILITY_INTERNET,NET_CAPABILITY_NOT_RESTRICTED,NET_CAPABILITY_TRUSTED,NET_CAPABILITY_NOT_VPN,NET_CAPABILITY_NOT_ROAMING,NET_CAPABILITY_FOREGROUND,NET_CAPABILITY_NOT_CONGESTED,NET_CAPABILITY_NOT_SUSPENDED","signalStrength":-48,"transportTypes":"TRANSPORT_WIFI"},"detailedState":"CONNECTED","extraInfo":null,"isAvailable":true,"isConnected":true,"isFailover":false,"isRoaming":false,"state":"CONNECTED","subtype":0,"subtypeName":"","type":1,"typeName":"WIFI"}],"platformVersion":"10","realDisplaySize":"1080x2310","timeZone":"Asia/Shanghai"}}
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell dumpsys window'
[AndroidDriver] Screen already unlocked, doing nothing
[UiAutomator2] Starting 'com.picc.mcp/com.picc.mcp.IndexVideoActivity and waiting for 'com.picc.mcp/com.picc.mcp.IndexVideoActivity'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell am start -W -n com.picc.mcp/com.picc.mcp.IndexVideoActivity -S -a android.intent.action.MAIN -c android.intent.category.LAUNCHER -f 0x10200000'
[debug] [WD Proxy] Proxying [GET /appium/device/pixel_ratio] to [GET http://127.0.0.1:8200/wd/hub/session/1b78bcae-293e-44c8-a79f-84a2318220c3/appium/device/pixel_ratio] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"1b78bcae-293e-44c8-a79f-84a2318220c3","value":3}
[debug] [WD Proxy] Matched '/appium/device/system_bars' to command name 'getSystemBars'
[debug] [WD Proxy] Proxying [GET /appium/device/system_bars] to [GET http://127.0.0.1:8200/wd/hub/session/1b78bcae-293e-44c8-a79f-84a2318220c3/appium/device/system_bars] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"1b78bcae-293e-44c8-a79f-84a2318220c3","value":{"statusBar":102}}
[debug] [WD Proxy] Matched '/window/current/size' to command name 'getWindowSize'
[debug] [WD Proxy] Proxying [GET /window/current/size] to [GET http://127.0.0.1:8200/wd/hub/session/1b78bcae-293e-44c8-a79f-84a2318220c3/window/current/size] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"1b78bcae-293e-44c8-a79f-84a2318220c3","value":{"height":2090,"width":1080}}
[Appium] New AndroidUiautomator2Driver session created successfully, session 5e0d7962-7781-4d80-aed0-78fd1beb4e1a added to master session list
[debug] [BaseDriver] Event 'newSessionStarted' logged at 1698371978726 (09:59:38 GMT+0800 (中国标准时间))
[debug] [W3C (5e0d7962)] Cached the protocol value 'W3C' for the new session 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[debug] [W3C (5e0d7962)] Responding to client with driver.createSession() result: {"capabilities":{"platform":"LINUX","webStorageEnabled":false,"takesScreenshot":true,"javascriptEnabled":true,"databaseEnabled":false,"networkConnectionEnabled":true,"locationContextEnabled":false,"warnings":{},"desired":{"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"showChromedriverLog":true,"chromeOptions":{"w3c":false}},"platformName":"Android","appPackage":"com.picc.mcp","appActivity":"com.picc.mcp.IndexVideoActivity","noReset":true,"unicodeKeyboard":true,"resetKeyboard":true,"newCommandTimeout":180,"adbExecTimeout":180000,"logcatFormat":"time","logcatFilterSpecs":["*:E"],"clearDeviceLogsOnStart":true,"showChromedriverLog":true,"chromeOptions":{"w3c":false},"deviceName":"GPG4C19619002744","deviceUDID":"GPG4C19619002744","deviceApiLevel":29,"platformVersion":"10","...
[HTTP] <-- POST /wd/hub/session 200 15910 ms - 1292
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/timeouts
[HTTP] {"implicit":20000}
[debug] [W3C (5e0d7962)] Calling AppiumDriver.timeouts() with args: [null,null,null,null,20000,"5e0d7962-7781-4d80-aed0-78fd1beb4e1a"]
[debug] [BaseDriver] W3C timeout argument: {"implicit":20000}}
[debug] [BaseDriver] Set implicit wait to 20000ms
[debug] [W3C (5e0d7962)] Responding to client with driver.timeouts() result: null
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/timeouts 200 7 ms - 14
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element
[HTTP] {"using":"xpath","value":"//android.view.View[@text=\"parameterSettings.html?returnUrl=login\"]"}
[debug] [W3C (5e0d7962)] Calling AppiumDriver.findElement() with args: ["xpath","//android.view.View[@text=\"parameterSettings.html?returnUrl=login\"]","5e0d7962-7781-4d80-aed0-78fd1beb4e1a"]
[debug] [BaseDriver] Valid locator strategies for this request: xpath, id, class name, accessibility id, css selector, -android uiautomator
[debug] [BaseDriver] Waiting up to 20000 ms for condition
[debug] [WD Proxy] Matched '/element' to command name 'findElement'
[debug] [WD Proxy] Proxying [POST /element] to [POST http://127.0.0.1:8200/wd/hub/session/1b78bcae-293e-44c8-a79f-84a2318220c3/element] with body: {"strategy":"xpath","selector":"//android.view.View[@text=\"parameterSettings.html?returnUrl=login\"]","context":"","multiple":false}
[WD Proxy] Got response with status 404: {"sessionId":"1b78bcae-293e-44c8-a79f-84a2318220c3","value":{"error":"no such element","message":"An element could not be located on the page using the given search parameters","stacktrace":"io.appium.uiautomator2.common.exceptions.ElementNotFoundException: An element could not be located on the page using the given search parameters\n\tat io.appium.uiautomator2.handler.FindElement.findElement(FindElement.java:90)\n\tat io.appium.uiautomator2.handler.FindElement.safeHandle(FindElement.java:67)\n\tat io.appium.uiautomator2.handler.request.SafeRequestHandler.handle(SafeRequestHandler.java:59)\n\tat io.appium.uiautomator2.server.AppiumServlet.handleRequest(AppiumServlet.java:264)\n\tat io.appium.uiautomator2.server.AppiumServlet.handleHttpRequest(AppiumServlet.java:258)\n\tat io.appium.uiautomator2.http.ServerHandler.channelRead(ServerHandler.java:68)\n\tat io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:366)\n\tat io.netty.channel.AbstractChannelHandlerCont...
[debug] [W3C] Matched W3C error code 'no such element' to NoSuchElementError
[debug] [BaseDriver] Waited for 516 ms so far
[debug] [WD Proxy] Matched '/element' to command name 'findElement'
[debug] [WD Proxy] Proxying [POST /element] to [POST http://127.0.0.1:8200/wd/hub/session/1b78bcae-293e-44c8-a79f-84a2318220c3/element] with body: {"strategy":"xpath","selector":"//android.view.View[@text=\"parameterSettings.html?returnUrl=login\"]","context":"","multiple":false}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"1b78bcae-293e-44c8-a79f-84a2318220c3","value":{"ELEMENT":"00000000-0000-001b-0000-002500000012","element-6066-11e4-a52e-4f735466cecf":"00000000-0000-001b-0000-002500000012"}}
[debug] [W3C (5e0d7962)] Responding to client with driver.findElement() result: {"element-6066-11e4-a52e-4f735466cecf":"00000000-0000-001b-0000-002500000012","ELEMENT":"00000000-0000-001b-0000-002500000012"}
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element 200 1689 ms - 137
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/00000000-0000-001b-0000-002500000012/click
[HTTP] {"id":"00000000-0000-001b-0000-002500000012"}
[debug] [W3C (5e0d7962)] Calling AppiumDriver.click() with args: ["00000000-0000-001b-0000-002500000012","5e0d7962-7781-4d80-aed0-78fd1beb4e1a"]
[debug] [WD Proxy] Matched '/element/00000000-0000-001b-0000-002500000012/click' to command name 'click'
[debug] [WD Proxy] Proxying [POST /element/00000000-0000-001b-0000-002500000012/click] to [POST http://127.0.0.1:8200/wd/hub/session/1b78bcae-293e-44c8-a79f-84a2318220c3/element/00000000-0000-001b-0000-002500000012/click] with body: {"element":"00000000-0000-001b-0000-002500000012"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"1b78bcae-293e-44c8-a79f-84a2318220c3","value":null}
[debug] [W3C (5e0d7962)] Responding to client with driver.click() result: null
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/00000000-0000-001b-0000-002500000012/click 200 467 ms - 14
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/context
[HTTP] {"name":"WEBVIEW_com.picc.mcp"}
[debug] [W3C (5e0d7962)] Calling AppiumDriver.setContext() with args: ["WEBVIEW_com.picc.mcp","5e0d7962-7781-4d80-aed0-78fd1beb4e1a"]
[debug] [AndroidDriver] Getting a list of available webviews
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell cat /proc/net/unix'
[debug] [AndroidDriver] Parsed 1 active devtools socket: ["@webview_devtools_remote_15874"]
[debug] [AndroidDriver] Collecting CDP data of 1 webview
[debug] [AndroidDriver] Forwarding remote port webview_devtools_remote_15874 to a local port in range 10900..11000
[debug] [AndroidDriver] You could use the 'webviewDevtoolsPort' capability to customize the starting port number
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 forward tcp:10900 localabstract:webview_devtools_remote_15874'
[debug] [ADB] Removing forwarded port socket connection: 10900 
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 forward --remove tcp:10900'
[debug] [AndroidDriver] CDP data collection completed
[debug] [AndroidDriver] WEBVIEW_15874 mapped to pid 15874
[debug] [AndroidDriver] Getting process name for webview 'WEBVIEW_15874'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell ps --help'
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 shell ps -A'
[debug] [AndroidDriver] Got process name: 'com.picc.mcp'
[debug] [AndroidDriver] Found 1 webview: ["WEBVIEW_com.picc.mcp"]
[debug] [AndroidDriver] Available contexts: ["NATIVE_APP","WEBVIEW_com.picc.mcp"]
[debug] [AndroidDriver] Connecting to chrome-backed webview context 'WEBVIEW_com.picc.mcp'
[debug] [AndroidDriver] A port was not given, using random free port: 8000
[debug] [AndroidDriver] Passing web view details to the Chromedriver constructor: {
[debug] [AndroidDriver]   "info": {
[debug] [AndroidDriver]     "Android-Package": "com.picc.mcp",
[debug] [AndroidDriver]     "Browser": "Chrome/81.0.4044.138",
[debug] [AndroidDriver]     "Protocol-Version": "1.3",
[debug] [AndroidDriver]     "User-Agent": "Mozilla/5.0 (Linux; Android 10; VCE-AL00 Build/HUAWEIVCE-AL00; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/81.0.4044.138 Mobile Safari/537.36",
[debug] [AndroidDriver]     "V8-Version": "8.1.307.32",
[debug] [AndroidDriver]     "WebKit-Version": "537.36 (@8c6c7ba89cc9453625af54f11fd83179e23450fa)",
[debug] [AndroidDriver]     "webSocketDebuggerUrl": "ws://127.0.0.1:10900/devtools/browser"
[debug] [AndroidDriver]   },
[debug] [AndroidDriver]   "process": {
[debug] [AndroidDriver]     "name": "com.picc.mcp",
[debug] [AndroidDriver]     "id": "15874"
[debug] [AndroidDriver]   }
[debug] [AndroidDriver] }
[debug] [AndroidDriver] Precalculated Chromedriver capabilities: {
[debug] [AndroidDriver]   "androidPackage": "com.picc.mcp",
[debug] [AndroidDriver]   "androidUseRunningApp": true,
[debug] [AndroidDriver]   "androidProcess": "com.picc.mcp",
[debug] [AndroidDriver]   "androidDeviceSerial": "GPG4C19619002744"
[debug] [AndroidDriver] }
[debug] [AndroidDriver] Before starting chromedriver, androidPackage is 'com.picc.mcp'
[debug] [Chromedriver] Changed state to 'starting'
[Chromedriver] Set chromedriver binary as: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe
[debug] [Chromedriver] Killing any old chromedrivers, running: wmic process where "commandline like '%chromedriver.exe%--port=8000%'" delete
[debug] [Chromedriver] Successfully cleaned up old chromedrivers
[debug] [Chromedriver] Cleaning this device's adb forwarded port socket connections: GPG4C19619002744
[debug] [ADB] List forwarding ports
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 forward --list'
[debug] [ADB] Removing forwarded port socket connection: 53189 
[debug] [ADB] Running 'D:\aa\SDK\platform-tools\adb.exe -P 5037 -s GPG4C19619002744 forward --remove tcp:53189'
[Chromedriver] Spawning chromedriver with: D:\aa\chromedriver_win3281.0.4044.138\chromedriver_win3281.0.4044.138.exe --url-base=wd/hub --port=8000 --adb-port=5037 --verbose
[debug] [Chromedriver] Chromedriver version: '81.0.4044.138'
[Chromedriver] Chromedriver v. 81.0.4044.138 supports W3C protocol, but MJSONWP one has been explicitly requested
[debug] [Chromedriver] [STDOUT] Starting ChromeDriver 81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}) on port 8000

[debug] [Chromedriver] [STDOUT] Only local connections are allowed.

[debug] [Chromedriver] [STDOUT] Please protect ports used by ChromeDriver and related test frameworks to prevent access by malicious code.
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8000/wd/hub/status] with no body
[WD Proxy] connect ECONNREFUSED 127.0.0.1:8000
[debug] [WD Proxy] Matched '/status' to command name 'getStatus'
[debug] [WD Proxy] Proxying [GET /status] to [GET http://127.0.0.1:8000/wd/hub/status] with no body
[debug] [WD Proxy] Got response with status 200: {"value":{"build":{"version":"81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999})"},"message":"ChromeDriver ready for new sessions.","os":{"arch":"x86_64","name":"Windows NT","version":"10.0.19045"},"ready":true}}
[Chromedriver] Starting MJSONWP Chromedriver session with capabilities: {
[Chromedriver]   "desiredCapabilities": {
[Chromedriver]     "chromeOptions": {
[Chromedriver]       "androidPackage": "com.picc.mcp",
[Chromedriver]       "androidUseRunningApp": true,
[Chromedriver]       "androidProcess": "com.picc.mcp",
[Chromedriver]       "androidDeviceSerial": "GPG4C19619002744",
[Chromedriver]       "w3c": false
[Chromedriver]     },
[Chromedriver]     "loggingPrefs": {
[Chromedriver]       "browser": "ALL"
[Chromedriver]     }
[Chromedriver]   }
[Chromedriver] }
[debug] [WD Proxy] Matched '/session' to command name 'createSession'
[debug] [WD Proxy] Proxying [POST /session] to [POST http://127.0.0.1:8000/wd/hub/session] with body: {"desiredCapabilities":{"chromeOptions":{"androidPackage":"com.picc.mcp","androidUseRunningApp":true,"androidProcess":"com.picc.mcp","androidDeviceSerial":"GPG4C19619002744","w3c":false},"loggingPrefs":{"browser":"ALL"}}}
[debug] [Chromedriver] Webview version: 'Chrome/81.0.4044.138'
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":0,"value":{"acceptInsecureCerts":false,"acceptSslCerts":false,"applicationCacheEnabled":false,"browserConnectionEnabled":false,"browserName":"chrome","chrome":{"chromedriverVersion":"81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999})"},"cssSelectorsEnabled":true,"databaseEnabled":false,"goog:chromeOptions":{"debuggerAddress":"localhost:53622"},"handlesAlerts":true,"hasTouchScreen":true,"javascriptEnabled":true,"locationContextEnabled":true,"mobileEmulationEnabled":false,"nativeEvents":true,"pageLoadStrategy":"normal","platform":"ANDROID","proxy":{},"rotatable":false,"setWindowRect":false,"strictFileInteractability":false,"takesHeapSnapshot":true,"takesScreenshot":true,"timeouts":{"implicit":0,"pageLoad":300000,"script":30000},"unexpectedAlertBehaviour":"ignore","version":"81.0.4044.138","webStorageEnabled":true,"webauthn:virtualAuthenticators":false}}
[WD Proxy] Determined the downstream protocol as 'MJSONWP'
[debug] [Chromedriver] Changed state to 'online'
[debug] [W3C (5e0d7962)] Responding to client with driver.setContext() result: null
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/context 200 6063 ms - 14
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/timeouts
[HTTP] {"implicit":20000}
[W3C (5e0d7962)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/timeouts' to command name 'timeouts'
[debug] [Protocol Converter] Will send the following request bodies to /timeouts: [{"type":"implicit","ms":20000}]
[debug] [WD Proxy] Proxying [POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/timeouts] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/timeouts] with body: {"type":"implicit","ms":20000}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":0,"value":null}
[WD Proxy] Replacing sessionId 5d2f44f57c6a1df7d6ab498319eb9a46 with 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/timeouts 200 13 ms - 65
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element
[HTTP] {"using":"id","value":"masterServer1"}
[W3C (5e0d7962)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element' to command name 'findElement'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/element] with body: {"using":"id","value":"masterServer1"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":0,"value":{"ELEMENT":"0.47396339724855663-1"}}
[WD Proxy] Replacing sessionId 5d2f44f57c6a1df7d6ab498319eb9a46 with 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element 200 282 ms - 158
[HTTP] 
[HTTP] --> GET /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/attribute/value
[HTTP] {}
[W3C (5e0d7962)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/attribute/value' to command name 'getAttribute'
[debug] [WD Proxy] Proxying [GET /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/attribute/value] to [GET http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/element/0.47396339724855663-1/attribute/value] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":0,"value":"10.22.64.173"}
[WD Proxy] Replacing sessionId 5d2f44f57c6a1df7d6ab498319eb9a46 with 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[HTTP] <-- GET /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/attribute/value 200 83 ms - 75
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value
[HTTP] {"text":"a","value":["","a"],"id":"0.47396339724855663-1"}
[W3C (5e0d7962)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value' to command name 'setValue'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/element/0.47396339724855663-1/value] with body: {"text":"a","value":["","a"],"id":"0.47396339724855663-1"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":0,"value":null}
[WD Proxy] Replacing sessionId 5d2f44f57c6a1df7d6ab498319eb9a46 with 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value 200 529 ms - 65
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value
[HTTP] {"text":"x","value":["","x"],"id":"0.47396339724855663-1"}
[W3C (5e0d7962)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value' to command name 'setValue'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/element/0.47396339724855663-1/value] with body: {"text":"x","value":["","x"],"id":"0.47396339724855663-1"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":0,"value":null}
[WD Proxy] Replacing sessionId 5d2f44f57c6a1df7d6ab498319eb9a46 with 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value 200 249 ms - 65
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value
[HTTP] {"text":"10.22.64.243","value":["1","0",".","2","2",".","6","4",".","2","4","3"],"id":"0.47396339724855663-1"}
[W3C (5e0d7962)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value' to command name 'setValue'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/element/0.47396339724855663-1/value] with body: {"text":"10.22.64.243","value":["1","0",".","2","2",".","6","4",".","2","4","3"],"id":"0.47396339724855663-1"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":0,"value":null}
[WD Proxy] Replacing sessionId 5d2f44f57c6a1df7d6ab498319eb9a46 with 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-1/value 200 1511 ms - 65
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element
[HTTP] {"using":"id","value":"port"}
[W3C (5e0d7962)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element' to command name 'findElement'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/element] with body: {"using":"id","value":"port"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":0,"value":{"ELEMENT":"0.47396339724855663-3"}}
[WD Proxy] Replacing sessionId 5d2f44f57c6a1df7d6ab498319eb9a46 with 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element 200 90 ms - 158
[HTTP] 
[HTTP] --> GET /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-3/attribute/value
[HTTP] {}
[W3C (5e0d7962)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-3/attribute/value' to command name 'getAttribute'
[debug] [WD Proxy] Proxying [GET /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-3/attribute/value] to [GET http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/element/0.47396339724855663-3/attribute/value] with no body
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":0,"value":"8005"}
[WD Proxy] Replacing sessionId 5d2f44f57c6a1df7d6ab498319eb9a46 with 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[HTTP] <-- GET /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element/0.47396339724855663-3/attribute/value 200 68 ms - 67
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element
[HTTP] {"using":"xpath","value":"//a[contains(@href,\"com.picc.mcp/files/mcph5/login.html\")]"}
[W3C (5e0d7962)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element' to command name 'findElement'
[debug] [WD Proxy] Proxying [POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/element] with body: {"using":"xpath","value":"//a[contains(@href,\"com.picc.mcp/files/mcph5/login.html\")]"}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":0,"value":{"ELEMENT":"0.47396339724855663-4"}}
[WD Proxy] Replacing sessionId 5d2f44f57c6a1df7d6ab498319eb9a46 with 5e0d7962-7781-4d80-aed0-78fd1beb4e1a
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/element 200 119 ms - 158
[HTTP] 
[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/execute/sync
[HTTP] {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}]}
[debug] [W3C (5e0d7962)] Calling AppiumDriver.execute() with args: ["return arguments[0].scrollIntoView(true);",[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}],"5e0d7962-7781-4d80-aed0-78fd1beb4e1a"]
[debug] [WD Proxy] Matched '/execute' to command name 'execute'
[debug] [Protocol Converter] Did not know how to rewrite the original URL '/execute' for MJSONWP protocol
[debug] [WD Proxy] Proxying [POST /execute] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/execute] with body: {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}]}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":17,"value":{"message":"javascript error: arguments[0].scrollIntoView is not a function\n  (Session info: chrome=81.0.4044.138)\n  (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)"}}
[debug] [MJSONWP] Matched JSONWP error code 17 to JavaScriptError
[debug] [W3C (5e0d7962)] Encountered internal error running command: JavaScriptError: javascript error: arguments[0].scrollIntoView is not a function
[debug] [W3C (5e0d7962)]   (Session info: chrome=81.0.4044.138)
[debug] [W3C (5e0d7962)]   (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)
[debug] [W3C (5e0d7962)]     at errorFromMJSONWPStatusCode (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:764:12)
[debug] [W3C (5e0d7962)]     at ProxyRequestError.getActualError (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:661:14)
[debug] [W3C (5e0d7962)]     at JWProxy.command (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\jsonwp-proxy\proxy.js:272:19)
[debug] [W3C (5e0d7962)]     at runMicrotasks (<anonymous>)
[debug] [W3C (5e0d7962)]     at processTicksAndRejections (internal/process/task_queues.js:93:5)
[debug] [W3C (5e0d7962)]     at AndroidUiautomator2Driver.execute (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-android-driver\lib\commands\execute.js:19:10)
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/execute/sync 500 206 ms - 1383
[HTTP] 
KazuCocoa commented 1 year ago

Hm, as the below error, the error itself came from chromedriver v81, not Appium own implementation.

[HTTP] --> POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/execute/sync
[HTTP] {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}]}
[debug] [W3C (5e0d7962)] Calling AppiumDriver.execute() with args: ["return arguments[0].scrollIntoView(true);",[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}],"5e0d7962-7781-4d80-aed0-78fd1beb4e1a"]
[debug] [WD Proxy] Matched '/execute' to command name 'execute'
[debug] [Protocol Converter] Did not know how to rewrite the original URL '/execute' for MJSONWP protocol
[debug] [WD Proxy] Proxying [POST /execute] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/execute] with body: {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}]}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":17,"value":{"message":"javascript error: arguments[0].scrollIntoView is not a function\n  (Session info: chrome=81.0.4044.138)\n  (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)"}}
[debug] [MJSONWP] Matched JSONWP error code 17 to JavaScriptError
[debug] [W3C (5e0d7962)] Encountered internal error running command: JavaScriptError: javascript error: arguments[0].scrollIntoView is not a function
[debug] [W3C (5e0d7962)]   (Session info: chrome=81.0.4044.138)
[debug] [W3C (5e0d7962)]   (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)
[debug] [W3C (5e0d7962)]     at errorFromMJSONWPStatusCode (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:764:12)
[debug] [W3C (5e0d7962)]     at ProxyRequestError.getActualError (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:661:14)
[debug] [W3C (5e0d7962)]     at JWProxy.command (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\jsonwp-proxy\proxy.js:272:19)
[debug] [W3C (5e0d7962)]     at runMicrotasks (<anonymous>)
[debug] [W3C (5e0d7962)]     at processTicksAndRejections (internal/process/task_queues.js:93:5)
[debug] [W3C (5e0d7962)]     at AndroidUiautomator2Driver.execute (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-android-driver\lib\commands\execute.js:19:10)
[HTTP] <-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/execute/sync 500 206 ms - 1383

why does scrollIntoView not report this error when running in selenium, but when executing in appium.

Have you run chrome v81 for selenium as well? Newer Chrome such as v118 as recent versions are quit new, so such newer one may have fixes.

tianyao1111 commented 1 year ago

Hm, as the below error, the error itself came from chromedriver v81, not Appium own implementation.

�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/execute/sync�[39m
�[35m[HTTP]�[39m �[90m{"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}]}�[39m
[debug] �[35m[W3C (5e0d7962)]�[39m Calling AppiumDriver.execute() with args: ["return arguments[0].scrollIntoView(true);",[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}],"5e0d7962-7781-4d80-aed0-78fd1beb4e1a"]
[debug] �[35m[WD Proxy]�[39m Matched '/execute' to command name 'execute'
[debug] �[35m[Protocol Converter]�[39m Did not know how to rewrite the original URL '/execute' for MJSONWP protocol
[debug] �[35m[WD Proxy]�[39m Proxying [POST /execute] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/execute] with body: {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}]}
[debug] �[35m[WD Proxy]�[39m Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":17,"value":{"message":"javascript error: arguments[0].scrollIntoView is not a function\n  (Session info: chrome=81.0.4044.138)\n  (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)"}}
[debug] �[35m[MJSONWP]�[39m Matched JSONWP error code 17 to JavaScriptError
[debug] �[35m[W3C (5e0d7962)]�[39m Encountered internal error running command: JavaScriptError: javascript error: arguments[0].scrollIntoView is not a function
[debug] �[35m[W3C (5e0d7962)]�[39m   (Session info: chrome=81.0.4044.138)
[debug] �[35m[W3C (5e0d7962)]�[39m   (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)
[debug] �[35m[W3C (5e0d7962)]�[39m     at errorFromMJSONWPStatusCode (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:764:12)
[debug] �[35m[W3C (5e0d7962)]�[39m     at ProxyRequestError.getActualError (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:661:14)
[debug] �[35m[W3C (5e0d7962)]�[39m     at JWProxy.command (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\jsonwp-proxy\proxy.js:272:19)
[debug] �[35m[W3C (5e0d7962)]�[39m     at runMicrotasks (<anonymous>)
[debug] �[35m[W3C (5e0d7962)]�[39m     at processTicksAndRejections (internal/process/task_queues.js:93:5)
[debug] �[35m[W3C (5e0d7962)]�[39m     at AndroidUiautomator2Driver.execute (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-android-driver\lib\commands\execute.js:19:10)
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/execute/sync �[39m�[31m500�[39m �[90m206 ms - 1383�[39m

why does scrollIntoView not report this error when running in selenium, but when executing in appium.

Have you run chrome v81 for selenium as well? Newer Chrome such as v118 as recent versions are quit new, so such newer one may have fixes. We haven't run selenium with Chrome v81, we're using the latest one. Let's give it a try, Chrome v81 runs selenium. Thank you for your patient answer!

tianyao1111 commented 1 year ago

Hm, as the below error, the error itself came from chromedriver v81, not Appium own implementation.

�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/execute/sync�[39m
�[35m[HTTP]�[39m �[90m{"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}]}�[39m
[debug] �[35m[W3C (5e0d7962)]�[39m Calling AppiumDriver.execute() with args: ["return arguments[0].scrollIntoView(true);",[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}],"5e0d7962-7781-4d80-aed0-78fd1beb4e1a"]
[debug] �[35m[WD Proxy]�[39m Matched '/execute' to command name 'execute'
[debug] �[35m[Protocol Converter]�[39m Did not know how to rewrite the original URL '/execute' for MJSONWP protocol
[debug] �[35m[WD Proxy]�[39m Proxying [POST /execute] to [POST http://127.0.0.1:8000/wd/hub/session/5d2f44f57c6a1df7d6ab498319eb9a46/execute] with body: {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.47396339724855663-4"}]}
[debug] �[35m[WD Proxy]�[39m Got response with status 200: {"sessionId":"5d2f44f57c6a1df7d6ab498319eb9a46","status":17,"value":{"message":"javascript error: arguments[0].scrollIntoView is not a function\n  (Session info: chrome=81.0.4044.138)\n  (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)"}}
[debug] �[35m[MJSONWP]�[39m Matched JSONWP error code 17 to JavaScriptError
[debug] �[35m[W3C (5e0d7962)]�[39m Encountered internal error running command: JavaScriptError: javascript error: arguments[0].scrollIntoView is not a function
[debug] �[35m[W3C (5e0d7962)]�[39m   (Session info: chrome=81.0.4044.138)
[debug] �[35m[W3C (5e0d7962)]�[39m   (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)
[debug] �[35m[W3C (5e0d7962)]�[39m     at errorFromMJSONWPStatusCode (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:764:12)
[debug] �[35m[W3C (5e0d7962)]�[39m     at ProxyRequestError.getActualError (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:661:14)
[debug] �[35m[W3C (5e0d7962)]�[39m     at JWProxy.command (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\jsonwp-proxy\proxy.js:272:19)
[debug] �[35m[W3C (5e0d7962)]�[39m     at runMicrotasks (<anonymous>)
[debug] �[35m[W3C (5e0d7962)]�[39m     at processTicksAndRejections (internal/process/task_queues.js:93:5)
[debug] �[35m[W3C (5e0d7962)]�[39m     at AndroidUiautomator2Driver.execute (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-android-driver\lib\commands\execute.js:19:10)
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/5e0d7962-7781-4d80-aed0-78fd1beb4e1a/execute/sync �[39m�[31m500�[39m �[90m206 ms - 1383�[39m

why does scrollIntoView not report this error when running in selenium, but when executing in appium.

Have you run chrome v81 for selenium as well? Newer Chrome such as v118 as recent versions are quit new, so such newer one may have fixes. We haven't run selenium with Chrome v81, we're using the latest one. Let's give it a try, Chrome v81 runs selenium. Thank you for your patient answer!

The following is the log of selenium running with Chrome v81, and there were no errors reported in the scoreIntoView. In addition, before upgrading the Python package, Chrome v81 was also used, but there would be no error at that time. If ScollIntoView reported an error on Chrome v81, it would have reported an error before the upgrade: https://github.com/tianyao1111/T2/blob/master/appium_chromedriver.log

KazuCocoa commented 1 year ago

The following is the log of selenium running with Chrome v81, and there were no errors reported in the scoreIntoView

The attached log had a 500 error as below line that might be the reported error. Perhaps a different log you wanted to share?

[HTTP] --> POST /wd/hub/session/df691e09-ab52-474e-9e0c-89a0c903d1c3/execute/sync
[HTTP] {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.8102463007490215-3"}]}
[debug] [W3C (df691e09)] Calling AppiumDriver.execute() with args: ["return arguments[0].scrollIntoView(true);",[{"element-6066-11e4-a52e-4f735466cecf":"0.8102463007490215-3"}],"df691e09-ab52-474e-9e0c-89a0c903d1c3"]
[debug] [WD Proxy] Matched '/execute' to command name 'execute'
[debug] [Protocol Converter] Did not know how to rewrite the original URL '/execute' for MJSONWP protocol
[debug] [WD Proxy] Proxying [POST /execute] to [POST http://127.0.0.1:8000/wd/hub/session/e283c1eb7270d45f38880a782782455c/execute] with body: {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.8102463007490215-3"}]}
[debug] [WD Proxy] Got response with status 200: {"sessionId":"e283c1eb7270d45f38880a782782455c","status":17,"value":{"message":"javascript error: arguments[0].scrollIntoView is not a function\n  (Session info: chrome=81.0.4044.138)\n  (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)"}}
[debug] [MJSONWP] Matched JSONWP error code 17 to JavaScriptError
[debug] [W3C (df691e09)] Encountered internal error running command: JavaScriptError: javascript error: arguments[0].scrollIntoView is not a function
[debug] [W3C (df691e09)]   (Session info: chrome=81.0.4044.138)
[debug] [W3C (df691e09)]   (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)
[debug] [W3C (df691e09)]     at errorFromMJSONWPStatusCode (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:764:12)
[debug] [W3C (df691e09)]     at ProxyRequestError.getActualError (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:661:14)
[debug] [W3C (df691e09)]     at JWProxy.command (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\jsonwp-proxy\proxy.js:272:19)
[debug] [W3C (df691e09)]     at runMicrotasks (<anonymous>)
[debug] [W3C (df691e09)]     at processTicksAndRejections (internal/process/task_queues.js:93:5)
[debug] [W3C (df691e09)]     at AndroidUiautomator2Driver.execute (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-android-driver\lib\commands\execute.js:19:10)
[HTTP] <-- POST /wd/hub/session/df691e09-ab52-474e-9e0c-89a0c903d1c3/execute/sync 500 188 ms - 1383
[HTTP] 

before upgrading the Python package

My best guess is protocol differences.

Btw, selenium v4 based appium python client (v2+) basically may have an issue for non-w3c webdriver protocol. I'd recommend using Python client v1 if you'd like to keep using "w3c": false

tianyao1111 commented 1 year ago

The following is the log of selenium running with Chrome v81, and there were no errors reported in the scoreIntoView

The attached log had a 500 error as below line that might be the reported error. Perhaps a different log you wanted to share?

�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/df691e09-ab52-474e-9e0c-89a0c903d1c3/execute/sync�[39m
�[35m[HTTP]�[39m �[90m{"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.8102463007490215-3"}]}�[39m
[debug] �[35m[W3C (df691e09)]�[39m Calling AppiumDriver.execute() with args: ["return arguments[0].scrollIntoView(true);",[{"element-6066-11e4-a52e-4f735466cecf":"0.8102463007490215-3"}],"df691e09-ab52-474e-9e0c-89a0c903d1c3"]
[debug] �[35m[WD Proxy]�[39m Matched '/execute' to command name 'execute'
[debug] �[35m[Protocol Converter]�[39m Did not know how to rewrite the original URL '/execute' for MJSONWP protocol
[debug] �[35m[WD Proxy]�[39m Proxying [POST /execute] to [POST http://127.0.0.1:8000/wd/hub/session/e283c1eb7270d45f38880a782782455c/execute] with body: {"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.8102463007490215-3"}]}
[debug] �[35m[WD Proxy]�[39m Got response with status 200: {"sessionId":"e283c1eb7270d45f38880a782782455c","status":17,"value":{"message":"javascript error: arguments[0].scrollIntoView is not a function\n  (Session info: chrome=81.0.4044.138)\n  (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)"}}
[debug] �[35m[MJSONWP]�[39m Matched JSONWP error code 17 to JavaScriptError
[debug] �[35m[W3C (df691e09)]�[39m Encountered internal error running command: JavaScriptError: javascript error: arguments[0].scrollIntoView is not a function
[debug] �[35m[W3C (df691e09)]�[39m   (Session info: chrome=81.0.4044.138)
[debug] �[35m[W3C (df691e09)]�[39m   (Driver info: chromedriver=81.0.4044.138 (8c6c7ba89cc9453625af54f11fd83179e23450fa-refs/branch-heads/4044@{#999}),platform=Windows NT 10.0.19045 x86_64)
[debug] �[35m[W3C (df691e09)]�[39m     at errorFromMJSONWPStatusCode (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:764:12)
[debug] �[35m[W3C (df691e09)]�[39m     at ProxyRequestError.getActualError (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\protocol\errors.js:661:14)
[debug] �[35m[W3C (df691e09)]�[39m     at JWProxy.command (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-base-driver\lib\jsonwp-proxy\proxy.js:272:19)
[debug] �[35m[W3C (df691e09)]�[39m     at runMicrotasks (<anonymous>)
[debug] �[35m[W3C (df691e09)]�[39m     at processTicksAndRejections (internal/process/task_queues.js:93:5)
[debug] �[35m[W3C (df691e09)]�[39m     at AndroidUiautomator2Driver.execute (C:\Users\admin\AppData\Roaming\npm\node_modules\appium\node_modules\appium-android-driver\lib\commands\execute.js:19:10)
�[35m[HTTP]�[39m �[37m<-- POST /wd/hub/session/df691e09-ab52-474e-9e0c-89a0c903d1c3/execute/sync �[39m�[31m500�[39m �[90m188 ms - 1383�[39m
�[35m[HTTP]�[39m �[90m�[39m

before upgrading the Python package

My best guess is protocol differences.

Btw, selenium v4 based appium python client (v2+) basically may have an issue for non-w3c webdriver protocol. I'd recommend using Python client v1 if you'd like to keep using "w3c": false

I comment out 'w3c': false, it also report this error; should I just upgrade my appium server to 2. X? Is it possible that my Python package has been upgraded to 2. X, and is the appium server still 1. X causing this?

KazuCocoa commented 1 year ago

Hm, then I don't have a good idea. Could you compare the request URL and the body like the below with ok/no cases? If these requests are the same, the behavior basically depends on the chromedriver side, out of Appium's control.

�[35m[HTTP]�[39m �[37m-->�[39m �[37mPOST�[39m �[37m/wd/hub/session/df691e09-ab52-474e-9e0c-89a0c903d1c3/execute/sync�[39m
�[35m[HTTP]�[39m �[90m{"script":"return arguments[0].scrollIntoView(true);","args":[{"element-6066-11e4-a52e-4f735466cecf":"0.8102463007490215-3"}]}�[39m
[debug] �[35m[W3C (df691e09)]�[39m Calling AppiumDriver.execute() with args: ["return arguments[0].scrollIntoView(true);",[{"element-6066-11e4-a52e-4f735466cecf":"0.8102463007490215-3"}],"df691e09-ab52-474e-9e0c-89a0c903d1c3"]
[debug] �[35m[WD Proxy]�[39m Matched '/execute' to command name 'execute'
KazuCocoa commented 1 year ago

Is it possible that my Python package has been upgraded to 2. X, and is the appium server still 1. X causing this?

Yes, basically Appium has been talking w3c webdriver protocol, so you could use a newer python client and older appium if necessary, while potentially you may need to manage the appium server instance by yourselves. (we no longer maintain older versions, though)