Skip to content

Commit 8c94c7f

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent fdccaa5 commit 8c94c7f

4 files changed

Lines changed: 7 additions & 9 deletions

File tree

src/attr/_make.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,10 +106,10 @@ def __reduce__(self, _none_constructor=type(None), _args=()): # noqa: B008
106106
class _TupleProxy(Sequence):
107107
__slots__ = ("_tup",)
108108
"""A wrapper for a tuple that makes it not type-check as a tuple
109-
109+
110110
This is a hack to make Sphinx document all cached properties on slots
111111
classes as if they were regular properties.
112-
112+
113113
"""
114114

115115
def __init__(self, tup: tuple):
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
.. autoclass:: tests.test_slots.SphinxDocTest
22

3-
.. autoproperty:: documented
3+
.. autoproperty:: documented

tests/members-cached-property.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
.. autoclass:: tests.test_slots.SphinxDocTest
2-
:members:
2+
:members:

tests/test_slots.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,24 +8,22 @@
88
import pickle
99
import shutil
1010
import weakref
11-
from itertools import zip_longest
1211

12+
from itertools import zip_longest
1313
from pathlib import Path
1414
from unittest import mock
1515

1616
import hypothesis.strategies as st
1717
import pytest
18-
from hypothesis import given
19-
20-
from attr._make import _TupleProxy
21-
2218

19+
from hypothesis import given
2320
from sphinx.application import Sphinx
2421

2522
import attr
2623
import attrs
2724

2825
from attr._compat import PY_3_14_PLUS, PYPY
26+
from attr._make import _TupleProxy
2927

3028

3129
# Pympler doesn't work on PyPy.

0 commit comments

Comments
 (0)