weblib.lock

Provide functions for check if file is locked.

weblib.lock.assert_lock(fname)[source]

If file is locked then terminate program else lock file.

weblib.lock.set_lock(fname)[source]

Try to lock file and write PID.

Return the status of operation.