Skip to content

Commit fe334dc

Browse files
CoolCat467A5rocks
andcommitted
Ignore A005
Co-authored-by: A5rocks <[email protected]>
1 parent a38f7f6 commit fe334dc

File tree

6 files changed

+6
-16
lines changed

6 files changed

+6
-16
lines changed

pyproject.toml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -148,16 +148,20 @@ extend-ignore = [
148148
# to export for public use.
149149
'src/trio/__init__.py' = ['F401']
150150
'src/trio/_core/__init__.py' = ['F401']
151-
'src/trio/abc.py' = ['F401']
151+
'src/trio/abc.py' = ['F401', 'A005']
152152
'src/trio/lowlevel.py' = ['F401']
153-
'src/trio/socket.py' = ['F401']
153+
'src/trio/socket.py' = ['F401', 'A005']
154154
'src/trio/testing/__init__.py' = ['F401']
155155
# RUF029 is ignoring tests that are marked as async functions but
156156
# do not use an await in their function bodies. There are several
157157
# places where internal trio synchronous code relies on being
158158
# called from an async function, where current task is set up.
159159
'src/trio/_tests/*.py' = ['RUF029']
160160
'src/trio/_core/_tests/*.py' = ['RUF029']
161+
# A005 is ignoring modules that shadow stdlib modules.
162+
'src/trio/_abc.py' = ['A005']
163+
'src/trio/_socket.py' = ['A005']
164+
'src/trio/_ssl.py' = ['A005']
161165

162166
[tool.ruff.lint.isort]
163167
combine-as-imports = true

src/trio/_abc.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
# ruff: noqa: A005
2-
# Module `_abc` is shadowing a Python builtin module
3-
41
from __future__ import annotations
52

63
import socket

src/trio/_socket.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
# ruff: noqa: A005
2-
# Module `_socket` is shadowing a Python builtin module
3-
41
# ruff: noqa: PYI063 # Several cases throughout file where
52
# argument names with __ used because of typeshed, see comment for recv in _SocketType
63

src/trio/_ssl.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
# ruff: noqa: A005
2-
# Module `_ssl` is shadowing a Python builtin module
3-
41
from __future__ import annotations
52

63
import contextlib

src/trio/abc.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
# ruff: noqa: A005
2-
# Module `abc` is shadowing a Python builtin module
31
# This is a public namespace, so we don't want to expose any non-underscored
42
# attributes that aren't actually part of our public API. But it's very
53
# annoying to carefully always use underscored names for module-level

src/trio/socket.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
# ruff: noqa: A005
2-
# Module `socket` is shadowing a Python builtin module
3-
41
from __future__ import annotations
52

63
# This is a public namespace, so we don't want to expose any non-underscored

0 commit comments

Comments
 (0)