Repository navigation
Closed
Labels
Description
Describe the issue
databricks auth login for an account-level profile auto-generates a workspace_id field in .databrickscfg. This causes databricks auth describe to fail with Unable to authenticate: Unable to load OAuth Config, even though databricks auth token works correctly with the same profile. Removing workspace_id from the profile resolves the issue.
Steps to reproduce the behavior
- Run account-level login:
databricks auth login --host https://accounts.cloud.databricks.com --account-id <account-id>
- Follow the interactive prompts (select a workspace when asked).
- Observe the auto-generated profile in
~/.databrickscfg:[ACCOUNT-<account-id>] host = https://accounts.cloud.databricks.com/ account_id = <account-id> workspace_id = <workspace-id> auth_type = databricks-cli
- Run
databricks auth token --profile ACCOUNT-<account-id>→ succeeds (returns a valid token). - Run
databricks auth describe --profile ACCOUNT-<account-id>→ fails withUnable to authenticate: Unable to load OAuth Config. - Manually remove
workspace_idfrom the profile and re-login. - Run
databricks auth describe --profile ACCOUNT-<account-id>again → succeeds (Authenticated with: databricks-cli).
Expected Behavior
auth describeshould work with the auto-generated profile without manual edits.
Actual Behavior
auth loginwritesworkspace_idinto the account-level profile.auth describefails withUnable to authenticate: Unable to load OAuth Config.auth tokensucceeds with the same profile, indicating an inconsistency between the two commands.
OS and CLI version
- OS: Windows
- CLI: Databricks CLI v1.2.1
Is this a regression?
Unknown. This was observed on v1.2.1 (latest as of 2026-06-09). Not tested on earlier versions.
Debug Logs
> databricks auth describe --profile ACCOUNT-<account-id>
Unable to authenticate: Unable to load OAuth Config
Token storage: secure, OS keyring (service: databricks-cli) (from auth_storage in [__settings__] section of C:/Users/<user>/.databrickscfg)
-----
Current configuration:
✓ host: https://accounts.cloud.databricks.com/ (from C:\Users\<user>/.databrickscfg config file)
✓ account_id: <account-id> (from C:\Users\<user>/.databrickscfg config file)
✓ workspace_id: <workspace-id> (from C:\Users\<user>/.databrickscfg config file)
✓ profile: ACCOUNT-<account-id> (from --profile flag)
✓ auth_type: databricks-cli (from C:\Users\<user>/.databrickscfg config file)
✓ cloud: AWS
✓ audience: <account-id>
✓ discovery_url: https://accounts.cloud.databricks.com/oidc/accounts/<account-id>/.well-known/oauth-authorization-server
Activity
simonfaltum commentedon Jun 9, 2026
Hi @yamadahirotaka3tm
Thanks for the report.
I have tried to reproduce it following your steps both on mac and windows 11.
In both cases, when after I login to my account through the browser, it asks me to enter a workspace Id and I press enter to skip.
My profile looks like this:
You wrote in your step-by-step
Follow the interactive prompts (select a workspace when asked).I think one option is to skip a workspace, though I agree it might not be the most intuitive solution. We will look into improving this workflow.
yamadahirotaka3tm commentedon Jun 9, 2026
@simonfaltum
Thanks for the response and for reproducing it.
Yes, I'm aware that skipping the workspace selection avoids the issue — I filed this primarily as a report, since the CLI's interactive prompt naturally encourages users to select a workspace, and doing so produces a profile that breaks
auth describe.I'm glad to hear you're looking into improving this workflow. Thanks again!
auth describe: try both verification endpoints before reporting failu…
Improve errors for workspace commands against account console hosts (#…
[Release] Release v1.3.0
Skip workspace selection in auth login on account console hosts (data…