AppiumTestDistribution / appium-device-farm

This is an Appium 2.0 plugin designed to manage and create driver sessions on available devices.
https://devicefarm.org
Other
345 stars 104 forks source link

InvalidArgumentError: property 'usePreinstalledWDA' should not exist on both primary {....} and secondary {....} #1155

Open user243256262 opened 5 months ago

user243256262 commented 5 months ago

When I press "Use Device" on the /device-farm UI, it tries to start and then it crashes with the errors I show below.

InvalidArgumentError: property 'usePreinstalledWDA' should not exist on both primary {....} and secondary {....}

Here is the full server log of the new error:

admin@admins-MacBook-Pro Desktop % sudo appium server -ka 800 --use-plugins=device-farm --config ./server-config.json -pa /wd/hub
[Appium] Attempting to load plugin device-farm...
[Appium] Requiring plugin at /Users/admin/.appium/node_modules/appium-device-farm/lib/src/main.js
{ DeviceFarmProLoader: [class l], default: [class l] }
[Appium] xU has been successfully loaded in 0.603s
[Appium] Welcome to Appium v2.9.0
[Appium] Non-default server args:
[Appium] {
[Appium]   basePath: '/wd/hub',
[Appium]   keepAliveTimeout: 800,
[Appium]   port: 31337,
[Appium]   usePlugins: [
[Appium]     'device-farm'
[Appium]   ]
[Appium] }
[Appium] The autodetected Appium home path: /Users/admin/.appium
[Appium] Attempting to load driver xcuitest...
[Appium] Requiring driver at /Users/admin/.appium/node_modules/appium-xcuitest-driver/build/index.js
[Appium] XCUITestDriver has been successfully loaded in 0.408s
[device-farm-main] πŸ“± Update server with CLI Args: {"subcommand":"server","address":"0.0.0.0","basePath":"/wd/hub","keepAliveTimeout":800,"port":31337,"usePlugins":["device-farm"],"configFile":"./server-config.json","extraArgs":[],"plugin":{"device-farm":{"platform":"ios","skipChromeDownload":true,"liveStreaming":true,"wdaBundleId":"me.mathiasb248.WebDriverAgentRunner","androidDeviceType":"both","iosDeviceType":"both"}},"allowCors":false,"allowInsecure":[],"callbackPort":4723,"debugLogSpacing":false,"denyInsecure":[],"localTimezone":false,"loglevel":"debug","logNoColors":false,"logTimestamp":false,"pluginsImportChunkSize":7,"driversImportChunkSize":3,"longStacktrace":false,"noPermsCheck":false,"relaxedSecurityEnabled":false,"sessionOverride":false,"strictCaps":false,"useDrivers":[],"driver":{"xcuitest":{"wdaLocalPort":8100}},"tmpDir":"/tmp"}
{ DeviceFarmProLoader: [class l], default: [class l] }
[device-farm-main] Cli Args: {"subcommand":"server","address":"0.0.0.0","basePath":"/wd/hub","keepAliveTimeout":800,"port":31337,"usePlugins":["device-farm"],"configFile":"./server-config.json","extraArgs":[],"plugin":{"device-farm":{"platform":"ios","skipChromeDownload":true,"liveStreaming":true,"wdaBundleId":"me.mathiasb248.WebDriverAgentRunner","androidDeviceType":"both","iosDeviceType":"both"}},"allowCors":false,"allowInsecure":[],"callbackPort":4723,"debugLogSpacing":false,"denyInsecure":[],"localTimezone":false,"loglevel":"debug","logNoColors":false,"logTimestamp":false,"pluginsImportChunkSize":7,"driversImportChunkSize":3,"longStacktrace":false,"noPermsCheck":false,"relaxedSecurityEnabled":false,"sessionOverride":false,"strictCaps":false,"useDrivers":[],"driver":{"xcuitest":{"wdaLocalPort":8100}},"tmpDir":"/tmp"}
[device-farm-main] πŸ“± Update server with Plugin Args: {"platform":"ios","iosDeviceType":"both","androidDeviceType":"both","skipChromeDownload":true,"maxSessions":8,"adbRemote":[],"emulators":[],"simulators":[],"deviceAvailabilityTimeoutMs":300000,"deviceAvailabilityQueryIntervalMs":10000,"sendNodeDevicesToHubIntervalMs":30000,"checkStaleDevicesIntervalMs":30000,"checkBlockedDevicesIntervalMs":30000,"newCommandTimeoutSec":60,"bindHostOrIp":"192.168.1.100","enableDashboard":false,"removeDevicesFromDatabaseBeforeRunningThePlugin":false,"remoteConnectionTimeout":60000,"liveStreaming":true,"wdaBundleId":"me.mathiasb248.WebDriverAgentRunner","preBuildWDAPath":""}
[device-farm-main] Initializing storage
[device-farm-main] Initializing database
[device-farm-main] Creating new database: ./temp-appium/db.json
[device-farm-main] Database loaded
[device-farm-main] proxy is not required for axios
[device-farm-main] Registering proxy middleware
[device-farm-main] Registering websocket handler for iOS Streaming
Inside get streaming server
[device-farm-main] πŸ“£πŸ“£πŸ“£ I'm a hub and I'm listening on 192.168.1.100:31337
[device-farm-main] Found 0 device candidates to be released
[device-farm-main] Hub will clean pending sessions every 30000 ms with pending session timeout: 310000 ms
[device-farm-main] Fetching local simulators
[device-farm-main] iOS device with udid b4a1e53e81397fed8b95921cf13a0e2fa930c2f3 plugged! updating device list...
[device-farm-main] Added 1 new devices to local database
[device-farm-main] iOS Simulators: true
[device-farm-main] tvOS Simulators: false
[device-farm-main] No tvOS simulators found!
[device-farm-main] Added 11 new devices to local database
[device-farm-main] πŸ“£πŸ“£πŸ“£ Device Farm Plugin will be served at πŸ”— http://192.168.1.100:31337/device-farm with id eabde268-af9b-45ea-964e-1c4aa38e044d
[Appium] Appium REST http interface listener started on http://0.0.0.0:31337/wd/hub
[Appium] You can provide the following URLs in your client code to connect to this server:
[Appium]    http://127.0.0.1:31337/wd/hub (only accessible from the same host)
[Appium]    http://192.168.1.100:31337/wd/hub
[Appium]    http://169.254.210.14:31337/wd/hub
[Appium] Available drivers:
[Appium]   - xcuitest@7.17.3 (automationName 'XCUITest')
[Appium] Available plugins:
[Appium]   - device-farm@8.4.7-rc.34 (ACTIVE)
[device-farm-main] Fetching local simulators
[device-farm-main] iOS Simulators: true
[device-farm-main] tvOS Simulators: false
[device-farm-main] No tvOS simulators found!
[HTTP] --> GET /device-farm/
[HTTP] {}
[device-farm-main] Received non-webdriver request with url /device-farm/. So, not proxying it to downstream.
[HTTP] <-- GET /device-farm/ 304 15 ms - -
[HTTP] 
[HTTP] --> GET /device-farm/api/device
[HTTP] {}
[device-farm-main] Received non-webdriver request with url /device-farm/api/device. So, not proxying it to downstream.
[HTTP] <-- GET /device-farm/api/device - - ms - -
[HTTP] 
[HTTP] --> GET /device-farm/ui-assets/index-C8lp4pRg.css
[HTTP] {}
[device-farm-main] Received non-webdriver request with url /device-farm/ui-assets/index-C8lp4pRg.css. So, not proxying it to downstream.
[HTTP] <-- GET /device-farm/ui-assets/index-C8lp4pRg.css 304 2 ms - -
[HTTP] 
[HTTP] --> GET /device-farm/ui-assets/index-BUJ0NMCU.js
[HTTP] {}
[device-farm-main] Received non-webdriver request with url /device-farm/ui-assets/index-BUJ0NMCU.js. So, not proxying it to downstream.
[HTTP] <-- GET /device-farm/ui-assets/index-BUJ0NMCU.js 304 1 ms - -
[HTTP] 
[HTTP] --> GET /dashboard/api/ping
[HTTP] {}
[device-farm-main] Received non-webdriver request with url /dashboard/api/ping. So, not proxying it to downstream.
[HTTP] No route found for /dashboard/api/ping
[HTTP] <-- GET /dashboard/api/ping 404 4 ms - 211
[HTTP] 
[HTTP] --> GET /device-farm/ui-assets/device-farm-logo-nn1d6kPf.png
[HTTP] {}
[device-farm-main] Received non-webdriver request with url /device-farm/ui-assets/device-farm-logo-nn1d6kPf.png. So, not proxying it to downstream.
[HTTP] --> GET /device-farm/api/device
[HTTP] {}
[device-farm-main] Received non-webdriver request with url /device-farm/api/device. So, not proxying it to downstream.
[HTTP] <-- GET /device-farm/api/device 200 1 ms - 11735
[HTTP] 
[HTTP] <-- GET /device-farm/ui-assets/device-farm-logo-nn1d6kPf.png 304 3 ms - -
[HTTP] 
[HTTP] --> GET /device-farm/api/queue/length
[HTTP] {}
[device-farm-main] Received non-webdriver request with url /device-farm/api/queue/length. So, not proxying it to downstream.
[HTTP] <-- GET /device-farm/api/queue/length 304 2 ms - -
[HTTP] 
[HTTP] --> POST /device-farm/api/block
[HTTP] {"udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","host":"http://192.168.1.100:31337"}
[device-farm-main] Received non-webdriver request with url /device-farm/api/block. So, not proxying it to downstream.
[device-farm-main] Updated devices with filter: {"udid":{"$in":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3"}}
[HTTP] <-- POST /device-farm/api/block 200 5 ms - 16
[HTTP] 
[HTTP] --> POST /device-farm/api/dashboard/installiOSWDA
[HTTP] {"udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3"}
[device-farm-main] Received non-webdriver request with url /device-farm/api/dashboard/installiOSWDA. So, not proxying it to downstream.
[device-farm-main] Updated devices with filter: {"udid":{"$in":["b4a1e53e81397fed8b95921cf13a0e2fa930c2f3"]}}
[device-farm-main] Fetching local simulators
[device-farm-main] iOS Simulators: true
[device-farm-main] tvOS Simulators: false
[device-farm-main] No tvOS simulators found!
stdout: 
stderr: {"appPath":"/Users/admin/.cache/appium-device-farm/assets/wda-resign.ipa","device":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","level":"info","msg":"installing","time":"2024-06-07T18:42:12+03:00"}
{"level":"info","msg":"installing","percentComplete":5,"status":"CreatingStagingDirectory","time":"2024-06-07T18:42:14+03:00"}
{"level":"info","msg":"installing","percentComplete":15,"status":"ExtractingPackage","time":"2024-06-07T18:42:14+03:00"}
{"level":"info","msg":"installing","percentComplete":20,"status":"InspectingPackage","time":"2024-06-07T18:42:14+03:00"}
{"level":"info","msg":"installing","percentComplete":30,"status":"PreflightingApplication","time":"2024-06-07T18:42:14+03:00"}
{"level":"info","msg":"installing","percentComplete":40,"status":"VerifyingApplication","time":"2024-06-07T18:42:14+03:00"}
{"level":"info","msg":"installing","percentComplete":50,"status":"CreatingContainer","time":"2024-06-07T18:42:16+03:00"}
{"level":"info","msg":"installing","percentComplete":60,"status":"InstallingApplication","time":"2024-06-07T18:42:16+03:00"}
{"level":"info","msg":"installing","percentComplete":70,"status":"PostflightingApplication","time":"2024-06-07T18:42:16+03:00"}
{"level":"info","msg":"installing","percentComplete":80,"status":"SandboxingApplication","time":"2024-06-07T18:42:16+03:00"}
{"level":"info","msg":"installing","percentComplete":90,"status":"GeneratingApplicationMap","time":"2024-06-07T18:42:16+03:00"}
{"level":"info","msg":"installing","percentComplete":100,"status":"InstallComplete","time":"2024-06-07T18:42:16+03:00"}
{"level":"info","msg":"installation successful","time":"2024-06-07T18:42:16+03:00"}

[HTTP] <-- POST /device-farm/api/dashboard/installiOSWDA 200 3889 ms - 106
[HTTP] 
[HTTP] --> POST /device-farm/api/dashboard/appiumSession
[HTTP] {"udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","origin":"http://127.0.0.1:31337"}
[device-farm-main] Received non-webdriver request with url /device-farm/api/dashboard/appiumSession. So, not proxying it to downstream.
[device-farm-main] Updated devices with filter: {"udid":{"$in":["b4a1e53e81397fed8b95921cf13a0e2fa930c2f3"]}}
[HTTP] --> POST /wd/hub/session
[HTTP] {"capabilities":{"alwaysMatch":{"platformName":"iOS","appium:automationName":"XCUITest","appium:newCommandTimeout":120,"appium:udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","df:skipReport":true,"appium:mjpegServerPort":61621,"appium:waitForQuiescence":false,"appium:wdaEventloopIdleDelay":0,"appium:eventLoopIdleDelaySec":0,"appium:waitForIdleTimeout":0,"appium:settings":{"mjpegServerFramerate":34,"mjpegServerScreenshotQuality":75,"mjpegScalingFactor":100,"animationCoolOffTimeout":0},"appium:usePreinstalledWDA":true,"appium:updatedWDABundleId":"me.mathiasb248.WebDriverAgentRunner.xctrunner","appium:updatedWDABundleIdSuffix":"","df:portForward":true},"firstMatch":[{}]},"desiredCapabilities":{"platformName":"iOS","appium:automationName":"XCUITest","appium:newCommandTimeout":120,"appium:udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","df:skipReport":true,"appium:mjpegServerPort":61621,"appium:waitForQuiescence":false,"appium:wdaEventloopIdleDelay":0,"appium:eventLoopIdleDelaySec":0,"appium:waitForIdleTimeou...
[AppiumDriver@02e6] Calling AppiumDriver.createSession() with args: [{"platformName":"iOS","appium:automationName":"XCUITest","appium:newCommandTimeout":120,"appium:udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","df:skipReport":true,"appium:mjpegServerPort":61621,"appium:waitForQuiescence":false,"appium:wdaEventloopIdleDelay":0,"appium:eventLoopIdleDelaySec":0,"appium:waitForIdleTimeout":0,"appium:settings":{"mjpegServerFramerate":34,"mjpegServerScreenshotQuality":75,"mjpegScalingFactor":100,"animationCoolOffTimeout":0},"appium:usePreinstalledWDA":true,"appium:updatedWDABundleId":"me.mathiasb248.WebDriverAgentRunner.xctrunner","appium:updatedWDABundleIdSuffix":"","df:portForward":true},null,{"alwaysMatch":{"platformName":"iOS","appium:automationName":"XCUITest","appium:newCommandTimeout":120,"appium:udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","df:skipReport":true,"appium:mjpegServerPort":61621,"appium:waitForQuiescence":false,"appium:wdaEventloopIdleDelay":0,"appium:eventLoopIdleDelaySec":0,"appium:waitForIdleTimeout":0,"appium:settings":{"mjpegServerFramerate":34,"...
[device-farm-main] πŸ“± Plugin Args: {"platform":"ios","skipChromeDownload":true,"liveStreaming":true,"wdaBundleId":"me.mathiasb248.WebDriverAgentRunner","androidDeviceType":"both","iosDeviceType":"both"}
[AppiumDriver@02e6] Plugins which can handle cmd 'createSession': device-farm
[AppiumDriver@02e6] Plugin device-farm is now handling cmd 'createSession'
[device-farm-main] πŸ“± pluginArgs: {"platform":"ios","iosDeviceType":"both","androidDeviceType":"both","skipChromeDownload":true,"maxSessions":8,"adbRemote":[],"emulators":[],"simulators":[],"deviceAvailabilityTimeoutMs":300000,"deviceAvailabilityQueryIntervalMs":10000,"sendNodeDevicesToHubIntervalMs":30000,"checkStaleDevicesIntervalMs":30000,"checkBlockedDevicesIntervalMs":30000,"newCommandTimeoutSec":60,"bindHostOrIp":"192.168.1.100","enableDashboard":false,"removeDevicesFromDatabaseBeforeRunningThePlugin":false,"remoteConnectionTimeout":60000,"liveStreaming":true,"wdaBundleId":"me.mathiasb248.WebDriverAgentRunner","preBuildWDAPath":""}
[device-farm-main] Receiving session request at host: 192.168.1.100
[device-farm-main] πŸ“± Creating temporary session capability_id: bdbe7c98-9be9-4bd8-b031-6e6da5700cfd
[device-farm-main] Max session count: 8, Busy device count: 0
[device-farm-main] Waiting for free device. Filter: {"platform":"ios","udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","busy":false,"userBlocked":false}}
[device-farm-main] Updated devices with filter: {"platform":"ios","udid":{"$in":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3"}}
[device-farm-main] Updated devices with filter: {"platform":"ios","udid":{"$in":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3"}}
[device-farm-main] πŸ“± Blocking device b4a1e53e81397fed8b95921cf13a0e2fa930c2f3 at host http://192.168.1.100:31337 for new session
[device-farm-main] Updating allocated device: "{"userBlocked":true,"offline":false,"wdaLocalPort":61620,"mjpegServerPort":61621,"udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","sdk":"16.7.4","name":"iPhone","busy":false,"realDevice":true,"deviceType":"real","platform":"ios","host":"http://192.168.1.100:31337","wdaBundleId":"","productModel":"iPhone10,6","totalUtilizationTimeMilliSec":0,"sessionStartTime":0,"width":"375","height":"812","tags":[],"nodeId":"eabde268-af9b-45ea-964e-1c4aa38e044d","meta":{"revision":1,"created":1717774914474,"version":0,"updated":1717774932465},"$loki":1}"
[device-farm-main] Updated allocated device: "[{"userBlocked":true,"offline":false,"wdaLocalPort":61620,"mjpegServerPort":61621,"udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","sdk":"16.7.4","name":"iPhone","busy":true,"realDevice":true,"deviceType":"real","platform":"ios","host":"http://192.168.1.100:31337","wdaBundleId":"","productModel":"iPhone10,6","totalUtilizationTimeMilliSec":0,"sessionStartTime":0,"width":"375","height":"812","tags":[],"nodeId":"eabde268-af9b-45ea-964e-1c4aa38e044d","meta":{"revision":3,"created":1717774914474,"version":0,"updated":1717774936388},"$loki":1,"newCommandTimeout":120}]"
[device-farm-main] device.host: http://192.168.1.100:31337 and pluginArgs.bindHostOrIp: 192.168.1.100
[device-farm-main] πŸ“± Creating session on the same node
[device-farm-main] Installing Resigned WDA on real device
[HTTP] --> GET /device-farm/api/device
[HTTP] {}
[device-farm-main] Received non-webdriver request with url /device-farm/api/device. So, not proxying it to downstream.
[HTTP] <-- GET /device-farm/api/device 200 2 ms - 11781
[HTTP] 
[HTTP] --> GET /device-farm/api/queue/length
[HTTP] {}
[device-farm-main] Received non-webdriver request with url /device-farm/api/queue/length. So, not proxying it to downstream.
[HTTP] <-- GET /device-farm/api/queue/length 200 1 ms - 1
[HTTP] 
stdout: 
stderr: {"appPath":"/Users/admin/.cache/appium-device-farm/assets/wda-resign.ipa","device":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","level":"info","msg":"installing","time":"2024-06-07T18:42:16+03:00"}
{"level":"info","msg":"installing","percentComplete":5,"status":"CreatingStagingDirectory","time":"2024-06-07T18:42:18+03:00"}
{"level":"info","msg":"installing","percentComplete":15,"status":"ExtractingPackage","time":"2024-06-07T18:42:18+03:00"}
{"level":"info","msg":"installing","percentComplete":20,"status":"InspectingPackage","time":"2024-06-07T18:42:18+03:00"}
{"level":"info","msg":"installing","percentComplete":30,"status":"PreflightingApplication","time":"2024-06-07T18:42:18+03:00"}
{"level":"info","msg":"installing","percentComplete":40,"status":"VerifyingApplication","time":"2024-06-07T18:42:18+03:00"}
{"level":"info","msg":"installing","percentComplete":50,"status":"CreatingContainer","time":"2024-06-07T18:42:19+03:00"}
{"level":"info","msg":"installing","percentComplete":60,"status":"InstallingApplication","time":"2024-06-07T18:42:19+03:00"}
{"level":"info","msg":"installing","percentComplete":70,"status":"PostflightingApplication","time":"2024-06-07T18:42:19+03:00"}
{"level":"info","msg":"installing","percentComplete":80,"status":"SandboxingApplication","time":"2024-06-07T18:42:19+03:00"}
{"level":"info","msg":"installing","percentComplete":90,"status":"GeneratingApplicationMap","time":"2024-06-07T18:42:19+03:00"}
{"level":"info","msg":"installing","percentComplete":100,"status":"InstallComplete","time":"2024-06-07T18:42:19+03:00"}
{"level":"info","msg":"installation successful","time":"2024-06-07T18:42:19+03:00"}

[AppiumDriver@02e6] Executing default handling behavior for command 'createSession'
[AppiumDriver@02e6] Event 'newSessionRequested' logged at 1717774939847 (18:42:19 GMT+0300 (Eastern European Summer Time))
[BaseDriver] property 'usePreinstalledWDA' should not exist on both primary ({"platformName":"iOS","df:skipReport":true,"df:portForward":true,"automationName":"XCUITest","newCommandTimeout":120,"waitForQuiescence":false,"wdaEventloopIdleDelay":0,"eventLoopIdleDelaySec":0,"waitForIdleTimeout":0,"usePreinstalledWDA":true,"updatedWDABundleId":"me.mathiasb248.WebDriverAgentRunner.xctrunner","updatedWDABundleIdSuffix":""}) and secondary ({"udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","deviceName":"iPhone","platformVersion":"16.7.4","wdaLocalPort":61620,"mjpegServerPort":61621,"usePreinstalledWDA":true,"updatedWDABundleId":"me.mathiasb248.WebDriverAgentRunner.xctrunner","updatedWDABundleIdSuffix":""}) object
[Appium] Could not parse W3C capabilities: property 'usePreinstalledWDA' should not exist on both primary ({"platformName":"iOS","df:skipReport":true,"df:portForward":true,"automationName":"XCUITest","newCommandTimeout":120,"waitForQuiescence":false,"wdaEventloopIdleDelay":0,"eventLoopIdleDelaySec":0,"waitForIdleTimeout":0,"usePreinstalledWDA":true,"updatedWDABundleId":"me.mathiasb248.WebDriverAgentRunner.xctrunner","updatedWDABundleIdSuffix":""}) and secondary ({"udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","deviceName":"iPhone","platformVersion":"16.7.4","wdaLocalPort":61620,"mjpegServerPort":61621,"usePreinstalledWDA":true,"updatedWDABundleId":"me.mathiasb248.WebDriverAgentRunner.xctrunner","updatedWDABundleIdSuffix":""}) object
[AppiumDriver@02e6] Event 'newSessionStarted' logged at 1717774939852 (18:42:19 GMT+0300 (Eastern European Summer Time))
[device-farm-main] πŸ“± Forwarding ios port to real device b4a1e53e81397fed8b95921cf13a0e2fa930c2f3 for manual interaction
[DevCon Factory Device Farm] Requesting connection for device b4a1e53e81397fed8b95921cf13a0e2fa930c2f3 on local port 61621, device port 61621
[DevCon Factory Device Farm] Cached connections count: 0
[DevCon Factory Device Farm] Successfully requested the connection for b4a1e53e81397fed8b95921cf13a0e2fa930c2f3:61621
[device-farm-main] πŸ“± bdbe7c98-9be9-4bd8-b031-6e6da5700cfd Session response: 
[device-farm-main] {"protocol":"W3C","error":{"jsonwpCode":61,"error":"invalid argument","w3cStatus":400,"_stacktrace":null}}
[device-farm-main] πŸ“± Removing pending session with capability_id: bdbe7c98-9be9-4bd8-b031-6e6da5700cfd
[device-farm-main] bdbe7c98-9be9-4bd8-b031-6e6da5700cfd πŸ“± Device UDID b4a1e53e81397fed8b95921cf13a0e2fa930c2f3 unblocked. Reason: Failed to create session
[AppiumDriver@02e6] Encountered internal error running command: Error: InvalidArgumentError: property 'usePreinstalledWDA' should not exist on both primary ({"platformName":"iOS","df:skipReport":true,"df:portForward":true,"automationName":"XCUITest","newCommandTimeout":120,"waitForQuiescence":false,"wdaEventloopIdleDelay":0,"eventLoopIdleDelaySec":0,"waitForIdleTimeout":0,"usePreinstalledWDA":true,"updatedWDABundleId":"me.mathiasb248.WebDriverAgentRunner.xctrunner","updatedWDABundleIdSuffix":""}) and secondary ({"udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","deviceName":"iPhone","platformVersion":"16.7.4","wdaLocalPort":61620,"mjpegServerPort":61621,"usePreinstalledWDA":true,"updatedWDABundleId":"me.mathiasb248.WebDriverAgentRunner.xctrunner","updatedWDABundleIdSuffix":""}) object
[AppiumDriver@02e6]     at xU.this (/Users/admin/.appium/node_modules/appium-device-farm/lib/webpack:/appium-device-farm/lib/src/plugin.js:342:23)
[AppiumDriver@02e6]     at xU.generator (/Users/admin/.appium/node_modules/appium-device-farm/lib/webpack:/appium-device-farm/lib/src/plugin.js:328:17)
[AppiumDriver@02e6]     at Generator.next (<anonymous>)
[AppiumDriver@02e6]     at xA (/Users/admin/.appium/node_modules/appium-device-farm/lib/webpack:/appium-device-farm/lib/src/plugin.js:28:48)
[HTTP] <-- POST /wd/hub/session 500 3550 ms - 2064
[HTTP] 
[device-farm-main] Received error from remote node: {"message":"Request failed with status code 500","name":"AxiosError","stack":"AxiosError: Request failed with status code 500\n    at settle (/Users/admin/.appium/node_modules/appium-device-farm/node_modules/axios/lib/core/settle.js:19:12)\n    at IncomingMessage.handleStreamEnd (/Users/admin/.appium/node_modules/appium-device-farm/node_modules/axios/lib/adapters/http.js:589:11)\n    at IncomingMessage.emit (node:events:530:35)\n    at endReadableNT (node:internal/streams/readable:1696:12)\n    at processTicksAndRejections (node:internal/process/task_queues:82:21)\n    at Axios.request (/Users/admin/.appium/node_modules/appium-device-farm/node_modules/axios/lib/core/Axios.js:45:41)\n    at processTicksAndRejections (node:internal/process/task_queues:95:5)","config":{"transitional":{"silentJSONParsing":true,"forcedJSONParsing":true,"clarifyTimeoutError":false},"adapter":["xhr","http","fetch"],"transformRequest":[null],"transformResponse":[null],"timeout":260000,"xsrfCookieName":"XSRF-TOKEN","xsrfHeaderName":"X-XSRF-TOKEN","maxContentLength":-1,"maxBodyLength":-1,"env":{},"headers":{"Accept":"application/json, text/plain, */*","Content-Type":"application/json","User-Agent":"axios/1.7.2","Content-Length":"1328","Accept-Encoding":"gzip, compress, deflate, br"},"method":"post","url":"http://127.0.0.1:31337/wd/hub/session","data":"{\"capabilities\":{\"alwaysMatch\":{\"platformName\":\"iOS\",\"appium:automationName\":\"XCUITest\",\"appium:newCommandTimeout\":120,\"appium:udid\":\"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3\",\"df:skipReport\":true,\"appium:mjpegServerPort\":61621,\"appium:waitForQuiescence\":false,\"appium:wdaEventloopIdleDelay\":0,\"appium:eventLoopIdleDelaySec\":0,\"appium:waitForIdleTimeout\":0,\"appium:settings\":{\"mjpegServerFramerate\":34,\"mjpegServerScreenshotQuality\":75,\"mjpegScalingFactor\":100,\"animationCoolOffTimeout\":0},\"appium:usePreinstalledWDA\":true,\"appium:updatedWDABundleId\":\"me.mathiasb248.WebDriverAgentRunner.xctrunner\",\"appium:updatedWDABundleIdSuffix\":\"\",\"df:portForward\":true},\"firstMatch\":[{}]},\"desiredCapabilities\":{\"platformName\":\"iOS\",\"appium:automationName\":\"XCUITest\",\"appium:newCommandTimeout\":120,\"appium:udid\":\"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3\",\"df:skipReport\":true,\"appium:mjpegServerPort\":61621,\"appium:waitForQuiescence\":false,\"appium:wdaEventloopIdleDelay\":0,\"appium:eventLoopIdleDelaySec\":0,\"appium:waitForIdleTimeout\":0,\"appium:settings\":{\"mjpegServerFramerate\":34,\"mjpegServerScreenshotQuality\":75,\"mjpegScalingFactor\":100,\"animationCoolOffTimeout\":0},\"appium:usePreinstalledWDA\":true,\"appium:updatedWDABundleId\":\"me.mathiasb248.WebDriverAgentRunner.xctrunner\",\"appium:updatedWDABundleIdSuffix\":\"\",\"df:portForward\":true}}"},"code":"ERR_BAD_RESPONSE","status":500}
[HTTP] <-- POST /device-farm/api/dashboard/appiumSession 400 3565 ms - 2326
[HTTP] 
[HTTP] --> POST /device-farm/api/unblock
[HTTP] {"udid":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3","host":"http://192.168.1.100:31337"}
[device-farm-main] Received non-webdriver request with url /device-farm/api/unblock. So, not proxying it to downstream.
[device-farm-main] Updated devices with filter: {"udid":{"$in":"b4a1e53e81397fed8b95921cf13a0e2fa930c2f3"}}
[HTTP] <-- POST /device-farm/api/unblock 200 1 ms - 16
[HTTP] 
[device-farm-main] Found 0 device candidates to be released
[device-farm-main] Cleaning pending sessions...
[device-farm-main] No pending sessions to clean
[device-farm-main] Fetching local simulators
[device-farm-main] iOS Simulators: true
[device-farm-main] tvOS Simulators: false

This is also my server-config.json:

{
  "server": {
    "port": 31337,
    "plugin": {
      "device-farm": {
        "platform": "ios",
        "skipChromeDownload": true,
        "liveStreaming": true,
        "wdaBundleId": "me.mathiasb248.WebDriverAgentRunner"
      }
    }
  }
}

And this is my startup command:

sudo appium server -ka 800 --use-plugins=device-farm --config ./server-config.json -pa /wd/hub
saikrishna321 commented 5 months ago

Which client ur using?

user243256262 commented 5 months ago

Which client ur using?

What do you mean by client? I am running;

And latest version Appium with latest version appium-device-farm.

And I compiled the wda-resign.ipa from https://github.com/appium/WebDriverAgent because https://github.com/DanTheMan827/ios-app-signer wasn't working.

saikrishna321 commented 5 months ago

Client meaning Java-client, wdio, python or ruby ?

saikrishna321 commented 5 months ago

@user243256262 Please the latest rc version