Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Notifier crashes due to incompatible datetimes being subtracted #1830

Closed
fniessink opened this issue Jan 14, 2021 · 0 comments · Fixed by #1868
Closed

Notifier crashes due to incompatible datetimes being subtracted #1830

fniessink opened this issue Jan 14, 2021 · 0 comments · Fixed by #1868
Assignees
Labels
Bug Something isn't working

Comments

@fniessink
Copy link
Member

notifier_1       |   Traceback (most recent call last):
notifier_1       |   File "/home/notifier/quality_time_notifier.py", line 113, in <module>
notifier_1       |     asyncio.run(notify(logging.INFO))  # pragma: no cover
notifier_1       |   File "/usr/local/lib/python3.9/asyncio/runners.py", line 44, in run
notifier_1       |     return loop.run_until_complete(main)
notifier_1       |   File "/usr/local/lib/python3.9/asyncio/base_events.py", line 642, in run_until_complete
notifier_1       |     return future.result()
notifier_1       |   File "/home/notifier/quality_time_notifier.py", line 41, in notify
notifier_1       |     notifications = notification_finder.get_notifications(json, most_recent_measurement_seen)
notifier_1       |   File "/home/notifier/strategies/notification_strategy.py", line 24, in get_notifications
notifier_1       |     notable = self.get_notification(metric, metric_uuid, most_recent_measurement_seen)
notifier_1       |   File "/home/notifier/strategies/notification_strategy.py", line 37, in get_notification
notifier_1       |     and self.long_unchanged_status(metric, metric_uuid, most_recent_measurement_seen)
notifier_1       |   File "/home/notifier/strategies/notification_strategy.py", line 61, in long_unchanged_status
notifier_1       |     difference = datetime_most_recent_measurement_seen - status_start
notifier_1       | TypeError: can't subtract offset-naive and offset-aware datetimes
quality-time_notifier_1 exited with code 1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

1 participant