Google Oauth - works but not /api/user/current

Setting up Metabase and using Google Oauth. It appears to work from the logs, but when it tries to get the current user, it comes back 401 Unauthenticated.

Apr 11 12:19:49 metalhub-metabase app/web.1:  04-11 11:19:48 INFO api.session :: Successfully authenticated Google Auth token for: Brett McHargue 
Apr 11 12:19:49 metalhub-metabase app/web.1:  04-11 11:19:48 DEBUG middleware.log :: POST /api/session/google_auth 200 238 ms (3 DB calls) Jetty threads: 8/50 (5 busy, 3 idle, 0 queued) (50 total active threads) 
Apr 11 12:19:49 metalhub-metabase app/web.1:  04-11 11:19:48 DEBUG middleware.log :: GET /api/user/current 401 414 µs (0 DB calls) Jetty threads: 8/50 (5 busy, 3 idle, 0 queued) (50 total active threads)  
Apr 11 12:19:49 metalhub-metabase app/web.1:  "Unauthenticated" 
Apr 11 12:19:49 metalhub-metabase app/web.1:  

The end result is it reverts to the login page with no error message. In the chrome console you see the following:

We have another instance for a different site which has Google Oauth setup and is working fine. The only difference is the version number of Metabase. The new created instance is (latest, as of today) and the other is 0.31.0-RC1

I see there is an even new version out - I’ll upgrade and see if that fixes it.

*** UPDATE ***

Yes! That worked. Cheers!

1 Like