

def is_cache_saving_allowed(self, task, grab):
    '\n        Check if network transport result could\n        be saved to cache layer.\n\n        res: {ok, grab, grab_config_backup, task, emsg}\n        '
    if (grab.request_method == 'GET'):
        if (not task.get('disable_cache')):
            if self.spider.is_valid_network_response_code(grab.response.code, task):
                return True
    return False

dataset/ETHPy150Open lorien/grab/grab/spider/cache_pipeline.py CachePipeline.is_cache_saving_allowed/original