python-openstackclient/releasenotes/notes/bug-1741223-7a5c5b6e7f232628.yaml
Mike Fedosin ed1b59848f Check that Glance returns image data before processing it
Now if Glance v2 cannot find image data it returns an empty
response with 204 status code, instead of raising an error.

Glance client handles this situation and wraps the response
with a RequestIdProxy object, whose 'wrapped' attribute is
None.

But when openstack client tries to parse this object using
glanceclient's save_image util function, it fails with
"NoneType object is not iterable" message, for the
object doesn't contain any data.

This patch adds additional check to prevent such behaviour
and raises SystemExit exception if no data was returned from
the server.

Glance v1 is not affected, because it raises an error if can't
find an image data.

Change-Id: I016a60462ba586f9fa7585c2cfafffd7be38de7b
Closes-Bug: #1741223
2018-01-05 19:36:49 +01:00

7 lines
180 B
YAML

---
fixes:
- |
'NoneType' object is not iterable when Glance cannot find image data in its
backend.
[Bug `1741223 <https://bugs.launchpad.net/ironic/+bug/1741223>`_]