Код: Выделить всё
Reauthentication is needed. Please run 'gcloud auth application-default login' to reauthenticate.Код: Выделить всё
import google.auth
import google.auth.transport.requests
SCOPES = ["https://www.googleapis.com/auth/cloud-platform.read-only"]
credentials, project_id = google.auth.default(scopes=SCOPES, quota_project_id=None)
_ = google.auth.transport.requests.Request()
credentials.refresh(_)
Один и тот же код без проблем работает на Mac и Linux.
Подробнее здесь: https://stackoverflow.com/questions/785 ... dk-475-0-0
Мобильная версия