appium server日志分析

appium server日志分析,第1张

概述Theserverisrunning[Appium]WelcometoAppiumv1.15.1appium版本号[Appium]Non-defaultserverargs:[Appium]allowInsecure:{[Appium]}[Appium]denyInsecure:{[Appium]}[Appium]AppiumRESThttpinterfacelistenerstartedon0.0.0.0:4723
The server is running[Appium] Welcome to Appium v1.15.1

appium版本号

[Appium] Non-default server args:[Appium]   allowInsecure: {[Appium]   }[Appium]   denyInsecure: {[Appium]   }[Appium] Appium REST http interface Listener started on 0.0.0.0:4723

开通了本地4723端口监听客户端发来的请求,如果server在别的服务器上,这里就是对应的server地址

[http] --> POST /wd/hub/session

http向appiumserver发起post请求,携带capabilitIEs

[http] {"capabilitIEs":{"firstMatch":[{"platformname":"AndroID","appium:platformVersion":"6.0","appium:devicename":"127.0.0.1:7555","appium:appPackage":"com.androID.settings","appium:appActivity":"com.androID.settings.Settings"}]},"desiredCapabilitIEs":{"platformname":"AndroID","platformVersion":"6.0","devicename":"127.0.0.1:7555","appPackage":"com.androID.settings","appActivity":"com.androID.settings.Settings"}}

为了创建session对象

[W3C] Calling AppiumDriver.createSession() with args: [{"platformname":"AndroID","platformVersion":"6.0","devicename":"127.0.0.1:7555","appPackage":"com.androID.settings","appActivity":"com.androID.settings.Settings"},null,{"firstMatch":[{"platformname":"AndroID","appium:platformVersion":"6.0","appium:devicename":"127.0.0.1:7555","appium:appPackage":"com.androID.settings","appium:appActivity":"com.androID.settings.Settings"}]}][BaseDriver] Event 'newSessionRequested' logged at 1613358360840 (11:06:00 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 v1.15.1 创建了 new AndroIDUiautomator2Driver session,带了以下这些参数

[Appium] Appium v1.15.1 creating new AndroIDUiautomator2Driver (v1.37.2) session[BaseDriver] W3C capabilitIEs and MJsONWP desired capabilitIEs were provIDed[BaseDriver] Creating session with W3C capabilitIEs: {[BaseDriver]   "alwaysMatch": {[BaseDriver]     "platformname": "AndroID",[BaseDriver]     "appium:platformVersion": "6.0",[BaseDriver]     "appium:devicename": "127.0.0.1:7555",[BaseDriver]     "appium:appPackage": "com.androID.settings",[BaseDriver]     "appium:appActivity": "com.androID.settings.Settings"[BaseDriver]   },[BaseDriver]   "firstMatch": [[BaseDriver]     {}[BaseDriver]   ][BaseDriver] }[BaseDriver] Session created with session ID: 2310235d-6518-4803-b9fd-9b2bbb44f4a8

返回了session ID,后面发送请求都会带session ID

[Uiautomator2] Starting 'com.androID.settings' directly on the device[ADB] Found 1 'build-tools' folders under 'D:\soft\androID-sdk-windows' (newest first):

build-tools配置的环境变量

[ADB]     D:/soft/androID-sdk-windows/build-tools/30.0.0-prevIEw[ADB] Using 'adb.exe' from 'D:\soft\androID-sdk-windows\platform-tools\adb.exe'

adb配置的环境变量

[AndroIDDriver] RetrIEving device List[ADB] Trying to find a connected androID device[ADB] Getting connected devices...[ADB] Connected devices: [{"udID":"127.0.0.1:7555","state":"device"}][AndroIDDriver] Looking for a device with AndroID '6.0'[ADB] Setting device ID to 127.0.0.1:7555[ADB] Getting device platform version[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell getprop ro.build.version.release'[ADB] Current device property 'ro.build.version.release': 6.0.1[ADB] Setting device ID to 127.0.0.1:7555[AndroIDDriver] Using device: 127.0.0.1:7555[ADB] Using 'adb.exe' from 'D:\soft\androID-sdk-windows\platform-tools\adb.exe'[ADB] Setting device ID to 127.0.0.1:7555

找到手机端设备的版本

[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell getprop ro.build.version.sdk'

找到设备,通过adb -s指定设备,发送了adb shell getprop ro.build.version.sdk

[ADB] Current device property 'ro.build.version.sdk': 23[ADB] Device API level: 23

返回了版本号,使用cmd,查看是一样的结果

[AndroIDDriver] No app sent in, not parsing package/activity[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 wait-for-device'[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell echo Ping'

能不能Ping通

[AndroIDDriver] Pushing settings apk to device...[ADB] Getting install status for io.appium.settings

io.appium.settings是给手机端设置一些基本设置

[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell dumpsys package io.appium.settings'[ADB] 'io.appium.settings' is installed[ADB] Getting package info for 'io.appium.settings'[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell dumpsys package io.appium.settings'[ADB] Cannot extract apk info using apkanalyzer. Falling back to aapt. Original error: Could not find 'apkanalyzer.bat' in ["D:\soft\androID-sdk-windows\platform-tools\apkanalyzer.bat","D:\soft\androID-sdk-windows\emulator\apkanalyzer.bat","D:\soft\androID-sdk-windows\tools\apkanalyzer.bat","D:\soft\androID-sdk-windows\tools\bin\apkanalyzer.bat","D:\soft\androID-sdk-windows\build-tools\30.0.0-prevIEw\apkanalyzer.bat"]. Do you have AndroID Build Tools installed at 'D:\soft\androID-sdk-windows'?[ADB] Using 'aapt.exe' from 'D:\soft\androID-sdk-windows\build-tools.0.0-prevIEw\aapt.exe'[ADB] The version name of the installed 'io.appium.settings' is greater or equal to the application version name ('2.14.2' >= '2.14.2')[ADB] There is no need to install/upgrade 'C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\io.appium.settings\apks\settings_apk-deBUG.apk'[ADB] Getting IDs of all 'io.appium.settings' processes[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell 'pgrep --help; echo $?''[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell pgrep -f io\.appium\.settings'

将.SET_ANIMATION_SCALE, CHANGE_CONfigURATION, ACCESS_FINE_LOCATION 授权给io.appium.settings,执行系统的 *** 作

[AndroIDDriver] Granting androID.permission.SET_ANIMATION_SCALE, CHANGE_CONfigURATION, ACCESS_FINE_LOCATION by pm grant[ADB] Granting permissions ["androID.permission.SET_ANIMATION_SCALE","androID.permission.CHANGE_CONfigURATION","androID.permission.ACCESS_FINE_LOCATION"] to 'io.appium.settings'[ADB] Got the following command chunks to execute: [["pm","grant","io.appium.settings","androID.permission.SET_ANIMATION_SCALE",";","pm","grant","io.appium.settings","androID.permission.CHANGE_CONfigURATION",";","pm","grant","io.appium.settings","androID.permission.ACCESS_FINE_LOCATION",";"]][ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell pm grant io.appium.settings androID.permission.SET_ANIMATION_SCALE \; pm grant io.appium.settings androID.permission.CHANGE_CONfigURATION \; pm grant io.appium.settings androID.permission.ACCESS_FINE_LOCATION \;'[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell am start -n io.appium.settings/.Settings -a androID.intent.action.MAIN -c androID.intent.category.LAUNCHER'[ADB] Getting IDs of all 'io.appium.settings' processes[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell pgrep -f io\.appium\.settings'[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell appops set io.appium.settings androID\:mock_location allow'[Logcat] Starting logcat capture

安装 io.appium.uiautomator2.server

[ADB] Getting install status for io.appium.uiautomator2.server[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell dumpsys package io.appium.uiautomator2.server'[ADB] 'io.appium.uiautomator2.server' is installed[ADB] Getting package info for 'io.appium.uiautomator2.server'[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell dumpsys package io.appium.uiautomator2.server'[ADB] Cannot extract apk info using apkanalyzer. Falling back to aapt. Original error: Could not find 'apkanalyzer.bat' in ["D:\soft\androID-sdk-windows\platform-tools\apkanalyzer.bat","D:\soft\androID-sdk-windows\emulator\apkanalyzer.bat","D:\soft\androID-sdk-windows\tools\apkanalyzer.bat","D:\soft\androID-sdk-windows\tools\bin\apkanalyzer.bat","D:\soft\androID-sdk-windows\build-tools\30.0.0-prevIEw\apkanalyzer.bat"]. Do you have AndroID Build Tools installed at 'D:\soft\androID-sdk-windows'?[ADB] The version name of the installed 'io.appium.uiautomator2.server' is greater or equal to the application version name ('4.3.0' >= '4.3.0')[Uiautomator2] io.appium.uiautomator2.server installation state: sameVersionInstalled[ADB] Checking app cert for C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.3.0.apk[ADB] Using 'apksigner.bat' from 'D:\soft\androID-sdk-windows\build-tools.0.0-prevIEw\apksigner.bat'[ADB] Starting 'D:\soft\androID-sdk-windows\build-tools.0.0-prevIEw\apksigner.bat' with args '["verify","--print-certs","C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.3.0.apk"]'[ADB] Got an error during apksigner execution: Command 'apksigner.bat verify --print-certs C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.3.0.apk' exited with code 1[ADB] apksigner stderr: java.lang.UnsupportedClassversionError: com/androID/apksigner/ApkSignerTool has been compiled by a more recent version of the Java Runtime (class file version 53.0), this version of the Java Runtime only recognizes class file versions up to 52.0[ADB] 	at java.lang.classLoader.defineClass1(Native Method)[ADB] 	at java.lang.classLoader.defineClass(UnkNown Source)[ADB] 	at java.security.SecureClassLoader.defineClass(UnkNown Source)[ADB] 	at java.net.urlclassloader.defineClass(UnkNown Source)[ADB] 	at java.net.urlclassloader.access0(UnkNown Source)[ADB] 	at java.net.urlclassloader.run(UnkNown Source)[ADB] 	at java.net.urlclassloader.run(UnkNown Source)[ADB] 	at java.security.AccessController.doPrivileged(Native Method)[ADB] 	at java.net.urlclassloader.findClass(UnkNown Source)[ADB] 	at java.lang.classLoader.loadClass(UnkNown Source)[ADB] 	at sun.misc.Launcher$AppClassLoader.loadClass(UnkNown Source)[ADB] 	at java.lang.classLoader.loadClass(UnkNown Source)[ADB] 	at sun.launcher.LauncherHelper.checkAndLoadMain(UnkNown Source)[ADB] Error: A JNI error has occurred, please check your installation and try again[ADB] Exception in thread "main" [ADB] Cannot use apksigner tool for signature verification. Original error: Command 'apksigner.bat verify --print-certs C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.3.0.apk' exited with code 1[ADB] Defaulting to verify.jar[ADB] 'C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.3.0.apk' is already signed.[ADB] Getting install status for io.appium.uiautomator2.server.test[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell dumpsys package io.appium.uiautomator2.server.test'[ADB] 'io.appium.uiautomator2.server.test' is installed[ADB] Checking app cert for C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-deBUG-androIDTest.apk[ADB] Starting 'D:\soft\androID-sdk-windows\build-tools.0.0-prevIEw\apksigner.bat' with args '["verify","--print-certs","C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-deBUG-androIDTest.apk"]'[ADB] Got an error during apksigner execution: Command 'apksigner.bat verify --print-certs C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-deBUG-androIDTest.apk' exited with code 1[ADB] apksigner stderr: java.lang.UnsupportedClassversionError: com/androID/apksigner/ApkSignerTool has been compiled by a more recent version of the Java Runtime (class file version 53.0), this version of the Java Runtime only recognizes class file versions up to 52.0[ADB] 	at java.lang.classLoader.defineClass1(Native Method)[ADB] 	at java.lang.classLoader.defineClass(UnkNown Source)[ADB] 	at java.security.SecureClassLoader.defineClass(UnkNown Source)[ADB] 	at java.net.urlclassloader.defineClass(UnkNown Source)[ADB] 	at java.net.urlclassloader.access0(UnkNown Source)[ADB] 	at java.net.urlclassloader.run(UnkNown Source)[ADB] 	at java.net.urlclassloader.run(UnkNown Source)[ADB] 	at java.security.AccessController.doPrivileged(Native Method)[ADB] 	at java.net.urlclassloader.findClass(UnkNown Source)[ADB] 	at java.lang.classLoader.loadClass(UnkNown Source)[ADB] 	at sun.misc.Launcher$AppClassLoader.loadClass(UnkNown Source)[ADB] 	at java.lang.classLoader.loadClass(UnkNown Source)[ADB] 	at sun.launcher.LauncherHelper.checkAndLoadMain(UnkNown Source)[ADB] Error: A JNI error has occurred, please check your installation and try again[ADB] Exception in thread "main" [ADB] Cannot use apksigner tool for signature verification. Original error: Command 'apksigner.bat verify --print-certs C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-deBUG-androIDTest.apk' exited with code 1[ADB] Defaulting to verify.jar[ADB] 'C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-deBUG-androIDTest.apk' is already signed.[Uiautomator2] Server packages are not going to be (re)installed[Uiautomator2] Waiting up to 30000ms for services to be available[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell pm List instrumentation'[Uiautomator2] Instrumentation target 'io.appium.uiautomator2.server.test/androIDx.test.runner.AndroIDJUnitRunner' is available[Uiautomator2] Forwarding Uiautomator2 Server port 6790 to 8200[ADB] Forwarding system: 8200 to device: 6790[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 forward tcp\:8200 tcp\:6790'

将pc端的8200端口映射到手机端的6790端口,可以进行进程通信,下面进行UIautomator2 server初始化设置

[Uiautomator2] No app capability. Assuming it is already on the device[ADB] Getting install status for com.androID.settings[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell dumpsys package com.androID.settings'[ADB] 'com.androID.settings' is installed[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell am force-stop com.androID.settings'[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell pm clear com.androID.settings'[AndroIDDriver] Performed fast reset on the installed 'com.androID.settings' application (stop and clear)[Uiautomator2] Performing shallow cleanup of automation leftovers[Uiautomator2] No obsolete sessions have been detected (Error: socket hang up)[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell am force-stop io.appium.uiautomator2.server.test'

启动 UIautomator2 server

[Uiautomator2] Starting UIautomator2 server 4.3.0[Uiautomator2] Using UIautomator2 server from 'C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v4.3.0.apk' and test from 'C:\Users\administrator\AppData\Local\Programs\Appium\resources\app\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...[ADB] Creating ADB subprocess with args: ["-P",5037,"-s","127.0.0.1:7555","shell","am","instrument","-w","io.appium.uiautomator2.server.test/androIDx.test.runner.AndroIDJUnitRunner"]

通过adb shell am instrument完成启动

[WD Proxy] Matched '/status' to command name 'getStatus'[WD Proxy] Proxying [GET /status] to [GET http://localhost:8200/wd/hub/status] with no body[WD Proxy] Got an unexpected response with status undefined: {"code":"ECONNreset"}[Instrumentation] io.appium.uiautomator2.server.test.AppiumUiautomator2Server:[WD Proxy] Matched '/status' to command name 'getStatus'[WD Proxy] Proxying [GET /status] to [GET http://localhost:8200/wd/hub/status] with no body[WD Proxy] Got an unexpected response with status undefined: {"code":"ECONNreset"}[WD Proxy] Matched '/status' to command name 'getStatus'[WD Proxy] Proxying [GET /status] to [GET http://localhost:8200/wd/hub/status] with no body[WD Proxy] Got response with status 200: {"sessionID":"None","value":{"ready":true,"message":"Uiautomator2 Server is ready to accept commands"}}

Uiautomator2 Server已经准备好

[Uiautomator2] The initialization of the instrumentation process took 3099ms

Uiautomator2 Server初始化完成,用时3.099s,以下是创建session

[WD Proxy] Matched '/session' to command name 'createSession'[WD Proxy] Proxying [POST /session] to [POST http://localhost: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","platformVersion":"6.0","devicename":"127.0.0.1:7555","appPackage":"com.androID.settings","appActivity":"com.androID.settings.Settings"},"platformname":"AndroID","platformVersion":"6.0","devicename":"127.0.0.1:7555","appPackage":"com.androID.settings","appActivity":"com.androID.settings.Settings","deviceUDID":"127.0.0.1:7555"}],"alwaysMatch":{}}}

发送post请求,带着capabilitIEs设置代理到http://localhost:8200这个端口,请求session

[WD Proxy] Got response with status 200: {"sessionID":"44e61b8a-8ad1-4c4c-a36a-468658f98987","value":{"sessionID":"44e61b8a-8ad1-4c4c-a36a-468658f98987","capabilitIEs":{"firstMatch":[{"platform":"liNUX","WebStorageEnabled":false,"takesScreenshot":true,"JavaScriptEnabled":true,"databaseEnabled":false,"networkConnectionEnabled":true,"locationContextEnabled":false,"warnings":{},"desired":{"platformname":"AndroID","platformVersion":"6.0","devicename":"127.0.0.1:7555","appPackage":"com.androID.settings","appActivity":"com.androID.settings.Settings"},"platformname":"AndroID","platformVersion":"6.0","devicename":"127.0.0.1:7555","appPackage":"com.androID.settings","appActivity":"com.androID.settings.Settings","deviceUDID":"127.0.0.1:7555"}],"alwaysMatch":{}}}}

返回了200,带着sessionID

[WD Proxy] Determined the downstream protocol as 'W3C'[WD Proxy] Proxying [GET /appium/device/info] to [GET http://localhost:8200/wd/hub/session/44e61b8a-8ad1-4c4c-a36a-468658f98987/appium/device/info] with no body
[WD Proxy] Got response with status 200: {"sessionID":"44e61b8a-8ad1-4c4c-a36a-468658f98987","value":{"androIDID":"db1dd5d30ad7e7d0","manufacturer":"Netease","model":"MuMu","brand":"AndroID","APIVersion":"23","platformVersion":"6.0.1","carrIErname":"","realdisplaySize":"1080x1920","displayDensity":360,"networks":[{"type":1,"typename":"WIFI","subtype":0,"subtypename":"","isConnected":true,"detailedState":"CONNECTED","state":"CONNECTED","extraInfo":"\"5W3CQx\"","isAvailable":true,"isFailover":false,"isRoaming":false,"capabilitIEs":{"transportTypes":"NET_CAPABIliTY_supl","networkCapabilitIEs":"","linkUpstreamBanDWIDthKbps":1048576,"linkDownBanDWIDthKbps":1048576,"signalStrength":-55,"networkSpecifIEr":null,"SSID":null}}],"locale":"zh_CN","timeZone":"Asia\/Shanghai"}}[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell dumpsys window'[AndroIDDriver] Screen already unlocked, doing nothing

打开指定包的指定页

[Uiautomator2] Starting 'com.androID.settings/com.androID.settings.Settings and waiting for 'com.androID.settings/com.androID.settings.Settings'[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell am start -W -n com.androID.settings/com.androID.settings.Settings -S'[WD Proxy] Proxying [GET /appium/device/pixel_ratio] to [GET http://localhost:8200/wd/hub/session/44e61b8a-8ad1-4c4c-a36a-468658f98987/appium/device/pixel_ratio] with body: {}[WD Proxy] Got response with status 200: {"sessionID":"44e61b8a-8ad1-4c4c-a36a-468658f98987","value":2.25}[WD Proxy] Matched '/appium/device/system_bars' to command name 'getSystembars'[WD Proxy] Proxying [GET /appium/device/system_bars] to [GET http://localhost:8200/wd/hub/session/44e61b8a-8ad1-4c4c-a36a-468658f98987/appium/device/system_bars] with body: {}[WD Proxy] Got response with status 200: {"sessionID":"44e61b8a-8ad1-4c4c-a36a-468658f98987","value":{"statusbar":54}}[WD Proxy] Matched '/window/current/size' to command name 'getwindowsize'[WD Proxy] Proxying [GET /window/current/size] to [GET http://localhost:8200/wd/hub/session/44e61b8a-8ad1-4c4c-a36a-468658f98987/window/current/size] with body: {}[WD Proxy] Got response with status 200: {"sessionID":"44e61b8a-8ad1-4c4c-a36a-468658f98987","value":{"height":1920,"wIDth":1080}}[Appium] New AndroIDUiautomator2Driver session created successfully, session 2310235d-6518-4803-b9fd-9b2bbb44f4a8 added to master session List[BaseDriver] Event 'newSessionStarted' logged at 1613358385423 (11:06:25 GMT+0800 (中国标准时间))[W3C (2310235d)] Cached the protocol value 'W3C' for the new session 2310235d-6518-4803-b9fd-9b2bbb44f4a8[W3C (2310235d)] 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","platformVersion":"6.0","devicename":"127.0.0.1:7555","appPackage":"com.androID.settings","appActivity":"com.androID.settings.Settings"},"platformname":"AndroID","platformVersion":"6.0.1","devicename":"127.0.0.1:7555","appPackage":"com.androID.settings","appActivity":"com.androID.settings.Settings","deviceUDID":"127.0.0.1:7555","deviceAPILevel":23,"deviceScreenSize":"1080x1920","deviceScreenDensity":360,"deviceModel":"MuMu","deviceManufacturer":"Netease","pixelRatio":2.25,"statbarHeight":54,"vIEwportRect":{"left":0,"top":54,"wIDth":1080,"height":1866}}}[http] <-- POST /wd/hub/session 200 24588 ms - 867

到现在脚本中dirver=webdriver.Remote(‘http://localhost:4723/wd/hub’,desired_caps)完成了,花费了24588 ms
带着sessionID通信

[http] [http] --> DELETE /wd/hub/session/2310235d-6518-4803-b9fd-9b2bbb44f4a8[http] {}[W3C (2310235d)] Calling AppiumDriver.deleteSession() with args: ["2310235d-6518-4803-b9fd-9b2bbb44f4a8"][BaseDriver] Event 'quitSessionRequested' logged at 1613358385505 (11:06:25 GMT+0800 (中国标准时间))[Appium] Removing session 2310235d-6518-4803-b9fd-9b2bbb44f4a8 from our master session List[Uiautomator2] Deleting Uiautomator2 session[Uiautomator2] Deleting Uiautomator2 server session[WD Proxy] Matched '/' to command name 'deleteSession'[WD Proxy] Proxying [DELETE /] to [DELETE http://localhost:8200/wd/hub/session/44e61b8a-8ad1-4c4c-a36a-468658f98987] with no body[WD Proxy] Got response with status 200: {"sessionID":"44e61b8a-8ad1-4c4c-a36a-468658f98987","value":null}[ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 shell am force-stop com.androID.settings'[Instrumentation] .[Instrumentation] Time: 6.42[Instrumentation] [Instrumentation] OK (1 test)[Instrumentation] The process has exited with code 0[Logcat] StopPing logcat capture[ADB] Removing forwarded port socket connection: 8200 [ADB] Running 'D:\soft\androID-sdk-windows\platform-tools\adb.exe -P 5037 -s 127.0.0.1\:7555 forward --remove tcp\:8200'[BaseDriver] Event 'quitSessionFinished' logged at 1613358386918 (11:06:26 GMT+0800 (中国标准时间))[W3C (2310235d)] Received response: null[W3C (2310235d)] But deleting session, so not returning[W3C (2310235d)] Responding to clIEnt with driver.deleteSession() result: null[http] <-- DELETE /wd/hub/session/2310235d-6518-4803-b9fd-9b2bbb44f4a8 200 1415 ms - 14[http] 
总结

以上是内存溢出为你收集整理的appium server日志分析全部内容,希望文章能够帮你解决appium server日志分析所遇到的程序开发问题。

如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。

欢迎分享,转载请注明来源:内存溢出

原文地址:https://54852.com/web/1046538.html

(0)
打赏 微信扫一扫微信扫一扫 支付宝扫一扫支付宝扫一扫
上一篇 2022-05-24
下一篇2022-05-24

发表评论

登录后才能评论

评论列表(0条)

    保存