]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-42508: Remove bogus idlelib.pyshell.ModifiedInterpreter attribute (GH-23570)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Mon, 30 Nov 2020 17:30:46 +0000 (09:30 -0800)
committerGitHub <noreply@github.com>
Mon, 30 Nov 2020 17:30:46 +0000 (09:30 -0800)
restart_subprocess is a method of self, the pyshell.InteractiveInterpreter instance. The latter does not have an interp attribute redundantly referring to itself. (The PyShell instance does have an interp attribute, referring to the InteractiveInterpreter instance.)
(cherry picked from commit e41bfd15dd148627b4f39c2a5837bddd8894d345)

Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Lib/idlelib/pyshell.py

index b69916dbe876cae7afce2d6f6aac3850f54def8f..adc302883ae66931fe40cb6e4259a86f11e8df3c 100755 (executable)
@@ -757,7 +757,7 @@ class ModifiedInterpreter(InteractiveInterpreter):
     def runcode(self, code):
         "Override base class method"
         if self.tkconsole.executing:
-            self.interp.restart_subprocess()
+            self.restart_subprocess()
         self.checklinecache()
         debugger = self.debugger
         try: