-
Notifications
You must be signed in to change notification settings - Fork 303
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
publicly expose _default._load_credentials_from_info #1313
Comments
Hey @kapilt, can you expand on your use case a bit more? How is this dict being created? |
we're typically storing the credential info in a big table style data store, we want to be able to use service accounts, or workload identity federation information directly from the data store. using load_credentials_from_info would allow that, serializing to a temp file to using the existing interface is fairly extraneous. |
That sounds reasonable. I'll chat with the team and propose adding an API |
…efault credential object from a dictionary. This resolves googleapis#1313.
…efault credential object from a dictionary. This resolves googleapis#1313.
feat: Add public API load_credentials_from_dict to allow creating a default credential object from a dictionary. This resolves #1313.
at the moment the public interface is just google.auth.default() and load_credentials_from_file, but if we have a data dictionary already due to it being loaded from a non file source it would be nice to pass it directly to
load_credentials_from_info
https://github.com/googleapis/google-auth-library-python/blob/main/google/auth/_default.py#L133the load from file function is just a super thin wrapper to load from info.
afaics load_credentials_from_info is the most compatible across all the auth forms that gcp supports. (user default app, service account, external).
The text was updated successfully, but these errors were encountered: