Commit 60b7aef
authored
Suggest bundle.engine config alternative in direct-only resource error (#5295)
## Changes
Update the error emitted by `ValidateDirectOnlyResources` (raised when a
direct-only resource type — catalogs, external locations, vector search
endpoints — is declared while running with the terraform engine) to
mention both ways of switching to the direct engine:
> Please set the `DATABRICKS_BUNDLE_ENGINE` environment variable to
'direct' **or set `bundle.engine: direct` in your databricks.yml** to
use ... resources.
## Why
The previous wording only pointed users at the env var. `bundle.engine`
is the equivalent (and usually more durable) configuration knob, so
mentioning it makes the error actionable for users who prefer to declare
engine choice in `databricks.yml` instead of plumbing an env var through
their workflow.
## Tests
- `go test ./bundle/config/mutator/ -run
TestValidateDirectOnlyResources` — unit tests updated to assert the new
message.
- `go test ./acceptance -run
TestAccept/bundle/validate/catalog_requires_direct_mode` — acceptance
snapshot updated.
- `./task fmt`, `./task checks`, `./task lint` — clean.
_This PR was written by Claude Code._1 parent 9411b84 commit 60b7aef
4 files changed
Lines changed: 6 additions & 5 deletions
File tree
- acceptance/bundle/validate/catalog_requires_direct_mode
- bundle/config/mutator
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| 10 | + | |
Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
54 | | - | |
| 54 | + | |
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| |||
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| |||
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
80 | | - | |
| 80 | + | |
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
| |||
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
96 | | - | |
| 96 | + | |
97 | 97 | | |
98 | 98 | | |
99 | 99 | | |
| |||
0 commit comments