Unverified Commit c7b370c6 authored by Ning Xie's avatar Ning Xie Committed by GitHub
Browse files

raise exception for pin_lora (#19809)


Signed-off-by: default avatarAndy Xie <andy.xning@gmail.com>
parent aa20d10a
...@@ -202,8 +202,7 @@ class LoRANotSupportedWorkerBase(WorkerBase): ...@@ -202,8 +202,7 @@ class LoRANotSupportedWorkerBase(WorkerBase):
raise ValueError(f"{type(self)} does not support LoRA") raise ValueError(f"{type(self)} does not support LoRA")
def pin_lora(self, lora_id: int) -> bool: def pin_lora(self, lora_id: int) -> bool:
return ValueError( raise ValueError(f"{type(self)} does not support LoRA")
f"{type(self)} does not support LoRA") # type: ignore
def list_loras(self) -> Set[int]: def list_loras(self) -> Set[int]:
raise ValueError(f"{type(self)} does not support LoRA") raise ValueError(f"{type(self)} does not support LoRA")
...@@ -398,7 +397,7 @@ class LocalOrDistributedWorkerBase(WorkerBase): ...@@ -398,7 +397,7 @@ class LocalOrDistributedWorkerBase(WorkerBase):
model_input, worker_input, kwargs = inputs model_input, worker_input, kwargs = inputs
num_steps = worker_input.num_steps num_steps = worker_input.num_steps
if (execute_model_req is not None and execute_model_req.spec_step_idx): if execute_model_req is not None and execute_model_req.spec_step_idx:
kwargs["spec_step_idx"] = execute_model_req.spec_step_idx kwargs["spec_step_idx"] = execute_model_req.spec_step_idx
self.execute_worker(worker_input) self.execute_worker(worker_input)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment