Try both adb reconnect and adb reconnect device

Change-Id: I14b887ab474b6c709127af84aa77ecdbfff57d45
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/480216
Commit-Queue: Joe Gregorio <jcgregorio@google.com>
Reviewed-by: Ravi Mistry <rmistry@google.com>
This commit is contained in:
Joe Gregorio 2021-12-06 10:24:44 -05:00 committed by SkCQ
parent 8d95ffce92
commit efc32815ba
4 changed files with 145 additions and 13 deletions

View File

@ -88,7 +88,19 @@ class AndroidFlavor(default.DefaultFlavor):
def wait_for_device(attempt):
self.m.run(self.m.step,
'kill adb server after failure of \'%s\' (attempt %d)' % (
'adb reconnect after failure of \'%s\' (attempt %d)' % (
title, attempt),
cmd=[self.ADB_BINARY, 'reconnect'],
infra_step=True, timeout=30, abort_on_failure=False,
fail_build_on_failure=False)
self.m.run(self.m.step,
'wait for device after failure of \'%s\' (attempt %d)' % (
title, attempt),
cmd=[self.ADB_BINARY, 'wait-for-device'], infra_step=True,
timeout=180, abort_on_failure=False,
fail_build_on_failure=False)
self.m.run(self.m.step,
'adb reconnect device after failure of \'%s\' (attempt %d)' % (
title, attempt),
cmd=[self.ADB_BINARY, 'reconnect', 'device'],
infra_step=True, timeout=30, abort_on_failure=False,

View File

@ -898,8 +898,7 @@
{
"cmd": [
"/opt/infra-android/tools/adb",
"reconnect",
"device"
"reconnect"
],
"cwd": "[START_DIR]/skia",
"env": {
@ -908,7 +907,7 @@
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "kill adb server after failure of 'read /sdcard/revenge_of_the_skiabot/SK_IMAGE_VERSION' (attempt 1)",
"name": "adb reconnect after failure of 'read /sdcard/revenge_of_the_skiabot/SK_IMAGE_VERSION' (attempt 1)",
"timeout": 30
},
{
@ -926,6 +925,37 @@
"name": "wait for device after failure of 'read /sdcard/revenge_of_the_skiabot/SK_IMAGE_VERSION' (attempt 1)",
"timeout": 180
},
{
"cmd": [
"/opt/infra-android/tools/adb",
"reconnect",
"device"
],
"cwd": "[START_DIR]/skia",
"env": {
"ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey",
"CHROME_HEADLESS": "1",
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "adb reconnect device after failure of 'read /sdcard/revenge_of_the_skiabot/SK_IMAGE_VERSION' (attempt 1)",
"timeout": 30
},
{
"cmd": [
"/opt/infra-android/tools/adb",
"wait-for-device"
],
"cwd": "[START_DIR]/skia",
"env": {
"ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey",
"CHROME_HEADLESS": "1",
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "wait for device after failure of 'read /sdcard/revenge_of_the_skiabot/SK_IMAGE_VERSION' (attempt 1) (2)",
"timeout": 180
},
{
"cmd": [
"/opt/infra-android/tools/adb",

View File

@ -202,8 +202,7 @@
{
"cmd": [
"/opt/infra-android/tools/adb",
"reconnect",
"device"
"reconnect"
],
"cwd": "[START_DIR]/skia",
"env": {
@ -212,7 +211,7 @@
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "kill adb server after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 1)",
"name": "adb reconnect after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 1)",
"timeout": 30
},
{
@ -230,6 +229,37 @@
"name": "wait for device after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 1)",
"timeout": 180
},
{
"cmd": [
"/opt/infra-android/tools/adb",
"reconnect",
"device"
],
"cwd": "[START_DIR]/skia",
"env": {
"ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey",
"CHROME_HEADLESS": "1",
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "adb reconnect device after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 1)",
"timeout": 30
},
{
"cmd": [
"/opt/infra-android/tools/adb",
"wait-for-device"
],
"cwd": "[START_DIR]/skia",
"env": {
"ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey",
"CHROME_HEADLESS": "1",
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "wait for device after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 1) (2)",
"timeout": 180
},
{
"cmd": [
"/opt/infra-android/tools/adb",

View File

@ -202,8 +202,7 @@
{
"cmd": [
"/opt/infra-android/tools/adb",
"reconnect",
"device"
"reconnect"
],
"cwd": "[START_DIR]/skia",
"env": {
@ -212,7 +211,7 @@
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "kill adb server after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 1)",
"name": "adb reconnect after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 1)",
"timeout": 30
},
{
@ -230,6 +229,37 @@
"name": "wait for device after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 1)",
"timeout": 180
},
{
"cmd": [
"/opt/infra-android/tools/adb",
"reconnect",
"device"
],
"cwd": "[START_DIR]/skia",
"env": {
"ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey",
"CHROME_HEADLESS": "1",
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "adb reconnect device after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 1)",
"timeout": 30
},
{
"cmd": [
"/opt/infra-android/tools/adb",
"wait-for-device"
],
"cwd": "[START_DIR]/skia",
"env": {
"ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey",
"CHROME_HEADLESS": "1",
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "wait for device after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 1) (2)",
"timeout": 180
},
{
"cmd": [
"/opt/infra-android/tools/adb",
@ -253,8 +283,7 @@
{
"cmd": [
"/opt/infra-android/tools/adb",
"reconnect",
"device"
"reconnect"
],
"cwd": "[START_DIR]/skia",
"env": {
@ -263,7 +292,7 @@
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "kill adb server after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 2)",
"name": "adb reconnect after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 2)",
"timeout": 30
},
{
@ -281,6 +310,37 @@
"name": "wait for device after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 2)",
"timeout": 180
},
{
"cmd": [
"/opt/infra-android/tools/adb",
"reconnect",
"device"
],
"cwd": "[START_DIR]/skia",
"env": {
"ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey",
"CHROME_HEADLESS": "1",
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "adb reconnect device after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 2)",
"timeout": 30
},
{
"cmd": [
"/opt/infra-android/tools/adb",
"wait-for-device"
],
"cwd": "[START_DIR]/skia",
"env": {
"ADB_VENDOR_KEYS": "/home/chrome-bot/.android/chrome_infrastructure_adbkey",
"CHROME_HEADLESS": "1",
"PATH": "<PATH>:RECIPE_REPO[depot_tools]"
},
"infra_step": true,
"name": "wait for device after failure of 'mkdir /sdcard/revenge_of_the_skiabot/resources' (attempt 2) (2)",
"timeout": 180
},
{
"cmd": [
"/opt/infra-android/tools/adb",