v1 image member add broken (IndexError)

Bug #1020380 reported by Dan Prince
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Glance
Fix Released
Critical
Dan Prince

Bug Description

Using the most recent Folsom glance builds I'm getting the following exception when trying to add an image member via the v1 API:

  File "/usr/lib/python2.7/site-packages/glance/common/wsgi.py", line 502, in __call__
    request, **action_args)
  File "/usr/lib/python2.7/site-packages/glance/common/wsgi.py", line 519, in dispatch
    return method(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/common/utils.py", line 315, in wrapped
    return func(self, req, *args, **kwargs)
  File "/usr/lib/python2.7/site-packages/glance/registry/api/v1/members.py", line 219, in update
    self.db_api.image_member_update(req.context, members[0],
IndexError: list index out of range

Dan Prince (dan-prince)
Changed in glance:
assignee: nobody → Dan Prince (dan-prince)
importance: Undecided → High
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to glance (master)

Fix proposed to branch: master
Review: https://review.openstack.org/9256

Brian Waldon (bcwaldon)
Changed in glance:
milestone: none → folsom-2
importance: High → Critical
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to glance (master)

Reviewed: https://review.openstack.org/9256
Committed: http://github.com/openstack/glance/commit/737bfc30b101a52612b70d6c33fb485809cd977a
Submitter: Jenkins
Branch: master

commit 737bfc30b101a52612b70d6c33fb485809cd977a
Author: Dan Prince <email address hidden>
Date: Mon Jul 2 23:02:08 2012 -0400

    Fix IndexError when adding/updating image members.

    This patch updates the v1 registry API to work with the latest
    DB API image_member_find function which no longer throws
    NoResultFound when it doesn't find any records.

    The latest version of the DB API image_member_find function simply
    returns an empty query result.

    This fixes both member-add and members-replace functionality.

    Fixes LP Bug #1020380.

    Change-Id: I8818c90e09bd9a17f208d0e20106007db04e77f1

Changed in glance:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in glance:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in glance:
milestone: folsom-2 → 2012.2
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.