Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error refreshing hardware page: 'virConnect' object has no attribute 'baselineHypervisorCPU' #57

Closed
bojansimicmb opened this issue Oct 16, 2019 · 4 comments · Fixed by #59

Comments

@bojansimicmb
Copy link

When going to Show virutal hardware details>CPUs constantly getting this error.

Error refreshing hardware page: 'virConnect' object has no attribute 'baselineHypervisorCPU'

Traceback (most recent call last):
File "/usr/share/virt-manager/virtManager/details/details.py", line 1025, in hw_selected
self.refresh_config_cpu()
File "/usr/share/virt-manager/virtManager/details/details.py", line 2223, in refresh_config_cpu
if not self._cpu_secure_is_available():
File "/usr/share/virt-manager/virtManager/details/details.py", line 2167, in _cpu_secure_is_available
features = domcaps.get_cpu_security_features()
File "/usr/share/virt-manager/virtinst/domcapabilities.py", line 309, in get_cpu_security_features
cpu = self._get_expanded_cpu(m)
File "/usr/share/virt-manager/virtinst/domcapabilities.py", line 278, in _get_expanded_cpu
expandedXML = self.conn.baselineHypervisorCPU(
File "/usr/share/virt-manager/virtinst/connection.py", line 118, in getattr
return getattr(libvirtconn, attr)
AttributeError: 'virConnect' object has no attribute 'baselineHypervisorCPU'

@phrdina
Copy link
Member

phrdina commented Oct 17, 2019

Hi, what is your OS and version of virt-manager and libvirt?

@bojansimicmb
Copy link
Author

Hi, Ubuntu 18.04.3, virt-manager is 2.2.1 and libvirt 4.0.0

@phrdina
Copy link
Member

phrdina commented Oct 22, 2019

Thanks for the info, it confirms my suspicion. You have libvirt 4.0.0 and probably libvirt-python 4.0.0 where there is no baselineHypervisorCPU API. I'll improve the code to properly handle this case and use older API if the new one is missing. Thanks for the report.

@bojansimicmb
Copy link
Author

Yes, python3-libvirt is 4.0.0. No problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants