File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -643,9 +643,9 @@ def showsyntaxerror(self, filename=None):
643643 text = tkconsole .text
644644 text .tag_remove ("ERROR" , "1.0" , "end" )
645645 type , value , tb = sys .exc_info ()
646- msg = value . msg or "<no detail available>"
647- lineno = value . lineno or 1
648- offset = value . offset or 0
646+ msg = getattr ( value , ' msg' , '' ) or value or "<no detail available>"
647+ lineno = getattr ( value , ' lineno' , '' ) or 1
648+ offset = getattr ( value , ' offset' , '' ) or 0
649649 if offset == 0 :
650650 lineno += 1 #mark end of offending line
651651 if lineno == 1 :
Original file line number Diff line number Diff line change @@ -101,10 +101,10 @@ def checksyntax(self, filename):
101101 try :
102102 # If successful, return the compiled code
103103 return compile (source , filename , "exec" )
104- except (SyntaxError , OverflowError ) as value :
105- msg = value . msg or "<no detail available>"
106- lineno = value . lineno or 1
107- offset = value . offset or 0
104+ except (SyntaxError , OverflowError , ValueError ) as value :
105+ msg = getattr ( value , ' msg' , '' ) or value or "<no detail available>"
106+ lineno = getattr ( value , ' lineno' , '' ) or 1
107+ offset = getattr ( value , ' offset' , '' ) or 0
108108 if offset == 0 :
109109 lineno += 1 #mark end of offending line
110110 pos = "0.0 + %d lines + %d chars" % (lineno - 1 , offset - 1 )
Original file line number Diff line number Diff line change @@ -705,6 +705,7 @@ Jean-François Piéronne
705705Guilherme Polo
706706Michael Pomraning
707707Iustin Pop
708+ Claudiu Popa
708709John Popplewell
709710Amrit Prem
710711Paul Prescod
Original file line number Diff line number Diff line change @@ -25,6 +25,10 @@ Core and Builtins
2525Library
2626-------
2727
28+ - Issue #9871: Prevent IDLE 3 crash when given byte stings
29+ with invalid hex escape sequences, like b'\x0'.
30+ (Original patch by Claudiu Popa.)
31+
2832- Issue #8933: distutils' PKG-INFO files will now correctly report
2933 Metadata-Version: 1.1 instead of 1.0 if a Classifier or Download-URL field is
3034 present.
You can’t perform that action at this time.
0 commit comments