openatx / adbutils

pure python adb library for google adb service.
MIT License
781 stars 180 forks source link

ConnectionResetError: [WinError 10054] An existing connection was forcibly closed by the remote host #131

Open ok-oldking opened 4 months ago

ok-oldking commented 4 months ago
def read(self, n: int) -> bytes:
      try:
          return self._read_fully(n)
      except socket.timeout:
          raise AdbTimeout("adb read timeout")

read的时候,如果adb.exe被别的进程杀掉可能会报ConnectionResetError,是否也catch尝试重连? File "D:\projects\ok-baijing\venv\Lib\site-packages\adbutils_adb.py", line 106, in _read_fully chunk = self.conn.recv(t) ^^^^^^^^^^^^^^^^^ ConnectionResetError: [WinError 10054] An existing connection was forcibly closed by the remote host