Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions virttest/libvirt_xml/vm_xml.py
Original file line number Diff line number Diff line change
Expand Up @@ -3844,6 +3844,8 @@ class VMFeaturesXML(base.LibvirtXMLBase):
"pmu",
"kvm_poll_control",
"ioapic",
"acpi",
"apic",
"kvm_dirty_ring_state",
"kvm_dirty_ring_size",
"ras",
Expand Down Expand Up @@ -3926,6 +3928,16 @@ def __init__(self, virsh_instance=base.virsh):
accessors.XMLElementDict(
property_name="ioapic", libvirtxml=self, parent_xpath="/", tag_name="ioapic"
)
accessors.XMLElementBool(
property_name="acpi",
libvirtxml=self,
parent_xpath="/",
tag_name="acpi")
accessors.XMLElementBool(
property_name="apic",
libvirtxml=self,
parent_xpath="/",
tag_name="apic")
Comment on lines +3931 to +3940
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The formatting of these XMLElementBool calls can be improved for better readability and consistency with PEP 8 style guidelines. When a function call is split across multiple lines, the closing parenthesis should be on a new line and aligned with the first character of the line that starts the multi-line construct.

        accessors.XMLElementBool(
            property_name="acpi",
            libvirtxml=self,
            parent_xpath="/",
            tag_name="acpi",
        )
        accessors.XMLElementBool(
            property_name="apic",
            libvirtxml=self,
            parent_xpath="/",
            tag_name="apic",
        )
References
  1. According to PEP 8, for multi-line constructs, the closing bracket/brace/parenthesis should be on a new line, aligned with the first character of the line that starts the multi-line construct. (link)

accessors.XMLAttribute(
property_name="kvm_dirty_ring_state",
libvirtxml=self,
Expand Down
Loading