-
-
Notifications
You must be signed in to change notification settings - Fork 770
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
Can not use command "select" to operate a dropdown list #1848
Comments
@heandping - Idk why but could you see if value=30 works better than label=30? |
@toddtarsi , Thanks for the suggestion, I will try to use value instead of label |
Yes, select locator value=30 can work now, just curious why label fails, anyway this doesn't block me. |
@heandping - To give you some idea, first we use a selector to get the element reference. From there, each option strategy does something different to get the child locator. For label, which I've struggled with, we have to use xpath. This is my xpath to go from the select to the option:
It's supposed to go like one child down and check for a text match? I suck at xpath, but I bet I need some crud like this on the . part in the bracket.
|
Yeah, circling back on this. I bet it's that space before and after 10, 30, 50, and 100. I think I'll just make a test for this permutation. Should be easily fixed in core. |
Im using selenium IDE is 4.0.1-beta.13, chrome is Version 126.0.6478.127 (Official Build) (arm64)
Try to select from dropdown list, but failed here
Here is the page DOM
Error pasted here:
0:38:46 AM [warn] [
'Unexpected error occured during command:',
'select-xpath=//select[@name="perPageSelect"]-label=30',
'retrying...'
]
10:38:46 AM [error] [
no such element: Unable to locate element: {"method":"xpath","selector":".//option[. = '30']"}\n
+' (Session info: chrome=120.0.6099.291)'
]
10:38:50 AM [debug] [
'Playing state changed errored for test I009 - Alter the number of the displayed items per page'
]
10:38:50 AM [debug] [ 'Releasing window for playback' ]
10:38:50 AM [error] [
Error: Operation timed out during select:xpath=//select[@name="perPageSelect"]:label=30
at Timeout._onTimeout (/Users/heyong/.nvm/versions/node/v16.20.2/lib/node_modules/selenium-ide/build/webpack:/side-runtime/src/playback-tree/command-node.ts:187:13)
at listOnTimeout (node:internal/timers:569:17)
at processTimers (node:internal/timers:512:7)
]
10:38:50 AM [error] [
'Command failure:',
'select-xpath=//select[@name="perPageSelect"]-label=30'
]
The text was updated successfully, but these errors were encountered: