Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
88ff426
Bump Go SDK to v0.126.0 and remove redundant agent tracking from CLI
simonfaltum Mar 20, 2026
11c2cc1
Revert codegen-induced action version downgrades
simonfaltum Mar 20, 2026
ef2d24d
Revert "Revert codegen-induced action version downgrades"
simonfaltum Mar 20, 2026
967eccb
Fix auth prompt logic to use HostType() and synthesize errors when pr…
simonfaltum Mar 20, 2026
5c74609
Fix auth prompt logic for SDK v0.126.0 host-type changes
simonfaltum Mar 20, 2026
a968333
Replace deprecated cfg.NewApiClient() with HTTPClientConfigFromConfig
simonfaltum Mar 20, 2026
8845a36
Add .well-known/databricks-config handler to test server
simonfaltum Mar 20, 2026
a66458b
Trust SDK auth resolution instead of overriding with HostType()
simonfaltum Mar 20, 2026
217f7a0
Regenerate remaining acceptance test golden files
simonfaltum Mar 20, 2026
2c7d6cf
Address PR review feedback
simonfaltum Mar 20, 2026
f21dc10
Fix auth error preservation and platform-specific DNS golden files
simonfaltum Mar 20, 2026
3075fda
Fix telemetry acceptance tests and pydabs check-formatting
simonfaltum Mar 20, 2026
bde633b
Fix flaky auth/switch/nominal test by mocking /.well-known/databricks…
simonfaltum Mar 20, 2026
c0fda17
Merge branch 'main' into simonfaltum/sdk-agent-cleanup
simonfaltum Mar 20, 2026
ae58ec5
Update record_cloud expected outputs to include .well-known/databrick…
simonfaltum Mar 20, 2026
711dee7
Address denik's review feedback on PR #4799
simonfaltum Mar 20, 2026
7bd2806
Merge branch 'main' into simonfaltum/sdk-agent-cleanup
simonfaltum Mar 20, 2026
809b73e
Update record_cloud volume-io expected outputs to include .well-known…
simonfaltum Mar 20, 2026
0a5aad8
Remove 4 incorrect .well-known/databricks-config entries from volume-…
simonfaltum Mar 20, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .codegen/_openapi_sha
Original file line number Diff line number Diff line change
@@ -1 +1 @@
a7c320a6b531263c8fa45619c1565b63849750e5
d09dbd77f5a9560cbb816746773da43a8bdbde08
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ cmd/workspace/enable-notebook-table-clipboard/enable-notebook-table-clipboard.go
cmd/workspace/enable-results-downloading/enable-results-downloading.go linguist-generated=true
cmd/workspace/enhanced-security-monitoring/enhanced-security-monitoring.go linguist-generated=true
cmd/workspace/entity-tag-assignments/entity-tag-assignments.go linguist-generated=true
cmd/workspace/environments/environments.go linguist-generated=true
cmd/workspace/experiments/experiments.go linguist-generated=true
cmd/workspace/external-lineage/external-lineage.go linguist-generated=true
cmd/workspace/external-locations/external-locations.go linguist-generated=true
Expand Down
4 changes: 4 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,7 @@ updates:
- "/.github/actions/setup-build-environment"
schedule:
interval: "monthly"
# tagging.yml is generated and maintained externally. Ignore
# actions/create-github-app-token since it is only used in tagging.yml.
ignore:
- dependency-name: "actions/create-github-app-token"
4 changes: 4 additions & 0 deletions acceptance/apps/deploy/bundle-with-appname/out.requests.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "POST",
"path": "/api/2.0/apps/test-app/deployments",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "POST",
"path": "/api/2.0/apps/test-app/deployments",
Expand Down
2 changes: 2 additions & 0 deletions acceptance/auth/bundle_and_profile/output.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@

=== Inside the bundle, profile flag not matching bundle host. Should use profile from the flag and not the bundle.
>>> errcode [CLI] current-user me -p profile_name
Warn: Failed to resolve host metadata: (redacted). Falling back to user config.
Error: Get "https://non.existing.subdomain.databricks.com/api/2.0/preview/scim/v2/Me": (redacted)

Exit code: 1
Expand Down Expand Up @@ -72,6 +73,7 @@ Validation OK!

=== Bundle commands load bundle configuration with -t and -p flag, validation not OK (profile host don't match bundle host)
>>> errcode [CLI] bundle validate -t prod -p DEFAULT
Warn: Failed to resolve host metadata: (redacted). Falling back to user config.
Error: cannot resolve bundle auth configuration: the host in the profile ([DATABRICKS_TARGET]) doesn’t match the host configured in the bundle (https://bar.com)

Name: test-auth
Expand Down
4 changes: 4 additions & 0 deletions acceptance/auth/bundle_and_profile/test.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ New='DATABRICKS_TARGET'
Old='DATABRICKS_URL'
New='DATABRICKS_TARGET'

[[Repls]]
Old='Warn: Failed to resolve host metadata: .*\. Falling back to user config\.'
New='Warn: Failed to resolve host metadata: (redacted). Falling back to user config.'

[[Repls]]
Old='Get "https://non.existing.subdomain.databricks.com/api/2.0/preview/scim/v2/Me": .*'
New='Get "https://non.existing.subdomain.databricks.com/api/2.0/preview/scim/v2/Me": (redacted)'
9 changes: 9 additions & 0 deletions acceptance/auth/credentials/basic/out.requests.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
{
"headers": {
"User-Agent": [
"cli/[DEV_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]"
]
},
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"headers": {
"Authorization": [
Expand Down
9 changes: 9 additions & 0 deletions acceptance/auth/credentials/oauth/out.requests.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
{
"headers": {
"User-Agent": [
"cli/[DEV_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]"
]
},
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"headers": {
"User-Agent": [
Expand Down
9 changes: 9 additions & 0 deletions acceptance/auth/credentials/pat/out.requests.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
{
"headers": {
"User-Agent": [
"cli/[DEV_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]"
]
},
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"headers": {
"Authorization": [
Expand Down
33 changes: 33 additions & 0 deletions acceptance/auth/credentials/unified-host/out.requests.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,36 @@
{
"headers": {
"User-Agent": [
"cli/[DEV_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]"
]
},
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"headers": {
"Authorization": [
"Bearer dapi-unified-token"
],
"User-Agent": [
"cli/[DEV_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS] cmd/current-user_me cmd-exec-id/[UUID] interactive/none auth/pat"
],
"X-Databricks-Org-Id": [
"[NUMID]"
]
},
"method": "GET",
"path": "/api/2.0/preview/scim/v2/Me"
}
{
"headers": {
"User-Agent": [
"cli/[DEV_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]"
]
},
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"headers": {
"Authorization": [
Expand Down
7 changes: 4 additions & 3 deletions acceptance/auth/credentials/unified-host/output.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
}

=== Without workspace_id (should error)
Error: WorkspaceID must be set when using WorkspaceClient with unified host

Exit code: 1
{
"id":"[USERID]",
"userName":"[USERNAME]"
}
25 changes: 11 additions & 14 deletions acceptance/bin/extract_command_exec_id.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,34 +8,31 @@
def extract_cmd_exec_id():
requests_file = Path("out.requests.txt")

# Read until we find a complete JSON object. This is required because we pretty
# print the JSON object (with new lines) in the out.requests.txt file.
# Read JSON objects one at a time and find the first one with a cmd-exec-id
# in the User-Agent header. Some requests (e.g. .well-known/databricks-config)
# are made before the command execution context is set and lack cmd-exec-id.
with requests_file.open("r") as f:
json_str = ""
while True:
line = f.readline()
if not line:
raise SystemExit("Requests file is empty")
break

json_str += line
try:
# Try to parse the accumulated string as JSON
data = json.loads(json_str)
break
except json.JSONDecodeError:
# If incomplete, continue reading
continue

user_agent = data["headers"]["User-Agent"][0]

if not user_agent:
raise SystemExit("User-Agent header is empty")
# Reset for next JSON object
json_str = ""

match = re.search(r"cmd-exec-id/([^\s]+)", user_agent)
if match:
return match.group(1)
user_agent = data.get("headers", {}).get("User-Agent", [""])[0]
match = re.search(r"cmd-exec-id/([^\s]+)", user_agent)
if match:
return match.group(1)

raise SystemExit(f"No command execution ID found in User-Agent: {user_agent}")
raise SystemExit("No command execution ID found in any request in out.requests.txt")


if __name__ == "__main__":
Expand Down
21 changes: 21 additions & 0 deletions acceptance/bundle/refschema/out.fields.txt
Original file line number Diff line number Diff line change
Expand Up @@ -890,6 +890,14 @@ resources.jobs.*.tags map[string]string ALL
resources.jobs.*.tags.* string ALL
resources.jobs.*.tasks []jobs.Task ALL
resources.jobs.*.tasks[*] jobs.Task ALL
resources.jobs.*.tasks[*].alert_task *jobs.AlertTask ALL
resources.jobs.*.tasks[*].alert_task.alert_id string ALL
resources.jobs.*.tasks[*].alert_task.subscribers []jobs.AlertTaskSubscriber ALL
resources.jobs.*.tasks[*].alert_task.subscribers[*] jobs.AlertTaskSubscriber ALL
resources.jobs.*.tasks[*].alert_task.subscribers[*].destination_id string ALL
resources.jobs.*.tasks[*].alert_task.subscribers[*].user_name string ALL
resources.jobs.*.tasks[*].alert_task.warehouse_id string ALL
resources.jobs.*.tasks[*].alert_task.workspace_path string ALL
resources.jobs.*.tasks[*].clean_rooms_notebook_task *jobs.CleanRoomsNotebookTask ALL
resources.jobs.*.tasks[*].clean_rooms_notebook_task.clean_room_name string ALL
resources.jobs.*.tasks[*].clean_rooms_notebook_task.etag string ALL
Expand Down Expand Up @@ -954,6 +962,14 @@ resources.jobs.*.tasks[*].for_each_task *jobs.ForEachTask ALL
resources.jobs.*.tasks[*].for_each_task.concurrency int ALL
resources.jobs.*.tasks[*].for_each_task.inputs string ALL
resources.jobs.*.tasks[*].for_each_task.task jobs.Task ALL
resources.jobs.*.tasks[*].for_each_task.task.alert_task *jobs.AlertTask ALL
resources.jobs.*.tasks[*].for_each_task.task.alert_task.alert_id string ALL
resources.jobs.*.tasks[*].for_each_task.task.alert_task.subscribers []jobs.AlertTaskSubscriber ALL
resources.jobs.*.tasks[*].for_each_task.task.alert_task.subscribers[*] jobs.AlertTaskSubscriber ALL
resources.jobs.*.tasks[*].for_each_task.task.alert_task.subscribers[*].destination_id string ALL
resources.jobs.*.tasks[*].for_each_task.task.alert_task.subscribers[*].user_name string ALL
resources.jobs.*.tasks[*].for_each_task.task.alert_task.warehouse_id string ALL
resources.jobs.*.tasks[*].for_each_task.task.alert_task.workspace_path string ALL
resources.jobs.*.tasks[*].for_each_task.task.clean_rooms_notebook_task *jobs.CleanRoomsNotebookTask ALL
resources.jobs.*.tasks[*].for_each_task.task.clean_rooms_notebook_task.clean_room_name string ALL
resources.jobs.*.tasks[*].for_each_task.task.clean_rooms_notebook_task.etag string ALL
Expand Down Expand Up @@ -2228,6 +2244,11 @@ resources.pipelines.*.health pipelines.GetPipelineResponseHealth REMOTE
resources.pipelines.*.id string ALL
resources.pipelines.*.ingestion_definition *pipelines.IngestionPipelineDefinition ALL
resources.pipelines.*.ingestion_definition.connection_name string ALL
resources.pipelines.*.ingestion_definition.connector_type pipelines.ConnectorType ALL
resources.pipelines.*.ingestion_definition.data_staging_options *pipelines.DataStagingOptions ALL
resources.pipelines.*.ingestion_definition.data_staging_options.catalog_name string ALL
resources.pipelines.*.ingestion_definition.data_staging_options.schema_name string ALL
resources.pipelines.*.ingestion_definition.data_staging_options.volume_name string ALL
resources.pipelines.*.ingestion_definition.full_refresh_window *pipelines.OperationTimeWindow ALL
resources.pipelines.*.ingestion_definition.full_refresh_window.days_of_week []pipelines.DayOfWeek ALL
resources.pipelines.*.ingestion_definition.full_refresh_window.days_of_week[*] pipelines.DayOfWeek ALL
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/api/2.0/preview/scim/v2/Me"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,15 @@
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/api/2.1/unity-catalog/volumes/main.myschema.myvolume"
}
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/api/2.1/unity-catalog/volumes/main.myschema.mynewvolume"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/oidc/.well-known/oauth-authorization-server"
Expand All @@ -12,6 +16,10 @@
"path": "/oidc/v1/token",
"raw_body": "grant_type=client_credentials\u0026scope=all-apis"
}
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/oidc/.well-known/oauth-authorization-server"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"headers": {
"Authorization": [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/oidc/.well-known/oauth-authorization-server"
Expand All @@ -12,6 +16,10 @@
"path": "/oidc/v1/token",
"raw_body": "grant_type=client_credentials\u0026scope=all-apis"
}
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/oidc/.well-known/oauth-authorization-server"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/oidc/.well-known/oauth-authorization-server"
Expand All @@ -21,6 +25,10 @@
"method": "GET",
"path": "/api/2.0/preview/scim/v2/Me"
}
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/oidc/.well-known/oauth-authorization-server"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"headers": {
"Authorization": [
Expand All @@ -7,6 +11,10 @@
"method": "GET",
"path": "/api/2.0/preview/scim/v2/Me"
}
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"headers": {
"Authorization": [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/oidc/.well-known/oauth-authorization-server"
Expand All @@ -21,6 +25,10 @@
"method": "GET",
"path": "/api/2.0/preview/scim/v2/Me"
}
{
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"method": "GET",
"path": "/oidc/.well-known/oauth-authorization-server"
Expand Down
5 changes: 5 additions & 0 deletions acceptance/bundle/telemetry/test.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,11 @@ DATABRICKS_CACHE_ENABLED = 'false'
Old = '"execution_time_ms": \d{1,5},'
New = '"execution_time_ms": SMALL_INT,'

# Same replacement for compact JSON inside protoLogs strings (no space after colon).
[[Repls]]
Old = 'execution_time_ms\\":\d{1,5},'
New = 'execution_time_ms\\":SMALL_INT,'

[[Repls]]
Old = '(linux|darwin|windows)'
New = '[OS]'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
{
"headers": {
"User-Agent": [
"cli/[DEV_VERSION] databricks-sdk-go/[SDK_VERSION] go/[GO_VERSION] os/[OS]"
]
},
"method": "GET",
"path": "/.well-known/databricks-config"
}
{
"headers": {
"User-Agent": [
Expand Down
Loading
Loading