projects
/
kiosk.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Towards mypy cleanliness.
[kiosk.git]
/
utils.py
diff --git
a/utils.py
b/utils.py
index e720ef7d565687999c1d41d5445862ddbb69b6b1..f486a8218661a7cf5b733e2a61e3030e53931205 100644
(file)
--- a/
utils.py
+++ b/
utils.py
@@
-17,6
+17,7
@@
def describe_age_of_file(filename) -> str:
now = time.time()
ts = os.stat(filename).st_ctime
age = now - ts
now = time.time()
ts = os.stat(filename).st_ctime
age = now - ts
+ age = int(age)
return describe_duration(age)
except Exception as e:
return "?????"
return describe_duration(age)
except Exception as e:
return "?????"
@@
-27,6
+28,7
@@
def describe_age_of_file_briefly(filename) -> str:
now = time.time()
ts = os.stat(filename).st_ctime
age = now - ts
now = time.time()
ts = os.stat(filename).st_ctime
age = now - ts
+ age = int(age)
return describe_duration_briefly(age)
except Exception as e:
return "?????"
return describe_duration_briefly(age)
except Exception as e:
return "?????"