yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #92928
[Bug 2037596] Re: Description Failed to invoke the API interface to obtain the address group list
Reviewed: https://review.opendev.org/c/openstack/neutron/+/896649
Committed: https://opendev.org/openstack/neutron/commit/7e10a01874b7d2e7f4a28b740a2ebfcd193ae797
Submitter: "Zuul (22348)"
Branch: master
commit 7e10a01874b7d2e7f4a28b740a2ebfcd193ae797
Author: liyou01 <liyou01@xxxxxxxxxx>
Date: Wed Sep 27 19:52:31 2023 +0800
Parameter filters may be None, which cannot be called with **
Change-Id: I546152312c1dfda69f90154cea5d87392e16a7ae
Closes-Bug: #2037596
** Changed in: neutron
Status: In Progress => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/2037596
Title:
Description Failed to invoke the API interface to obtain the address
group list
Status in neutron:
Fix Released
Bug description:
Call API interface:
GET /v2.0/address_groups
Exception log:
2023-09-28 09:05:07.951 182 ERROR futurist.periodics File "/var/lib/kolla/venv/lib/python3.6/site-packages/neutron/db/address group db.py", line 174, in get_address_groups
2023-09-28 09:05:07.951 182 ERROR futurist.periodics context, _pager=pager,**filters)
2023-09-28 09:05:07.951 182 ERROR futurist.periodics TypeError: get_objects() argument after ** must be a mapping, not NoyeType
2023-09-28 09:05:07.951 182 ERROR futurist.periodics
View code:
...
def get_address_groups(self, context, filters=None, fields=None,
sorts=None, limit=None, marker=None,
page_reverse=False):
pager = base_obj.Pager(sorts, limit, page_reverse, marker)
address_groups = ag_obj.AddressGroup.get_objects(
context, _pager=pager, **filters)
solution:
You need to add that you can judge whether the filters are None before using **filters
Add code:
filters = filters or {}
To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/2037596/+subscriptions
References