style: apply ruff format to the files this branch touches

This commit is contained in:
YueGuobin committed 2026-10-14 22:13:58 +08:00
1 parent 97b5514134
commit 3e6a53c4b9
12 files changed
+17 -15

No files matched your search

@@ -795,7 +795,7 @@ class EthernetSwitch(KernelDatapathMixin, BaseNode):
anchor = self._kernel_ports.get(port_number)
if anchor is not None:
# Per-interface stop: only this port's capture is stopped.
await self._ubridge_send(f'capture stop_kernel {anchor}')
await self._ubridge_send(f"capture stop_kernel {anchor}")
else:
ubridge_bridge = self._ubridge_bridge_name(port_number)
await self._ubridge_send(f"bridge stop_capture {ubridge_bridge}")
+1 -1
View File
@@ -2044,7 +2044,7 @@ class DockerVM(DockerKernelDatapathMixin, BaseNode):
# capturing flag above gates it, so uBridge's 208-on-idle-
# interface can only surface on a genuine desync).
host_ifc = self._kernel_host_ifc(adapter_number, port_number)
await self._ubridge_send(f'capture stop_kernel {host_ifc}')
await self._ubridge_send(f"capture stop_kernel {host_ifc}")
return
bridge_name = self._bridge_name(adapter_number, port_number)
await self._ubridge_send(f"bridge stop_capture {bridge_name}")
+1 -1
View File
@@ -1536,7 +1536,7 @@ class Router(KernelDatapathMixin, BaseNode):
anchor = self._kernel_host_ifc(slot_number, port_number)
if self.ubridge and anchor is not None:
# Per-interface stop: only this port's capture is stopped.
await self._ubridge_send(f'capture stop_kernel {anchor}')
await self._ubridge_send(f"capture stop_kernel {anchor}")
return
await nio.stop_packet_capture()
+1 -1
View File
@@ -1869,7 +1869,7 @@ class IOUVM(KernelDatapathMixin, BaseNode):
# Per-interface stop: only this port's capture is stopped.
anchor = self._kernel_host_ifc(adapter_number, port_number)
if anchor is not None:
await self._ubridge_send(f'capture stop_kernel {anchor}')
await self._ubridge_send(f"capture stop_kernel {anchor}")
else:
await self._ubridge_send(
f"iol_bridge stop_capture {self._iol_bridge_name()} {adapter_number} {port_number}"
+1 -1
View File
@@ -1790,7 +1790,7 @@ class QemuVM(KernelDatapathMixin, BaseNode):
anchor = self._kernel_host_ifc(adapter_number)
if isinstance(nio, NIOBridge) and anchor is not None:
# Per-interface stop: only this port's capture is stopped.
await self._ubridge_send(f'capture stop_kernel {anchor}')
await self._ubridge_send(f"capture stop_kernel {anchor}")
else:
await self._ubridge_send("bridge stop_capture {name}".format(name=f"QEMU-{self._id}-{adapter_number}"))
+1 -1
View File
@@ -691,7 +691,7 @@ class VPCSVM(KernelDatapathMixin, BaseNode):
anchor = self._kernel_host_ifc(0, port_number)
if isinstance(nio, NIOBridge) and anchor is not None:
# Per-interface stop: only this port's capture is stopped.
await self._ubridge_send(f'capture stop_kernel {anchor}')
await self._ubridge_send(f"capture stop_kernel {anchor}")
else:
await self._ubridge_send("bridge stop_capture {name}".format(name=f"VPCS-{self._id}"))