mirror of
https://github.com/virt-manager/virt-manager.git
synced 2025-03-10 12:58:27 +03:00
inspection: handle failures in application listing
The Python binding of libguestfs errors out in case any of the details (e.g. summary, description) of an application are not proper UTF-8. This seems a rare situation, which nevertheless causes the failure of the inspection of a guest, making the rest of the metadata not used. While these encoding issues are tackled, and fixed in python-libguestfs (or libguestfs itself), gracefully handle the failure of inspect_list_applications(), so at least the rest of the details of a guest are used/shown.
This commit is contained in:
parent
af63426970
commit
1018ab4484
@ -275,7 +275,11 @@ class vmmInspection(vmmGObject):
|
|||||||
icon = None
|
icon = None
|
||||||
|
|
||||||
# Inspection applications.
|
# Inspection applications.
|
||||||
apps = g.inspect_list_applications(root)
|
try:
|
||||||
|
apps = g.inspect_list_applications(root)
|
||||||
|
except Exception:
|
||||||
|
logging.exception("%s: exception while listing apps (ignored)",
|
||||||
|
prettyvm)
|
||||||
|
|
||||||
# Force the libguestfs handle to close right now.
|
# Force the libguestfs handle to close right now.
|
||||||
del g
|
del g
|
||||||
|
Loading…
x
Reference in New Issue
Block a user