lru_cache is the simplest method of caching expensive function calls. It's hassle-free and it doesn't need a backend (such as Redis). But there's a gotcha when testing your application. Data could leak from a test case to another since they are cache...