"nova actions" fails with HTTP 400 / TypeError if a server action has been performed

Bug #897091 reported by Ewan Mellor
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Medium
Ewan Mellor
Diablo
Fix Released
Undecided
Unassigned

Bug Description

"nova actions 1" (where credentials are set and 1 is a valid server ID) with an HTTP 400 error and TypeError: 'dict' object is not callable in the nova-api logs, iff there has been a previous call to the /servers/%s/action handler (such as "nova reboot 1").

The problem is that Controller.action sets self.actions to a dictionary, which overwrites the definition of the Controller.actions method.

Ewan Mellor (ewanmellor)
Changed in nova:
status: New → In Progress
assignee: nobody → Ewan Mellor (ewanmellor)
Revision history for this message
Ewan Mellor (ewanmellor) wrote :
Brian Waldon (bcwaldon)
Changed in nova:
importance: Undecided → Medium
milestone: none → essex-2
Revision history for this message
Openstack Gerrit (openstack-gerrit) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/1915
Committed: http://github.com/openstack/nova/commit/4a76167e354eed4aa98232fbf6c845f86ce4cf22
Submitter: Jenkins
Branch: master

 status fixcommitted
 done

commit 4a76167e354eed4aa98232fbf6c845f86ce4cf22
Author: Ewan Mellor <email address hidden>
Date: Sun Nov 27 23:26:49 2011 -0800

    Bug #897091: "nova actions" fails with HTTP 400 / TypeError if a server action has been performed

    Fix code in Controller.action that was overwriting the definition of the
    actions method with a dictionary. This meant that 'nova actions' would fail
    if 'nova reboot' had previously been called.

    Added two tests, one for the actions call in general, and one for this
    failure mode specifically.

    Change-Id: I695bb5c4dcfba96a5aba54125a8f3163e1a6a193

Changed in nova:
status: In Progress → Fix Committed
Revision history for this message
Openstack Gerrit (openstack-gerrit) wrote : Fix merged to nova (stable/diablo)

Reviewed: https://review.openstack.org/2187
Committed: http://github.com/openstack/nova/commit/c733462b229290210d6249e0f8fc7d2beaab9091
Submitter: Jenkins
Branch: stable/diablo

 tag in-stable-diablo
 done

commit c733462b229290210d6249e0f8fc7d2beaab9091
Author: Ewan Mellor <email address hidden>
Date: Sun Nov 27 23:26:49 2011 -0800

    Bug #897091: "nova actions" fails with HTTP 400 / TypeError if a server action has been performed

    Fix code in Controller.action that was overwriting the definition of the
    actions method with a dictionary. This meant that 'nova actions' would fail
    if 'nova reboot' had previously been called.

    Added two tests, one for the actions call in general, and one for this
    failure mode specifically.

    (cherry picked from commit 4a76167e354eed4aa98232fbf6c845f86ce4cf22)

    Change-Id: I695bb5c4dcfba96a5aba54125a8f3163e1a6a193

Thierry Carrez (ttx)
Changed in nova:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: essex-2 → 2012.1
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.