PagerDuty / pdpyras

Low-level PagerDuty REST/Events API client for Python
MIT License
130 stars 30 forks source link

Add abstraction for date ranges (since/until) #31

Closed Deconstrained closed 3 years ago

Deconstrained commented 4 years ago

I've just rediscovered how annoying it is to have to cobble together ISO8601 timestamps for when I just want to select an hour in the past or somesuch thing.

There thus needs to be an easier way to generate since and until parameters to reduce repeated work making function calls to datetime.datetime and datetime.timedelta and datetime.datetime.strftime (etc)