serhatbolsu / robotframework-appiumlibrary

AppiumLibrary is an appium testing library for RobotFramework
Apache License 2.0
403 stars 291 forks source link

gives an error for xpath" (//div[contains(@class,'no-result-contact-info')]/p)[1]" InvalidArgumentException: #411

Open prakashAadhirai opened 11 months ago

prakashAadhirai commented 11 months ago

(//div[contains(@class,'no-result-contact-info')]/p)[1] FAIL InvalidArgumentException: Message: invalid argument: invalid locator

This type of above Xpath [1] or ( used ) robotframework-appiumlibrary is not supporting is there any work around. Libaray used Appium-Python-Client 3.1.0 robotframework-appiumlibrary 2.0.0

Dor-bl commented 10 months ago

Same issue for me when using Indexed XPATH. i.e. (//XCUIElementTypeButton[@name="CowDetailCell_SaveButton"])[8]

robotframework-appiumlibrary 2.0.0
Appium-Python-Client==2.7.1
mit4ever commented 10 months ago

u can try xpath=(//XCUIElementTypeButton[@name="CowDetailCell_SaveButton"])[8]

Dor-bl commented 10 months ago

You mean prefix the xpath=?

michaljirka1-ext43891 commented 3 weeks ago

Hello, Im dealing with the same problem in my project. This type of locator is working only with the xpath= prefix. I would like to kindly ask you if you plan to solve this issue in any of te upcoming releases?

Thank you, Michal