i18n Error for message objects concatenation

Bug #1575787 reported by Madhu Mohan Nelemane
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python-openstackclient
Fix Released
Undecided
Madhu Mohan Nelemane

Bug Description

Following error is seen on tests in some platforms. But it would be better to fix it in general.

     Traceback (most recent call last):
       File "/home/abuild/rpmbuild/BUILD/python-openstackclient-2.2.1.dev189/openstackclient/tests/common/test_clientmanager.py", line 345, in test_client_manager_select_auth_plugin_failure
         client_manager.setup_auth,
       File "/usr/lib/python2.7/site-packages/testtools/testcase.py", line 420, in assertRaises
         self.assertThat(our_callable, matcher)
       File "/usr/lib/python2.7/site-packages/testtools/testcase.py", line 431, in assertThat
         mismatch_error = self._matchHelper(matchee, matcher, message, verbose)
       File "/usr/lib/python2.7/site-packages/testtools/testcase.py", line 481, in _matchHelper
         mismatch = matcher.match(matchee)
       File "/usr/lib/python2.7/site-packages/testtools/matchers/_exception.py", line 108, in match
         mismatch = self.exception_matcher.match(exc_info)
       File "/usr/lib/python2.7/site-packages/testtools/matchers/_higherorder.py", line 62, in match
         mismatch = matcher.match(matchee)
       File "/usr/lib/python2.7/site-packages/testtools/testcase.py", line 412, in match
         reraise(*matchee)
       File "/usr/lib/python2.7/site-packages/testtools/matchers/_exception.py", line 101, in match
         result = matchee()
       File "/usr/lib/python2.7/site-packages/testtools/testcase.py", line 965, in __call__
         return self._callable_object(*self._args, **self._kwargs)
       File "/home/abuild/rpmbuild/BUILD/python-openstackclient-2.2.1.dev189/openstackclient/common/clientmanager.py", line 154, in setup_auth
         required_scope=required_scope)
       File "/home/abuild/rpmbuild/BUILD/python-openstackclient-2.2.1.dev189/openstackclient/api/auth.py", line 148, in check_valid_auth_options
         msg += _('Set a username with --os-username, OS_USERNAME,'
       File "/usr/lib/python2.7/site-packages/oslo_i18n/_message.py", line 233, in __radd__
         return self.__add__(other)
       File "/usr/lib/python2.7/site-packages/oslo_i18n/_message.py", line 230, in __add__
         raise TypeError(msg)
     TypeError: Message objects do not support addition.

Changed in python-openstackclient:
assignee: nobody → Madhu Mohan Nelemane (mmohan-9)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-openstackclient (master)

Fix proposed to branch: master
Review: https://review.openstack.org/310537

Changed in python-openstackclient:
status: New → In Progress
Revision history for this message
Steve Martinelli (stevemar) wrote :

how are you running the tests?

Revision history for this message
Guang Yee (guang-yee) wrote :

I got the same traceback simply by running tox.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-openstackclient (master)

Reviewed: https://review.openstack.org/310537
Committed: https://git.openstack.org/cgit/openstack/python-openstackclient/commit/?id=a4d4e81c88da400d4ec62fb9fdc00eeeafafc0e5
Submitter: Jenkins
Branch: master

commit a4d4e81c88da400d4ec62fb9fdc00eeeafafc0e5
Author: Madhu Mohan Nelemane <email address hidden>
Date: Wed Apr 27 18:43:57 2016 +0200

    Avoid TypeError on message object additions

    Change-Id: I634c1e158e93eeb55ab17fef8a0715b6678dffec
    Closes-Bug: #1575787

Changed in python-openstackclient:
status: In Progress → Fix Released
Revision history for this message
Doug Hellmann (doug-hellmann) wrote : Fix included in openstack/python-openstackclient 2.5.0

This issue was fixed in the openstack/python-openstackclient 2.5.0 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.