Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Firebase TransportError for repeated requests from the same user #20

Closed
francbartoli opened this issue May 21, 2018 · 2 comments
Closed

Comments

@francbartoli
Copy link
Owner

Firebase sdk library seems to manage badly repeated requests:

    user = firebase_decode_handler(key)
  File "/home/gis/development/python/apps/gee-bridge/rest_auth_firebase/firebase_sdkadm.py", line 15, in firebase_decode_handler
    decoded_token = auth.verify_id_token(id_token, check_revoked=True)
  File "/home/gis/.local/share/virtualenvs/gee-bridge-u7zdh93C/lib/python2.7/site-packages/firebase_admin/auth.py", line 104, in verify_id_token
    verified_claims = token_generator.verify_id_token(id_token)
  File "/home/gis/.local/share/virtualenvs/gee-bridge-u7zdh93C/lib/python2.7/site-packages/firebase_admin/auth.py", line 838, in verify_id_token
    audience=project_id)
  File "/home/gis/.local/share/virtualenvs/gee-bridge-u7zdh93C/lib/python2.7/site-packages/google/oauth2/id_token.py", line 159, in verify_firebase_token
    id_token, request, audience=audience, certs_url=_GOOGLE_APIS_CERTS_URL)
  File "/home/gis/.local/share/virtualenvs/gee-bridge-u7zdh93C/lib/python2.7/site-packages/google/oauth2/id_token.py", line 120, in verify_token
    certs = _fetch_certs(request, certs_url)
  File "/home/gis/.local/share/virtualenvs/gee-bridge-u7zdh93C/lib/python2.7/site-packages/google/oauth2/id_token.py", line 94, in _fetch_certs
    response = request(certs_url, method='GET')
  File "/home/gis/.local/share/virtualenvs/gee-bridge-u7zdh93C/lib/python2.7/site-packages/google/auth/transport/requests.py", line 124, in __call__
    six.raise_from(new_exc, caught_exc)
  File "/home/gis/.local/share/virtualenvs/gee-bridge-u7zdh93C/lib/python2.7/site-packages/six.py", line 737, in raise_from
    raise value
TransportError: HTTPSConnectionPool(host='www.googleapis.com', port=443): Max retries exceeded with url: /robot/v1/metadata/x509/securetoken@system.gserviceaccount.com (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x7fd35de70650>: Failed to establish a new connection: [Errno 11] Resource temporarily unavailable',))
@francbartoli
Copy link
Owner Author

francbartoli commented May 21, 2018

It seems there should be no limitation on the number of requests

@francbartoli
Copy link
Owner Author

Upgrade to library 2.10+ and the problem seems solved

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant