Read-handle oplock stalls unrelated async tasks on Windows
Description
Impact
On Windows, a local account with read access to a native lock file can delay a nonblocking or short-timeout FileLock acquisition. With AsyncFileLock(run_in_executor=False), the delay also blocks unrelated tasks on the event loop. The default executor keeps the loop responsive but an acquisition can still miss its own deadline on the affected release.
Affected versions and mitigation
Confirmed affected: = 4.2.12. Upgrade to 4.3.0.
The acquisition loop now treats an oplock conflict as contention immediately. Nonblocking calls can raise Timeout even if the file becomes available shortly afterward. Restrict lock-file read access to trusted accounts and retain the default async executor. Fix in PR #1033
Credits
Scan filelock-20261116-009; finding ANT-2026-F0PRXOX0.