Skip to content

list images does not break in case of invalid OS image types#447

Closed
mgogoulos wants to merge 1 commit into
apache:trunkfrom
mgogoulos:GCE_IMAGES
Closed

list images does not break in case of invalid OS image types#447
mgogoulos wants to merge 1 commit into
apache:trunkfrom
mgogoulos:GCE_IMAGES

Conversation

@mgogoulos

Copy link
Copy Markdown
Contributor

Make sure that list_images will not break if one of the IMAGE_PROJECTS keys (OS image types) changes in future. Right now if you run list_images with an invalid project name, the connection.request_path is not restored after the exception is run, so all requests that follow will be invalid.

from libcloud.compute.providers import get_driver; from libcloud.compute.types import Provider; driver = get_driver('gce')

c = driver('email', 'key_path', project='name')

c.list_images(ex_project='centos-cloudX')
InvalidRequestError

c.list_nodes()
InvalidRequestError

@erjohnso

erjohnso commented Feb 9, 2015

Copy link
Copy Markdown
Contributor

Thanks @mgogoulos - this looks great. @Kami just cut 0.17.0, so I don't think it will get added to the release, but definitely will merge when travis catches up.

@Kami

Kami commented Feb 9, 2015

Copy link
Copy Markdown
Member

@erjohnso If you think this is a big issue, you can also vote -1 and we can cancel the vote and roll out a new release.

Or we can wait and release 0.17.1 soon after 0.17.0 is out.

@asfgit asfgit closed this in 7ca1336 Feb 9, 2015
@erjohnso

erjohnso commented Feb 9, 2015

Copy link
Copy Markdown
Contributor

I think it's a great fix and hardens the driver, but I don't think we need to hold off on 0.17.0. Adding it the next release is fine.

Thanks again @mgogoulos!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants