Skip to content
This repository was archived by the owner on Feb 13, 2025. It is now read-only.

Commit c6696fe

Browse files
authored
[3.6] bpo-29919 Remove unused imports from idlelib [GH-137] (python#2105)
Part of patch by Victor Stinner. (cherry-pick from d6debb2)
1 parent d755d19 commit c6696fe

File tree

7 files changed

+4
-9
lines changed

7 files changed

+4
-9
lines changed

Lib/idlelib/config.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
import os
3030
import sys
3131

32-
from tkinter.font import Font, nametofont
32+
from tkinter.font import Font
3333

3434
class InvalidConfigType(Exception): pass
3535
class InvalidConfigSet(Exception): pass

Lib/idlelib/editor.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
from idlelib import query
2727
from idlelib import replace
2828
from idlelib import search
29-
from idlelib import textview
3029
from idlelib import windows
3130

3231
# The default tab setting for a Text widget, in average-width characters.

Lib/idlelib/idle_test/test_config.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,7 @@
33
Much is tested by opening config dialog live or in test_configdialog.
44
Coverage: 27%
55
'''
6-
from sys import modules
76
from test.support import captured_stderr
8-
from tkinter import Tk
97
import unittest
108
from idlelib import config
119

Lib/idlelib/idle_test/test_config_key.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
from test.support import requires
77
requires('gui')
88
import unittest
9-
from tkinter import Tk, Text
9+
from tkinter import Tk
1010

1111

1212
class GetKeysTest(unittest.TestCase):

Lib/idlelib/idle_test/test_editor.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
import unittest
2-
from tkinter import Tk, Text
32
from idlelib.editor import EditorWindow
4-
from test.support import requires
53

64
class Editor_func_test(unittest.TestCase):
75
def test_filename_to_unicode(self):

Lib/idlelib/idle_test/test_searchbase.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
'''
66
import unittest
77
from test.support import requires
8-
from tkinter import Tk, Toplevel, Frame ##, BooleanVar, StringVar
8+
from tkinter import Tk, Frame ##, BooleanVar, StringVar
99
from idlelib import searchengine as se
1010
from idlelib import searchbase as sdb
1111
from idlelib.idle_test.mock_idle import Func

Lib/idlelib/query.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
import os
2525
from sys import executable, platform # Platform is set for one test.
2626

27-
from tkinter import Toplevel, StringVar, W, E, N, S
27+
from tkinter import Toplevel, StringVar, W, E, S
2828
from tkinter.ttk import Frame, Button, Entry, Label
2929
from tkinter import filedialog
3030
from tkinter.font import Font

0 commit comments

Comments
 (0)