def parse_err(err):
    """
    Parse a `TwitterHTTPError and extract the error codes from it
    """
    response_data = err.response_data
    codes = set([error['code'] for error in response_data['errors']])
    return codes