From 57012cbaa39660b73820882b8bc69e1194cd5241 Mon Sep 17 00:00:00 2001 From: Jakob Meng Date: Tue, 12 Apr 2022 21:50:41 +0200 Subject: [PATCH] Drop username from return values of identity_user_info Users would have a non-null username only with Identity API v2 which was available in Keystone of OpenStack Pike. Identity API v2 has been removed since OpenStack Queens [1]. Function search_users() from OpenStack SDK still returns the username attribute because of [2][3] but it will always be None since Keystone's API does not return username since OpenStack Pike. [1] https://docs.openstack.org/releasenotes/keystone/queens.html [2] https://github.com/openstack/openstacksdk/blob/975cabbdd84baa8e05dc5b107b673607e7c0af1a/openstack/cloud/_utils.py#L246 [3] https://github.com/openstack/openstacksdk/commit/76b081efe45f1f2ab8e09a1fd5a23d9fc54361bc Change-Id: I2054dd55662698dabd0f2b3565c31dcd3bf24e5a (cherry picked from commit 5fc8fca06bfa3899a6183ec61349017bcc8fd0ec) --- plugins/modules/identity_user_info.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/modules/identity_user_info.py b/plugins/modules/identity_user_info.py index ccdee830..ee48a9c1 100644 --- a/plugins/modules/identity_user_info.py +++ b/plugins/modules/identity_user_info.py @@ -82,7 +82,7 @@ openstack_users: returned: success type: str name: - description: Name given to the user. + description: Username of the user. returned: success type: str enabled: @@ -102,7 +102,7 @@ openstack_users: returned: success type: str username: - description: Username of the user + description: Username with Identity API v2 (OpenStack Pike or earlier) else Null returned: success type: str '''