File-based locks for Python for Linux and Windows
conda install anaconda::locket
Locket implements a lock that can be used by multiple processes provided they use the same path.