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

Consider showing cause of errors from Google Cloud #65

Open
ccjernigan opened this issue Jan 13, 2025 · 0 comments
Open

Consider showing cause of errors from Google Cloud #65

ccjernigan opened this issue Jan 13, 2025 · 0 comments

Comments

@ccjernigan
Copy link

Problem:
This try-catch hides underlying error messages from Google Cloud, which makes it very difficult to identify the root cause of configuration issues.

I recently tried setting up the gcp-gradle-build-cache with workload identity federation. I first followed the instructions from the Google Auth GitHub Action for workload identity federation through a device account. Then I followed the instructions in this project for setting up the Google Cloud storage and permissions. The result was error messages saying my token was expired, which I knew wasn't accurate.

Solution:
Can the code be updated to propagate the cause of the exception?

In my case the underlying error was a disabled API in Google Cloud, which became clear once I modified the code to include the underlying cause which told me: "IAM Service Account Credentials API has not been used in project X before or it is disabled. Enable it by visiting https://console.developers.google.com/apis/api/iamcredentials.googleapis.com/overview?project=X then retry. If you enabled this API recently, wait a few minutes for the action to propagate to our systems and retry.",

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