Comment 0 for bug 1819453

Revision history for this message
David O Neill (dmzoneill) wrote :

Proposed action:
=============
Key / value failed check error.
Should check key exists and warn user of bad users / continue

Bug presented by:
=================
openstack user list --domain neo.id
cannot concatenate 'str' and 'NoneType' objects (HTTP 400) (Request-ID: req-cc0e225d-d033-4dfa-aff8-7311389d4f58)

Trace:
======
(keystone.common.wsgi): 2019-03-11 12:30:47,154 ERROR cannot concatenate 'str' and 'NoneType' objects
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/keystone/common/wsgi.py", line 228, in __call__
    result = method(req, **params)
  File "/usr/lib/python2.7/dist-packages/keystone/common/controller.py", line 235, in wrapper
    return f(self, request, filters, **kwargs)
  File "/usr/lib/python2.7/dist-packages/keystone/identity/controllers.py", line 233, in list_users
    return UserV3.wrap_collection(request.context_dict, refs, hints=hints)
  File "/usr/lib/python2.7/dist-packages/keystone/common/controller.py", line 499, in wrap_collection
    cls.wrap_member(context, ref)
  File "/usr/lib/python2.7/dist-packages/keystone/common/controller.py", line 468, in wrap_member
    cls._add_self_referential_link(context, ref)
  File "/usr/lib/python2.7/dist-packages/keystone/common/controller.py", line 464, in _add_self_referential_link
    ref['links']['self'] = cls.base_url(context) + '/' + ref['id']
TypeError: cannot concatenate 'str' and 'NoneType' objects

Offending Data:
===============
@ line 233 i put LOG.debug( pprint.pformat( refs ) )

grep -b 2 "'id': None," /varlog/keystone/keystone.log

{'domain_id': u'8ce102de5ac644288f61838f5e0f46e7',
  'email': <email address hidden>',
  'id': None,
--
 {'domain_id': u'8ce102de5ac644288f61838f5e0f46e7',
  'email': <email address hidden>',
  'id': None,
--
 {'domain_id': u'8ce102de5ac644288f61838f5e0f46e7',
  'email': <email address hidden>',
  'id': None,

Platform:
=========
root@juju-a45617-8-lxd-4:/home/ubuntu# cat /etc/*-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=16.04
DISTRIB_CODENAME=xenial
DISTRIB_DESCRIPTION="Ubuntu 16.04.5 LTS"
NAME="Ubuntu"
VERSION="16.04.5 LTS (Xenial Xerus)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 16.04.5 LTS"
VERSION_ID="16.04"
HOME_URL="http://www.ubuntu.com/"
SUPPORT_URL="http://help.ubuntu.com/"
BUG_REPORT_URL="http://bugs.launchpad.net/ubuntu/"
VERSION_CODENAME=xenial
UBUNTU_CODENAME=xenial

verions:
========
root@juju-a45617-8-lxd-4:/home/ubuntu# dpkg --list | grep keystone
ii keystone 2:11.0.3-0ubuntu1~cloud0 all OpenStack identity service - Daemons
ii python-keystone 2:11.0.3-0ubuntu1~cloud0 all OpenStack identity service - Python library
ii python-keystoneauth1 2.18.0-0ubuntu2~cloud0 all authentication library for OpenStack Identity - Python 2.7
ii python-keystoneclient 1:3.10.0-0ubuntu1~cloud0 all client library for the OpenStack Keystone API - Python 2.x
ii python-keystonemiddleware 4.14.0-0ubuntu1.2~cloud0 all Middleware for OpenStack Identity (Keystone) - Python 2.x