File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -562,7 +562,7 @@ def process_control_event(self, e):
562562 self .startup ()
563563 except IOError as e :
564564 self .status_bar .message (
565- _ ('Executing PYTHONSTARTUP failed: %s' ) % (str ( e ) ))
565+ _ ('Executing PYTHONSTARTUP failed: %s' ) % (e , ))
566566
567567 elif isinstance (e , bpythonevents .UndoEvent ):
568568 self .undo (n = e .n )
@@ -1532,7 +1532,7 @@ def show_source(self):
15321532 try :
15331533 source = self .get_source_of_current_name ()
15341534 except SourceNotFound as e :
1535- self .status_bar .message (str ( e ))
1535+ self .status_bar .message ('%s' % ( e , ))
15361536 else :
15371537 if self .config .highlight_show_source :
15381538 source = format (PythonLexer ().get_tokens (source ),
Original file line number Diff line number Diff line change @@ -545,11 +545,11 @@ def get_source_of_current_name(self):
545545 obj = self .get_object (line )
546546 return inspection .get_source_unicode (obj )
547547 except (AttributeError , NameError ) as e :
548- msg = _ ("Cannot get source: %s" ) % (str ( e ) , )
548+ msg = _ (u "Cannot get source: %s" ) % (e , )
549549 except IOError as e :
550- msg = str ( e )
550+ msg = u"%s" % ( e , )
551551 except TypeError as e :
552- if "built-in" in str ( e ):
552+ if "built-in" in u"%s" % ( e , ):
553553 msg = _ ("Cannot access source of %r" ) % (obj , )
554554 else :
555555 msg = _ ("No source code found for %s" ) % (self .current_line , )
You can’t perform that action at this time.
0 commit comments