mirror of
https://gitee.com/sui-feng-cb/AzurLaneAutoScript1
synced 2026-03-13 02:06:59 +08:00
Fix: [ALAS] Trying to handle AdbError: unknown host service
(cherry picked from commit 59ad8bd6fcd4b63ab9a557b1bd11aa92fb071e13)
This commit is contained in:
@@ -1,16 +1,16 @@
|
||||
import re
|
||||
import time
|
||||
from functools import wraps
|
||||
|
||||
import cv2
|
||||
import numpy as np
|
||||
import time
|
||||
from adbutils.errors import AdbError
|
||||
from lxml import etree
|
||||
|
||||
from module.base.decorator import Config
|
||||
from module.device.connection import Connection
|
||||
from module.device.method.utils import (RETRY_TRIES, retry_sleep, remove_prefix, handle_adb_error,
|
||||
ImageTruncated, PackageNotInstalled)
|
||||
from module.device.method.utils import (ImageTruncated, PackageNotInstalled, RETRY_TRIES, handle_adb_error,
|
||||
handle_unknown_host_service, remove_prefix, retry_sleep)
|
||||
from module.exception import RequestHumanTakeover, ScriptError
|
||||
from module.logger import logger
|
||||
|
||||
@@ -43,6 +43,10 @@ def retry(func):
|
||||
if handle_adb_error(e):
|
||||
def init():
|
||||
self.adb_reconnect()
|
||||
elif handle_unknown_host_service(e):
|
||||
def init():
|
||||
self.adb_start_server()
|
||||
self.adb_reconnect()
|
||||
else:
|
||||
break
|
||||
# Package not installed
|
||||
|
||||
Reference in New Issue
Block a user