Acquire the lock. :return: the lock object
(self)
| 367 | _LOGGER.debug("Lock %s released on %s", lock_id, lock_filename) |
| 368 | |
| 369 | def __enter__(self) -> Self: |
| 370 | """ |
| 371 | Acquire the lock. |
| 372 | |
| 373 | :return: the lock object |
| 374 | |
| 375 | """ |
| 376 | self.acquire() |
| 377 | return self |
| 378 | |
| 379 | def __exit__( |
| 380 | self, |