-
-
Notifications
You must be signed in to change notification settings - Fork 32.2k
gh-134357: Remove unused imports in tests #134340
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
4c79022
d6de873
8a964a0
775cdd5
16c200c
37d6384
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -6,8 +6,8 @@ | |||||||||||||
|
||||||||||||||
# aliases: | ||||||||||||||
from _interpchannels import ( | ||||||||||||||
ChannelError, ChannelNotFoundError, ChannelClosedError, | ||||||||||||||
ChannelEmptyError, ChannelNotEmptyError, | ||||||||||||||
hugovk marked this conversation as resolved.
Show resolved
Hide resolved
|
||||||||||||||
ChannelError, ChannelNotFoundError, ChannelClosedError, # noqa: F401 | ||||||||||||||
ChannelEmptyError, ChannelNotEmptyError, # noqa: F401 | ||||||||||||||
Comment on lines
+9
to
+10
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. In this specific case maybe better to add a per-file ignore? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Or would you prefer the two unused imports on the same line? That way we still check the rest of the file.
Suggested change
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm fine with the current PR: two lines with |
||||||||||||||
) | ||||||||||||||
from ._crossinterp import ( | ||||||||||||||
UNBOUND_ERROR, UNBOUND_REMOVE, | ||||||||||||||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
"""Cross-interpreter Queues High Level Module.""" | ||
|
||
import pickle | ||
import queue | ||
import time | ||
import weakref | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,7 +3,6 @@ | |
""" | ||
import os | ||
import sys | ||
import sysconfig | ||
import types | ||
import unittest | ||
from test import support | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,4 @@ | ||
import contextlib | ||
import importlib | ||
import importlib.util | ||
import itertools | ||
import sys | ||
import types | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
import binascii | ||
import ctypes | ||
import math | ||
import struct | ||
import sys | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,7 +12,6 @@ | |
import threading | ||
import types | ||
import unittest | ||
import warnings | ||
|
||
from test import support | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
import unittest | ||
from string.templatelib import Interpolation | ||
|
||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
import unittest | ||
|
||
from . import load_tests # noqa: F401 | ||
from . import load_tests | ||
|
||
|
||
if __name__ == "__main__": | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This import has to stay. It deserves a
# noqa: F401
.@encukou: Can you confirm?