yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #17480
[Bug 1318487] Re: Got error Message objects do not support str() because they may..
[Expired for Keystone because there has been no activity for 60 days.]
** Changed in: keystone
Status: Incomplete => Expired
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Keystone.
https://bugs.launchpad.net/bugs/1318487
Title:
Got error Message objects do not support str() because they may..
Status in OpenStack Identity (Keystone):
Expired
Bug description:
I was trying keystone integration with Tivoli directoy server, in the course of playing around several times I got an error message.
The file was /usr/lib/python2.6/site-packages/keystone/openstack/common/gettextutils.py
Instead of raising exception, I modified the __str__ method to instead call translate. And I started getting proper error logs.
I am not a python expert and may be __str__ is not suppose to return double byte chars, I wish I could provide the exact setting that gives this error, but I am not getting it anymore, even after I have reverted my change.
def __str__(self):
# NOTE(luisg): Logging in python 2.6 tries to str() log records,
# and it expects specifically a UnicodeError in order to proceed.
msg = _('Message objects do not support str() because they may '
'contain non-ascii characters. '
'Please use unicode() or translate() instead.')
#mahesh commented out the code below
return translate(self)
#raise UnicodeError(msg)
To manage notifications about this bug go to:
https://bugs.launchpad.net/keystone/+bug/1318487/+subscriptions
References