yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #70949
[Bug 1744160] Re: Change in iso8601 0.1.12 date format breaks parsing with py35
Reviewed: https://review.openstack.org/541142
Committed: https://git.openstack.org/cgit/openstack/oslo.utils/commit/?id=010fe3b1023871740b57dbc450f80e6c0c0f6e43
Submitter: Zuul
Branch: master
commit 010fe3b1023871740b57dbc450f80e6c0c0f6e43
Author: John L. Villalovos <openstack.org@xxxxxxxxxxxx>
Date: Mon Feb 5 22:29:38 2018 -0800
Fix breaking unit tests due to iso8601 changes
The move from iso8601===0.1.11 to iso8601===0.1.12 broke unit
tests in oslo.utils.
iso8601 used to do:
from datetime import datetime
But now they call datetime.datetime():
import datetime
datetime.datetime()
Unfortunately the unit tests that mocked datetime.datetime() are now
mocking the one in iso8601. This causes a failure in the unit tests.
Fix this by using the 'wraps' argument to mock. So that the calls will
get passed through to datetime.datetime. Also changed to using the
decorator style of mock.
In addition Python 3 unit tests were broken due to changing how the
UTC time zone is represented from 'UTC' to 'UTC+00:00'.
Closes-Bug: #1747575
Closes-Bug: #1744160
Change-Id: Ia80ffb5e571cc5366bef2bc1a32c457a3c16843d
** Changed in: oslo.utils
Status: In Progress => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1744160
Title:
Change in iso8601 0.1.12 date format breaks parsing with py35
Status in Cinder:
Fix Released
Status in Glance:
Fix Released
Status in OpenStack Identity (keystone):
Fix Released
Status in Manila:
Fix Released
Status in OpenStack Compute (nova):
Fix Released
Status in oslo.utils:
Fix Released
Status in oslo.versionedobjects:
Fix Released
Bug description:
New package of iso8601 returns string in the format:
'2012-02-14T20:53:07UTC+00:00'
instead of:
'2012-02-14T20:53:07Z'
This is resulting in date string comparison failures and timeutils.parse_isotime errors with:
ValueError: Unable to parse date string '2014-08-08T00:00:00UTC+00:00'
To manage notifications about this bug go to:
https://bugs.launchpad.net/cinder/+bug/1744160/+subscriptions
References