Repository navigation
fix(goose): let goose config.yaml DATABRICKS_HOST win over env - #388
Merged
Merged
Conversation
When ~/.config/goose/config.yaml sets a valid DATABRICKS_HOST, pass it to goose serve so it takes precedence over the login-shell and runtime-config values. Goose only reads the file itself when the env var is unset, so Berd's env layers would otherwise shadow it. A missing file or key leaves the current behavior unchanged; an invalid value is logged and ignored. The value must be an HTTPS URL without credentials, query, or fragment; a path prefix is allowed for proxies. Skipped in BYO-key dev and E2E runs. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Pinning the file's host into the env froze it at spawn, so later edits in settings were shadowed while the file-backed token changed, pairing a new token with the old host. Remove the env var instead so goose keeps re-reading its own config file; the user config.yaml is its last merged layer. Also skip the override when the child would resolve a different goose config file than Berd (shell-only GOOSE_PATH_ROOT, XDG_CONFIG_HOME, etc.). Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…missions A closing SQLite connection can delete derived.sqlite-wal/-shm between the exists() check and set_permissions(), failing SearchIndex::open with ENOENT. This made reopening_after_offline_delete_cannot_preserve_prior_generation_rows flaky (~1 in 30 locally). Treat NotFound as success instead. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
atishpatel
approved these changes
Oct 14, 2026
kalvinnchau
approved these changes
Oct 14, 2026
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
Goose only reads
DATABRICKS_HOSTfromconfig.yamlwhen the env var is unset, so the value Berd injects from the shell and runtime config always shadowed a user's goose config. Now, when the user's goose config has a validDATABRICKS_HOST, Berd removes the env var before it spawnsgoose serve. Goose then reads the host from its config file. Berd removes the var instead of copying the value in, so goose keeps re-reading the file: settings edits apply live, and the host stays paired with the token stored in the same file.GOOSE_PATH_ROOT,HOME,XDG_CONFIG_HOME,APPDATA,USERPROFILE), so an isolated goose root never picks up the real user config.Also fixes a flaky
message_searchtest:secure_cache_permissionscould hit ENOENT when a closing SQLite connection deleted its-wal/-shmfiles between theexists()check andset_permissions(). A missing sidecar is now treated as success.Related issue
N/A
Testing
cargo test --lib -- databricks_host config_environment(7 passed).reopening_after_offline_delete_cannot_preserve_prior_generation_rowstest failed 1 in 30 runs before the fix and passed 60 of 60 after.🤖 Generated with Claude Code