With a new account in keystone upon the first nova request a 500 is retuned. Account creation through the shim succeeds, but the actual request fails. All subsequent requests are fine.
it seems that in the _build_mc_key method there is a string join, if one of the components is unicode the whole string becomes unicode.
(nova.api.openstack): TRACE:
(nova.api.openstack): TRACE: Traceback (most recent call last):
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/nova/api/openstack/__init__.py", line 64, in __call__
(nova.api.openstack): TRACE: return req.get_response(self.application)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/webob/request.py", line 1053, in get_response
(nova.api.openstack): TRACE: application, catch_exc_info=False)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/webob/request.py", line 1022, in call_application
(nova.api.openstack): TRACE: app_iter = application(self.environ, start_response)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/keystone/middleware/auth_token.py", line 212, in __call__
(nova.api.openstack): TRACE: return self._forward_request(env, start_response, proxy_headers)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/keystone/middleware/auth_token.py", line 344, in _forward_request
(nova.api.openstack): TRACE: return self.app(env, start_response)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/webob/dec.py", line 147, in __call__
(nova.api.openstack): TRACE: resp = self.call_func(req, *args, **self.kwargs)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/webob/dec.py", line 208, in call_func
(nova.api.openstack): TRACE: return self.func(req, *args, **kwargs)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/keystone/middleware/nova_auth_token.py", line 73, in __call__
(nova.api.openstack): TRACE: if user_ref.is_admin() != is_admin:
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/nova/auth/manager.py", line 134, in is_admin
(nova.api.openstack): TRACE: return AuthManager().is_admin(self)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/nova/auth/manager.py", line 376, in is_admin
(nova.api.openstack): TRACE: if self.is_superuser(user):
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/nova/auth/manager.py", line 362, in is_superuser
(nova.api.openstack): TRACE: if self.has_role(user, role):
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/nova/auth/manager.py", line 433, in has_role
(nova.api.openstack): TRACE: None)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/nova/auth/manager.py", line 394, in _has_role
(nova.api.openstack): TRACE: rslt = self.mc.get(mc_key)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/memcache.py", line 698, in get
(nova.api.openstack): TRACE: check_key(key)
(nova.api.openstack): TRACE: File "/usr/lib/pymodules/python2.6/memcache.py", line 985, in check_key
(nova.api.openstack): TRACE: raise Client.MemcachedStringEncodingError, ("Keys must be str()'s, not "
(nova.api.openstack): TRACE: MemcachedStringEncodingError: Keys must be str()'s, not unicode. Convert your unicode strings using mystring.encode(charset)!
(nova.api.openstack): TRACE:
this affects the diablo release, i have added a fix to gerrit https:/ /review. openstack. org/#change, 4380