functional tests fail to pick an image if no cirros image available

Bug #1618089 reported by Matt Riedemann
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python-novaclient
In Progress
Undecided
tamil vanan

Bug Description

This was pointed out in review of this change:

https://review.openstack.org/#/c/357845/2/novaclient/tests/functional/base.py

That's using glanceclient now to get images, but glanceclient.v2.images.list returns a generator, not a list, so we can't use images[0] there if no cirros image is found.

Matt Riedemann (mriedem)
Changed in python-novaclient:
status: New → Triaged
tags: added: low-hanging-fruit
tamil vanan (tamilhce)
Changed in python-novaclient:
assignee: nobody → tamil vanan (tamilhce)
tamil vanan (tamilhce)
Changed in python-novaclient:
status: Triaged → In Progress
Revision history for this message
tamil vanan (tamilhce) wrote :

@Matt

As you have mentioned glance returns generator obj :https://github.com/openstack/python-glanceclient/blob/master/glanceclient/v2/images.py#L176

ukesh made accordingly to accept the generator
https://review.openstack.org/#/c/358575/1/novaclient/tests/functional/base.py

Can we change glanceclient/v2/images.py# to return list ?, Even in earlier versions(mitaka,liberty), it returns only a generator obj.

Looking forward to your suggestion

Revision history for this message
Matt Riedemann (mriedem) wrote :

This is already fixed so I'm going to just duplicate it against bug 1615594 - nothing else to do here.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.