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

Core: ServiceOptions.setCredentials fails with ClassCastException when using UserCredentials #123

vladimir-lu opened this issue Jan 9, 2020 · 1 comment · Fixed by #124
priority: p1 🚨 type: bug


Copy link

@vladimir-lu vladimir-lu commented Jan 9, 2020

On line

this.quotaProjectId = ((ServiceAccountCredentials) credentials).getQuotaProjectId();
the check is instanceof QuotaProjectIdProvider but the cast is to ServiceAccountCredentials therefore you get

class cannot be cast to class ( and are in unnamed module of loader 'app')

The cast needs to be changed. google-cloud-core version 1.92.0

@chingor13 chingor13 added priority: p1 type: bug labels Jan 9, 2020
Copy link

@chingor13 chingor13 commented Jan 9, 2020

Thanks for finding this and reporting it! It's definitely a bug and we'll fix and push a release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
priority: p1 🚨 type: bug
None yet

Successfully merging a pull request may close this issue.

3 participants