Skip to content

Exception when printing models with Unicode characters #36

@jgarman

Description

@jgarman
---------------------------------------------------------------------------
UnicodeDecodeError                        Traceback (most recent call last)
<ipython-input-12-ab3a5d8f1075> in <module>()
----> 1 print b

.../six.pyc in <lambda>(self)
    840                              klass.__name__)
    841         klass.__unicode__ = klass.__str__
--> 842         klass.__str__ = lambda self: self.__unicode__().encode('utf-8')
    843     return klass
    844

.../cbapi-python/src/cbapi/oldmodels.pyc in __str__(self)
    164
    165         ret += u'\n'.join(['%-20s : %s' %
--> 166                            (a, getattr(self, a, "")) for a in self._stat_titles])
    167
    168         return ret

UnicodeDecodeError: 'ascii' codec can't decode byte 0x89 in position 0: ordinal not in range(128)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions