

def _parse_response(self, callback, response):
    if callback.error:
        gen_log.warning('HTTP error from Facebook: %s', response.error)
        callback(None)
        return
    try:
        json = escape.json_decode(response.body)
    except Exception:
        gen_log.warning('Invalid JSON from Facebook: %r', response.body)
        callback(None)
        return
    if (isinstance(json, dict) and json.get('error_code')):
        gen_log.warning('Facebook error: %d: %r', json['error_code'], json.get('error_msg'))
        callback(None)
        return
    callback(json)

dataset/ETHPy150Open D-L/SimpleBookMarks/src/tornado/auth.py FacebookMixin._parse_response/VarMisuse@15/18 `response`->`callback`