mirror of
https://github.com/alexal1/Insomniac.git
synced 2026-04-26 10:05:50 +03:00
[GH-ISSUE #444] Error - module 'uiautomator2' has no attribute 'JSONRPCError' #848
Labels
No labels
bug
duplicate
enhancement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/Insomniac#848
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @codeclinic on GitHub (Sep 20, 2022).
Original GitHub issue: https://github.com/alexal1/Insomniac/issues/444
I keep getting the following error. It happens almost every session (possibly all sessions).
Here is the most recent crash log:
Crash-2022-09-20-17-10-30.zip
[09/20 17:10:30] Error - module 'uiautomator2' has no attribute 'JSONRPCError'
Traceback (most recent call last):
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\insomniac\device_facade.py", line 537, in scroll
self.viewV2.scroll.toEnd(max_swipes=1)
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\uiautomator2\session.py", line 1196, in call
return jsonrpc.scrollToEnd(selector, self.vertical,
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\uiautomator2_init_.py", line 546, in call
return self.server.jsonrpc_retry_call(self.method, params,
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\uiautomator2_init_.py", line 553, in jsonrpc_retry_call
return self.jsonrpc_call(*args, **kwargs)
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\uiautomator2_init_.py", line 645, in jsonrpc_call
raise err
uiautomator2.exceptions.UiObjectNotFoundError: -32001 Jsonrpc error: <android.support.test.uiautomator.UiObjectNotFoundException> data: UiSelector[CLASS=android.widget.ListView, RESOURCE_ID=android:id/list], method: scrollToEnd
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "insomniac/extra_features/session.py", line 277, in run
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\insomniac\action_runners\interact_init_.py", line 203, in run
job()
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\insomniac\safely_runner.py", line 24, in wrapper
return func(*args, **kwargs)
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\insomniac\action_runners\interact_init_.py", line 151, in job
handle_blogger(device_wrapper.get(),
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\insomniac\action_runners\interact\action_handle_blogger.py", line 234, in handle_blogger
followers_following_list_view.iterate_over_followers(is_myself, interact_with_follower, pre_conditions)
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\insomniac\views.py", line 1502, in iterate_over_followers
list_view.scroll(DeviceFacade.Direction.BOTTOM)
File "C:\Users\phill.pyenv\pyenv-win\versions\3.10.7\lib\site-packages\insomniac\device_facade.py", line 538, in scroll
except uiautomator2.JSONRPCError as e:
AttributeError: module 'uiautomator2' has no attribute 'JSONRPCError'
@evanpoliquin commented on GitHub (Oct 3, 2022):
I'm having the same issue on Linux Mint. Installed everything correctly and have no crashes using the same interaction.json file on Windows. Any help or explanation would be super appreciated! @alexal1
Crash-2022-10-03-13-22-59.zip
@giobbepelle commented on GitHub (Oct 14, 2022):
Error - module 'uiautomator2' has no attribute 'JSONRPCError'
Traceback (most recent call last):
File "/home/giobbe/.local/lib/python3.10/site-packages/insomniac/device_facade.py", line 537, in scroll
self.viewV2.scroll.toEnd(max_swipes=1)
File "/home/giobbe/.local/lib/python3.10/site-packages/uiautomator2/session.py", line 1196, in call
return jsonrpc.scrollToEnd(selector, self.vertical,
File "/home/giobbe/.local/lib/python3.10/site-packages/uiautomator2/init.py", line 546, in call
return self.server.jsonrpc_retry_call(self.method, params,
File "/home/giobbe/.local/lib/python3.10/site-packages/uiautomator2/init.py", line 553, in jsonrpc_retry_call
return self.jsonrpc_call(*args, **kwargs)
File "/home/giobbe/.local/lib/python3.10/site-packages/uiautomator2/init.py", line 645, in jsonrpc_call
raise err
uiautomator2.exceptions.UiObjectNotFoundError: -32001 Jsonrpc error: <android.support.test.uiautomator.UiObjectNotFoundException> data: UiSelector[CLASS=android.widget.ListView, RESOURCE_ID=android:id/list], method: scrollToEnd
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/giobbe/.local/lib/python3.10/site-packages/insomniac/session.py", line 361, in run
action_runner.run(device_wrapper,
File "/home/giobbe/.local/lib/python3.10/site-packages/insomniac/action_runners/interact/init.py", line 203, in run
job()
File "/home/giobbe/.local/lib/python3.10/site-packages/insomniac/safely_runner.py", line 24, in wrapper
return func(*args, **kwargs)
File "/home/giobbe/.local/lib/python3.10/site-packages/insomniac/action_runners/interact/init.py", line 151, in job
handle_blogger(device_wrapper.get(),
File "/home/giobbe/.local/lib/python3.10/site-packages/insomniac/action_runners/interact/action_handle_blogger.py", line 234, in handle_blogger
followers_following_list_view.iterate_over_followers(is_myself, interact_with_follower, pre_conditions)
File "/home/giobbe/.local/lib/python3.10/site-packages/insomniac/views.py", line 1502, in iterate_over_followers
list_view.scroll(DeviceFacade.Direction.BOTTOM)
File "/home/giobbe/.local/lib/python3.10/site-packages/insomniac/device_facade.py", line 538, in scroll
except uiautomator2.JSONRPCError as e:
AttributeError: module 'uiautomator2' has no attribute 'JSONRPCError'
I have a similar problem