Virt-manager fails to start

Trying to start virt-manager, I get the following:

Traceback (most recent call last):
File “/usr/share/virt-manager/virt-manager”, line 15, in
import gi
ModuleNotFoundError: No module named ‘gi’

Anyone with the same problem or with an idea how to solve it?

I have not this problem. You must perhaps add : sudo swupd bundle-add virt-manager-gui kvm-host


Do you still have the issue if you update the latest version? If so, can you share the output of swupd info and swupd bundle-list?

The only thing I can think of is that PyGObject, where this module comes from, was update to Python 3.8 compatibility but that was a week ago. I’m not seeing this on 31960.

Thank you for the replies!
Here is the information. And yes, I still have the issue.

# swupd bundle-add virt-manager-gui kvm-host
Loading required manifests…
Warning: Bundle “kvm-host” is already installed, skipping it…
Warning: Bundle “virt-manager-gui” is already installed, skipping it…
2 bundles were already installed

# swupd info
Distribution: Clear Linux OS
Installed version: 31960
Version URL:
Content URL:

# swupd bundle-list

Can you show us the output of which python?

I had the same problem starting up gnome-tweaks.
Then I realized that I also had anaconda3 installed which
comes with its own python runtime and that didn’t
have pygobject installed. I removed anaconda3 and
gnome-tweaks started working.

1 Like