Skip to content
Snippets Groups Projects
Commit a9168cfb authored by ale's avatar ale
Browse files

Do not fail if no SMART self-tests were ever run

parent f2972b7b
No related branches found
No related tags found
No related merge requests found
Pipeline #82663 passed
...@@ -193,7 +193,8 @@ def smartd_devices(config='/etc/smartd.conf'): ...@@ -193,7 +193,8 @@ def smartd_devices(config='/etc/smartd.conf'):
def collect_self_test_status(device, data): def collect_self_test_status(device, data):
"""Extract SMART self-test status from logs.""" """Extract SMART self-test status from logs."""
if 'ata_smart_self_test_log' not in data: if 'ata_smart_self_test_log' not in data or \
'table' not in data['ata_smart_self_test_log']['standard']:
return return
# Attempt to extract the most recent self test status by type. # Attempt to extract the most recent self test status by type.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment