commit 9889ab2c1a549d0bd91d969f8af09e1df8279681
Author: Richard Pioso <email address hidden>
Date: Fri Oct 28 20:11:18 2016 -0400
DRAC get_bios_config() passthru causes exception
The DRAC driver's (pxe_drac) get_bios_config() vendor passthru method
raises an AttributeError exception. It no longer returns the current
BIOS configuration. This is a regression from stable/mitaka.
Triage found that get_bios_config() mistakenly treats the value returned
by python-dracclient's list_bios_settings() as containing named tuples.
When it calls the namedtuple _asdict() method, an AttributeError
exception is raised.
Revert get_bios_config()'s handling of the return value to use __dict__.
Remove the comment that is not consistent with the implementation.
Also revert the unit test case for a successful call to use mock to
create the return value. Use mock.NonCallableMock with an empty
specification (spec) to catch this type of bug in the future.
Change-Id: I94afaa72a1ef25efc1b622e29e3a92a5d27f1892
Closes-Bug: #1637671
(cherry picked from commit 6d6cf18f3171f42af1567c65240a7a6a759377c2)
Reviewed: https:/ /review. openstack. org/392548 /git.openstack. org/cgit/ openstack/ ironic/ commit/ ?id=9889ab2c1a5 49d0bd91d969f8a f09e1df8279681
Committed: https:/
Submitter: Jenkins
Branch: stable/newton
commit 9889ab2c1a549d0 bd91d969f8af09e 1df8279681
Author: Richard Pioso <email address hidden>
Date: Fri Oct 28 20:11:18 2016 -0400
DRAC get_bios_config() passthru causes exception
The DRAC driver's (pxe_drac) get_bios_config() vendor passthru method
raises an AttributeError exception. It no longer returns the current
BIOS configuration. This is a regression from stable/mitaka.
Triage found that get_bios_config() mistakenly treats the value returned settings( ) as containing named tuples.
by python-dracclient's list_bios_
When it calls the namedtuple _asdict() method, an AttributeError
exception is raised.
Revert get_bios_config()'s handling of the return value to use __dict__.
Remove the comment that is not consistent with the implementation.
Also revert the unit test case for a successful call to use mock to eMock with an empty
create the return value. Use mock.NonCallabl
specification (spec) to catch this type of bug in the future.
Change-Id: I94afaa72a1ef25 efc1b622e29e3a9 2a5d27f1892 af1567c65240a7a 6a759377c2)
Closes-Bug: #1637671
(cherry picked from commit 6d6cf18f3171f42