Example #1
0
 def _write_cache(self, response):
     """
     Overrides parent method to use CachedResponse instead of memcache
     """
     if tba_config.CONFIG["response_cache"]:
         CachedResponse(
             id=self.cache_key,
             headers_json=json.dumps(dict(response.headers)),
             body=response.body,
         ).put()