Hacktoberfest 2026 : les issues que les mainteneurs ont marquées pour octobre, ouvertes et accessibles aux débutants. Parcourir les issues Hacktoberfest

google.api_core.exceptions.RetryError: Timeout of 60.0s exceeded, last exception: 503 DNS resolution failed for firestore.googleapis.com: C-ares status is not ARES_SUCCESS qtype=A name=firestore.googleapis.com is_balancer=0: DNS query cancelled

Ouverte
#858 1 commentaire 1 réaction 0 personnes assignées Voir sur GitHub

Personne n'a encore pris cette issue.

Évaluation

Difficulté
4/5
Temps estimé
3-5 jours
Accessibilité débutants
20/100
Type d'issue
Bug
Clarté
À clarifier
Activité
À l'abandon
Stack technique
python
Domaine
databases

Piste de recherche

Commencez par reproduire le problème dans museum.py à la ligne 24, en utilisant Python 3.12.2, Firebase SDK 6.1.0 et l’appel montré au client Firestore. Vérifiez si l’échec peut être reproduit et s’il est causé par le SDK ou par la résolution DNS de firestore.googleapis.com. La tâche est considérée comme terminée lorsqu’un problème reproductible du SDK et un résultat attendu clair ont été identifiés, mais le rapport ne définit aucune modification de code.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Description

api: firestore
[REQUIRED] Step 2: Describe your environment
  • Operating System version: Mac OS
  • Firebase SDK version: 6.1.0
  • Firebase Product: firestore
  • Python version: 3.12.2
  • Pip version: 24.0 from /Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/pip (python 3.12)
[REQUIRED] Step 3: Describe the problem
cred = credentials.Certificate("firebase-privateKey.json")
firebase_admin.initialize_app(cred) 
db = firestore.client()


collections = list(db.collections())
if collections:
    print("Collections found:", [col.id for col in collections])
else:
    print("No collections found or access denied.")

The code fails with error below.

Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/google/api_core/grpc_helpers.py", line 76, in error_remapped_callable
    return callable_(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/grpc/_channel.py", line 1181, in __call__
    return _end_unary_response_blocking(state, call, False, None)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/grpc/_channel.py", line 1006, in _end_unary_response_blocking
    raise _InactiveRpcError(state)  # pytype: disable=not-instantiable
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with:
        status = StatusCode.UNAVAILABLE
        details = "DNS resolution failed for firestore.googleapis.com: C-ares status is not ARES_SUCCESS qtype=SRV name=_grpclb._tcp.firestore.googleapis.com: DNS query cancelled"
        debug_error_string = "UNKNOWN:Error received from peer  {grpc_message:"DNS resolution failed for firestore.googleapis.com: C-ares status is not ARES_SUCCESS qtype=SRV name=_grpclb._tcp.firestore.googleapis.com: DNS query cancelled", grpc_status:14, created_time:"2025-02-02T19:42:12.316149+09:00"}"
>

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/google/api_core/retry/retry_unary.py", line 144, in retry_target
    result = target()
             ^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/google/api_core/timeout.py", line 130, in func_with_timeout
    return func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/google/api_core/grpc_helpers.py", line 78, in error_remapped_callable
    raise exceptions.from_grpc_error(exc) from exc
google.api_core.exceptions.ServiceUnavailable: 503 DNS resolution failed for firestore.googleapis.com: C-ares status is not ARES_SUCCESS qtype=SRV name=_grpclb._tcp.firestore.googleapis.com: DNS query cancelled

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/Users/tenna/Desktop/tenna/art_sanpo/scraping/museum.py", line 24, in <module>
    collections = list(db.collections())
                  ^^^^^^^^^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/google/cloud/firestore_v1/client.py", line 279, in collections
    iterator = self._firestore_api.list_collection_ids(
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/google/cloud/firestore_v1/services/firestore/client.py", line 2057, in list_collection_ids
    response = rpc(
               ^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/google/api_core/gapic_v1/method.py", line 131, in __call__
    return wrapped_func(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/google/api_core/retry/retry_unary.py", line 293, in retry_wrapped_func
    return retry_target(
           ^^^^^^^^^^^^^
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/google/api_core/retry/retry_unary.py", line 153, in retry_target
    _retry_error_helper(
  File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/google/api_core/retry/retry_base.py", line 221, in _retry_error_helper
    raise final_exc from source_exc
google.api_core.exceptions.RetryError: Timeout of 60.0s exceeded, last exception: 503 DNS resolution failed for firestore.googleapis.com: C-ares status is not ARES_SUCCESS qtype=SRV name=_grpclb._tcp.firestore.googleapis.com: DNS query cancelled

I am running the script once a month, and It was working fine until 2025/1/5.
Suddenly stopped working yesterday (2025/2/1).

I can confirm the reject exists at: https://console.firebase.google.com/u/0/project/art-sanpo/overview?hl=ja
And the Blaze plan is turned on, access rule is allow read: if true; for all of the collections.

Langage dominant
Python
Étoiles
1.2k
Forks
359
Merge moyen
3 j 9 h
PR mergées (30 j)
3

Guide de contribution

Ouvrir le guide de contribution

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Autres issues de firebase/firebase-admin-python

Toutes les issues de firebase/firebase-admin-python

Issues similaires

Plus d'issues Python

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.