(self,
cache_key: str,
regenerate_function,
miss_function_args={})
| 136 | |
| 137 | |
| 138 | def regenerate_cache_by_key(self, |
| 139 | cache_key: str, |
| 140 | regenerate_function, |
| 141 | miss_function_args={}): |
| 142 | # This assumes that get_with_cache() has been called first |
| 143 | |
| 144 | self.cache_dict[cache_key] = regenerate_function(**miss_function_args) |
| 145 | self.cache_dict['__info'][cache_key]['regenerate_datetime'] = datetime.datetime.utcnow().isoformat() |
| 146 | return self.cache_dict[cache_key] |
no outgoing calls
no test coverage detected