[issue46622] Support decorating a coroutine with functools.cached_property

Andrew Svetlov report at bugs.python.org
Mon Feb 14 09:46:21 EST 2022


Andrew Svetlov <andrew.svetlov at gmail.com> added the comment:

>From my point of view, both sync and async functions can be cached.

Sync and async iterators/generators are other beasts: they don't return a value but generate a series of items. The series can be long and memory-consuming, I doubt if it should be cached safely.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue46622>
_______________________________________


More information about the Python-bugs-list mailing list