File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -85,7 +85,7 @@ def getprog(self):
8585 except re .error as what :
8686 args = what .args
8787 msg = args [0 ]
88- col = arg [1 ] if len (args ) >= 2 else - 1
88+ col = args [1 ] if len (args ) >= 2 else - 1
8989 self .report_error (pat , msg , col )
9090 return None
9191 return prog
Original file line number Diff line number Diff line change @@ -131,8 +131,8 @@ def _stack_viewer(parent):
131131 root .geometry ("+%d+%d" % (x , y + 150 ))
132132 flist = PyShellFileList (root )
133133 try : # to obtain a traceback object
134- a
135- except :
134+ intentional_name_error
135+ except NameError :
136136 exc_type , exc_value , exc_tb = sys .exc_info ()
137137
138138 # inject stack trace to sys
Original file line number Diff line number Diff line change 1212
1313import unittest
1414import os
15- from tkinter import Tk , Text , TclError
15+ from tkinter import Tk
1616from idlelib import textView as tv
1717from idlelib .idle_test .mock_idle import Func
1818from idlelib .idle_test .mock_tk import Mbox
@@ -23,7 +23,7 @@ def setUpModule():
2323
2424def tearDownModule ():
2525 global root
26- root .destroy ()
26+ root .destroy () # pyflakes falsely sees root as undefined
2727 del root
2828
2929
You can’t perform that action at this time.
0 commit comments