Problem with mapping of timestamps with glance
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Undecided
|
justinsb |
Bug Description
When I was trying to launch an image with a non-deleted image from glance, I hit the following exception:
2011-03-24 02:45:36,012 ERROR nova.api [F-V0NVACOWF073
(nova.api): TRACE: Traceback (most recent call last):
(nova.api): TRACE: File "/root/
(nova.api): TRACE: result = api_request.
(nova.api): TRACE: File "/root/
(nova.api): TRACE: result = method(context, **args)
(nova.api): TRACE: File "/root/
(nova.api): TRACE: image_id=
(nova.api): TRACE: File "/root/
(nova.api): TRACE: return self.image_
(nova.api): TRACE: File "/root/
(nova.api): TRACE: image = self.service.
(nova.api): TRACE: File "/root/
(nova.api): TRACE: return self._convert_
(nova.api): TRACE: File "/root/
(nova.api): TRACE: image[attr] = self._parse_
(nova.api): TRACE: File "/root/
(nova.api): TRACE: return datetime.
(nova.api): TRACE: File "/usr/lib/
(nova.api): TRACE: (data_string, format))
(nova.api): TRACE: ValueError: time data '' does not match format '%Y-%m-
(nova.api): TRACE:
The image in question looks like this when printed:
{'status': 'active', 'name': 'lucid-x86', 'deleted': 'False', 'container_format': 'bare', 'created_at': '2011-03-
The problem is that deleted_at is '', not None.
Related branches
- Josh Kearney (community): Approve
- Mark Washenberger (community): Approve
-
Diff: 11 lines (+1/-1)1 file modifiednova/image/glance.py (+1/-1)
Changed in nova: | |
assignee: | nobody → justinsb (justin-fathomdb) |
Changed in nova: | |
milestone: | none → 2011.2 |
status: | Fix Committed → Fix Released |
The problem isn't just 'deleted_at' being an empty string. I'm getting:
2011-03-24 12:47:20,303 ERROR nova.api.openstack [-] Caught error: time data '2011-03- 16T20:33: 46' does not match format '%Y-%m- %dT%H:% M:%S.%f'
Full traceback here: http:// paste.openstack .org/show/ 989/