mirror of
https://github.com/python/cpython.git
synced 2025-08-22 09:45:06 +00:00
gh-84623: Remove unused imports in stdlib (#93773)
This commit is contained in:
parent
65ac273280
commit
259dd71c32
12 changed files with 3 additions and 12 deletions
|
@ -1,7 +1,6 @@
|
||||||
__all__ = ()
|
__all__ = ()
|
||||||
|
|
||||||
import reprlib
|
import reprlib
|
||||||
from _thread import get_ident
|
|
||||||
|
|
||||||
from . import format_helpers
|
from . import format_helpers
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,6 @@ import collections.abc
|
||||||
import inspect
|
import inspect
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
import traceback
|
|
||||||
import types
|
import types
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -8,7 +8,6 @@ import enum
|
||||||
|
|
||||||
from . import exceptions
|
from . import exceptions
|
||||||
from . import mixins
|
from . import mixins
|
||||||
from . import tasks
|
|
||||||
|
|
||||||
class _ContextManagerMixin:
|
class _ContextManagerMixin:
|
||||||
async def __aenter__(self):
|
async def __aenter__(self):
|
||||||
|
|
|
@ -5,7 +5,6 @@ import enum
|
||||||
import functools
|
import functools
|
||||||
import threading
|
import threading
|
||||||
import signal
|
import signal
|
||||||
import sys
|
|
||||||
from . import coroutines
|
from . import coroutines
|
||||||
from . import events
|
from . import events
|
||||||
from . import exceptions
|
from . import exceptions
|
||||||
|
|
|
@ -4,7 +4,6 @@ __all__ = (
|
||||||
|
|
||||||
import socket
|
import socket
|
||||||
import sys
|
import sys
|
||||||
import warnings
|
|
||||||
import weakref
|
import weakref
|
||||||
|
|
||||||
if hasattr(socket, 'AF_UNIX'):
|
if hasattr(socket, 'AF_UNIX'):
|
||||||
|
|
|
@ -9,7 +9,6 @@ Written by: Fred L. Drake, Jr.
|
||||||
Email: <fdrake@acm.org>
|
Email: <fdrake@acm.org>
|
||||||
"""
|
"""
|
||||||
|
|
||||||
import _imp
|
|
||||||
import os
|
import os
|
||||||
import re
|
import re
|
||||||
import sys
|
import sys
|
||||||
|
|
|
@ -11,7 +11,7 @@ Refer to comments in EditorWindow autoindent code for details.
|
||||||
"""
|
"""
|
||||||
import re
|
import re
|
||||||
|
|
||||||
from tkinter import (Toplevel, Listbox, Scale, Canvas,
|
from tkinter import (Toplevel, Listbox, Canvas,
|
||||||
StringVar, BooleanVar, IntVar, TRUE, FALSE,
|
StringVar, BooleanVar, IntVar, TRUE, FALSE,
|
||||||
TOP, BOTTOM, RIGHT, LEFT, SOLID, GROOVE,
|
TOP, BOTTOM, RIGHT, LEFT, SOLID, GROOVE,
|
||||||
NONE, BOTH, X, Y, W, E, EW, NS, NSEW, NW,
|
NONE, BOTH, X, Y, W, E, EW, NS, NSEW, NW,
|
||||||
|
|
|
@ -12,7 +12,6 @@ TODO:
|
||||||
* std streams (pyshell, run),
|
* std streams (pyshell, run),
|
||||||
* warning stuff (pyshell, run).
|
* warning stuff (pyshell, run).
|
||||||
"""
|
"""
|
||||||
from os import path
|
|
||||||
|
|
||||||
# .pyw is for Windows; .pyi is for stub files.
|
# .pyw is for Windows; .pyi is for stub files.
|
||||||
py_extensions = ('.py', '.pyw', '.pyi') # Order needed for open/save dialogs.
|
py_extensions = ('.py', '.pyw', '.pyi') # Order needed for open/save dialogs.
|
||||||
|
|
|
@ -7,7 +7,7 @@ import functools
|
||||||
|
|
||||||
from time import monotonic as _time
|
from time import monotonic as _time
|
||||||
from _weakrefset import WeakSet
|
from _weakrefset import WeakSet
|
||||||
from itertools import islice as _islice, count as _count
|
from itertools import count as _count
|
||||||
try:
|
try:
|
||||||
from _collections import deque as _deque
|
from _collections import deque as _deque
|
||||||
except ImportError:
|
except ImportError:
|
||||||
|
|
|
@ -10,7 +10,7 @@
|
||||||
|
|
||||||
__all__ = ["Dialog"]
|
__all__ = ["Dialog"]
|
||||||
|
|
||||||
from tkinter import Frame, _get_temp_root, _destroy_temp_root
|
from tkinter import _get_temp_root, _destroy_temp_root
|
||||||
|
|
||||||
|
|
||||||
class Dialog:
|
class Dialog:
|
||||||
|
|
|
@ -30,7 +30,6 @@ test_urlparse.py provides a good indicator of parsing behavior.
|
||||||
from collections import namedtuple
|
from collections import namedtuple
|
||||||
import functools
|
import functools
|
||||||
import re
|
import re
|
||||||
import sys
|
|
||||||
import types
|
import types
|
||||||
import warnings
|
import warnings
|
||||||
|
|
||||||
|
|
|
@ -88,7 +88,6 @@ import hashlib
|
||||||
import http.client
|
import http.client
|
||||||
import io
|
import io
|
||||||
import os
|
import os
|
||||||
import posixpath
|
|
||||||
import re
|
import re
|
||||||
import socket
|
import socket
|
||||||
import string
|
import string
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue