Skip to content

Commit

Permalink
🐛 fixup LRU eviction
Browse files Browse the repository at this point in the history
Signed-off-by: Joe Runde <[email protected]>
  • Loading branch information
joerunde committed Jan 8, 2025
1 parent 28226b0 commit cf12e6a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vllm/lora/worker_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ def add_adapter(self, lora_request: LoRARequest) -> bool:
lora = self._load_adapter(lora_request)
loaded = self._adapter_manager.add_adapter(lora)
# If adding this adapter took us over capacity, evict the oldest one
if len(self._adapter_manager) + 1 > self._adapter_manager.capacity:
if len(self._adapter_manager) > self._adapter_manager.capacity:
assert isinstance(self._adapter_manager,
LRUCacheLoRAModelManager)
self._adapter_manager.remove_oldest_adapter()
Expand Down

0 comments on commit cf12e6a

Please sign in to comment.