Avoid rare crash concerning disk attributes
* Crash would occur under these circumstances: * Disk Attributes test was not selected * One or more other disk tests were selected * A non-blocking attribute error was detected
This commit is contained in:
parent
417241acb5
commit
86f0f1e5fd
1 changed files with 5 additions and 1 deletions
|
|
@ -198,7 +198,11 @@ class State():
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
# No blocking errors encountered, check for minor attribute failures
|
# No blocking errors encountered, check for minor attribute failures
|
||||||
if not disk.check_attributes(only_blocking=False):
|
if ('Disk Attributes' in disk.tests:
|
||||||
|
and not disk.tests['Disk Attributes'].failed
|
||||||
|
and not disk.check_attributes(only_blocking=False)):
|
||||||
|
# Mid-diag failure detected
|
||||||
|
LOG.warning('Disk attributes failure detected during diagnostics')
|
||||||
disk.tests['Disk Attributes'].failed = True
|
disk.tests['Disk Attributes'].failed = True
|
||||||
disk.tests['Disk Attributes'].set_status('Failed')
|
disk.tests['Disk Attributes'].set_status('Failed')
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue