Google Auth in Tableau Desktop

What I’m trying to do:

I’m building a Tableau extension for my company that needs authentication, and I’m using the Google Auth option.

What I’ve tried and what’s not working:

I’ve tried adding Google Auth and running it either in Tableau Desktop, or Tableau Online.

The Tableau Desktop version pops up the browser window for authentication, but never authenticates in the extension itself (just stays on the “Log in with…” view)

The same version of the app authenticates in the Online version fine.

Is that expected that the locally run Tableau Desktop cannot use Google Auth, or am I doing something wrong? Ultimately the extension will be used in Tableau Online, but would need to work locally for development of those Tableau dashboards.

Code Sample:
It’s literally just adding the example code sample for Google Auth

# ...snip
class Homepage(HomepageTemplate):
    def __init__(self, **properties):
        # Show login
        email_addr = anvil.google.auth.login()
        print(f"User logged in as {email_addr}")

       self.dashboard = get_dashboard()
       # ...snip...

Hi @gergely.imreh,

Yes, I’m afraid that’s an annoying limitation of Tableau Desktop! Because the Google authentication window opens in the browser, it isn’t able to communicate the login details back to the extension running in the desktop. Other authentication methods that rely on popups (eg MS Azure or SAML) have the same problem - but as you say, they work fine in Tableau Online or Tableau Server, where Tableau and the popup run in the same web browser.

What I’d suggest is enabling ordinary email/password login for your development purposes, then switching to SSO only for production use.

1 Like

Thanks for confirming the experience!

Yeah, that difference makes sense in general. I’m checking whether that dual path worth it for our particular use case, or some other simplifications we can do. But cheers for the suggestion for different behaviour on Desktop and Web (good to see that I can get that info from the EnvironmentContext).