4e01f29bafc75ef7c9ecc14cb7df25c6ba5c76cf
This patches deprecated strtime() as it's a either useless or a very bad idea to use it. It's useless because it's a 3 lines wrapper around utcnow(), datetime.strftime() and isotime() so does not bring anything useful as it can be replaced by one line of code in all cases. It's a bad idea because contrary to what one could expect: strtime() != isotime(subsecond=True) strtime(dt) != isotime(dt, subsecond=True) Also, it does not include any timezone information so it loses essential information on the datetime object. So it's really best to use isoformat() instead of strtime() in all cases, so you are sure that if you end up comparing timestamps as string (i.e. in tests) you are sure it's going to work, including the timezone. Change-Id: I8b5119e64369ccac3423dccc04421f99912df733
oslo.utils
The oslo.utils library provides support for common utility type functions, such as encoding, exception handling, string manipulation, and time handling.
- Free software: Apache license
- Documentation: http://docs.openstack.org/developer/oslo.utils
- Source: http://git.openstack.org/cgit/openstack/oslo.utils
- Bugs: http://bugs.launchpad.net/oslo.utils
Description
Languages
Python
93.9%
Gettext Catalog
6.1%