]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
mgr/dashboard: do not import tools in access_control
authorKefu Chai <kchai@redhat.com>
Thu, 1 Apr 2021 04:14:31 +0000 (12:14 +0800)
committerKefu Chai <kchai@redhat.com>
Thu, 1 Apr 2021 08:05:57 +0000 (16:05 +0800)
commite2614de5d3ebb8b240facbc5e7ef3fc6293fbe12
tree0efebe46f6e91134a9c13fadc821db6158e1686d
parentf01c95f29c0214171040a435cab853b898c60c9c
mgr/dashboard: do not import tools in access_control

this addresses a regression introduced by
2cd94293268116838c3ddcebdedde4fbd9cb93aa. which

from ..tools import ensure_str

and it causes recursive import.

so, in this change, an copy of ensure_str() is added
to access_control.py

this change is not cherry-picked from master, as the offending commit
which is fixed by this change is not included in master.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/pybind/mgr/dashboard/services/access_control.py