]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
mgr/restful: do not use filter() for list
authorKefu Chai <kchai@redhat.com>
Thu, 2 May 2019 15:02:15 +0000 (23:02 +0800)
committerKefu Chai <kchai@redhat.com>
Thu, 2 May 2019 15:06:28 +0000 (23:06 +0800)
commit427bca899cb1f9ab041f4a33dfeb97a8edeb8211
treeee6c40fc73e217de9e458cec62892dd6ba999d62
parentaadb8ec856659a015f16d319efe4d4588362f97f
mgr/restful: do not use filter() for list

unlike python2, python3 returns an iterator instead of a list, so
construct a list using list comprehension directly.

Fixes: https://tracker.ceph.com/issues/38628
Signed-off-by: Kefu Chai <kchai@redhat.com>
src/pybind/mgr/restful/api/mon.py
src/pybind/mgr/restful/api/request.py