Skip to content

Commit a33809a

Browse files
committed
typing
1 parent 6fca904 commit a33809a

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed

src/aleph/vm/models.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -361,6 +361,7 @@ async def start(self):
361361

362362
async def wait_for_persistent_boot(self):
363363
"""Determine if VM has booted by responding to ping and check if the process is still running"""
364+
assert self.vm
364365
assert self.vm.enable_networking and self.vm.tap_interface, f"Network not enabled for VM {self.vm.vm_id}"
365366
ip = self.vm.get_ip()
366367
if not ip:

tests/supervisor/test_instance.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ class MockSystemDManager(SystemDManager):
2323
execution: MicroVM | None = None
2424
process: Process | None = None
2525

26-
async def enable_and_start(self, service: str) -> tuple[MicroVM, Process]:
26+
async def enable_and_start(self, service: str) -> tuple[MicroVM | None, Process | None]:
2727
vm_hash = service.split("@", maxsplit=1)[1].split(".", maxsplit=1)[0]
2828

2929
config_path = Path(f"{settings.EXECUTION_ROOT}/{vm_hash}-controller.json")

tests/supervisor/test_qemu_instance.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ class MockSystemDManager(SystemDManager):
2323
execution: QemuVM | None = None
2424
process: Process | None = None
2525

26-
async def enable_and_start(self, service: str) -> tuple[QemuVM, Process]:
26+
async def enable_and_start(self, service: str) -> tuple[QemuVM | None, Process | None]:
2727
# aleph-vm-controller@decadecadecadecadecadecadecadecadecadecadecadecadecadecadecadeca.service-controller.json
2828
vm_hash = service.split("@", maxsplit=1)[1].split(".", maxsplit=1)[0]
2929

0 commit comments

Comments
 (0)