Fix race condition in async lora unload (#9084)

This commit is contained in:
Lifu Huang
2025-08-11 22:59:29 -07:00
committed by GitHub
parent 4093d460ce
commit 5ded39cab2
4 changed files with 35 additions and 19 deletions

View File

@@ -2960,7 +2960,7 @@ class ConcurrentCounter:
This suspends the calling coroutine without blocking the thread, allowing
other tasks to run while waiting. When the counter becomes zero, the coroutine resumes.
"""
self.wait_for(lambda count: count == 0)
await self.wait_for(lambda count: count == 0)
@lru_cache(maxsize=1)