-
-
Notifications
You must be signed in to change notification settings - Fork 6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Clicks on elements don't work properly on iPad and iPhone 10.0+ in landscape mode #6994
Comments
@mykola-mokhnach I'm having the same issue with our app, unfortunately our app only supports iPad landscape mode therefore we were unable to run any tests since the xcode 8.0 upgrade. As you mentioned it worked fine before the upgrade. |
I have exactly the same issue with my app in the landscape mode. Works fine in portrait though. |
What is actually possible, we can intercept all calls to click and other similar methods in an inherited AppiumDriver instance, translate coordinates manually for landscape mode only and then execute click by coordinates instead. But i's going to be slow and lousy way of doing things %/ |
This is really turning out to be a blocking issue for me as I am trying to automate a video player app which always is launched on Landscape view. Hardcoding elements x-y co-ordinates could be one workaround but not sure how viable it is as we run our tests across a combination of different devices. |
@imurchie Could you please add this to the list of known issues in the official documentation? |
I am experiencing same issue. I have been trying to set coordinates manually for landscape mode, but it's really annoying and I couldn't not use tests for cross devices testing. Do you have an idea when it's going to be fixed? |
I am seeing this on iphone also. This issue might also be related appium/appium-xcuitest-driver#209 |
@imurchie Would this issue be part on 1.6.1? this is blocking us with all our tests since our app only supports Landscape mode :( |
@joshrlesch :any idea why is this thread closed ? |
My app too switches to landscape on launch. Same observation in 1.6.1 beta. It clicks at wrong location and if I force my app to portrait in it's code, click/sendkey/tap work well. Unfortunately, my app is supposed to be tested on Ls and eagerly waiting for the fix. https://discuss.appium.io/t/ios-10-hybrid-app-webview-tap-with-offset-not-working/13025/2 |
We are eagerly awaiting a fix too. Apple is aware of the problem. |
The issue seems to be fixed in the most recent WDA master branch. Just update the submodule for the upcoming Appium release |
@mykola-mokhnach I have updated to Appium 1.6.1 today and i still see this issue. Do we still need to update dependencies ? I had it done when 1.6.0 was installed. Even if i ran bootstrap.sh now it just doesn't show any updates except "fetching dependencies". Is there a way to clean the dependencies and get them again if required? |
@gopi09m Appium update won't help, since 1.6.1 does not include the source needed to fix the problem. Either update the webdriver sources manually or wait until Appium 1.6.2 is released. |
Can you let me know how do i update WDA master branch alone ? Download and Copy the code folder manually ? Or is there a npm command for that ? I downloaded it from : https://github.com/facebook/WebDriverAgent and |
1.6.2 is released now, so I'd just try that |
Jonathan, Thanks for the update. I appreciate your continuous efforts and support. I could install 1.6.2. However, my test execution is stuck at: I see that my application and WebDriverAgent get installed and the WebDriverAgent starts and .. nothing .. App doesn't launch. I ensured that WebDriverAgent is signed and my application.app works. Am I missing something else? |
Hi @jlipps , I have updated the appium version to 1.6.2. After updating the appium i am facing an issue while launching simulator like killing all simulator. Thanks. |
Hi, We are seeing this issue using iOS 9 only, seems like the issue is resolved is iOS 10. |
@mzvuluni facebookarchive/WebDriverAgent#411 should fix the issue. The problem is, that XCTest returns correct location in landscape mode for elements in 9.3, but this was broken in 10.0+ |
@mykola-mokhnach thanks for that. |
Verified on 1.6.3 on iOS 10.0.2 and XCode 8. But, landscape mode click issue still persists. Clicks work for some elements if dynamic id locators are used (ext-element-xx .. ) though. Yet won't be able to proceed with my app tests. Hoping to see the fix (facebookarchive/WebDriverAgent#411) after Christmas. |
Good to see that the fix (facebookarchive/WebDriverAgent#411) is merged. Would love to see it working in the next Appium release. |
You can use it now if you upgrade to |
@imurchie, I updated the xcuitest-driver to 2.5.4 by "npm install -g appium-xcuitest-driver@2.5.4".
But, when I run the test code with Appium, I see the log:
And, the landscape issue persists, as I guess its still using the older version of xcuitest-driver. |
@maesiva You need to install it within the Appium installation for it to work. Or you can re-install the whole thing with |
For those who refer above & are wondering what is |
@imurchie Thanks for the installation instruction. I could install Appium with latest xcuitest-driver.
However, I am still facing the Landscape issue. Is driver version supposed to be 2.5.4 ? And, like earlier, SendKeys() / Click() work, if I use the dynamic ids .. like "ext-element-24". but, I can't rely on it, as the dynamic IDs tend to change often. Test Code and Appium server logs shared on gist here: I appreciate your continuous support and help. |
If I call driver.getPageSource() before SendKeys: And, if I use regular ID for id field and dynamic ID for Password field, I could see the password is typed in while execution, but not the id field.
Please let me know if I can dig in any further. |
@mykola-mokhnach No luck.. Server logs show 200 for all 3 element sendkey/clicks.. But, on screen, no ui action is observed. My application is Cordova based hybrid app and runs in Landscape mode. I'm using iPad Mini 4 with iOS 10.0.2 (MK9J2CL/A) Can you please help me in getting through the Click/SendKeys ? I've been stuck with the issue ever since Dev team upgraded to XCode 8.x and I moved to Appium 1.6.. due to the notorious introduction of XCUITest by Apple. I appreciate any hints / workarounds / offset approaches. Please let me know if any logs or further information is required. |
@maesiva Sorry, I don't have physical capability and time to investigate the thing for all possible cases. I'm doing the stuff as a non-paid contributor and testing these workarounds in our local environment, that Wire uses for automated testing. |
I've got the same issue. Our app only supports landscape. At the moment I can not execute any testcases. |
Is there any update for this problem? |
I was having the same issue in iOS 9 devices. Here is the code sample code.
` Here is the method : |
I am having this same issue. Appium - v1.7.2 |
Just want to make everyone aware that this is still an issue using iOS 12 on an iPad. We will investigate the issue further when we get a chance. |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
The problem
Triggering WebElement->click method on iPad 10.0 simulator in landscape mode does work properly and always clicks at wrong location. At the same time it works as expected in portrait mode.
Environment
Details
This is, most likely, bug in XCTest framework itself and I have already reported it to Apple bugtracker, but, probably, we can introduce a workaround or add it to the official documentation as known issue. Although, the described problem is not reproducible in iPad simulator 9.3. It only started to fail after I upgraded Xcode to version 8.0. It looks like XCTest always assumes we are in portrait mode and calculates wrong coordinates for clicking.
I've tried to directly call WDA methods like setOrientation and setRotation, but neither of them helps to workaround the problem.
Reference to the other known issue: facebookarchive/WebDriverAgent#300
Code To Reproduce Issue [ Good To Have ]
The text was updated successfully, but these errors were encountered: