INADA Naoki <songofaca...@gmail.com> added the comment:
> I like the idea of using @functools.cached_property in an abstract class as > "documentation". To announce that the property will be cached, even if > technically it will not be cached. It's more to use the code as documentation > than to execute any code. When thinking about "code as documentation", we should think not only Python iterpreter, but also IDE, static analystics tools. If we support abstractmethod + cached_property, it means we encourage to all IDEs & tools to support it. Otherwise, code completion or static analytics will be broken. I think "this property is likely (but not must be) cached" hint is not worth enough to add such complexity to all IDEs / static analytics tools. ---------- _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue34995> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com