MCPcopy Create free account
hub / github.com/FastLED/FastLED / break_stale_lock

Function break_stale_lock

ci/util/file_lock_rw.py:107–119  ·  view source on GitHub ↗

Remove stale lock entries (dead PIDs) from the database. Args: lock_file_path: Path to the lock file Returns: True if stale lock was broken, False otherwise

(lock_file_path: Path)

Source from the content-addressed store, hash-verified

105
106
107def break_stale_lock(lock_file_path: Path) -> bool:
108 """
109 Remove stale lock entries (dead PIDs) from the database.
110
111 Args:
112 lock_file_path: Path to the lock file
113
114 Returns:
115 True if stale lock was broken, False otherwise
116 """
117 db = get_lock_database(lock_file_path)
118 lock_name = str(lock_file_path)
119 return db.break_stale_lock(lock_name)
120
121
122class FileLock:

Calls 2

get_lock_databaseFunction · 0.90
break_stale_lockMethod · 0.80