From 6334bd05e3221ff2955bbe1788289e7327ac908b Mon Sep 17 00:00:00 2001 From: Dave Bouvier Date: Tue, 4 Jun 2013 11:05:17 -0400 Subject: [PATCH] Fix server error when displaying a tool dependency installation status when the tool dependency contains certain unicode characters in the displayed error message. --- lib/tool_shed/util/shed_util_common.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/tool_shed/util/shed_util_common.py b/lib/tool_shed/util/shed_util_common.py index 7ae9e9dcd81..658ab6a014a 100644 --- a/lib/tool_shed/util/shed_util_common.py +++ b/lib/tool_shed/util/shed_util_common.py @@ -1214,7 +1214,7 @@ def to_safe_string( text, to_html=True ): if text: if to_html: try: - escaped_text = text.decode( 'utf-8' ) + escaped_text = unicodify( text ) escaped_text = escaped_text.encode( 'ascii', 'ignore' ) escaped_text = str( markupsafe.escape( escaped_text ) ) except UnicodeDecodeError, e: