Merge pull request #1774 from danielaskdd/fix-keyed-lock-error

Hotfix: prevent premature lock cleanup in multiprocess mode
This commit is contained in:
Daniel.y 2025-07-13 14:13:32 +08:00 committed by GitHub
commit 7945d7de59
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -422,7 +422,7 @@ def _get_or_create_shared_raw_mp_lock(
f"Shared-Data lock registry for {factory_name} is corrupted for key {key}"
)
if (
count == 1 and combined_key in _lock_cleanup_data
count == 0 and combined_key in _lock_cleanup_data
): # Reusing an key waiting for cleanup, remove it from cleanup list
_lock_cleanup_data.pop(combined_key)
count += 1