FIX timestamp handling
This commit is contained in:
vanhempi
b5a100f9e7
commit
ae9cb38bbe
2 muutettua tiedostoa jossa 4 lisäystä ja 1 poistoa
|
@ -112,6 +112,9 @@ class Monitor(ParentedLet):
|
|||
except:
|
||||
logging.exception("Could not generate "
|
||||
"an alarm from timespec {}".format(timespec))
|
||||
if when is None:
|
||||
# expired
|
||||
return
|
||||
delta = when - now
|
||||
assert delta.total_seconds() > 0
|
||||
self.log.info('Will run after %d seconds' % delta.total_seconds())
|
||||
|
|
|
@ -17,5 +17,5 @@ def singlealarm_receive(form):
|
|||
return {
|
||||
'kind': 'single',
|
||||
'nick': form.nick.data,
|
||||
'timestamp': form.dt.data.strftime('%s')
|
||||
'timestamp': int(form.dt.data.strftime('%s'))
|
||||
}
|
||||
|
|
Ladataan…
Viittaa uudesa ongelmassa