We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
_make_cached_property_uncached
1 parent 4f8f814 commit 0a09093Copy full SHA for 0a09093
1 file changed
src/attr/_make.py
@@ -498,10 +498,9 @@ def _transform_attrs(
498
def _make_cached_property_uncached(original_cached_property_func, cls):
499
"""Make an ordinary :deco:`property` to replace a :deco:`cached_property`
500
501
- This is mainly done for documentation purposes. The generated
502
- :deco:`property` won't be called, because of our custom :meth:`__getattr__`.
503
- We still want it there, so that its docstring is accessible, both to
504
- :function:`help` and to documentation generators, such as Sphinx.
+ The :deco:`property` will work on slotted instances. We'll make a slot
+ to keep the result of :func:`original_cached_property_func`, named like it,
+ with the suffix ``_cached``.
505
506
"""
507
name = original_cached_property_func.__name__
0 commit comments