Extended the ruff rule list and applied fixes · pypa/wheel@bd8ab85 (original) (raw)

8 files changed

lines changed

Original file line number Diff line number Diff line change
@@ -91,17 +91,16 @@ omit = ["*/vendored/*"]
91 91 [tool.coverage.report]
92 92 show_missing = true
93 93
94 -[tool.ruff]
95 -line-length = 88
96 -src = ["src"]
97 -
98 94 [tool.ruff.lint]
99 -select = [
100 -"E", "F", "W", # default flake-8
95 +extend-select = [
96 +"B", # flake8-bugbear
97 +"G", # flake8-logging-format
101 98 "I", # isort
99 +"ISC", # flake8-implicit-str-concat
102 100 "PGH", # pygrep-hooks
101 +"RUF100", # unused noqa (yesqa)
103 102 "UP", # pyupgrade
104 -"B", # flake8-bugbear
103 +"W", # pycodestyle warnings
105 104 ]
106 105
107 106 # Tox (https://tox.wiki/) is a tool for running tests in multiple virtualenvs.
Original file line number Diff line number Diff line change
@@ -96,7 +96,7 @@ def get_flag(
96 96 if val is None:
97 97 if warn:
98 98 warnings.warn(
99 -f"Config variable '{var}' is unset, Python ABI tag may " "be incorrect",
99 +f"Config variable '{var}' is unset, Python ABI tag may be incorrect",
100 100 RuntimeWarning,
101 101 stacklevel=2,
102 102 )
@@ -192,23 +192,23 @@ class bdist_wheel(Command):
192 192 (
193 193 "relative",
194 194 None,
195 -"build the archive using relative paths " "(default: false)",
195 +"build the archive using relative paths (default: false)",
196 196 ),
197 197 (
198 198 "owner=",
199 199 "u",
200 -"Owner name used when creating a tar file" " [default: current user]",
200 +"Owner name used when creating a tar file [default: current user]",
201 201 ),
202 202 (
203 203 "group=",
204 204 "g",
205 -"Group name used when creating a tar file" " [default: current group]",
205 +"Group name used when creating a tar file [default: current group]",
206 206 ),
207 - ("universal", None, "make a universal wheel" " (default: false)"),
207 + ("universal", None, "make a universal wheel (default: false)"),
208 208 (
209 209 "compression=",
210 210 None,
211 -"zipfile compression (one of: {})" " (default: 'deflated')".format(
211 +"zipfile compression (one of: {}) (default: 'deflated')".format(
212 212 ", ".join(supported_compressions)
213 213 ),
214 214 ),
@@ -228,7 +228,7 @@ class bdist_wheel(Command):
228 228 (
229 229 "py-limited-api=",
230 230 None,
231 -"Python tag (cp32|cp33
231 +"Python tag (cp32|cp33
232 232 ),
233 233 ]
234 234
Original file line number Diff line number Diff line change
@@ -7,7 +7,6 @@
7 7 from zipfile import ZipFile
8 8
9 9 import pytest
10 -
11 10 from wheel.cli.pack import pack
12 11
13 12 THISDIR = os.path.dirname(__file__)
Original file line number Diff line number Diff line change
@@ -6,7 +6,6 @@
6 6 from zipfile import ZipFile
7 7
8 8 import pytest
9 -
10 9 from wheel.cli import main, parser
11 10 from wheel.cli.tags import tags
12 11 from wheel.wheelfile import WheelFile
Original file line number Diff line number Diff line change
@@ -4,7 +4,6 @@
4 4 import stat
5 5
6 6 import pytest
7 -
8 7 from wheel.cli.unpack import unpack
9 8 from wheel.wheelfile import WheelFile
10 9
Original file line number Diff line number Diff line change
@@ -16,7 +16,6 @@
16 16
17 17 import pytest
18 18 import setuptools
19 -
20 19 from wheel.bdist_wheel import (
21 20 bdist_wheel,
22 21 get_abi_tag,
Original file line number Diff line number Diff line change
@@ -5,7 +5,6 @@
5 5 import sysconfig
6 6
7 7 import pytest
8 -
9 8 from wheel.bdist_wheel import get_platform
10 9 from wheel.macosx_libfile import extract_macosx_min_system_version
11 10
Original file line number Diff line number Diff line change
@@ -5,7 +5,6 @@
5 5 from zipfile import ZIP_DEFLATED, ZipFile
6 6
7 7 import pytest
8 -
9 8 from wheel.cli import WheelError
10 9 from wheel.wheelfile import WheelFile
11 10