KeyError: 'overLimit' on 413 return

Bug #920812 reported by Jay Pipes
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tempest
Fix Released
Medium
Jay Pipes

Bug Description

======================================================================
ERROR: Negative test: Metadata should not be set to a nonexistant image
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/jpipes/repos/tempest/tempest/tests/test_image_metadata.py", line 135, in test_set_nonexistant_image_metadata
    resp, meta = self.client.set_image_metadata(999, meta)
  File "/home/jpipes/repos/tempest/tempest/services/nova/json/images_client.py", line 114, in set_image_metadata
    str(image_id), post_body, self.headers)
  File "/home/jpipes/repos/tempest/tempest/common/rest_client.py", line 95, in put
    return self.request('PUT', url, headers, body)
  File "/home/jpipes/repos/tempest/tempest/common/rest_client.py", line 118, in request
    raise exceptions.OverLimit(body['overLimit']['message'])
KeyError: 'overLimit'

I guess 413 is returned for things other than Over Limits...

Jay Pipes (jaypipes)
Changed in tempest:
status: New → Confirmed
importance: Undecided → Medium
assignee: nobody → Jay Pipes (jaypipes)
milestone: none → essex-3
Revision history for this message
Jay Pipes (jaypipes) wrote :

Turns out the key is overLimitFault, not overLimit...

Changed in tempest:
status: Confirmed → Triaged
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tempest (master)

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

Changed in tempest:
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tempest (master)

Reviewed: https://review.openstack.org/3341
Committed: http://github.com/openstack/tempest/commit/9b04384ac9f3ce87444eafccbb63444911d5a87a
Submitter: Jenkins
Branch: master

commit 9b04384ac9f3ce87444eafccbb63444911d5a87a
Author: Jay Pipes <email address hidden>
Date: Mon Jan 23 23:34:26 2012 -0500

    Fixes LP#920812 - KeyError: 'overLimit' on 413 return

    Turns out that over quota limit and over ratelimits
    return different keys in the faults. This patch adds
    a new exception for RateLimitExceeded that handles
    413 returns when there is an overLimitFault key (and
    not the overLimit key that is in the over Quota fault)

    Change-Id: I64d10cb592512e7de71c5d8518131deee516d9b2

Changed in tempest:
status: In Progress → Fix Committed
Jay Pipes (jaypipes)
Changed in tempest:
status: Fix Committed → Fix Released
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.