goth icon indicating copy to clipboard operation
goth copied to clipboard

Access Tokens returned but no raw data (on-prem gitlab)

Open nhi-vanye opened this issue 4 years ago • 2 comments

Successfully logged in using GitHub and google

Version 13.1.4 of gitlab-ce

2020-07-17T15:52:32.128 | ERROR | (goth.User) {
 RawData: (map[string]interface {}) <nil>,
 Provider: (string) (len=6) "gitlab",
 Email: (string) "",
 Name: (string) "",
 FirstName: (string) "",
 LastName: (string) "",
 NickName: (string) "",
 Description: (string) "",
 UserID: (string) "",
 AvatarURL: (string) "",
 Location: (string) "",
 AccessToken: (string) (len=64) "ae4dc7c22470c8de4031ff3177c4029365fca77acf2fe6b59786d038636fa889",
 AccessTokenSecret: (string) "",
 RefreshToken: (string) (len=64) "6eaaad2f48b3e3777e151b6ad8f4c2e1bd0d1a15d497520830d315c22e35be53",
 ExpiresAt: (time.Time) 0001-01-01 00:00:00 +0000 UTC,
 IDToken: (string) ""
}
2020-07-17T15:52:32.128 | ERROR | invalid character '<' looking for beginning of value
2020-07-17_15-05-27

nhi-vanye avatar Jul 17 '20 14:07 nhi-vanye

I had same issue in gitlab.com.

Maybe you need to pass "read_user" as scopes arguments of gitlab.New(). It seems that api scope needs to be granted in GitLab application setting when you don't specify any scopes in the function, but I think this behavior is a problem on GitLab.

GitLab version: GitLab Enterprise Edition 13.3.0-pre ac4beb53d4e

osamu329 avatar Aug 06 '20 20:08 osamu329

That didn't seem to work for me...

nhi-vanye avatar Aug 06 '20 20:08 nhi-vanye