taobao-iphone-device tidevice启动wda报错BrokenPipeError: [Errno 32] Broken pipe

but5z9lq  于 2022-10-26  发布在  其他
关注(0)|答案(1)|浏览(338)

iPhone8 IOS14.1
使用tidevice启动命令tidevice xctest -B com.XX.xctrunner报错如下:

Traceback (most recent call last):
  File "/Users/XXX/Library/Python/3.8/bin/tidevice", line 10, in <module>
    sys.exit(main())
  File "/Users/XXX/Library/Python/3.8/lib/python/site-packages/tidevice/__main__.py", line 519, in main
    actions[args.subparser](args)
  File "/Users/XXX/Library/Python/3.8/lib/python/site-packages/tidevice/__main__.py", line 262, in cmd_launch
    pid = d.instruments.app_launch(args.bundle_id,
  File "/Users/XXX/Library/Python/3.8/lib/python/site-packages/tidevice/_instruments.py", line 636, in app_launch
    code = self.make_channel(self._SERVICE_PROCESS_CONTROL)
  File "/Users/XXX/Library/Python/3.8/lib/python/site-packages/tidevice/_instruments.py", line 313, in make_channel
    result = self.call_message(0, '_requestChannelWithCode:identifier:', aux)
  File "/Users/XXX/Library/Python/3.8/lib/python/site-packages/tidevice/_instruments.py", line 354, in call_message
    _id = self.send_dtx_message(channel,
  File "/Users/XXX/Library/Python/3.8/lib/python/site-packages/tidevice/_instruments.py", line 390, in send_dtx_message
    self.sendall(data)
  File "/Users/XXX/Library/Python/3.8/lib/python/site-packages/tidevice/_safe_socket.py", line 63, in sendall
    return self._sock.sendall(data)
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/ssl.py", line 1204, in sendall
    v = self.send(byte_view[count:])
  File "/Applications/Xcode.app/Contents/Developer/Library/Frameworks/Python3.framework/Versions/3.8/lib/python3.8/ssl.py", line 1173, in send
    return self._sslobj.write(data)
BrokenPipeError: [Errno 32] Broken pipe

使用Xcode启动xctrunner正常。并且监控到手机lockdownd进程有如下通信区别。

tidevice 启动下lockdownd日志

Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 testmanagerd[275] <Notice>: IDE connected via lockdown over socket 5, with SSL
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 testmanagerd[275] <Notice>: IDE connected via lockdown over socket 9, with SSL
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:38:22 DTServiceHub[279] <Notice>: incoming connection for service: com.apple.instruments.deviceservice.lockdown.secure
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:38:22 testmanagerd[275] <Notice>: Disconnected lockdown socket
Sep 17 21:38:22 testmanagerd[275] <Notice>: Disconnected lockdown socket
Sep 17 21:38:22 testmanagerd[275] <Notice>: Shutting down lockdown socket
Sep 17 21:38:22 testmanagerd[275] <Notice>: Shutting down lockdown socket

Xcode启动下,lockdownd日志

Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:33 testmanagerd[275] <Notice>: IDE connected via lockdown over socket 11, with SSL
Sep 17 21:44:33 testmanagerd[275] <Notice>: IDE connected via lockdown over socket 13, with SSL
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:33 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 DTServiceHub[279] <Notice>: incoming connection for service: com.apple.instruments.deviceservice.lockdown.secure
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:34 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 DTServiceHub[279] <Notice>: incoming connection for service: com.apple.instruments.deviceservice.lockdown.secure
Sep 17 21:44:35 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 DTServiceHub[279] <Notice>: incoming connection for service: com.apple.instruments.deviceservice.lockdown.secure
Sep 17 21:44:35 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_start_service: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: spawn_xpc_service: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: handle_get_value: <private>
Sep 17 21:44:35 DTServiceHub[279] <Notice>: incoming connection for service: com.apple.instruments.deviceservice.lockdown.secure
Sep 17 21:44:35 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>
Sep 17 21:44:35 lockdownd[8907] <Notice>: spawn_xpc_service_block_invoke: <private>

请问如何解决上诉问题?

相关问题