cancel
Showing results forĀ 
Search instead forĀ 
Did you mean:Ā 
Get Started Discussions
Start your journey with Databricks by joining discussions on getting started guides, tutorials, and introductory topics. Connect with beginners and experts alike to kickstart your Databricks experience.
cancel
Showing results forĀ 
Search instead forĀ 
Did you mean:Ā 

Error while installing lakebridge

Himanshu_Singh
New Contributor II

Hi All,

As part of my Databricks learning journey, I am trying installing the Lakebridge in my system but getting below error.

Traceback (most recent call last):
File "C:\Users\himan\.databricks\labs\lakebridge\state\venv\Lib\site-packages\databricks\sdk\config.py", line 272, in __init__
self._validate()
~~~~~~~~~~~~~~^^
File "C:\Users\himan\.databricks\labs\lakebridge\state\venv\Lib\site-packages\databricks\sdk\config.py", line 672, in _validate
raise ValueError(f"validate: more than one authorization method configured: {names}")
ValueError: validate: more than one authorization method configured: github-oidc and pat

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "C:\Users\himan\.databricks\labs\lakebridge\lib\src\databricks\labs\lakebridge\install.py", line 531, in <module>
ws=lakebridge.create_workspace_client(),
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
File "C:\Users\himan\.databricks\labs\lakebridge\lib\src\databricks\labs\lakebridge\cli.py", line 67, in create_workspace_client
return self._workspace_client()
~~~~~~~~~~~~~~~~~~~~~~^^
File "C:\Users\himan\.databricks\labs\lakebridge\state\venv\Lib\site-packages\databricks\labs\blueprint\cli.py", line 208, in _workspace_client
return WorkspaceClient(
product=self._product_info.product_name(),
product_version=self._product_info.version(),
)
File "C:\Users\himan\.databricks\labs\lakebridge\state\venv\Lib\site-packages\databricks\sdk\__init__.py", line 230, in __init__
config = client.Config(
host=host,
...<29 lines>...
),
)
File "C:\Users\himan\.databricks\labs\lakebridge\state\venv\Lib\site-packages\databricks\sdk\config.py", line 277, in __init__
raise ValueError(message) from e
ValueError: validate: more than one authorization method configured: github-oidc and pat. Config: host=https://adb-7405615889085100.0.azuredatabricks.net, account_id=72022d01-11ba-410c-83ba-4d1d262d6a02, workspace_id=7405615889085100, token=***, token_audience=https://adb-7405615889085100.0.azuredatabricks.net/oidc/v1/token, databricks_cli_path=C:\Users\himan\AppData\Local\Microsoft\WinGet\Packages\Databricks.DatabricksCLI_Microsoft.Winget.Source_8wekyb3d8bbwe\databricks.exe. Env: DATABRICKS_HOST, DATABRICKS_ACCOUNT_ID, DATABRICKS_WORKSPACE_ID, DATABRICKS_TOKEN, DATABRICKS_TOKEN_AUDIENCE, DATABRICKS_CLI_PATH
Error: installer: exit status 1
23:33:13 Info: failed execution pid=15164 exit_code=1 error="installer: exit status 1"
23:33:13 Debug: no telemetry logs to upload pid=15164

 

Can anyone guide me and explain what this error is all about, please? If need further info, let me know as well please.

 

Thank you.

5 REPLIES 5

balajij8
Esteemed Contributor

Hi,

It occurs as you have two different authentication methods configured simultaneously.

  1. PAT (Personal Access Token) - configured DATABRICKS_TOKEN environment variable
  2. GitHub OIDC - configured DATABRICKS_TOKEN_AUDIENCE environment variable

You can remove one of these authentication methods from the environment variables. PAT authentication is simpler and you can use it.

Use PAT - Find and delete the DATABRICKS_TOKEN_AUDIENCE variable from either User variables (for your account only), or System variables (if set there). Keep these variables - DATABRICKS_HOST, DATABRICKS_TOKEN, DATABRICKS_WORKSPACE_ID, DATABRICKS_ACCOUNT_ID

Close and reopen any command prompt/terminal windows for changes to take effect. Retry the Lakebridge installation

Use GitHub OIDC

If you want to use GitHub OIDC authentication, remove DATABRICKS_TOKEN instead, but this requires additional GitHub Actions setup and is typically used for CI/CD pipelines

Hi @balajij8 ,

I am not able to find out DATABRICKS_TOKEN_AUDIENCE set in environment variable neither as user nor as system variable. Is there any other way I can find out this value and remove it so that only PAT authentication comes into picture when installing the Lakebridge? Thanks for your help

balajij8
Esteemed Contributor

Hi @Himanshu_Singh 

When the process initializes it evaluates all available credentials across the system (environment variables, .databrickscfg file, CLI profiles). If it detects overlapping methods as in this case, traces of an OIDC configuration (DATABRICKS_TOKEN_AUDIENCE) alongside a Personal Access Token (DATABRICKS_TOKEN or pat) -it throws a ValueError to prevent ambiguous or insecure workspace connections. It is likely cached in the active terminal session retained by a background process.

You can follow below

  • If the variables are cached in the current terminal session - Identify the variables in the active environment. Open a PowerShell terminal and list the active variables
# List DATABRICKS_* environment variables
Get-ChildItem Env: | Where-Object { $_.Name -like "DATABRICKS_*" } | Format-Table Name, Value​
  • In the same PowerShell window (run as Administrator for system variables) execute
# Remove OIDC-related variables from User scope
[System.Environment]::SetEnvironmentVariable('DATABRICKS_TOKEN_AUDIENCE', $null, 'User')

# Remove from System scope (requires Administrator)
[System.Environment]::SetEnvironmentVariable('DATABRICKS_TOKEN_AUDIENCE', $null, 'Machine')

# If DATABRICKS_TOKEN is set via environment variable, remove it too
[System.Environment]::SetEnvironmentVariable('DATABRICKS_TOKEN', $null, 'User')
[System.Environment]::SetEnvironmentVariable('DATABRICKS_TOKEN', $null, 'Machine')

If you want the most stable and direct step - Remove the environment variables for credential management and rely exclusively on a configuration file. This provides a cleaner separation of environments. Create or edit your C:\Users\himan\.databrickscfg file to explicitly define your [DEFAULT] profile

[DEFAULT]
host = https://adb-7405615889085100.0.azuredatabricks.net
token = put the token

Retry the lakebridge installation after you remove the variables. You must close & reopen all terminals after removing the environment variables. Use the databrickscfg for authentication steps. Ensure the token is copied completely and the user account has necessary permissions. Regenerate the token if necessary.

More details here

balajij8
Esteemed Contributor

Hi Himan, Run the 1 command below before you retry the lakebridge installation.

set DATABRICKS_AUTH_TYPE=pat

 Lakebridge will install without issues.

DanielHarris
New Contributor

@Himanshu_Singh wrote:

Hi All,

As part of my Databricks learning journey, I am trying installing the Lakebridge in my system but getting below error.

Traceback (most recent call last):
File "C:\Users\himan\.databricks\labs\lakebridge\state\venv\Lib\site-packages\databricks\sdk\config.py", line 272, in __init__
self._validate()
~~~~~~~~~~~~~~^^
File "C:\Users\himan\.databricks\labs\lakebridge\state\venv\Lib\site-packages\databricks\sdk\config.py", line 672, in _validate
raise ValueError(f"validate: more than one authorization method configured: {names}")
ValueError: validate: more than one authorization method configured: github-oidc and pat

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "C:\Users\himan\.databricks\labs\lakebridge\lib\src\databricks\labs\lakebridge\install.py", line 531, in <module>
ws=lakebridge.create_workspace_client(),
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
File "C:\Users\himan\.databricks\labs\lakebridge\lib\src\databricks\labs\lakebridge\cli.py", line 67, in create_workspace_client
return self._workspace_client()
~~~~~~~~~~~~~~~~~~~~~~^^
File "C:\Users\himan\.databricks\labs\lakebridge\state\venv\Lib\site-packages\databricks\labs\blueprint\cli.py", line 208, in _workspace_client
return WorkspaceClient(
product=self._product_info.product_name(),
product_version=self._product_info.version(),
)
File "C:\Users\himan\.databricks\labs\lakebridge\state\venv\Lib\site-packages\databricks\sdk\__init__.py", line 230, in __init__
config = client.Config(
host=host,
...<29 lines>...
),
)
File "C:\Users\himan\.databricks\labs\lakebridge\state\venv\Lib\site-packages\databricks\sdk\config.py", line 277, in __init__
raise ValueError(message) from e
ValueError: validate: more than one authorization method configured: github-oidc and pat. Config: host=https://adb-7405615889085100.0.azuredatabricks.net , account_id=72022d01-11ba-410c-83ba-4d1d262d6a02, workspace_id=7405615889085100, token=***, token_audience=https://adb-7405615889085100.0.azuredatabricks.net/oidc/v1/token, databricks_cli_path=C:\Users\himan\AppData\Local\Microsoft\WinGet\Packages\Databricks.DatabricksCLI_Microsoft.Winget.Source_8wekyb3d8bbwe\databricks.exe. Env: DATABRICKS_HOST, DATABRICKS_ACCOUNT_ID, DATABRICKS_WORKSPACE_ID, DATABRICKS_TOKEN, DATABRICKS_TOKEN_AUDIENCE, DATABRICKS_CLI_PATH
Error: installer: exit status 1
23:33:13 Info: failed execution pid=15164 exit_code=1 error="installer: exit status 1"
23:33:13 Debug: no telemetry logs to upload pid=15164

 

Can anyone guide me and explain what this error is all about, please? If need further info, let me know as well please.

 

Thank you.


The full error message will probably make a big difference here. Installation issues can come from several places, such as missing prerequisites, network restrictions, or an incomplete Databricks CLI configuration. If you can share the complete stack trace along with your Python, Java, and CLI versions, it should be much easier to identify the root cause.