[1]: https://docs.python.org/3/library/datetime.html#date-objects [2]: https://docs.python.org/3/library/datetime.html#time-objects
For events in the last hour, the following expression should evaluate to True:
(datetime.now() - timedelta(hours=1)) <= event_datetime
date.today().replace(month=5, day=1) <= event_datetime.date() <= date.today().replace(month=5, day=31)
[1]: https://docs.python.org/3/library/datetime.html#timedelta-ob... [2]: http://arrow.readthedocs.io/en/latest/
event_datetime in daterange(timedelta(hours=1), before=datetime.now())