Skip to content

Python library for providing a higher-level interface to flock(2).

License

Notifications You must be signed in to change notification settings

fishface60/python-flock

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

I need a library that provides both shared and exclusive locks on files.

oslo.concurrency and lockfile attempt the highest common factor approach
based on atomic file creation, which only provides exclusive locks

portalocker is more portable and provides shared and exclusive locks,
but doesn't work with directories since it requires a file object,
and python2 doesn't let you have a file object for a directory.

Also its timeout approach is to non-blocking flock in a loop until the
timeout period is over,
which is less performant than a proper blocking lock with wakeup.

About

Python library for providing a higher-level interface to flock(2).

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages