From: Terry Jan Reedy Date: Tue, 18 Aug 2015 17:26:57 +0000 (-0400) Subject: Issue #24790: Remove extraneous code (which also create 2 & 3 conflicts). X-Git-Tag: v3.5.1rc1~427^2~77^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=a78ebe63239eb665ae139cf8155108af16b26b64;p=thirdparty%2FPython%2Fcpython.git Issue #24790: Remove extraneous code (which also create 2 & 3 conflicts). --- diff --git a/Lib/idlelib/StackViewer.py b/Lib/idlelib/StackViewer.py index b1e5e2674275..36507eea684d 100644 --- a/Lib/idlelib/StackViewer.py +++ b/Lib/idlelib/StackViewer.py @@ -10,8 +10,7 @@ from idlelib.PyShell import PyShellFileList def StackBrowser(root, flist=None, tb=None, top=None): if top is None: - from tkinter import Toplevel - top = Toplevel(root) + top = tk.Toplevel(root) sc = ScrolledCanvas(top, bg="white", highlightthickness=0) sc.frame.pack(expand=1, fill="both") item = StackTreeItem(flist, tb) @@ -108,12 +107,9 @@ class VariablesTreeItem(ObjectTreeItem): def IsExpandable(self): return len(self.object) > 0 - def keys(self): - return list(self.object.keys()) - def GetSubList(self): sublist = [] - for key in self.keys(): + for key in self.object.keys(): try: value = self.object[key] except KeyError: