fix: update DockerVMManager method signatures for interface compatibility (#287)
- Fix delete_vm() method to accept region and **kwargs parameters - Fix occupy_vm() method to accept pid, region and **kwargs parameters - Ensures consistency with base VMManager interface and other providers - Resolves runtime argument mismatch errors when calling these methods This maintains backward compatibility while fixing the interface contract.
This commit is contained in:
@@ -99,7 +99,8 @@ class DockerVMManager(VMManager):
|
|||||||
def check_and_clean(self):
|
def check_and_clean(self):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
def delete_vm(self, vm_path):
|
def delete_vm(self, vm_path, region=None, **kwargs):
|
||||||
|
# Fixed: Added region and **kwargs parameters for interface compatibility
|
||||||
pass
|
pass
|
||||||
|
|
||||||
def initialize_registry(self):
|
def initialize_registry(self):
|
||||||
@@ -108,7 +109,8 @@ class DockerVMManager(VMManager):
|
|||||||
def list_free_vms(self):
|
def list_free_vms(self):
|
||||||
return os.path.join(VMS_DIR, DOWNLOADED_FILE_NAME)
|
return os.path.join(VMS_DIR, DOWNLOADED_FILE_NAME)
|
||||||
|
|
||||||
def occupy_vm(self, vm_path):
|
def occupy_vm(self, vm_path, pid, region=None, **kwargs):
|
||||||
|
# Fixed: Added pid, region and **kwargs parameters for interface compatibility
|
||||||
pass
|
pass
|
||||||
|
|
||||||
def get_vm_path(self, os_type, region, screen_size=(1920, 1080), **kwargs):
|
def get_vm_path(self, os_type, region, screen_size=(1920, 1080), **kwargs):
|
||||||
|
|||||||
Reference in New Issue
Block a user