Commits

Naoki INADA committed d203c93

More accurate error handling.

Comments (0)

Files changed (1)

                 encoding = 'utf-8'
             try:
                 return source.decode(encoding)
-            except Exception:
-                return None
+            except UnicodeError:
+                return source
 
     def complete(self, tab=False):
         """Construct a full list of possible completions and construct and