yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #84460
[Bug 1904446] Re: 'GetPMEMNamespacesFailed' is not a valid exception
Reviewed: https://review.opendev.org/762898
Committed: https://opendev.org/openstack/nova/commit/160ed6ff652b80cd0a86d41dc3f66c15cee66290
Submitter: Zuul
Branch: master
commit 160ed6ff652b80cd0a86d41dc3f66c15cee66290
Author: Stephen Finucane <stephenfin@xxxxxxxxxx>
Date: Mon Nov 16 17:35:07 2020 +0000
Add missing exception
Change Idd49b0c70caedfcd42420ffa2ac926a6087d406e added support for
discovery of PMEM devices by the libvirt driver. Some error handling
code in this was expected to raise a 'GetPMEMNamespacesFailed'
exception, however, a typo meant the exception was actually called
'GetPMEMNamespaceFailed' (singular). This exception was later removed in
change I6fd027fb51823b8a8a24ed7b864a2191c4e8e8c0 because it had no
references.
Re-introduce the exception, this time with the correct name, and add
some unit tests to prevent us regressing.
Change-Id: I3b597a46314a1b29a952fc0f7a9c4537341e37b8
Signed-off-by: Stephen Finucane <stephenfin@xxxxxxxxxx>
Closes-Bug: #1904446
** Changed in: nova
Status: In Progress => Fix Released
** Changed in: nova/victoria
Status: New => In Progress
** Changed in: nova/victoria
Assignee: (unassigned) => Stephen Finucane (stephenfinucane)
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1904446
Title:
'GetPMEMNamespacesFailed' is not a valid exception
Status in OpenStack Compute (nova):
Fix Released
Status in OpenStack Compute (nova) train series:
New
Status in OpenStack Compute (nova) ussuri series:
In Progress
Status in OpenStack Compute (nova) victoria series:
In Progress
Bug description:
Attempting to retrieve a non-existent PMEM device results in the
following traceback:
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova During handling of the above exception, another exception occurred:
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova Traceback (most recent call last):
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova File "/usr/bin/nova-compute", line 10, in <module>
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova sys.exit(main())
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova File "/usr/lib/python3.6/site-packages/nova/cmd/compute.py", line 57, in main
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova topic=compute_rpcapi.RPC_TOPIC)
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova File "/usr/lib/python3.6/site-packages/nova/service.py", line 271, in create
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova periodic_interval_max=periodic_interval_max)
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova File "/usr/lib/python3.6/site-packages/nova/service.py", line 129, in __init__
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova self.manager = manager_class(host=self.host, *args, **kwargs)
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova File "/usr/lib/python3.6/site-packages/nova/compute/manager.py", line 571, in __init__
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova self.driver = driver.load_compute_driver(self.virtapi, compute_driver)
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova File "/usr/lib/python3.6/site-packages/nova/virt/driver.py", line 1911, in load_compute_driver
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova virtapi)
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova File "/usr/lib/python3.6/site-packages/oslo_utils/importutils.py", line 44, in import_object
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova return import_class(import_str)(*args, **kwargs)
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova File "/usr/lib/python3.6/site-packages/nova/virt/libvirt/driver.py", line 446, in __init__
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova vpmem_conf=CONF.libvirt.pmem_namespaces)
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova File "/usr/lib/python3.6/site-packages/nova/virt/libvirt/driver.py", line 477, in _discover_vpmems
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova vpmems_host = self._get_vpmems_on_host()
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova File "/usr/lib/python3.6/site-packages/nova/virt/libvirt/driver.py", line 512, in _get_vpmems_on_host
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova raise exception.GetPMEMNamespacesFailed(reason=reason)
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova AttributeError: module 'nova.exception' has no attribute 'GetPMEMNamespacesFailed'
./nova-compute.log.1:2020-11-16 16:01:22.704 7 ERROR nova
It seems there was a typo introduced when this code was added. The
code referenced 'GetPMEMNamespacesFailed' but the exception, which has
since been removed since it was "unused", was called
'GetPMEMNamespaceFailed'.
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1904446/+subscriptions
References