Comparison
fasteners vs flufl.lock vs lockfile vs portalocker
Maintenance, adoption and momentum side by side, from PyPI, GitHub and deps.dev data refreshed every day.
A python package that provides useful locks
Low maintenance activity. Last release 16 months ago, commits in 1 of the last 26 weeks. Weaker on commit activity and recent releases.
pip install fastenersNFS-safe file locking with timeouts for POSIX and Windows
Actively maintained. Last release 7 weeks ago. A safe choice.
pip install flufl-lockPlatform-independent file locking module
Likely abandoned. No release or commit for years (last release over 11 years ago).
pip install lockfileCross-platform file locking, with Redis, PID-file and bounded-semaphore locks
Actively maintained. Last release 5 weeks ago, commits in 14 of the last 26 weeks. A safe choice.
pip install portalockerIn short
- lockfile looks abandoned: avoid it for new projects.
- portalocker is the most used: 47.8M downloads a month, 3.3× more than fasteners.
- Maintenance is comparable: portalocker 85, flufl.lock 77, fasteners 24 on Pythie’s Index.
- fasteners is growing fastest: downloads +14% over the last month.
- Safe default for a new project: portalocker.
Side by side
| Metric | fasteners | flufl.lock | lockfile | portalocker |
|---|---|---|---|---|
| Pythie’s Index | Pythie’s Index: 24 | 77 |