i am trying to run tests for real device on sauce labs and there are few issues i am facing
- Appium abruptly gets stuck in between appears to have stopped without any failure and it tries to wait for some alert? but in our application we are not waiting for any alert
for example after looking for an element it has to tap on that element so it tries to find the location but suddenly it is looking for alert modal window which we have not scripted.
here are the logs
00:43:57 V [debug] [MJSONWP (e592bfa5)] Calling AppiumDriver.getLocation() with args: [“5158”,“e592bfa5-bec8-4e8a-b7f6-65e9b6cd4147”]
00:43:57 V [debug] [XCUITest] Executing command ‘getLocation’
00:43:57 V [debug] [RemoteDebugger] Executing atom ‘get_top_left_coordinates’ with ‘args=[{“ELEMENT”:":wdc:1645404121898"}]; frames=’
00:43:57 V [debug] [RemoteDebugger] Executing ‘get_top_left_coordinates’ atom in default context
00:43:57 V [debug] [RemoteDebugger] Sending javascript command: ‘(function(){return function(){var h,l=this;func…’
00:43:57 V [debug] [RemoteDebugger] Sending ‘_rpc_forwardSocketData:’ message to app ‘PID:69738’, page ‘1’, target ‘page-12’ (id: 830): ‘Runtime.evaluate’
00:43:58 V [debug] [XCUITest] Setting custom timeout to 60000 ms for ‘getAlertText’ command
00:43:58 V [debug] [WD Proxy] Matched ‘/alert/text’ to command name ‘getAlertText’
00:43:58 V [debug] [WD Proxy] Proxying [GET /alert/text] to [GET http://127.0.0.1:5711/session/B2DB2ED9-720E-4888-98B7-E586471744F9/alert/text] with no body
00:43:58 V [WD Proxy] Got response with status 404: {“value”:{“error”:“no such alert”,“message”:“An attempt was made to operate on a modal dialog when one was not open”,“traceback”:""},“sessionId”:“B2DB2ED9-720E-4888-98B7-E586471744F9”}
00:43:58 V [debug] [W3C] Matched W3C error code ‘no such alert’ to NoSuchAlertError
is this internally from appium? how can we avoid this?
- When i try to run with latest appium version 1.21.1 or 1.22.2
i get Appium did not get any response from ‘getScreenInfo’ command in 60000 ms (WARNING: The server did not provide any stack trace information)
i am passing capabilities like
{
“platformName”: “iOS”,
“platformVersion”: “14”,
“deviceName”: “(iPhone)(((?!(?i)SE).)*$)”,
“deviceOrientation”: “portrait”,
“app”: “storage:filename=SAPAnalyticiOS-Debug-2022.04.ipa”,
“appiumVersion”: “1.21.1”,
“autoAcceptAlerts”: true,
“tunnelIdentifier”: “",
“parentTunnel”: "***”,
“commandTimeout”: 600,
“idleTimeout”: 1000
}
some info has been hidden due to privacy concern
please help this has been causing flaky tests
Thanks in advance!