def _is_gzip(self, response):
        archive = StringIO(response.body)
        try:
            body = gzip.GzipFile(fileobj=archive).read()
        except __HOLE__:
            return

        respcls = responsetypes.from_args(body=body)
        return response.replace(body=body, cls=respcls)
dataset/ETHPy150Open wcong/ants/ants/contrib_exp/downloadermiddleware/decompression.py/DecompressionMiddleware._is_gzip