@gen.engine
  def _GetUserInfo(self, device_dict, refresh_token, response):
    tokens = www_util.ParseJSONResponse(response)
    assert tokens, 'unable to fetch access token'
    access_token = tokens['access_token']
    expires = tokens['expires_in']
    if tokens.has_key('refresh_token') and not refresh_token:
      refresh_token = tokens['refresh_token']

    # Using the access token that was previously retrieved, request information about the
    # user that is logging in.
    assert access_token, 'no access token was provided'
    url = AuthGoogleHandler._OAUTH2_USERINFO_URL + '?' + urllib.urlencode({'access_token': access_token})
    http_client = httpclient.AsyncHTTPClient()
    response = yield gen.Task(http_client.fetch, url)

    # Parse the user information from the JSON response body and invoke _OnAuthenticate to
    # register the user as a viewfinder account. Create user dict from Google's JSON response.
    user_dict = www_util.ParseJSONResponse(response)
    assert user_dict, 'unable to fetch user data'
    assert 'phone' not in user_dict, user_dict
    assert 'email' in user_dict, user_dict
    user_dict['email'] = Identity.CanonicalizeEmail(user_dict['email'])

    # Ensure that user email is verified, else we can't trust that the user really owns it.
    if not user_dict.get('verified_email', False):
      raise web.HTTPError(403, _CANNOT_USE_UNVERIFIED_EMAIL % user_dict['email'])

    # Create identity dict from Google's email field.
    ident_dict = {'key': 'Email:%s' % user_dict['email'],
                  'authority': 'Google',
                  'refresh_token': refresh_token,
                  'access_token': access_token,
                  'expires': util.GetCurrentTimestamp() + expires}

    self._AuthUser(user_dict, ident_dict, device_dict)
L{isIPAddress} should return C{False} for a string containing
dataset/ETHPy150Open viewfinderco/viewfinder/backend/www/auth_google.py/AuthGoogleHandler._GetUserInfo--crossover with--dataset/ETHPy150Open kuri65536/python-for-android/python-modules/twisted/twisted/test/test_abstract.py/AddressTests.test_invalidPositive