Does anyone care about this anymore? Unity is gone, if the libs are
present on a gnome install it's always been funky (currently doesn't
display an icon on f27), libappindator seems largely dead upstream,
and traditional systray icons give very similar behavior.
Kill it and see if anyone complains
Use enumerate instead of iterating with range and len.
This pylint message is emitted when code that iterates with range and
len is encountered. Such code can be simplified by using the enumerate
built-in. [1]
In addition, remove some unused variables to avoid warnings
`unused-argument` and `redefined-variable-type`.
[1] https://pylint.readthedocs.io/en/latest/technical_reference/features.html#id23
Signed-off-by: Radostin Stoyanov <rstoyanov1@gmail.com>
A new Python checker was added to warn about using a + operator inside
call of logging methods when one of the operands is a literal string.
https://pylint.readthedocs.io/en/latest/whatsnew/1.8.html
Signed-off-by: Radostin Stoyanov <rstoyanov1@gmail.com>
Moves the libxml2 bits to a separate xmlapi file and class, a bunch
of cleanups to xmlbuilder internals dealing with XML stuff.
The main point is to experiment with different XML library impls,
since libxml2 is unfun to deal with and we are having python3
issues like
https://bugzilla.gnome.org/show_bug.cgi?id=776815
Currently the domain CPU class has a child property like:
siblings = XMLChildProperty(_CPUCellSibling)
If a user wants to add a new sibling, we add a convenience function:
def add_sibling(self):
obj = _CPUCellSibling(self.conn)
self.add_child(obj)
return obj
Rather than require every child property to define a similar matching
helper function, this adds infrastructure in xmlbuilder to do this
generically for every child property. Now callers can do
obj = guest.cpu.siblings.add_new()
The `ipaddress` is available in Python 3.3+ [1] and backport for
Python 2 is available on PyPI [2].
The main differences between ipaddr and ipaddress are:
- ipaddress *Network classes are equivalent to the ipaddr *Network
class counterparts with the strict flag set to True.
- ipaddress *Interface classes are equivalent to the ipaddr *Network
class counterparts with the strict flag set to False.
- The factory functions in ipaddress were renamed to disambiguate them
from classes.
- A few attributes were renamed to disambiguate their purpose as well.
(eg. network -> network_address, numhosts -> num_addresses)
- A number of methods and functions which returned containers in ipaddr
now return iterators. This includes subnets, address_exclude,
summarize_address_range and collapse_address_list.
Another major difference is that in Python 2 the `ipaddress` module
must use unicode. [3]
[1] https://www.python.org/dev/peps/pep-3144/
[2] https://pypi.python.org/pypi/ipaddress
[3] https://github.com/phihag/ipaddress
When creating a new root file system out of an downloaded image,
the root password is likely to be changed. Add a field for this
in the new guest wizard.
Through virt-manager, After we removed a virtio-scsi controller which
virtual disks still attach to it, Libvirt will add a LSI scsi controller
for this guest automatically and trigger a lifecycle event, virt-manager
updates and shows this new scsi controller in details panel once it got
the lifecycle event.
It may confuse user that a LSI scsi controller occurs while one removes
the virtio-scsi controller.
This patch prevents removing a scsi controller if any disks attaching to
it.
Signed-off-by: Lin Ma <lma@suse.com>
We were passing in a unicode string object, but add_from_string
depends on knowing binary length. This caused signals to not
be registered which broke reopening the details window
Just switch to add_from_file to sidestep the issue
In python3 exceptions aren't defined outside the except block. Leading
to 'UnboundLocalError: local variable 'e' referenced before assignment'
errors.
To work around this, store the local variable into one that will have a
longer life.
Libvirt only supports built-in IDE controller so far, There is no
any case that needs us manually add an IDE controller, So remove
it from the controller list.
Signed-off-by: Lin Ma <lma@suse.com>