-------------------------------------------------------------------------------
ISSUES:
-------------------------------------------------------------------------------
- Some auto-corrected code (when line is too long) may still be over-indented.
It can be manually chaged and it will be left alone, or is it acceptable as
I am not sure how strict your rule is for under-indented lines for which
context. If you want this only indented 4 spaces, I can work on it some more.
[Also @ ~line:385 in new file]
For example, __init__.py:382
OLD:
def __contains__(self, key):
return any((key == vm or key == vm.qid or key == vm.name) for vm in self)
NEW:
def __contains__(self, key):
return any((key == vm or key == vm.qid or key == vm.name)
for vm in self)
- will not detect if there are more than 2 spaces between function methods
-------------------------------------------------------------------------------
FIXED:
-------------------------------------------------------------------------------
- Now uses the most horizontial space and does not use excessive lines when
splitting a line
- __init__:489
- '#' comments being indented for some lines and not others; would like no indent
- Only happens if line preceeding comment ends in a ':'
E128 - Fix visual indentation
E128 - Fix a badly indented line [Now allows under-indented lines]
E309 - Add missing blank line (after class declaration) [No longer adds it]
E303 - Remove extra blank lines [Now allows 2 blank lines between function defs]
[TODO: Create definition to enforce this]
Conflicts:
qubes/__init__.py
Methods returning lxml.etree.Elements are called xml_ or lvxml_, meant for
qubes.xml or libvirt respectively.
Acknowledgement:
This commit is a result of core3 review by Marek.
Two important fixes are in this commit: handlers from decorators are added when
class is defined (and not when class is instantiated); also multiple events can
be specified in the decorator.
Automatic acquiring default*_netvm, default_template and {clock,update}vm is no
more. This will be moved to firstboot. Advanced users (those, who elect not to
autoconfig their initial VMs) will have to deal with that.
Acknowledgement:
This commit is a result of core3 review by Marek.
collections.defaultdict was not enough, because it cannot pass any arguments to
factory. We need to pass domain object and device class to fire events on attach
and detach.