-
Notifications
You must be signed in to change notification settings - Fork 42
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
IllegalArgumentException from OAuthApp when passing in tokens #41
Comments
Hey, @eschultink, thanks for letting us know! It does look like constructing the app with a refresh token passed in isn't doing the right thing - that is, in Google's examples, the code path for not having a refresh token is clearly different from when you do specify a token, so we should be following that lead. |
¿Theres an alternative to solve this bug? |
Anything? I just came across this issue and I have no way to use my refreshToken without a valid way to construct a credential? |
Any news on this? As of version 0.8.1 this problem is still not solved. Creating an OAuthApp with a refreshToken is currently not possible. |
Trying to migrate to v0.5, we're using the new OAuthApp constructor that accepts a refresh token, as follows:
But we get an exception like the following:
And related, as it's not using
Credential.Builder
, it doesn't respect use of theJsonFactory
/HttpTransport
dependencies that are passed into the constructor.This is actually one-and-the-same bug; If you look at the check failing in
Credential
, it's that you must first have specified transport/jsonfactory/etc so that it knows how to use the refresh token.The text was updated successfully, but these errors were encountered: