aside.boilerplate.timeutils module¶
Implements human-readable datetime tools.
- relative_to_absolute(relative: str) Optional[datetime][source]¶
Try to convert a relative time string like
in 1 hourto adatetime.
- dump_iso_dt()¶
[sep] -> string in ISO 8601 format, YYYY-MM-DDT[HH[:MM[:SS[.mmm[uuu]]]]][+HH:MM]. sep is used to separate the year from the time, and defaults to ‘T’. timespec specifies what components of the time to include (allowed values are ‘auto’, ‘hours’, ‘minutes’, ‘seconds’, ‘milliseconds’, and ‘microseconds’).