Skip to content

Commit a7906c2

Browse files
Merge branch 'main' into validate/for_each_task_validation
2 parents 6292ae5 + 6098fef commit a7906c2

File tree

303 files changed

+4726
-395
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

303 files changed

+4726
-395
lines changed

.codegen/_openapi_sha

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
8b2cd47cbac64b32e120601110a5fc70b8189ba4
1+
e1ea3f5ba0bc5b53be94f56535a67ba701a52a52

.release_metadata.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
"timestamp": "2025-12-10 14:20:46+0000"
2+
"timestamp": "2025-12-18 13:04:36+0000"
33
}

CHANGELOG.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,22 @@
11
# Version changelog
22

3+
## Release v0.281.0 (2025-12-18)
4+
5+
### CLI
6+
* Fix lakeview publish to default `embed_credentials` to false ([#4066](https://github.com/databricks/cli/pull/4066))
7+
8+
### Bundles
9+
* Add support for configurable catalog/schema for dashboards ([#4130](https://github.com/databricks/cli/pull/4130))
10+
* Pass SYSTEM\_ACCESSTOKEN from env to the Terraform provider ([#4135](https://github.com/databricks/cli/pull/4135))
11+
* `bundle deployment migrate`: when running `bundle plan` propagate `-var` arguments.
12+
* engine/direct: New option --plan to `bundle deploy` to deploy previously saved plan (saved plan with `bundle plan -o json`) ([#4134](https://github.com/databricks/cli/pull/4134))
13+
* engine/direct: Fix dependency-ordered deletion by persisting depends\_on in state ([#4105](https://github.com/databricks/cli/pull/4105))
14+
15+
### Dependency updates
16+
* Upgrade Go SDK to 0.94.0 ([#4148](https://github.com/databricks/cli/pull/4148))
17+
* Upgrade Terraform provider to 1.100.0 ([#4150](https://github.com/databricks/cli/pull/4150))
18+
19+
320
## Release v0.280.0 (2025-12-10)
421

522
### Bundles

Makefile

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,10 @@ test-update:
8787
test-update-templates:
8888
-go test ./acceptance -run '^TestAccept/bundle/templates' -update -timeout=${LOCAL_TIMEOUT}
8989

90+
# Regenerate out.test.toml files without running tests
91+
generate-out-test-toml:
92+
go test ./acceptance -run '^TestAccept$$' -only-out-test-toml -timeout=${LOCAL_TIMEOUT}
93+
9094
# Updates acceptance test output (integration tests, requires access)
9195
test-update-aws:
9296
deco env run -i -n aws-prod-ucws -- go test ./acceptance -run ^TestAccept$$ -update -timeout=1h -skiplocal -v
@@ -167,7 +171,7 @@ generate:
167171
$(GENKIT_BINARY) update-sdk
168172

169173

170-
.PHONY: lint lintfull tidy lintcheck fmt fmtfull test test-unit test-acc test-slow test-slow-unit test-slow-acc cover showcover build snapshot snapshot-release schema integration integration-short acc-cover acc-showcover docs ws wsfix links checks test-update test-update-templates test-update-aws test-update-all generate-validation
174+
.PHONY: lint lintfull tidy lintcheck fmt fmtfull test test-unit test-acc test-slow test-slow-unit test-slow-acc cover showcover build snapshot snapshot-release schema integration integration-short acc-cover acc-showcover docs ws wsfix links checks test-update test-update-templates generate-out-test-toml test-update-aws test-update-all generate-validation
171175

172176
test-exp-aitools:
173177
make test TEST_PACKAGES="./experimental/aitools/..." ACCEPTANCE_TEST_FILTER="TestAccept/idontexistyet/aitools"

NEXT_CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# NEXT CHANGELOG
22

3-
## Release v0.281.0
3+
## Release v0.282.0
44

55
### Notable Changes
66

acceptance/acceptance_test.go

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ var (
4848
UseVersion string
4949
WorkspaceTmpDir bool
5050
TerraformDir string
51+
OnlyOutTestToml bool
5152
)
5253

5354
// In order to debug CLI running under acceptance test, search for TestInprocessMode and update
@@ -78,6 +79,7 @@ func init() {
7879
// creates these symlinks when a file_mirror is used for a provider (in .terraformrc). This flag
7980
// allows us to download the provider to the workspace file system on DBR enabling DBR integration testing.
8081
flag.StringVar(&TerraformDir, "terraform-dir", "", "Directory to download the terraform provider to")
82+
flag.BoolVar(&OnlyOutTestToml, "only-out-test-toml", false, "Only regenerate out.test.toml files without running tests")
8183
}
8284

8385
const (
@@ -307,14 +309,19 @@ func testAccept(t *testing.T, inprocessMode bool, singleTest string) int {
307309
config, configPath := internal.LoadConfig(t, dir)
308310
skipReason := getSkipReason(&config, configPath)
309311

310-
if testdiff.OverwriteMode {
312+
if testdiff.OverwriteMode || OnlyOutTestToml {
311313
// Generate materialized config for this test
312314
// We do this before skipping the test, so the configs are generated for all tests.
313315
materializedConfig, err := internal.GenerateMaterializedConfig(config)
314316
require.NoError(t, err)
315317
testutil.WriteFile(t, filepath.Join(dir, internal.MaterializedConfigFile), materializedConfig)
316318
}
317319

320+
// If only regenerating out.test.toml, skip the actual test execution
321+
if OnlyOutTestToml {
322+
t.Skip("Skipping test execution (only regenerating out.test.toml)")
323+
}
324+
318325
if skipReason != "" {
319326
skippedDirs += 1
320327
t.Skip(skipReason)
@@ -329,7 +336,7 @@ func testAccept(t *testing.T, inprocessMode bool, singleTest string) int {
329336
if testdiff.OverwriteMode && len(expanded) > 1 {
330337
// All variants of the test are producing the same output,
331338
// there is no need to run the concurrently when updating.
332-
// Exception: if EnvVaryOutput is configured with multiple values, we must
339+
// Exception: if EnvVaryOutput is configured, we must
333340
// run all variants to record variant-specific outputs.
334341
if config.EnvVaryOutput == nil || len(config.EnvMatrix[*config.EnvVaryOutput]) <= 1 {
335342
expanded = expanded[0:1]
@@ -344,6 +351,9 @@ func testAccept(t *testing.T, inprocessMode bool, singleTest string) int {
344351
runTest(t, dir, 0, coverDir, repls.Clone(), config, expanded[0], envFilters)
345352
} else {
346353
for ind, envset := range expanded {
354+
if forbiddenEnvSet(envset) {
355+
continue
356+
}
347357
envname := strings.Join(envset, "/")
348358
t.Run(envname, func(t *testing.T) {
349359
if !inprocessMode {
@@ -361,6 +371,23 @@ func testAccept(t *testing.T, inprocessMode bool, singleTest string) int {
361371
return selectedDirs - skippedDirs
362372
}
363373

374+
func forbiddenEnvSet(envset []string) bool {
375+
hasTerraform := false
376+
hasReadplan := false
377+
378+
for _, pair := range envset {
379+
if pair == "DATABRICKS_BUNDLE_ENGINE=terraform" {
380+
hasTerraform = true
381+
}
382+
if pair == "READPLAN=1" {
383+
hasReadplan = true
384+
}
385+
}
386+
387+
// Do not run terraform tests with --plan option:
388+
return hasTerraform && hasReadplan
389+
}
390+
364391
func getEnvFilters(t *testing.T) []string {
365392
envFilterValue := os.Getenv(EnvFilterVar)
366393
if envFilterValue == "" {

acceptance/bundle/artifacts/whl_dynamic/out.plan_update.direct.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
{
22
"plan_version": 1,
33
"cli_version": "[DEV_VERSION]",
4+
"lineage": "[UUID]",
5+
"serial": 1,
46
"plan": {
57
"resources.jobs.test_job": {
68
"action": "update",
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
bundle:
2+
name: test-bundle
3+
4+
resources:
5+
jobs:
6+
job:
7+
name: test-job
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"plan_version": 1,
3+
"cli_version": "[DEV_VERSION]",
4+
"plan": {
5+
"resources.jobs.job": {
6+
"action": "create",
7+
"new_state": {
8+
"value": {
9+
"deployment": {
10+
"kind": "BUNDLE",
11+
"metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json"
12+
},
13+
"edit_mode": "UI_LOCKED",
14+
"format": "MULTI_TASK",
15+
"max_concurrent_runs": 1,
16+
"name": "test-job",
17+
"queue": {
18+
"enabled": true
19+
}
20+
}
21+
}
22+
}
23+
}
24+
}
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
{
2+
"plan_version": 1,
3+
"cli_version": "[DEV_VERSION]",
4+
"lineage": "[UUID]",
5+
"serial": 1,
6+
"plan": {
7+
"resources.jobs.job": {
8+
"action": "skip",
9+
"remote_state": {
10+
"created_time": [UNIX_TIME_MILLIS],
11+
"creator_user_name": "[USERNAME]",
12+
"job_id": [NUMID],
13+
"run_as_user_name": "[USERNAME]",
14+
"settings": {
15+
"deployment": {
16+
"kind": "BUNDLE",
17+
"metadata_file_path": "/Workspace/Users/[USERNAME]/.bundle/test-bundle/default/state/metadata.json"
18+
},
19+
"edit_mode": "UI_LOCKED",
20+
"email_notifications": {},
21+
"format": "MULTI_TASK",
22+
"max_concurrent_runs": 1,
23+
"name": "test-job",
24+
"queue": {
25+
"enabled": true
26+
},
27+
"timeout_seconds": 0,
28+
"webhook_notifications": {}
29+
}
30+
},
31+
"changes": {
32+
"remote": {
33+
"email_notifications": {
34+
"action": "skip",
35+
"reason": "server_side_default"
36+
},
37+
"timeout_seconds": {
38+
"action": "skip",
39+
"reason": "server_side_default"
40+
},
41+
"webhook_notifications": {
42+
"action": "skip",
43+
"reason": "server_side_default"
44+
}
45+
}
46+
}
47+
}
48+
}
49+
}

0 commit comments

Comments
 (0)