'Appium mac - XCUI test failing

We are running test cases as part of pipeline in lab Random times test cases are failing with this error

Feb 11, 2022 11:05:09 AM io.appium.java_client.remote.AppiumCommandExecutor$1 lambda$0
INFO: Detected dialect: W3C
[HTTP] --> GET /wd/hub/session/67f020a4-2a7a-4d5f-b8b8-3988315bd8b5/screenshot
[HTTP] {}
[W3C (67f020a4)] Driver proxy active, passing request on via HTTP proxy
[debug] [WD Proxy] Matched '/wd/hub/session/67f020a4-2a7a-4d5f-b8b8-3988315bd8b5/screenshot' to command name 'getScreenshot'
[debug] [WD Proxy] Proxying [GET /wd/hub/session/67f020a4-2a7a-4d5f-b8b8-3988315bd8b5/screenshot] to [GET http://127.0.0.1:10100/session/91A2EE89-04DD-4636-9A2D-4344B257FCAF/screenshot] with no body
[debug] [WD Proxy] Got response with status 200: {"value":"iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAAAAAA6fptVAAANBGlDQ1BrQ0dDb2xv\r\nclNwYWNlR2VuZXJpY0dyYXlHYW1tYTJfMgAAWIWlVwdck9cWv9/IAJKwp4ywkWVA\r\ngQAyIjOA7CG4iEkggRBiBgLiQooVrFscOCoqilpcFYE6UYtW6satD2qpoNRiLS6s\r\nvpsEEKvte+/3vvzud//fPefcc8495557A4DuRo5EIkIBAHliuTQikZU+KT2DTroH\r\nyMAYaAN3oM3hyiSs+PgYyALE+WI++OR5cQMgyv6am3KuT+n/+BB4fBkX9idhK+LJ\r\nuHkAIOMBIJtxJVI5ABqT4LjtLLlEiUsgNshNTgyBeDnkoQzKKh+rCL6YLxVy6RFS\r\nThE9gpOXx6F7unvS46X5WULRZ6z+f588kWJYN2wUWW5SNOzdof1lPE6oEvtBfJDL\r\nCUuCmAlxb4EwNRbiYABQO4l8QiLEURDzFLkpLIhdIa7PkoanQBwI8R2BIlKJxwGA\r\nmRQLktMgNoM4Jjc/WilrA3GWeEZsnFoX9iVXFpIBsRPELQI+WxkzO4gfS/MTlTzO\r\nAOA0Hj80DGJoB84UytnJg7hcVpAUprYTv14sCIlV6yJQcjhR8RA7QOzAF0Ukquch\r\nxEjk8co54TehQCyKjVH7RTjHl6n8hd9EslyQHAmxJ8TJcmlyotoeYnmWMJwNcTjE\r\nuwXSyES1v8Q+iUiVZ3BNSO4caViEek1IhVJFYoraR9J2vjhFOT/MEdIDkIpwAB/k\r\ngxnwzQVi0AnoQAaEoECFsgEH5MFGhxa4whYBucSwSSGHDOSqOKSga5g+JKGUcQMS\r\nSMsHWZBXBCWHxumAB2dQSypnyYdN+aWcuVs1xh3U6A5biOUOoIBfAtAL6QKIJoIO\r\n1UghtDAP9iFwVAFp2RCP1KKWj1dZq7aBPmh/z6CWfJUtnGG5D7aFQLoYFMM...
[WD Proxy] Replacing sessionId 91A2EE89-04DD-4636-9A2D-4344B257FCAF with 67f020a4-2a7a-4d5f-b8b8-3988315bd8b5
[HTTP] <-- GET /wd/hub/session/67f020a4-2a7a-4d5f-b8b8-3988315bd8b5/screenshot 200 429 ms - 5007
[HTTP] 
[debug] [WebDriverAgentMac] [xcodebuild] Test Case '-[UITestingUITests testRunner]' failed (61.453 seconds).
[debug] [WebDriverAgentMac] Test Suite 'UITestingUITests' failed at 2022-02-11 11:05:10.092.
[debug] [WebDriverAgentMac]      Executed 1 test, with 1 failure (0 unexpected) in 61.453 (61.455) seconds
[debug] [WebDriverAgentMac] Test Suite 'WebDriverAgentRunner.xctest' failed at 2022-02-11 11:05:10.092.
[debug] [WebDriverAgentMac]      Executed 1 test, with 1 failure (0 unexpected) in 61.453 (61.456) seconds
[debug] [WebDriverAgentMac] Test Suite 'All tests' failed at 2022-02-11 11:05:10.093.
[debug] [WebDriverAgentMac]      Executed 1 test, with 1 failure (0 unexpected) in 61.453 (61.457) seconds
[HTTP] --> POST /wd/hub/session/67f020a4-2a7a-4d5f-b8b8-3988315bd8b5/elements
[HTTP] {"using":"accessibility id","value":"profile"}
[debug] [W3C (67f020a4)] Calling AppiumDriver.findElements() with args: ["accessibility id","profile","67f020a4-2a7a-4d5f-b8b8-3988315bd8b5"]
[debug] [BaseDriver] Valid locator strategies for this request: id, name, accessibility id, xpath, class name, -ios predicate string, predicate string, -ios class chain, class chain
[debug] [WD Proxy] Matched '/elements' to command name 'findElements'
[debug] [WD Proxy] Proxying [POST /elements] to [POST http://127.0.0.1:10100/session/91A2EE89-04DD-4636-9A2D-4344B257FCAF/elements] with body: {"using":"accessibility id","value":"profile"}
[WD Proxy] connect ECONNREFUSED 127.0.0.1:10100
[debug] [W3C (67f020a4)] Encountered internal error running command: UnknownError: An unknown server-side error occurred while processing the command. Original error: Could not proxy command to the remote server. Original error: connect ECONNREFUSED 127.0.0.1:10100
[debug] [W3C (67f020a4)]     at WDAMacProxy.command (/usr/local/lib/node_modules/appium/node_modules/appium-base-driver/lib/jsonwp-proxy/proxy.js:274:13)
[debug] [W3C (67f020a4)]     at processTicksAndRejections (node:internal/process/task_queues:96:5)
[debug] [W3C (67f020a4)]     at Mac2Driver.findElOrEls (/usr/local/lib/node_modules/appium/node_modules/appium-mac2-driver/lib/commands/find.js:17:10)
[debug] [W3C (67f020a4)]     at Mac2Driver.findElOrElsWithProcessing (/usr/local/lib/node_modules/appium/node_modules/appium-base-driver/lib/basedriver/commands/find.js:33:12)
[debug] [W3C (67f020a4)]     at Mac2Driver.findElements (/usr/local/lib/node_modules/appium/node_modules/appium-base-driver/lib/basedriver/commands/find.js:63:10)
[HTTP] <-- POST /wd/hub/session/67f020a4-2a7a-4d5f-b8b8-3988315bd8b5/elements 500 46 ms - 1065

Anything I can do to fix this?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source