Skip to content

0.3.2

Compare
Choose a tag to compare
@kalaspuff kalaspuff released this 06 Apr 08:03
· 208 commits to master since this release
d1f6a80
  • Added Added utcnow.get_today() / utcnow.as_date_string(value) which returns the date part in string format. Note that the date string that is returned does not include timezone information. The function take an optional value argument which will transform input to a UTC timezoned timestamp from which it'll extract the date.
  • An optional tz keyword argument to utcnow.get_today(tz=UTC) can be used to get the current date for another timezone than UTC (which otherwise is the default behaviour). The value for tz should be a datetime.tzinfo value (such as produced from timezone libraries, for example pytz.timezone(tz_str) or tzlocal.get_localzone()) or a string describing an utcoffset, such as "+02:00" or "-06:00".