Add support for default_profile in [__settings__] section - #698
Merged
Conversation
simonfaltum
temporarily deployed
to
test-trigger-is
March 11, 2026 14:55 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
March 11, 2026 14:55 — with
GitHub Actions
Inactive
Adds support for the __settings__ section in .databrickscfg, enabling default_profile to specify which profile to use when none is explicitly set. The resolved profile is written back to DatabricksConfig so downstream consumers (e.g. DatabricksCliCredentialsProvider) see it. Rejects __settings__ as a profile target to prevent self-referencing. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
simonfaltum
force-pushed
the
default-profile
branch
from
March 11, 2026 15:10
9dd595d to
39ecf38
Compare
simonfaltum
temporarily deployed
to
test-trigger-is
March 11, 2026 15:10 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
March 11, 2026 15:10 — with
GitHub Actions
Inactive
Keep default_profile resolution aligned with the other SDKs by preserving the resolved profile name and surfacing bad settings targets instead of silently falling back.
simonfaltum
temporarily deployed
to
test-trigger-is
March 11, 2026 16:04 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
March 11, 2026 16:06 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
March 11, 2026 16:27 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
March 11, 2026 16:27 — with
GitHub Actions
Inactive
simonfaltum
marked this pull request as ready for review
March 11, 2026 20:19
Move all profile resolution logic (explicit, __settings__, DEFAULT fallback) into a single resolveProfile method that returns the profile name and whether it is a silent fallback. This replaces the two-boolean pattern (hasExplicitProfile, hasDefaultProfileSetting) with a clearer isFallback flag, and keeps __settings__ knowledge out of loadFromConfig entirely. Also improves error messages when __settings__ is used as a profile name: now says "reserved section name" instead of the generic "has no __settings__ profile configured". Co-authored-by: Isaac
simonfaltum
temporarily deployed
to
test-trigger-is
March 16, 2026 15:52 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
March 16, 2026 15:53 — with
GitHub Actions
Inactive
Co-authored-by: Isaac
simonfaltum
temporarily deployed
to
test-trigger-is
March 16, 2026 15:56 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
March 16, 2026 15:56 — with
GitHub Actions
Inactive
simonfaltum
requested review from
renaudhartert-db
and removed request for
parthban-db and
renaudhartert-db
March 22, 2026 07:10
Address review feedback: use a typed inner class instead of a String array to represent the resolved profile name and fallback flag. Co-authored-by: Isaac
# Conflicts: # NEXT_CHANGELOG.md
simonfaltum
temporarily deployed
to
test-trigger-is
March 28, 2026 07:41 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
March 28, 2026 07:43 — with
GitHub Actions
Inactive
hectorcast-db
approved these changes
Mar 30, 2026
simonfaltum
temporarily deployed
to
test-trigger-is
April 1, 2026 18:04 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
April 1, 2026 18:05 — with
GitHub Actions
Inactive
Maven Central is blocked on Databricks network (including GH Actions runners). Add proxy mirror config to all CI workflows so dependency resolution goes through maven-proxy.dev.databricks.com. For the release workflow, a Python script injects the mirror into the settings.xml that setup-java creates (to preserve server credentials). Co-authored-by: Isaac
simonfaltum
temporarily deployed
to
test-trigger-is
April 1, 2026 18:11 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
April 1, 2026 18:11 — with
GitHub Actions
Inactive
This reverts commit c200b12.
simonfaltum
temporarily deployed
to
test-trigger-is
April 1, 2026 18:12 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
April 1, 2026 18:14 — with
GitHub Actions
Inactive
simonfaltum
temporarily deployed
to
test-trigger-is
April 7, 2026 10:44 — with
GitHub Actions
Inactive
simonfaltum
had a problem deploying
to
test-trigger-is
April 7, 2026 10:46 — with
GitHub Actions
Failure
Co-authored-by: Isaac
simonfaltum
temporarily deployed
to
test-trigger-is
April 9, 2026 09:14 — with
GitHub Actions
Inactive
simonfaltum
had a problem deploying
to
test-trigger-is
April 9, 2026 09:15 — with
GitHub Actions
Failure
simonfaltum
temporarily deployed
to
test-trigger-is
April 10, 2026 14:20 — with
GitHub Actions
Inactive
simonfaltum
had a problem deploying
to
test-trigger-is
April 10, 2026 14:21 — with
GitHub Actions
Failure
simonfaltum
temporarily deployed
to
test-trigger-is
April 16, 2026 08:54 — with
GitHub Actions
Inactive
Contributor
|
If integration tests don't run automatically, an authorized user can run them manually by following the instructions below: Trigger: Inputs:
Checks will be approved automatically on success. |
simonfaltum
had a problem deploying
to
test-trigger-is
April 16, 2026 08:56 — with
GitHub Actions
Failure
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.
Summary
[__settings__].default_profilein~/.databrickscfgbefore falling back to theDEFAULTsectionauth switchfeatureProfile resolution order:
--profileflag, env var, or programmatic config)[__settings__].default_profile(new)[DEFAULT]section (legacy fallback)Changes
ConfigLoader.java: Extracted aresolveProfilemethod that encapsulates all profile resolution logic (explicit,[__settings__].default_profile, DEFAULT fallback). Returns the resolved profile name and whether it is a silent fallback.loadFromConfigno longer needs to know about__settings__at all, replacing two booleans (hasExplicitProfile,hasDefaultProfileSetting) with a singleisFallbackflag.Using
__settings__as a profile name (either via--profileordefault_profile) now returns a specific error ("reserved section name") instead of the generic "has no profile configured".DefaultProfileTest.java: 8 test scenarios covering resolution, precedence, legacy fallback, empty settings, explicit override, settings-not-a-profile (both via default_profile and explicit --profile), and nonexistent profile error.Test plan
default_profileresolves correctlydefault_profiletakes precedence over[DEFAULT][__settings__]default_profileis empty[__settings__]is not treated as a profile (viadefault_profile)[__settings__]is not treated as a profile (via explicit--profile)--profileoverridesdefault_profiledefault_profilepointing to nonexistent section throws error