Mercurial > hg > bzconsole
changeset 29:c412148c8c1e
fix piping issue
author | Jeff Hammel <jhammel@mozilla.com> |
---|---|
date | Tue, 24 Apr 2012 13:46:15 -0700 |
parents | a46a76a7990d |
children | 07dc3f9de6bc |
files | bzconsole/command.py |
diffstat | 1 files changed, 4 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/bzconsole/command.py Thu Apr 05 08:51:33 2012 -0700 +++ b/bzconsole/command.py Tue Apr 24 13:46:15 2012 -0700 @@ -128,7 +128,10 @@ # invoke the command retval = getattr(_object, name)(*command_args, **command_options.__dict__) if isinstance(retval, basestring): - print retval + try: + print retval + except: + print str(retval.encode('ascii', errors='ignore')) elif retval is None: pass elif isinstance(retval, list):