Skip to content

Gate static aitools install text on the agent features switch - #8223

Open
simonfaltum wants to merge 4 commits into
skills/agentoff-databricks-agent-features-disabled-turnsfrom
skills/agentoffhelp-gate-static-agent-text-that-names-databr
Open

simonfaltum wants to merge 4 commits into
skills/agentoff-databricks-agent-features-disabled-turnsfrom
skills/agentoffhelp-gate-static-agent-text-that-names-databr

Conversation

@simonfaltum

@simonfaltum simonfaltum commented Nov 30, 2026 •

Copy link
Copy Markdown
Member

Changes

With DATABRICKS_CLI_DISABLE_AGENT_FEATURES set, static help and template text no longer names databricks aitools install. This is stacked on the PR that adds the switch; it merges after that one.

  • databricks air --help drops the "Coding agent skill" line.
  • databricks air run --help and databricks air run -h config drop the install step.
  • The interactive databricks quickstart drops the "Using an AI coding assistant?" line.
  • The AGENTS.md written by databricks bundle init omits the install step and keeps the rest.

The switch is read through skills.AgentFeaturesDisabled(ctx), like the other gates. Unset, every text and golden is unchanged.

Why

The switch turns off the agent nudges, but this static text still told agents to run aitools install. It was flagged in review of the PR that adds the switch. The comment on airSkillLine said the air line was deliberate; the switch overrides it for this case.

Tests

  • TestAgentFeaturesDisabled in libs/skills covers value parsing: unset, true, 1, false and an invalid value.
  • TestQuickstartForInteractiveAitoolsLine covers the interactive quickstart line.
  • Acceptance cases air/agent-features-disabled (air help, run help and config help) and bundle/templates/default-minimal/agent-features-disabled (the rendered AGENTS.md) show the text gone with the switch set and present with it unset.
  • Existing air, quickstart, template, skills and aitools acceptance goldens are unchanged.
  • Package tests also pass with the switch exported.

This pull request and its description were written by Isaac.

…es switch

With DATABRICKS_CLI_DISABLE_AGENT_FEATURES set, the air help pages, the
interactive quickstart and the AGENTS.md written by bundle init no longer
name `databricks aitools install`. Unset, every text is unchanged.

Co-authored-by: Isaac <no-reply@databricks.com>
@github-actions

github-actions Bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Contributor

Regression test report ✅

Commit: 69666d64f | Workflow run

Selected 7 changed tests (limit=20, 0 not selected)

7 tests: regression=7 unreleased=0 coverage=0 failing=0
test branch main (d9bab18) latest (v1.28.0)
TestAccept/air/agent-features-disabled ✅ ❌ ❌
TestAccept/bundle/templates/default-minimal/agent-features-disabled/DMS= ✅ ❌ ❌
TestAccept/cmd/aitools/auto-install/agent-features-disabled ✅ ❌ ❌
TestAccept/cmd/aitools/auto-install/enable-disable ✅ ❌ ❌
TestAccept/cmd/aitools/telemetry/apps-init-tip ✅ ❌ ❌
TestAccept/cmd/skills/agent-features-disabled ✅ ❌ ❌
TestAccept/cmd/version ✅ ❌ ❌
TestAccept/air/agent-features-disabled: branch ✅ | main (d9bab18) ❌ | latest (v1.28.0) ❌

main (d9bab18):

acceptance_test.go:1409: 
        	Error Trace:	/home/runner/work/cli/cli/libs/testdiff/testdiff.go:22
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1409
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1150
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:693
        	Error:      	Not equal: 
        	            	expected: "\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] air --help\n\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] air run --help\n\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] air run -h config\n\n>>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] air --help\n\n>>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] air run --help\n\n>>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] air run -h config\n"
        	            	actual  : "\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] air --help\ncontains error: 'aitools install' was not expected: 'Coding agent skill       databricks aitools install --skills-only --skills databricks-ai-runtime'\n\nExit code: 1\n"
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -2,12 +2,5 @@
        	            	 >>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] air --help
        	            	+contains error: 'aitools install' was not expected: 'Coding agent skill       databricks aitools install --skills-only --skills databricks-ai-runtime'
        	            	 
        	            	->>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] air run --help
        	            	+Exit code: 1
        	            	 
        	            	->>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] air run -h config
        	            	-
        	            	->>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] air --help
        	            	-
        	            	->>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] air run --help
        	            	-
        	            	->>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] air run -h config
        	            	-
        	Test:       	TestAccept/air/agent-features-disabled
        	Messages:   	air/agent-features-disabled/output.txt vs /tmp/TestAcceptairagent-features-disabled3358075850/002/output.txt
    acceptance_test.go:1187: 
        LOG.air: Run GPU workloads on Databricks serverless compute.
        LOG.air: 
        LOG.air: Describe a workload in a YAML file and submit it with "databricks air run".
        LOG.air: Follow a run with "databricks air logs --follow" and "databricks air get", or
        LOG.air: see your active runs with "databricks air list".
        LOG.air: 
        LOG.air: Usage:
        LOG.air:   databricks air [command]
        LOG.air: 
        LOG.air: Run workloads:
        LOG.air:   run             Submit a workload from a YAML config
        LOG.air: 
        LOG.air: Manage runs:
        LOG.air:   cancel          Cancel one or more runs
        LOG.air:   get             Show a run's status, configuration, and timing
        LOG.air:   list            List your active runs
        LOG.air:   logs            Print or follow a run's logs
        LOG.air: 
        LOG.air: Package and deploy:
        LOG.air:   convert-to-dabs Convert a workload YAML into a Databricks Asset Bundle
        LOG.air:   images          Push container images for custom environments
        LOG.air: 
        LOG.air: Provisioned capacity:
        LOG.air:   pools           View provisioned GPU Pools, if any (not required to run)
        LOG.air: 
        LOG.air: Flags:
        LOG.air:   -h, --help[=true|false]   help for air
        LOG.air: 
        LOG.air: Global Flags:
        LOG.air:       --debug[=true|false]   enable debug logging
        LOG.air:   -o, --output type          output type: text or json (default text)
        LOG.air:   -p, --profile string       ~/.databrickscfg profile
        LOG.air:   -t, --target string        bundle target to use (if applicable)
        LOG.air: 
        LOG.air: Use "databricks air [command] --help" for more information about a command.
        LOG.air: 
        LOG.air: Learn more:
        LOG.air:   YAML fields and example  databricks air run -h config
        LOG.air:   Quickstart (AWS)         https://docs.databricks.com/aws/en/machine-learning/ai-runtime/quickstart
        LOG.air:   Quickstart (Azure)       https://learn.microsoft.com/azure/databricks/machine-learning/ai-runtime/quickstart
        LOG.air:   Coding agent skill       databricks aitools install --skills-only --skills databricks-ai-runtime

latest (v1.28.0): same output as main (d9bab18)

TestAccept/bundle/templates/default-minimal/agent-features-disabled/DMS=: branch ✅ | main (d9bab18) ❌ | latest (v1.28.0) ❌

main (d9bab18):

acceptance_test.go:1409: Diff:
        --- bundle/templates/default-minimal/agent-features-disabled/output.txt
        +++ /tmp/TestAcceptbundletemplatesdefault-minimalagent-features-disab3829642263/002/output.txt
        @@ -23,42 +23,11 @@
         selection, data discovery, and the bundle deployment workflow. Without it,
         results are often slower and less accurate.
         
        -If the CLI is not installed, see: https://docs.databricks.com/dev-tools/cli/install
        -
        ----
        -
        -## Project Instructions
        -
        -<!-- Add your project-specific instructions, coding conventions, or notes here -->
        -
        ->>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] bundle init default-minimal --config-file ./input.json --output-dir enabled
        -Welcome to the minimal Declarative Automation Bundle template!
        -
        -This template creates a minimal project structure without sample code, ideal for advanced users.
        -(For getting started with Python or SQL code, use the default-python or default-sql templates instead.)
        -
        -Your workspace at [DATABRICKS_URL] is used for initialization.
        -(See https://docs.databricks.com/dev-tools/cli/profiles.html for how to change your profile.)
        -
        -✨ Your new project has been created in the 'my_project' directory!
        -
        -To get started, refer to the project README.md file and the documentation at https://docs.databricks.com/dev-tools/bundles/index.html.
        -# Declarative Automation Bundles Project
        -
        -This project uses Declarative Automation Bundles (DABs) for deployment. Add project-specific instructions below.
        -
        -## For AI Agents: Use Databricks AI Tools
        -
        -**BEFORE any other action, read the `databricks-core` skill.**
        -
        -It sets you up to work with this project reliably: CLI authentication, profile
        -selection, data discovery, and the bundle deployment workflow. Without it,
        -results are often slower and less accurate.
        -
         If this skill is not available (Databricks AI Tools are not installed), you can install them for your coding agent in seconds:
         
         ```bash
         databricks aitools install
        +contains error: 'aitools install' was not expected: 'databricks aitools install'
         ```
         
         If the CLI is not installed, see: https://docs.databricks.com/dev-tools/cli/install
        @@ -68,3 +33,5 @@
         ## Project Instructions
         
         <!-- Add your project-specific instructions, coding conventions, or notes here -->
        +
        +Exit code: 1
        
    acceptance_test.go:1199: Test produced unexpected files:
        disabled/my_project/.gitignore
        disabled/my_project/.vscode/extensions.json
        disabled/my_project/.vscode/settings.json
        disabled/my_project/AGENTS.md
        disabled/my_project/README.md

latest (v1.28.0):

acceptance_test.go:1409: Diff:
        --- bundle/templates/default-minimal/agent-features-disabled/output.txt
        +++ /tmp/TestAcceptbundletemplatesdefault-minimalagent-features-disab3956292403/002/output.txt
        @@ -23,42 +23,11 @@
         selection, data discovery, and the bundle deployment workflow. Without it,
         results are often slower and less accurate.
         
        -If the CLI is not installed, see: https://docs.databricks.com/dev-tools/cli/install
        -
        ----
        -
        -## Project Instructions
        -
        -<!-- Add your project-specific instructions, coding conventions, or notes here -->
        -
        ->>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] bundle init default-minimal --config-file ./input.json --output-dir enabled
        -Welcome to the minimal Declarative Automation Bundle template!
        -
        -This template creates a minimal project structure without sample code, ideal for advanced users.
        -(For getting started with Python or SQL code, use the default-python or default-sql templates instead.)
        -
        -Your workspace at [DATABRICKS_URL] is used for initialization.
        -(See https://docs.databricks.com/dev-tools/cli/profiles.html for how to change your profile.)
        -
        -✨ Your new project has been created in the 'my_project' directory!
        -
        -To get started, refer to the project README.md file and the documentation at https://docs.databricks.com/dev-tools/bundles/index.html.
        -# Declarative Automation Bundles Project
        -
        -This project uses Declarative Automation Bundles (DABs) for deployment. Add project-specific instructions below.
        -
        -## For AI Agents: Use Databricks AI Tools
        -
        -**BEFORE any other action, read the `databricks-core` skill.**
        -
        -It sets you up to work with this project reliably: CLI authentication, profile
        -selection, data discovery, and the bundle deployment workflow. Without it,
        -results are often slower and less accurate.
        -
         If this skill is not available (Databricks AI Tools are not installed), you can install them for your coding agent in seconds:
         
         ```bash
         databricks aitools install
        +contains error: 'aitools install' was not expected: 'databricks aitools install'
         ```
         
         If the CLI is not installed, see: https://docs.databricks.com/dev-tools/cli/install
        @@ -68,3 +33,5 @@
         ## Project Instructions
         
         <!-- Add your project-specific instructions, coding conventions, or notes here -->
        +
        +Exit code: 1
        
    acceptance_test.go:1199: Test produced unexpected files:
        disabled/my_project/.gitignore
        disabled/my_project/.vscode/extensions.json
        disabled/my_project/.vscode/settings.json
        disabled/my_project/AGENTS.md
        disabled/my_project/README.md
FAIL
TestAccept/cmd/aitools/auto-install/agent-features-disabled: branch ✅ | main (d9bab18) ❌ | latest (v1.28.0) ❌

main (d9bab18):

acceptance_test.go:1277: Substituted DATABRICKS_CLI_GITHUB_API_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:46875" ("[DATABRICKS_HOST]")
    acceptance_test.go:1277: Substituted DATABRICKS_SKILLS_BASE_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:46875" ("[DATABRICKS_HOST]")
    acceptance_test.go:1409: Diff:
        --- cmd/aitools/auto-install/agent-features-disabled/output.txt
        +++ /tmp/TestAcceptcmdaitoolsauto-installagent-features-disabled3472273484/002/output.txt
        @@ -5,15 +5,19 @@
         === disabled: no install notice, no install or skills hint, nothing installed
         
         >>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] jobs list
        +Installed Databricks AI tools for Claude Code, Cursor. Turn off: databricks aitools auto-install disable. Remove: databricks aitools uninstall
         
         >>> print_telemetry
         {"command":"aitools_auto-install_enable","exit_code":0,"aitools_consent_event":{"occasion":"AUTO_INSTALL_ENABLE","answer":"CONSENTED","previous":"UNKNOWN"}}
        +{"command":"jobs_list","exit_code":0,"aitools_install_event":{"agents":["CLAUDE_CODE","CURSOR"],"scope":"GLOBAL","error_category":"TYPE_UNSPECIFIED","agent_results":[{"agent":"CLAUDE_CODE","error_category":"CLI_NOT_ON_PATH"}],"trigger":"AUTO_FIRST_RUN"}}
        +{"command":"jobs_list","exit_code":0,"aitools_auto_install_event":{"outcome":"INSTALLED","holdout_arm":"TREATMENT","interactive":false}}
         
         >>> cursor_skills
        -(no skills)
        +databricks-test
         
         >>> auto_install_state
         {
        +  "last_version": "1.30.0",
           "consented": true,
           "id": "treatment-machine"
         }
        @@ -21,11 +17,8 @@
         === unset: the first run of this version installs, and no hint is printed
         
         >>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES CLAUDECODE=1 [CLI] jobs list
        -Installed Databricks AI tools for Claude Code, Cursor. Turn off: databricks aitools auto-install disable. Remove: databricks aitools uninstall
         
         >>> print_telemetry
        -{"command":"jobs_list","exit_code":0,"aitools_install_event":{"agents":["CLAUDE_CODE","CURSOR"],"scope":"GLOBAL","error_category":"TYPE_UNSPECIFIED","agent_results":[{"agent":"CLAUDE_CODE","error_category":"CLI_NOT_ON_PATH"}],"trigger":"AUTO_FIRST_RUN"}}
        -{"command":"jobs_list","exit_code":0,"aitools_auto_install_event":{"outcome":"INSTALLED","holdout_arm":"TREATMENT","interactive":false}}
         
         >>> cursor_skills
         databricks-test

latest (v1.28.0):

acceptance_test.go:1277: Substituted DATABRICKS_CLI_GITHUB_API_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:37699" ("[DATABRICKS_HOST]")
    acceptance_test.go:1277: Substituted DATABRICKS_SKILLS_BASE_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:37699" ("[DATABRICKS_HOST]")
    acceptance_test.go:1409: Diff:
        --- cmd/aitools/auto-install/agent-features-disabled/output.txt
        +++ /tmp/TestAcceptcmdaitoolsauto-installagent-features-disabled3269307095/002/output.txt
        @@ -5,27 +5,26 @@
         === disabled: no install notice, no install or skills hint, nothing installed
         
         >>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] jobs list
        +Installed Databricks AI tools for Claude Code, Cursor. Disable: databricks aitools auto-install disable
         
         >>> print_telemetry
        -{"command":"aitools_auto-install_enable","exit_code":0,"aitools_consent_event":{"occasion":"AUTO_INSTALL_ENABLE","answer":"CONSENTED","previous":"UNKNOWN"}}
        +{"command":"jobs_list","exit_code":0,"aitools_install_event":{"agents":["CLAUDE_CODE","CURSOR"],"scope":"GLOBAL","error_category":"TYPE_UNSPECIFIED","agent_results":[{"agent":"CLAUDE_CODE","error_category":"CLI_NOT_ON_PATH"}],"trigger":"AUTO_FIRST_RUN"}}
        +{"command":"jobs_list","exit_code":0,"aitools_auto_install_event":{"outcome":"INSTALLED","holdout_arm":"TREATMENT","interactive":false}}
         
         >>> cursor_skills
        -(no skills)
        +databricks-test
         
         >>> auto_install_state
         {
        -  "consented": true,
        +  "last_version": "1.30.0",
           "id": "treatment-machine"
         }
         
         === unset: the first run of this version installs, and no hint is printed
         
         >>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES CLAUDECODE=1 [CLI] jobs list
        -Installed Databricks AI tools for Claude Code, Cursor. Turn off: databricks aitools auto-install disable. Remove: databricks aitools uninstall
         
         >>> print_telemetry
        -{"command":"jobs_list","exit_code":0,"aitools_install_event":{"agents":["CLAUDE_CODE","CURSOR"],"scope":"GLOBAL","error_category":"TYPE_UNSPECIFIED","agent_results":[{"agent":"CLAUDE_CODE","error_category":"CLI_NOT_ON_PATH"}],"trigger":"AUTO_FIRST_RUN"}}
        -{"command":"jobs_list","exit_code":0,"aitools_auto_install_event":{"outcome":"INSTALLED","holdout_arm":"TREATMENT","interactive":false}}
         
         >>> cursor_skills
         databricks-test
TestAccept/cmd/aitools/auto-install/enable-disable: branch ✅ | main (d9bab18) ❌ | latest (v1.28.0) ❌

main (d9bab18):

acceptance_test.go:1277: Substituted DATABRICKS_CLI_GITHUB_API_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:45227" ("[DATABRICKS_HOST]")
    acceptance_test.go:1277: Substituted DATABRICKS_SKILLS_BASE_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:45227" ("[DATABRICKS_HOST]")
    acceptance_test.go:1409: Diff:
        --- cmd/aitools/auto-install/enable-disable/output.txt
        +++ /tmp/TestAcceptcmdaitoolsauto-installenable-disable92459494/002/output.txt
        @@ -42,7 +42,6 @@
         
         >>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] aitools auto-install enable
         Automatic installation of Databricks AI tools is enabled.
        -DATABRICKS_CLI_DISABLE_AGENT_FEATURES still disables it in this environment; unset it to let it run.
         
         === disable replaces a state file it cannot read
         
        
    acceptance_test.go:1187: LOG.enable-reset-1: Automatic installation of Databricks AI tools is enabled.
    acceptance_test.go:1187: LOG.enable-reset-1-telemetry: {"command":"aitools_auto-install_enable","exit_code":0,"aitools_consent_event":{"occasion":"AUTO_INSTALL_ENABLE","answer":"CONSENTED","previous":"OPTED_OUT"}}
    acceptance_test.go:1187: LOG.enable-reset-2: Automatic installation of Databricks AI tools is enabled.
    acceptance_test.go:1187: LOG.enable-reset-2-telemetry: {"command":"aitools_auto-install_enable","exit_code":0,"aitools_consent_event":{"occasion":"AUTO_INSTALL_ENABLE","answer":"CONSENTED","previous":"OPTED_OUT"}}
    acceptance_test.go:1187: 
        LOG.install-global: Installing Databricks skills for Cursor...
        LOG.install-global: Using skills version test-ref
        LOG.install-global: Fetching skills manifest...
        LOG.install-global: Installed 1 skill in /tmp/TestAcceptcmdaitoolsauto-installenable-disable92459494/001/home/.databricks/aitools/skills.
FAIL

latest (v1.28.0):

acceptance_test.go:1277: Substituted DATABRICKS_CLI_GITHUB_API_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:34965" ("[DATABRICKS_HOST]")
    acceptance_test.go:1277: Substituted DATABRICKS_SKILLS_BASE_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:34965" ("[DATABRICKS_HOST]")
    acceptance_test.go:1409: Diff:
        --- cmd/aitools/auto-install/enable-disable/output.txt
        +++ /tmp/TestAcceptcmdaitoolsauto-installenable-disable2932144090/002/output.txt
        @@ -10,7 +10,6 @@
         Automatic installation of Databricks AI tools is disabled.
         
         >>> print_consent_events
        -{"command":"aitools_auto-install_disable","exit_code":0,"aitools_consent_event":{"occasion":"AUTO_INSTALL_DISABLE","answer":"OPTED_OUT","previous":"UNKNOWN"}}
         
         >>> auto_install_state
         {
        @@ -23,12 +22,9 @@
         Automatic installation of Databricks AI tools is enabled.
         
         >>> print_consent_events
        -{"command":"aitools_auto-install_enable","exit_code":0,"aitools_consent_event":{"occasion":"AUTO_INSTALL_ENABLE","answer":"CONSENTED","previous":"OPTED_OUT"}}
         
         >>> auto_install_state
        -{
        -  "consented": true
        -}
        +{}
         
         === enable says when the environment still turns it off
         
        @@ -42,7 +36,6 @@
         
         >>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] aitools auto-install enable
         Automatic installation of Databricks AI tools is enabled.
        -DATABRICKS_CLI_DISABLE_AGENT_FEATURES still disables it in this environment; unset it to let it run.
         
         === disable replaces a state file it cannot read
         
        @@ -50,7 +43,6 @@
         Automatic installation of Databricks AI tools is disabled.
         
         >>> print_consent_events
        -{"command":"aitools_auto-install_disable","exit_code":0,"aitools_consent_event":{"occasion":"AUTO_INSTALL_DISABLE","answer":"OPTED_OUT","previous":"UNKNOWN"}}
         
         >>> auto_install_state
         {
        @@ -65,9 +57,7 @@
         >>> print_consent_events
         
         >>> auto_install_state
        -{
        -  "consented": true
        -}
        +{}
         
         === a global uninstall of a mistyped skill leaves it on
         
        @@ -77,9 +67,7 @@
         >>> print_consent_events
         
         >>> auto_install_state
        -{
        -  "consented": true
        -}
        +{}
         
         === a global uninstall turns it off
         
        @@ -87,7 +75,6 @@
         Uninstalled 1 skill.
         
         >>> print_consent_events
        -{"command":"aitools_uninstall","exit_code":0,"aitools_consent_event":{"occasion":"UNINSTALL","answer":"OPTED_OUT","previous":"CONSENTED"}}
         
         >>> auto_install_state
         {
        @@ -102,9 +89,7 @@
         >>> print_consent_events
         
         >>> auto_install_state
        -{
        -  "consented": true
        -}
        +{}
         
         === a project install stores no consent
         
        @@ -116,12 +101,9 @@
         === a global install stores the consent
         
         >>> print_consent_events
        -{"command":"aitools_install","exit_code":0,"aitools_consent_event":{"occasion":"INSTALL","answer":"CONSENTED","previous":"UNKNOWN"}}
         
         >>> auto_install_state
        -{
        -  "consented": true
        -}
        +(no auto-install state)
         
         === a global install keeps an opt-out
         
        
    acceptance_test.go:1187: LOG.enable-reset-1: Automatic installation of Databricks AI tools is enabled.
    acceptance_test.go:1187: LOG.enable-reset-1-telemetry: 
    acceptance_test.go:1187: LOG.enable-reset-2: Automatic installation of Databricks AI tools is enabled.
    acceptance_test.go:1187: LOG.enable-reset-2-telemetry: 
    acceptance_test.go:1187: 
        LOG.install-global: Installing Databricks skills for Cursor...
        LOG.install-global: Using skills version test-ref
        LOG.install-global: Fetching skills manifest...
        LOG.install-global: Installed 1 skill in /tmp/TestAcceptcmdaitoolsauto-installenable-disable2932144090/001/home/.databricks/aitools/skills.
TestAccept/cmd/aitools/telemetry/apps-init-tip: branch ✅ | main (d9bab18) ❌ | latest (v1.28.0) ❌

main (d9bab18):

acceptance_test.go:1277: Substituted DATABRICKS_CLI_GITHUB_API_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:32963" ("[DATABRICKS_HOST]")
    acceptance_test.go:1277: Substituted DATABRICKS_SKILLS_BASE_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:32963" ("[DATABRICKS_HOST]")
    acceptance_test.go:1409: Diff:
        --- cmd/aitools/telemetry/apps-init-tip/output.txt
        +++ /tmp/TestAcceptcmdaitoolstelemetryapps-init-tip3335156222/002/output.txt
        @@ -43,5 +43,8 @@
         >>> print_telemetry
         
         === agent features switch: no tip, no event
        +contains error: 'aitools install' was not expected: 'Databricks skills are not installed. To work with Databricks reliably, first run: databricks aitools install'
        +contains error: 'Tip:' was not expected: "Tip: coding agents detected without Databricks skills. Run 'databricks aitools install' to install them."
        +contains error: 'aitools install' was not expected: "Tip: coding agents detected without Databricks skills. Run 'databricks aitools install' to install them."
         
        ->>> print_telemetry
        +Exit code: 1
        
    acceptance_test.go:1187: LOG.apps-init: 
    acceptance_test.go:1187: 
        LOG.apps-init-disabled: 
        LOG.apps-init-disabled: >>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 /tmp/TestAccept1371565973/001/databricks apps init --template ./template --skip-install --name app-disabled
        LOG.apps-init-disabled: Databricks skills are not installed. To work with Databricks reliably, first run: databricks aitools install
        LOG.apps-init-disabled: ✔ Creating project
        LOG.apps-init-disabled: 
        LOG.apps-init-disabled: ✔ Project created successfully!
        LOG.apps-init-disabled: 
        LOG.apps-init-disabled:   Location: /tmp/TestAcceptcmdaitoolstelemetryapps-init-tip3335156222/001/app-disabled
        LOG.apps-init-disabled:   Files: 3
        LOG.apps-init-disabled: 
        LOG.apps-init-disabled: Tip: coding agents detected without Databricks skills. Run 'databricks aitools install' to install them.
    acceptance_test.go:1187: LOG.apps-init-plugin: 
    acceptance_test.go:1187: LOG.apps-init-recorded: 
    acceptance_test.go:1199: Test produced unexpected files:
        app-disabled/app.yaml
        app-disabled/appkit.plugins.json
        app-disabled/databricks.yml

latest (v1.28.0):

acceptance_test.go:1277: Substituted DATABRICKS_CLI_GITHUB_API_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:41363" ("[DATABRICKS_HOST]")
    acceptance_test.go:1277: Substituted DATABRICKS_SKILLS_BASE_URL "$DATABRICKS_HOST" -> "http://127.0.0.1:41363" ("[DATABRICKS_HOST]")
    acceptance_test.go:1409: Diff:
        --- cmd/aitools/telemetry/apps-init-tip/output.txt
        +++ /tmp/TestAcceptcmdaitoolstelemetryapps-init-tip3222946027/002/output.txt
        @@ -15,6 +15,7 @@
         >>> print_telemetry
         {"command":"apps_init","exit_code":0,"aitools_hint_event":{"hint_kind":"INSTALL_TEXT"}}
         {"command":"apps_init","exit_code":0,"aitools_hint_event":{"hint_kind":"APPS_INIT_TIP"}}
        +{"command":"apps_init","exit_code":0,"aitools_auto_install_event":{"outcome":"SKIPPED_CI","holdout_arm":"TREATMENT","interactive":false}}
         
         === plugin installed: no hint, no tip, no event
         
        @@ -28,6 +29,7 @@
         
         
         >>> print_telemetry
        +{"command":"apps_init","exit_code":0,"aitools_auto_install_event":{"outcome":"SKIPPED_CI","holdout_arm":"TREATMENT","interactive":false}}
         
         === codex and copilot plugins recorded by aitools install: no tip, no event
         
        @@ -41,7 +43,11 @@
         
         
         >>> print_telemetry
        +{"command":"apps_init","exit_code":0,"aitools_auto_install_event":{"outcome":"SKIPPED_CI","holdout_arm":"HOLDOUT","interactive":false}}
         
         === agent features switch: no tip, no event
        +contains error: 'aitools install' was not expected: 'Databricks skills are not installed. To work with Databricks reliably, first run: databricks aitools install'
        +contains error: 'Tip:' was not expected: "Tip: coding agents detected without Databricks skills. Run 'databricks aitools install' to install them."
        +contains error: 'aitools install' was not expected: "Tip: coding agents detected without Databricks skills. Run 'databricks aitools install' to install them."
         
        ->>> print_telemetry
        +Exit code: 1
        
    acceptance_test.go:1187: LOG.apps-init: 
    acceptance_test.go:1187: 
        LOG.apps-init-disabled: 
        LOG.apps-init-disabled: >>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 /home/runner/work/cli/cli/acceptance/build/linux_amd64/1.28.0/databricks apps init --template ./template --skip-install --name app-disabled
        LOG.apps-init-disabled: Databricks skills are not installed. To work with Databricks reliably, first run: databricks aitools install
        LOG.apps-init-disabled: ✔ Creating project
        LOG.apps-init-disabled: 
        LOG.apps-init-disabled: ✔ Project created successfully!
        LOG.apps-init-disabled: 
        LOG.apps-init-disabled:   Location: /tmp/TestAcceptcmdaitoolstelemetryapps-init-tip3222946027/001/app-disabled
        LOG.apps-init-disabled:   Files: 3
        LOG.apps-init-disabled: 
        LOG.apps-init-disabled: Tip: coding agents detected without Databricks skills. Run 'databricks aitools install' to install them.
    acceptance_test.go:1187: LOG.apps-init-plugin: 
    acceptance_test.go:1187: LOG.apps-init-recorded: 
    acceptance_test.go:1199: Test produced unexpected files:
        app-disabled/app.yaml
        app-disabled/appkit.plugins.json
        app-disabled/databricks.yml
        plugin-home/.databricks/aitools/auto-install.json
        plugin-home/.databricks/aitools/auto-install.json.lock
        plugin-home/.databricks/aitools/auto-install.lock
        recorded-plugin-home/.databricks/aitools/auto-install.json
        recorded-plugin-home/.databricks/aitools/auto-install.json.lock
        recorded-plugin-home/.databricks/aitools/auto-install.lock
TestAccept/cmd/skills/agent-features-disabled: branch ✅ | main (d9bab18) ❌ | latest (v1.28.0) ❌

main (d9bab18):

acceptance_test.go:1409: 
        	Error Trace:	/home/runner/work/cli/cli/libs/testdiff/testdiff.go:22
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1409
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1150
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:693
        	Error:      	Not equal: 
        	            	expected: "\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] skills list\nError: unknown command \"skills\" for \"databricks\"\n\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] --help\n\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] fs --help\n\n>>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] --help\n\n>>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] fs --help\n\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] quickstart\n\n>>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES -u DATABRICKS_SKILLS_PREVIEW [CLI] quickstart\n"
        	            	actual  : "\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] skills list\nPick the skill whose description matches the task.\nRead the skill before you act on it.\n\n-foo: A skill whose name starts with a hyphen.\ndemo-skill: A skill for tests.\nfuture-skill: A skill that needs a newer CLI.\nguide-skill: A skill with a supporting file.\nTo read a skill, run: databricks skills read <name>\n\nUnexpected success\n\nExit code: 1\n"
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -2,15 +2,14 @@
        	            	 >>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] skills list
        	            	-Error: unknown command "skills" for "databricks"
        	            	+Pick the skill whose description matches the task.
        	            	+Read the skill before you act on it.
        	            	 
        	            	->>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] --help
        	            	+-foo: A skill whose name starts with a hyphen.
        	            	+demo-skill: A skill for tests.
        	            	+future-skill: A skill that needs a newer CLI.
        	            	+guide-skill: A skill with a supporting file.
        	            	+To read a skill, run: databricks skills read <name>
        	            	 
        	            	->>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] fs --help
        	            	+Unexpected success
        	            	 
        	            	->>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] --help
        	            	+Exit code: 1
        	            	 
        	            	->>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] fs --help
        	            	-
        	            	->>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] quickstart
        	            	-
        	            	->>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES -u DATABRICKS_SKILLS_PREVIEW [CLI] quickstart
        	            	-
        	Test:       	TestAccept/cmd/skills/agent-features-disabled
        	Messages:   	cmd/skills/agent-features-disabled/output.txt vs /tmp/TestAcceptcmdskillsagent-features-disabled911021320/002/output.txt

latest (v1.28.0):

acceptance_test.go:1409: 
        	Error Trace:	/home/runner/work/cli/cli/libs/testdiff/testdiff.go:22
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1409
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1150
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:693
        	Error:      	Not equal: 
        	            	expected: "\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] skills list\nError: unknown command \"skills\" for \"databricks\"\n\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] --help\n\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] fs --help\n\n>>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] --help\n\n>>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] fs --help\n\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] quickstart\n\n>>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES -u DATABRICKS_SKILLS_PREVIEW [CLI] quickstart\n"
        	            	actual  : "\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] skills list\nError: unknown command \"skills\" for \"databricks\"\n\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] --help\n\n>>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] fs --help\n\n>>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] --help\ncontains error: 'databricks skills' not found in the output.\n\nExit code: 1\n"
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -9,8 +9,5 @@
        	            	 >>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] --help
        	            	+contains error: 'databricks skills' not found in the output.
        	            	 
        	            	->>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES [CLI] fs --help
        	            	+Exit code: 1
        	            	 
        	            	->>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 CLAUDECODE=1 [CLI] quickstart
        	            	-
        	            	->>> env -u DATABRICKS_CLI_DISABLE_AGENT_FEATURES -u DATABRICKS_SKILLS_PREVIEW [CLI] quickstart
        	            	-
        	Test:       	TestAccept/cmd/skills/agent-features-disabled
        	Messages:   	cmd/skills/agent-features-disabled/output.txt vs /tmp/TestAcceptcmdskillsagent-features-disabled204383098/002/output.txt
    acceptance_test.go:1187: 
        LOG.fs-help: Commands to do file system operations on DBFS, UC Volumes and UC Skills.
        LOG.fs-help: 
        LOG.fs-help: Usage:
        LOG.fs-help:   databricks fs [command]
        LOG.fs-help: 
        LOG.fs-help: Available Commands:
        LOG.fs-help:   cat         Show file content.
        LOG.fs-help:   cp          Copy files and directories.
        LOG.fs-help:   ls          Lists files.
        LOG.fs-help:   mkdir       Make directories.
        LOG.fs-help:   rm          Remove files and directories.
        LOG.fs-help: 
        LOG.fs-help: Flags:
        LOG.fs-help:   -h, --help[=true|false]   help for fs
        LOG.fs-help: 
        LOG.fs-help: Global Flags:
        LOG.fs-help:       --debug[=true|false]   enable debug logging
        LOG.fs-help:   -o, --output type          output type: text or json (default text)
        LOG.fs-help:   -p, --profile string       ~/.databrickscfg profile
        LOG.fs-help:   -t, --target string        bundle target to use (if applicable)
        LOG.fs-help: 
        LOG.fs-help: Use "databricks fs [command] --help" for more information about a command.
    acceptance_test.go:1187: 
        LOG.help: Databricks CLI
        LOG.help: 
        LOG.help: Usage:
        LOG.help:   databricks [command]
        LOG.help: 
        LOG.help: Lakewatch
        LOG.help:   lakewatch                              *Beta* Manage Lakewatch: security-analytics data sources, detection rules, and per-catalog configuration.
        LOG.help: 
        LOG.help: Databricks Workspace
        LOG.help:   fs                                     Filesystem related commands
        LOG.help:   git-credentials                        Registers personal access token for Databricks to do operations on behalf of the user.
        LOG.help:   repos                                  The Repos API allows users to manage their git repos.
        LOG.help:   secrets                                The Secrets API allows you to manage secrets, secret scopes, and access permissions.
        LOG.help:   workspace                              The Workspace API allows you to list, import, export, and delete workspace objects such as notebooks, files, folders, and dashboards.
        LOG.help: 
        LOG.help: Compute
        LOG.help:   cluster-policies                       You can use cluster policies to control users' ability to configure clusters based on a set of rules.
        LOG.help:   clusters                               The Clusters API allows you to create, start, edit, list, terminate, and delete clusters.
        LOG.help:   global-init-scripts                    The Global Init Scripts API enables Workspace administrators to configure global initialization scripts for their workspace.
        LOG.help:   instance-pools                         Instance Pools API are used to create, edit, delete and list instance pools by using ready-to-use cloud instances which reduces a cluster start and auto-scaling times.
        LOG.help:   instance-profiles                      The Instance Profiles API allows admins to add, list, and remove instance profiles that users can launch clusters with.
        LOG.help:   libraries                              The Libraries API allows you to install and uninstall libraries and get the status of libraries on a cluster.
        LOG.help:   policy-compliance-for-clusters         The policy compliance APIs allow you to view and manage the policy compliance status of clusters in your workspace.
        LOG.help:   policy-families                        View available policy families.
        LOG.help: 
        LOG.help: Lakeflow
        LOG.help:   jobs                                   The Jobs API allows you to create, edit, and delete jobs.
        LOG.help:   pipelines                              The Lakeflow Spark Declarative Pipelines API allows you to create, edit, delete, start, and view details about pipelines.
        LOG.help:   policy-compliance-for-jobs             The compliance APIs allow you to view and manage the policy compliance status of jobs in your workspace.
        LOG.help: 
        LOG.help: Machine Learning
        LOG.help:   experiments                            Experiments are the primary unit of organization in MLflow; all MLflow runs belong to an experiment.
        LOG.help:   feature-engineering                    Feature Engineering provides APIs for managing features and materialized features.
        LOG.help:   model-registry                         Note: This API reference documents APIs for the Workspace Model Registry.
        LOG.help: 
        LOG.help: Real-time Serving
        LOG.help:   serving-endpoints                      The Serving Endpoints API allows you to create, update, and delete model serving endpoints.
        LOG.help: 
        LOG.help: Apps
        LOG.help:   apps                                   Apps run directly on a customer's Databricks instance, integrate with their data, use and extend Databricks services, and enable users to interact through single sign-on.
        LOG.help: 
        LOG.help: Vector Search
        LOG.help:   vector-search-endpoints                **Endpoint**: Represents the compute resources to host AI Search indexes.
        LOG.help:   vector-search-indexes                  **Index**: An efficient representation of your embedding vectors that supports real-time and efficient approximate nearest neighbor (ANN) search queries.
        LOG.help: 
        LOG.help: AI Search
        LOG.help:   ai-search                              **AI Search Endpoint**: Represents the compute resources to host AI Search indexes.
        LOG.help: 
        LOG.help: Identity and Access Management
        LOG.help:   assume-group                           *Beta* Manage the workspace's restricted sharing groups.
        LOG.help:   current-user                           *Public Preview* This API allows retrieving information about currently authenticated user or service principal.
        LOG.help:   groups                                 Groups simplify identity management, making it easier to assign access to Databricks workspace, data, and other securable objects.
        LOG.help:   groups-v2                              *Public Preview* Groups simplify identity management, making it easier to assign access to Databricks workspace, data, and other securable objects.
        LOG.help:   permissions                            Permissions API are used to create read, write, edit, update and manage access for various users on different objects and endpoints.
        LOG.help:   service-principals                     Identities for use with jobs, automated tools, and systems such as scripts, apps, and CI/CD platforms.
        LOG.help:   service-principals-v2                  *Public Preview* Identities for use with jobs, automated tools, and systems such as scripts, apps, and CI/CD platforms.
        LOG.help:   users                                  User identities recognized by Databricks and represented by email addresses.
        LOG.help:   users-v2                               *Public Preview* User identities recognized by Databricks and represented by email addresses.
        LOG.help:   workspace-iam-v2                       These APIs are used to manage identities and the workspace access of these identities in Databricks.
        LOG.help: 
        LOG.help: Databricks SQL
        LOG.help:   alerts                                 The alerts API can be used to perform CRUD operations on alerts.
        LOG.help:   alerts-legacy                          *Public Preview* The alerts API can be used to perform CRUD operations on alerts.
        LOG.help:   alerts-v2                              New version of SQL Alerts.
        LOG.help:   dashboards                             In general, there is little need to modify dashboards using the API.
        LOG.help:   data-sources                           This API is provided to assist you in making new query objects.
        LOG.help:   queries                                The queries API can be used to perform CRUD operations on queries.
        LOG.help:   queries-legacy                         These endpoints are used for CRUD operations on query definitions.
        LOG.help:   query-history                          A service responsible for storing and retrieving the list of queries run against SQL endpoints and serverless compute.
        LOG.help:   statement-execution-v2                 *Public Preview* The Statement Execution API v2 can be used to execute SQL statements on a SQL warehouse and fetch the result.
        LOG.help:   warehouses                             A SQL warehouse is a compute resource that lets you run SQL commands on data objects within Databricks SQL.
        LOG.help: 
        LOG.help: AI/BI
        LOG.help:   genie                                  Genie provides a no-code experience for business users, powered by AI/BI.
        LOG.help:   lakeview                               These APIs provide specific management operations for Lakeview dashboards.
        LOG.help:   lakeview-embedded                      Token-based Lakeview APIs for embedding dashboards in external applications.
        LOG.help: 
        LOG.help: Unity Catalog
        LOG.help:   ai-gateway                             Govern AI workloads in Unity Catalog.
        LOG.help:   artifact-allowlists                    In Databricks Runtime 13.3 and above, you can add libraries and init scripts to the allowlist in UC so that users can use these artifacts on compute configured with shared access mode.
        LOG.help:   catalogs                               A catalog is the first layer of Unity Catalog’s three-level namespace.
        LOG.help:   connections                            A connection represents an external data source for use within Databricks.
        LOG.help:   credentials                            A credential represents an authentication and authorization mechanism for accessing services on your cloud tenant.
        LOG.help:   entity-tag-assignments                 Tags are attributes that include keys and optional values that you can use to organize and categorize entities in Unity Catalog.
        LOG.help:   external-lineage                       *Public Preview* External Lineage APIs enable defining and managing lineage relationships between Databricks objects and external systems.
        LOG.help:   external-locations                     An external location is an object that combines a cloud storage path with a storage credential that authorizes access to the cloud storage path.
        LOG.help:   external-metadata                      *Public Preview* External Metadata objects enable customers to register and manage metadata about external systems within Unity Catalog.
        LOG.help:   functions                              Functions implement User-Defined Functions (UDFs) in Unity Catalog.
        LOG.help:   grants                                 In Unity Catalog, data is secure by default.
        LOG.help:   metastores                             A metastore is the top-level container of objects in Unity Catalog.
        LOG.help:   model-versions                         Databricks provides a hosted version of MLflow Model Registry in Unity Catalog.
        LOG.help:   online-tables                          *Public Preview* Online tables provide lower latency and higher QPS access to data from Delta tables.
        LOG.help:   policies                               Attribute-Based Access Control (ABAC) provides high leverage governance for enforcing compliance policies in Unity Catalog.
        LOG.help:   quality-monitors                       Deprecated: Please use the Data Quality Monitors API instead (REST: /api/data-quality/v1/monitors), which manages both Data Profiling and Anomaly Detection.
        LOG.help:   registered-models                      Databricks provides a hosted version of MLflow Model Registry in Unity Catalog.
        LOG.help:   resource-quotas                        Unity Catalog enforces resource quotas on all securable objects, which limits the number of resources that can be created.
        LOG.help:   rfa                                    *Public Preview* Request for Access enables users to request access for Unity Catalog securables.
        LOG.help:   schemas                                A schema (also called a database) is the second layer of Unity Catalog’s three-level namespace.
        LOG.help:   secrets-uc                             A secret is a Unity Catalog securable object that stores sensitive credential data (such as passwords, tokens, and keys) within a three-level namespace (**catalog_name.schema_name.secret_name**).
        LOG.help:   software-artifacts                     *Public Preview* Manage software artifacts and their versions in Unity Catalog.
        LOG.help: ... (113 more lines truncated, raise DATABRICKS_CLI_TEST_MAX_LOG to see more)
    acceptance_test.go:1187: 
        LOG.help-unset: Databricks CLI
        LOG.help-unset: 
        LOG.help-unset: Usage:
        LOG.help-unset:   databricks [command]
        LOG.help-unset: 
        LOG.help-unset: Lakewatch
        LOG.help-unset:   lakewatch                              *Beta* Manage Lakewatch: security-analytics data sources, detection rules, and per-catalog configuration.
        LOG.help-unset: 
        LOG.help-unset: Databricks Workspace
        LOG.help-unset:   fs                                     Filesystem related commands
        LOG.help-unset:   git-credentials                        Registers personal access token for Databricks to do operations on behalf of the user.
        LOG.help-unset:   repos                                  The Repos API allows users to manage their git repos.
        LOG.help-unset:   secrets                                The Secrets API allows you to manage secrets, secret scopes, and access permissions.
        LOG.help-unset:   workspace                              The Workspace API allows you to list, import, export, and delete workspace objects such as notebooks, files, folders, and dashboards.
        LOG.help-unset: 
        LOG.help-unset: Compute
        LOG.help-unset:   cluster-policies                       You can use cluster policies to control users' ability to configure clusters based on a set of rules.
        LOG.help-unset:   clusters                               The Clusters API allows you to create, start, edit, list, terminate, and delete clusters.
        LOG.help-unset:   global-init-scripts                    The Global Init Scripts API enables Workspace administrators to configure global initialization scripts for their workspace.
        LOG.help-unset:   instance-pools                         Instance Pools API are used to create, edit, delete and list instance pools by using ready-to-use cloud instances which reduces a cluster start and auto-scaling times.
        LOG.help-unset:   instance-profiles                      The Instance Profiles API allows admins to add, list, and remove instance profiles that users can launch clusters with.
        LOG.help-unset:   libraries                              The Libraries API allows you to install and uninstall libraries and get the status of libraries on a cluster.
        LOG.help-unset:   policy-compliance-for-clusters         The policy compliance APIs allow you to view and manage the policy compliance status of clusters in your workspace.
        LOG.help-unset:   policy-families                        View available policy families.
        LOG.help-unset: 
        LOG.help-unset: Lakeflow
        LOG.help-unset:   jobs                                   The Jobs API allows you to create, edit, and delete jobs.
        LOG.help-unset:   pipelines                              The Lakeflow Spark Declarative Pipelines API allows you to create, edit, delete, start, and view details about pipelines.
        LOG.help-unset:   policy-compliance-for-jobs             The compliance APIs allow you to view and manage the policy compliance status of jobs in your workspace.
        LOG.help-unset: 
        LOG.help-unset: Machine Learning
        LOG.help-unset:   experiments                            Experiments are the primary unit of organization in MLflow; all MLflow runs belong to an experiment.
        LOG.help-unset:   feature-engineering                    Feature Engineering provides APIs for managing features and materialized features.
        LOG.help-unset:   model-registry                         Note: This API reference documents APIs for the Workspace Model Registry.
        LOG.help-unset: 
        LOG.help-unset: Real-time Serving
        LOG.help-unset:   serving-endpoints                      The Serving Endpoints API allows you to create, update, and delete model serving endpoints.
        LOG.help-unset: 
        LOG.help-unset: Apps
        LOG.help-unset:   apps                                   Apps run directly on a customer's Databricks instance, integrate with their data, use and extend Databricks services, and enable users to interact through single sign-on.
        LOG.help-unset: 
        LOG.help-unset: Vector Search
        LOG.help-unset:   vector-search-endpoints                **Endpoint**: Represents the compute resources to host AI Search indexes.
        LOG.help-unset:   vector-search-indexes                  **Index**: An efficient representation of your embedding vectors that supports real-time and efficient approximate nearest neighbor (ANN) search queries.
        LOG.help-unset: 
        LOG.help-unset: AI Search
        LOG.help-unset:   ai-search                              **AI Search Endpoint**: Represents the compute resources to host AI Search indexes.
        LOG.help-unset: 
        LOG.help-unset: Identity and Access Management
... (52 more lines truncated, raise DATABRICKS_CLI_TEST_MAX_LOG to see more)
TestAccept/cmd/version: branch ✅ | main (d9bab18) ❌ | latest (v1.28.0) ❌

main (d9bab18):

acceptance_test.go:1409: Diff:
        --- cmd/version/output.txt
        +++ /tmp/TestAcceptcmdversion3472274497/002/output.txt
        @@ -31,6 +31,7 @@
         >>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] version --check
         Databricks CLI v[CLI_VERSION]
         This is a development build; skipping the update check.
        +Tip: coding agents detected without Databricks skills. Run 'databricks aitools install' to install them.
         
         === version --check --output json with a coding agent prints no tip

latest (v1.28.0):

acceptance_test.go:1409: Diff:
        --- cmd/version/output.txt
        +++ /tmp/TestAcceptcmdversion537118158/002/output.txt
        @@ -8,7 +8,7 @@
         
         >>> [CLI] version --check
         Databricks CLI v[CLI_VERSION]
        -This is a development build; skipping the update check.
        +Could not reach GitHub to check for a newer version. See https://github.com/databricks/cli/releases for the latest release.
         
         === version --check --output json
         
        @@ -16,21 +16,22 @@
         {
           "current_version": "[CLI_VERSION]",
           "update_available": false,
        -  "development_build": true
        +  "check_failed": true
         }
         
         === version --check with a coding agent and no Databricks tooling
         
         >>> [CLI] version --check
         Databricks CLI v[CLI_VERSION]
        -This is a development build; skipping the update check.
        +Could not reach GitHub to check for a newer version. See https://github.com/databricks/cli/releases for the latest release.
         Tip: coding agents detected without Databricks skills. Run 'databricks aitools install' to install them.
         
         === version --check with the agent features switch prints no tip
         
         >>> DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 [CLI] version --check
         Databricks CLI v[CLI_VERSION]
        -This is a development build; skipping the update check.
        +Could not reach GitHub to check for a newer version. See https://github.com/databricks/cli/releases for the latest release.
        +Tip: coding agents detected without Databricks skills. Run 'databricks aitools install' to install them.
         
         === version --check --output json with a coding agent prints no tip
         
        @@ -38,17 +27,17 @@
         {
           "current_version": "[CLI_VERSION]",
           "update_available": false,
        -  "development_build": true
        +  "check_failed": true
         }
         
         === version --check from Claude Code prints no hint
         
         >>> [CLI] version --check
         Databricks CLI v[CLI_VERSION]
        -This is a development build; skipping the update check.
        +Could not reach GitHub to check for a newer version. See https://github.com/databricks/cli/releases for the latest release.
         
         === version --check from Codex prints no hint
         
         >>> [CLI] version --check
         Databricks CLI v[CLI_VERSION]
        -This is a development build; skipping the update check.
        +Could not reach GitHub to check for a newer version. See https://github.com/databricks/cli/releases for the latest release.

@eng-dev-ecosystem-bot

eng-dev-ecosystem-bot commented Nov 30, 2026 •

Copy link
Copy Markdown
Collaborator

✅ Integration test report

Commit: 69666d6

Run: 46532802944

Env 💚​RECOVERED ✅​pass 🙈​skip Time
💚​ aws linux-2core-8gb 1 88 13 1:50
💚​ aws-windows-latest-4core-16gb 1 88 13 3:21
💚​ azure linux-2core-8gb 1 88 13 1:59
💚​ azure-windows-latest-4core-16gb 1 88 13 3:21
💚​ gcp linux-2core-8gb 1 88 13 1:55
💚​ gcp-windows-latest-4core-16gb 1 88 13 3:08
Test Name aws linux-2core-8gb aws-windows-latest-4core-16gb azure linux-2core-8gb azure-windows-latest-4core-16gb gcp linux-2core-8gb gcp-windows-latest-4core-16gb
💚​ TestAccept 💚​R 💚​R 💚​R 💚​R 💚​R 💚​R
Top 3 slowest tests (at least 2 minutes):
duration env testname
3:20 azure-windows-latest-4core-16gb TestAccept
3:19 aws-windows-latest-4core-16gb TestAccept
3:06 gcp-windows-latest-4core-16gb TestAccept

@simonfaltum
simonfaltum marked this pull request as ready for review November 30, 2026 21:56
@simonfaltum
simonfaltum requested review from a team as code owners November 30, 2026 21:56
@simonfaltum
simonfaltum requested a review from denik November 30, 2026 21:57

@review-oss-bot review-oss-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated review at c5da815. Each finding was verified against the code.

No blocking issues found. 9 non-blocking comment(s) below.

This PR hides the static databricks aitools install text in air help, the interactive quickstart and the generated AGENTS.md when DATABRICKS_CLI_DISABLE_AGENT_FEATURES is set. I found no bug: with the switch unset every text stays the same, and with it set each path drops the install text. What I'd change is mostly fit with existing code. Quickstart adds a second way to filter the text next to variantText. The air run help reads the switch in two places, and one of them has a context.TODO() fallback. Two comments are stale or unclear, and the new tests break a few rules in testing.md.

Comment thread cmd/quickstart/quickstart.go Outdated
}

// dropAitoolsInstallLines removes the lines that name `databricks aitools install`.
func dropAitoolsInstallLines(s string) string {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nice to have] This file already gates aitools text with <!--aitools-->/<!--plain--> blocks through variantText, and dropAitoolsInstallLines adds a second mechanism that matches on line content. Any future line in quickstart-human.md that mentions databricks aitools install gets dropped silently. A nudge that wraps across two lines or rewords the command would be only partly removed. Can you wrap quickstart-human.md:63 in the existing markers and return variantText(humanQuickstart, false, aitoolsNudge) instead?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. The human quickstart line is now wrapped in the existing aitools markers and quickstartFor returns variantText(humanQuickstart, false, aitoolsNudge); dropAitoolsInstallLines is gone.

Comment thread cmd/air/run.go Outdated

// helpContext returns the command's context, or an empty one for a command
// that was not run through Execute.
func helpContext(c *cobra.Command) context.Context {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nice to have] The run help decides whether to show the skill in two ways. newRunCommand sets Long to runLong + runSkillLong, then buildCommand (air.go:56) overwrites it from the build ctx. Meanwhile -h config reads c.Context() at help time through helpContext. The context.TODO() fallback exists only for the new unit test, which calls the help func without Execute. In the real CLI, cobra always sets the context, which AGENTS.md says not to guard against ("Avoid speculative fallbacks", "Do not add defensive nil checks"). Could newRunCommand take the bool from buildCommand and choose both Long and the config-help skill line, so the overwrite and helpContext both go away?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. newRunCommand now takes an agentSkill bool from buildCommand and picks both Long and the config-help skill line from it. The post-hoc Long override and helpContext are removed.

Comment thread cmd/air/air_test.go Outdated
}

func TestAirHelpInstallTextFollowsAgentFeaturesSwitch(t *testing.T) {
for _, tc := range agentFeatureSwitchCases {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nice to have] TestAirHelpInstallTextFollowsAgentFeaturesSwitch checks the same three outputs and substrings as acceptance/air/agent-features-disabled. Likewise, TestAgentsMdInstallStepFollowsAgentFeaturesSwitch (libs/template/renderer_test.go:696) repeats bundle/templates/default-minimal/agent-features-disabled. The only extra coverage is how false, maybe and true parse, and that belongs to skills.AgentFeaturesDisabled. testing.md says not to add a unit test that only duplicates an acceptance test. Can these be dropped, or cut down to what the acceptance tests don't cover?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. I dropped both unit tests. The acceptance cases cover the set and unset outputs, and the true/false/invalid parsing is already covered by TestAgentFeaturesDisabled in libs/skills.

@@ -0,0 +1,11 @@
# With DATABRICKS_CLI_DISABLE_AGENT_FEATURES set, the AGENTS.md written by bundle init names no aitools install.
echo '{"project_name": "my_project", "language_choice": "sql"}' > input.json

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nice to have] input.json is a fixed string, but the script writes it with echo and deletes it at the end. testing.md asks for static inputs to be committed next to script. Can you commit input.json and drop it from the rm -rf?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. input.json is committed next to the script and removed from the rm -rf.

# With DATABRICKS_CLI_DISABLE_AGENT_FEATURES set, the AGENTS.md written by bundle init names no aitools install.
echo '{"project_name": "my_project", "language_choice": "sql"}' > input.json
trace DATABRICKS_CLI_DISABLE_AGENT_FEATURES=1 $CLI bundle init default-minimal --config-file ./input.json --output-dir disabled
grep -c "aitools install" disabled/my_project/AGENTS.md || true

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nice to have] grep -c "aitools install" ... || true hides grep's exit code, so the check rests only on the 0 in output.txt. testing.md allows || true only for cleanup or when exit codes legitimately differ, and asks for the acceptance/bin helpers instead of inline grep. Can lines 4, 5 and 9 use cat .../AGENTS.md | contains.py "If the CLI is not installed" "!aitools install", as the air test in this PR does?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. The script now uses cat ... | contains.py with "If the CLI is not installed" and "!aitools install" for the disabled case, and contains.py "aitools install" for the unset case. The grep/|| true calls are gone.

@@ -0,0 +1,10 @@
# With DATABRICKS_CLI_DISABLE_AGENT_FEATURES set, the air help pages name no

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nit] acceptance/air/help already traces $CLI air --help, and testing.md asks to extend an existing acceptance directory when coverage overlaps. Could these cases go there instead, or is a separate directory clearer because it is about the switch?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I kept the separate directory. The case is about the env switch and runs each command both set and unset, and the help directory pins the unset command tree only. Adding set/unset runs there would mix two purposes in one golden.

Comment thread cmd/air/air.go
w := c.OutOrStdout()
fmt.Fprint(w, airHelpLinks)
fmt.Fprint(w, airSkillLine)
if !skills.AgentFeaturesDisabled(ctx) {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nit] The doc comment on airSkillLine (line 28) still says it "is always printed for air", but this branch now leaves it out when DATABRICKS_CLI_DISABLE_AGENT_FEATURES is set. Can you update that comment to name the exception?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. The comment now says the line is printed except when DATABRICKS_CLI_DISABLE_AGENT_FEATURES is set.

Comment thread cmd/air/run.go Outdated
}

// runLong is the run help text without the skill pointer. It is what is left
// when the agent features switch is on.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nit] "when the agent features switch is on" is easy to read as "when agent features are on", but the switch disables them. Suggest: "It is used alone when DATABRICKS_CLI_DISABLE_AGENT_FEATURES is set; otherwise runSkillLong is appended."

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. The comment now reads: used alone when DATABRICKS_CLI_DISABLE_AGENT_FEATURES is set; otherwise runSkillLong is appended.

Comment thread libs/template/renderer.go Outdated
tmpl := template.New("").Funcs(helpers).Funcs(template.FuncMap{
// False when DATABRICKS_CLI_DISABLE_AGENT_FEATURES is set. The shared library uses
// it to leave out text that points coding agents at `databricks aitools install`.
// It is defined here, not in the helpers, because the library parses without them.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nit] In production, promptForInput passes loadHelpers(ctx), so the shared library is parsed with the helpers attached. "the library parses without them" is only true for callers that pass nil helpers. Could the comment name those callers? Or could the helper move into loadHelpers next to deployment_history, which is the existing env-switch helper, with those callers updated?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tried moving it into loadHelpers, but several tests pass nil helpers and still parse the shared library (for example config_test.go and TestRendererSubTemplateInPath), and they fail with an undefined function. I kept it in newRenderer and reworded the comment to say that callers passing nil helpers still parse the library and need it.

simonfaltum and others added 3 commits November 30, 2026 22:08
…markers, trim duplicate tests

Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>
Co-authored-by: Isaac <no-reply@databricks.com>

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants