Commit dceee4ae authored by erikchen's avatar erikchen Committed by Commit Bot

Handle nil return from ColorSyncDeviceCopyDeviceInfo.

ColorSyncDeviceCopyDeviceInfo sometimes returns nil. The GPU test framework
should gracefully handle this failure.

Bug: 888035
Cq-Include-Trybots: luci.chromium.try:android_optional_gpu_tests_rel;luci.chromium.try:linux_optional_gpu_tests_rel;luci.chromium.try:mac_optional_gpu_tests_rel;luci.chromium.try:win_optional_gpu_tests_rel
Change-Id: I6374f2ef01e6272a7220a030e1e0ff5ecdaa80b9
Reviewed-on: https://chromium-review.googlesource.com/1238780Reviewed-by: default avatarKenneth Russell <kbr@chromium.org>
Commit-Queue: Erik Chen <erikchen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#593596}
parent 9d7e1613
...@@ -80,6 +80,8 @@ def GetDisplaysToProfileURLMap(): ...@@ -80,6 +80,8 @@ def GetDisplaysToProfileURLMap():
device_info = ColorSyncDeviceCopyDeviceInfo( device_info = ColorSyncDeviceCopyDeviceInfo(
kColorSyncDisplayDeviceClass, kColorSyncDisplayDeviceClass,
CGDisplayCreateUUIDFromDisplayID(display_id)) CGDisplayCreateUUIDFromDisplayID(display_id))
if not device_info:
raise Exception('KVM connection on bot is broken, please file a bug')
device_id = device_info['DeviceID'] device_id = device_info['DeviceID']
custom_profile_url = None custom_profile_url = None
if 'CustomProfiles' in device_info and '1' in device_info['CustomProfiles']: if 'CustomProfiles' in device_info and '1' in device_info['CustomProfiles']:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment