← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 2119543] [NEW] Keystone trusts cannot be listed

 

Public bug reported:

After upgrading from 2024.1 to 2025.1, python-openstackclient gets 400
Bad Request error when use command ``openstack trust list``.

This can be seen in tempest test
tempest.api.identity.admin.v3.test_trusts.TrustsV3TestJSON.test_get_trusts_all
as well.

Traceback (most recent call last):
  File "/home/rally/.rally/verification/verifier-748b0ee0-bac5-4455-8f75-0f849e022e9b/repo/tempest/api/identity/admin/v3/test_trusts.py", line 296, in test_get_trusts_all
    trusts_get = self.trusts_client.list_trusts()['trusts']
  File "/home/rally/.rally/verification/verifier-748b0ee0-bac5-4455-8f75-0f849e022e9b/repo/tempest/lib/services/identity/v3/trusts_client.py", line 54, in list_trusts
    resp, body = self.get(url)
  File "/home/rally/.rally/verification/verifier-748b0ee0-bac5-4455-8f75-0f849e022e9b/repo/tempest/lib/common/rest_client.py", line 342, in get
    return self.request('GET', url, extra_headers, headers,
  File "/home/rally/.rally/verification/verifier-748b0ee0-bac5-4455-8f75-0f849e022e9b/repo/tempest/lib/common/rest_client.py", line 762, in request
    self._error_checker(resp, resp_body)
  File "/home/rally/.rally/verification/verifier-748b0ee0-bac5-4455-8f75-0f849e022e9b/repo/tempest/lib/common/rest_client.py", line 877, in _error_checker
    raise exceptions.BadRequest(resp_body, resp=resp)
tempest.lib.exceptions.BadRequest: Bad request
Details: {'code': 400, 'message': "Invalid input for field/attribute 0. Value: {'delegation_depth': 0, 'id': '<trust id>', 'trustor_user_id': '<trustor user id>', 'trustee_user_id': '<trustee user id>', 'project_id': '<project id>', 'impersonation': True, 'expires_at': None, 'remaining_uses': None, 'deleted_at': None, 'redelegated_trust_id': None, 'redelegation_count': 0, 'links': {'self': 'https://<external keystone endpoint>:5000/v3/OS-TRUST/trusts/0428e7ecb9bc40db9a10a238851d1987'}}. Additional properties are not allowed ('delegation_depth' was unexpected)", 'title': 'Bad Request'}

The change https://review.opendev.org/c/openstack/keystone/+/939583,
specifically setting ``additionalProperties: False`` seems to be a root
cause of this problem.

** Affects: keystone
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Identity (keystone).
https://bugs.launchpad.net/bugs/2119543

Title:
  Keystone trusts cannot be listed

Status in OpenStack Identity (keystone):
  New

Bug description:
  After upgrading from 2024.1 to 2025.1, python-openstackclient gets 400
  Bad Request error when use command ``openstack trust list``.

  This can be seen in tempest test
  tempest.api.identity.admin.v3.test_trusts.TrustsV3TestJSON.test_get_trusts_all
  as well.

  Traceback (most recent call last):
    File "/home/rally/.rally/verification/verifier-748b0ee0-bac5-4455-8f75-0f849e022e9b/repo/tempest/api/identity/admin/v3/test_trusts.py", line 296, in test_get_trusts_all
      trusts_get = self.trusts_client.list_trusts()['trusts']
    File "/home/rally/.rally/verification/verifier-748b0ee0-bac5-4455-8f75-0f849e022e9b/repo/tempest/lib/services/identity/v3/trusts_client.py", line 54, in list_trusts
      resp, body = self.get(url)
    File "/home/rally/.rally/verification/verifier-748b0ee0-bac5-4455-8f75-0f849e022e9b/repo/tempest/lib/common/rest_client.py", line 342, in get
      return self.request('GET', url, extra_headers, headers,
    File "/home/rally/.rally/verification/verifier-748b0ee0-bac5-4455-8f75-0f849e022e9b/repo/tempest/lib/common/rest_client.py", line 762, in request
      self._error_checker(resp, resp_body)
    File "/home/rally/.rally/verification/verifier-748b0ee0-bac5-4455-8f75-0f849e022e9b/repo/tempest/lib/common/rest_client.py", line 877, in _error_checker
      raise exceptions.BadRequest(resp_body, resp=resp)
  tempest.lib.exceptions.BadRequest: Bad request
  Details: {'code': 400, 'message': "Invalid input for field/attribute 0. Value: {'delegation_depth': 0, 'id': '<trust id>', 'trustor_user_id': '<trustor user id>', 'trustee_user_id': '<trustee user id>', 'project_id': '<project id>', 'impersonation': True, 'expires_at': None, 'remaining_uses': None, 'deleted_at': None, 'redelegated_trust_id': None, 'redelegation_count': 0, 'links': {'self': 'https://<external keystone endpoint>:5000/v3/OS-TRUST/trusts/0428e7ecb9bc40db9a10a238851d1987'}}. Additional properties are not allowed ('delegation_depth' was unexpected)", 'title': 'Bad Request'}

  The change https://review.opendev.org/c/openstack/keystone/+/939583,
  specifically setting ``additionalProperties: False`` seems to be a
  root cause of this problem.

To manage notifications about this bug go to:
https://bugs.launchpad.net/keystone/+bug/2119543/+subscriptions