Sviatoslav Sydorenko added the comment: Hi,
I've got similar need (caching exceptions). My use case is syscall, which is not going to result in something different regardless of the number of times it's called. But I'd like to be able to have exception already raised for me by lru_cache, so that I won't poke kernel with no need. I'd suggest adding `cache_exceptions=False` key to the decorator to let user control whether it's worth enabling. This might be useful in stdlib. ---------- nosy: +webknjaz _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue21537> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com