diff options
| author | Scott <[email protected]> | 2022-02-02 11:09:18 -0800 |
|---|---|---|
| committer | Scott <[email protected]> | 2022-02-02 11:09:18 -0800 |
| commit | 5317c50ce7a96a37acfab3800c0935580766dbbf (patch) | |
| tree | 2da99b27342a873e0a8fe0e3d49fa1bec1637e79 /lockfile.py | |
| parent | 1ce11b3c28d175b6dcbfea9cf6367081f049c5a9 (diff) | |
mypy clean!
Diffstat (limited to 'lockfile.py')
| -rw-r--r-- | lockfile.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lockfile.py b/lockfile.py index 4b6aade..03fbb9e 100644 --- a/lockfile.py +++ b/lockfile.py @@ -34,7 +34,7 @@ class LockFileException(Exception): class LockFileContents: pid: int commandline: str - expiration_timestamp: float + expiration_timestamp: Optional[float] class LockFile(object): @@ -181,7 +181,7 @@ class LockFile(object): # Has the lock expiration expired? if contents.expiration_timestamp is not None: now = datetime.datetime.now().timestamp() - if now > contents.expiration_datetime: + if now > contents.expiration_timestamp: msg = f'Lockfile {self.lockfile} expiration time has passed; force acquiring' logger.warning(msg) self.release() |
