Index: views/debug.py
===================================================================
--- views/debug.py	(Revision 5830)
+++ views/debug.py	(Arbeitskopie)
@@ -123,10 +128,19 @@
             'function': '?',
             'lineno': '?',
         }]
+
+    hint=""
+    if issubclass(exc_type, UnicodeError):
+        start=getattr(exc_value, 'start', None)
+        end=getattr(exc_value, 'end', None)
+        if start!=None and end!=None:
+            ustr=exc_value.args[1]
+            hint=smart_unicode(ustr[max(start-5, 0):min(end+5, len(ustr))], "ascii", errors="replace")
     t = Template(TECHNICAL_500_TEMPLATE, name='Technical 500 template')
     c = Context({
         'exception_type': exc_type.__name__,
         'exception_value': smart_unicode(exc_value, errors='replace'),
+        'hint': hint,
         'frames': frames,
         'lastframe': frames[-1],
         'request': request,
@@ -356,6 +370,10 @@
       <th>Python Version:</th>
       <td>{{ sys_version_info }}</td>
     </tr>
+    <tr>
+      <th>Hint:</th>
+      <td>{{ hint }}</td>
+    </tr>
   </table>
 </div>
 {% if template_does_not_exist %}
