network agent delete throws "ignore_missing" error

Bug #1711301 reported by do3meli
18
This bug affects 3 people
Affects Status Importance Assigned to Milestone
python-openstackclient
Fix Released
Undecided
Praveen N

Bug Description

deleting a network agent throws below error:

[root@server] # openstack network agent delete e8d1c0ff-483c-4e19-a9c2-274816827de1
Failed to delete network agent with ID 'e8d1c0ff-483c-4e19-a9c2-274816827de1': get_agent() got an unexpected keyword argument 'ignore_missing'
1 of 1 network agents failed to delete.

it seems that the take_action() function is using the get_agent() function with wrong attributes.

the following line [1] should not have the "ignore_missing=False" attribute. any other get_agent() call in this script is not having a second attribute. so i assume that one got missed when the second attribute got removed.

[1] https://github.com/openstack/python-openstackclient/blob/master/openstackclient/network/v2/network_agent.py#L137

once i removed the second attribute in this line the command worked successfully.

Praveen N (praveenn)
Changed in python-openstackclient:
assignee: nobody → Praveen N (praveenn)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-openstackclient (master)

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

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

Reviewed: https://review.openstack.org/495155
Committed: https://git.openstack.org/cgit/openstack/python-openstackclient/commit/?id=6c8e5177bc54ba215aad310094b1eefd6ce709cf
Submitter: Zuul
Branch: master

commit 6c8e5177bc54ba215aad310094b1eefd6ce709cf
Author: npraveen35 <email address hidden>
Date: Fri Aug 18 15:48:54 2017 +0530

    Neutron agent delete: remove the wrong argument

    The take_action() function was calling get_agent() with the wrong
    attribute, causing agent deletion to fail. It turns out calling
    get_agent() isn't necessary; this removes the call entirely and moves
    the 'ignore_missing' argument to the delete_agent() function.

    Change-Id: Iaa3754a3be0765112f396495fa5fb2e32e6eae4e
    Closes-Bug: #1711301

Changed in python-openstackclient:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-openstackclient (stable/pike)

Fix proposed to branch: stable/pike
Review: https://review.openstack.org/518371

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-openstackclient (stable/ocata)

Fix proposed to branch: stable/ocata
Review: https://review.openstack.org/518516

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-openstackclient (stable/pike)

Reviewed: https://review.openstack.org/518371
Committed: https://git.openstack.org/cgit/openstack/python-openstackclient/commit/?id=11e2f54ea4b45e8e0813fc93765bc1c088aea842
Submitter: Zuul
Branch: stable/pike

commit 11e2f54ea4b45e8e0813fc93765bc1c088aea842
Author: npraveen35 <email address hidden>
Date: Fri Aug 18 15:48:54 2017 +0530

    Neutron agent delete: remove the wrong argument

    The take_action() function was calling get_agent() with the wrong
    attribute, causing agent deletion to fail. It turns out calling
    get_agent() isn't necessary; this removes the call entirely and moves
    the 'ignore_missing' argument to the delete_agent() function.

    Change-Id: Iaa3754a3be0765112f396495fa5fb2e32e6eae4e
    Closes-Bug: #1711301
    (cherry picked from commit 6c8e5177bc54ba215aad310094b1eefd6ce709cf)

tags: added: in-stable-pike
tags: added: in-stable-ocata
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-openstackclient (stable/ocata)

Reviewed: https://review.openstack.org/518516
Committed: https://git.openstack.org/cgit/openstack/python-openstackclient/commit/?id=e2cbe8bedb868cc9412f902f54d75296ce39eed4
Submitter: Zuul
Branch: stable/ocata

commit e2cbe8bedb868cc9412f902f54d75296ce39eed4
Author: npraveen35 <email address hidden>
Date: Fri Aug 18 15:48:54 2017 +0530

    Neutron agent delete: remove the wrong argument

    The take_action() function was calling get_agent() with the wrong
    attribute, causing agent deletion to fail. It turns out calling
    get_agent() isn't necessary; this removes the call entirely and moves
    the 'ignore_missing' argument to the delete_agent() function.

    Change-Id: Iaa3754a3be0765112f396495fa5fb2e32e6eae4e
    Closes-Bug: #1711301
    (cherry picked from commit 6c8e5177bc54ba215aad310094b1eefd6ce709cf)

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/python-openstackclient 3.13.0

This issue was fixed in the openstack/python-openstackclient 3.13.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/python-openstackclient 3.12.1

This issue was fixed in the openstack/python-openstackclient 3.12.1 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/python-openstackclient 3.8.2

This issue was fixed in the openstack/python-openstackclient 3.8.2 release.

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

Duplicates of this bug

Other bug subscribers

Remote bug watches

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