Skip to content
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

uiautomator2 uninstall add -s/--serial support #934

Open
ponponon opened this issue Jan 18, 2024 · 0 comments
Open

uiautomator2 uninstall add -s/--serial support #934

ponponon opened this issue Jan 18, 2024 · 0 comments
Assignees

Comments

@ponponon
Copy link

╰─➤  python -m uiautomator2 uninstall 192.168.168.27:42659                                                                                                                                                                                                      1 ↵

Traceback (most recent call last):
  File "/opt/homebrew/Cellar/python@3.10/3.10.13_1/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/opt/homebrew/Cellar/python@3.10/3.10.13_1/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/Users/ponponon/.local/share/virtualenvs/wechatimagesearch-ut6SlEe8/lib/python3.10/site-packages/uiautomator2/__main__.py", line 289, in <module>
    main()
  File "/Users/ponponon/.local/share/virtualenvs/wechatimagesearch-ut6SlEe8/lib/python3.10/site-packages/uiautomator2/__main__.py", line 279, in main
    actions[args.subparser](args)
  File "/Users/ponponon/.local/share/virtualenvs/wechatimagesearch-ut6SlEe8/lib/python3.10/site-packages/uiautomator2/__main__.py", line 65, in cmd_uninstall
    d = u2.connect(args.serial)
  File "/Users/ponponon/.local/share/virtualenvs/wechatimagesearch-ut6SlEe8/lib/python3.10/site-packages/uiautomator2/__init__.py", line 1928, in connect
    return connect_usb(addr)
  File "/Users/ponponon/.local/share/virtualenvs/wechatimagesearch-ut6SlEe8/lib/python3.10/site-packages/uiautomator2/__init__.py", line 1967, in connect_usb
    device = adbutils.adb.device()
  File "/Users/ponponon/.local/share/virtualenvs/wechatimagesearch-ut6SlEe8/lib/python3.10/site-packages/adbutils/__init__.py", line 81, in device
    raise RuntimeError(
RuntimeError: more than one device/emulator, please specify the serial number

有两个设备,怎么指定 uninstall 哪个?python -m uiautomator2 uninstall 192.168.168.27:42659 这样的格式不对

╰─➤  adb devices                                                                                                                                                                                                                                                1 ↵
List of devices attached
192.168.168.27:42659    device
adb-WW59LJ594T8HVGO7-3NJYYA._adb-tls-connect._tcp.      device
@codeskyblue codeskyblue changed the title RuntimeError: more than one device/emulator, please specify the serial number uiautomator2 uninstall add -s/--serial support May 1, 2024
@codeskyblue codeskyblue self-assigned this May 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants