portalocker
portalocker copied to clipboard
An easy library for Python file locking. It works on Windows, Linux, BSD and Unix systems and can even perform distributed locking. Naturally it also supports the with statement.
https://portalocker.readthedocs.io/en/latest/#examples These examples just show how to lock a file, not what errors or responses are possible. What happens if another process tries to lock a file during the same...
look, I know how weird this looks, but hear me out. I somehow managed to get a race condition(?) where portalocker.open('file/path', 'a') would not actually get me at the end...
Hi Rick, thanks for this portalocker library! It has been reliably serving us for quite a while. :-) We recently encountered a [cross-library issue](https://github.com/AzureAD/microsoft-authentication-extensions-for-python/issues/66#issuecomment-670578560) likely caused by different locking mechanisms....
Hello, I create this issue because it seems to me that portalocker does not work well with NFS mount. The problem was discovered while using cachier package : https://github.com/python-cachier/cachier/issues/128
Fix a simple spelling error - s/locing/locking
`Lock.acquire` is defined as: `def acquire(...) -> typing.IO[typing.AnyStr]:` but `typing.AnyStr` is a `TypeVar`, and _"A function returning TypeVar should receive at least one argument containing the same TypeVar"_ (this is...