Skip to content
This repository has been archived by the owner on Nov 23, 2023. It is now read-only.

scroll to element issue #26

Open
wsfcsk opened this issue Feb 17, 2023 · 0 comments
Open

scroll to element issue #26

wsfcsk opened this issue Feb 17, 2023 · 0 comments

Comments

@wsfcsk
Copy link

wsfcsk commented Feb 17, 2023

HI Team
The scroll element function does not support the listView ,because it's used the flutter driver function:scrollIntoView , but it's not used when the element is listView , I tried to use scrollUntilVisible instead in your python lib :

code:

def scroll_listView(self,ele_locator):
application = self._current_application()
list_view = self._element_finder.find(application,"type=ListView")
element = self._element_finder.find(application, ele_locator)
print(list_view)
print(element)
application.execute_script('flutter:scrollUntilVisible',list_view, {"item":element, "dxScroll": 90, "dyScroll": -400})

but it's not working as error below:

error details :

WebDriverException: Message: An unknown server-side error occurred while processing the command. Original error: input is invalid {"element-6066-11e4-a52e-4f735466cecf":"eyJmaW5kZXJUeXBlIjoiQnlUeXBlIiwidHlwZSI6Ikxpc3RWaWV3In0="}
Stacktrace:
UnknownError: An unknown server-side error occurred while processing the command. Original error: input is invalid {"element-6066-11e4-a52e-4f735466cecf":"eyJmaW5kZXJUeXBlIjoiQnlUeXBlIiwidHlwZSI6Ikxpc3RWaWV3In0="}
at getResponseForW3CError (/opt/homebrew/lib/node_modules/appium/node_modules/@appium/base-driver/lib/protocol/errors.js:1067:9)
at asyncHandler (/opt/homebrew/lib/node_modules/appium/node_modules/@appium/base-driver/lib/protocol/protocol.js:476:57)
at runNextTicks (node:internal/process/task_queues:60:5)
at processImmediate (node:internal/timers:442:9)

could you help this ??

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant