Make auth profiles respect DATABRICKS_CLI_PATH env var#4467
Merged
tejaskochar-db merged 9 commits intomainfrom Feb 12, 2026
Merged
Make auth profiles respect DATABRICKS_CLI_PATH env var#4467tejaskochar-db merged 9 commits intomainfrom
tejaskochar-db merged 9 commits intomainfrom
Conversation
Collaborator
|
Commit: 0159bc0
272 interesting tests: 244 MISS, 10 FAIL, 7 KNOWN, 5 SKIP, 3 flaky, 2 PANIC, 1 RECOVERED
Top 50 slowest tests (at least 2 minutes):
|
Collaborator
|
Commit: 0159bc0
292 interesting tests: 261 MISS, 14 FAIL, 7 KNOWN, 5 SKIP, 3 PANIC, 1 RECOVERED, 1 flaky
Top 50 slowest tests (at least 2 minutes):
|
Collaborator
|
Commit: 7d8620e
18 interesting tests: 7 KNOWN, 5 SKIP, 3 flaky, 2 RECOVERED, 1 FAIL
Top 50 slowest tests (at least 2 minutes):
|
denik
reviewed
Feb 11, 2026
| Loaders: []config.Loader{config.ConfigFile}, | ||
| ConfigFile: configFilePath, | ||
| Profile: c.Name, | ||
| DatabricksCliPath: os.Getenv("DATABRICKS_CLI_PATH"), |
Contributor
There was a problem hiding this comment.
Set DATABRICKS_CLI_PATH env variable to tmp build#4467
title does not match the change. The change is that "auth profiles" now respects $DATABRICKS_CLI_PATH, right?
Contributor
Author
There was a problem hiding this comment.
You're right, fixed.
Contributor
There was a problem hiding this comment.
Can you use env.Get(ctx, "DATABRICKS_CLI_PATH") here?
denik
approved these changes
Feb 11, 2026
Contributor
denik
left a comment
There was a problem hiding this comment.
Do we need to review other places as well?
% git grep config.Config{ ':(exclude)*_test.go' cmd
cmd/api/api.go: cfg := &config.Config{}
cmd/auth/env.go: cfg := &config.Config{
cmd/auth/login.go: err := databrickscfg.SaveToProfile(ctx, &config.Config{
cmd/auth/login.go: cfg := &config.Config{
cmd/auth/profiles.go: cfg := &config.Config{
cmd/configure/configure.go: return databrickscfg.SaveToProfile(ctx, &config.Config{
cmd/labs/project/entrypoint.go: return &config.Config{
cmd/labs/project/entrypoint.go: return &config.Config{}, nil
cmd/root/auth.go: cfg := &config.Config{}
cmd/root/auth.go: cfg := &config.Config{}
Collaborator
|
Commit: 3d8db90
30 interesting tests: 9 flaky, 7 KNOWN, 5 SKIP, 4 RECOVERED, 3 MISS, 1 FAIL, 1 PANIC
Top 50 slowest tests (at least 2 minutes):
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Update the
auth profilescommand to always load the value of theDATABRICKS_CLI_PATHenvironment variable as it otherwise does not load any environment variables.Why
databricks/databricks-sdk-go#1428 changed the
databricks-cliauth type in the Go SDK to use the CLI to fetch tokens instead of touching the U2M token store itself. Because of this acceptance tests break when we try to bump the go sdk version in the CLI, as the CLI was not accessible in the test environment. This PR makes it accessible.Tests
auth login acceptance tests should pass