Skip to content

Added databricks apps run-local command to run Databricks apps locally - #2555

Merged
andrewnester merged 20 commits into
mainfrom
feature/local-app-run
Apr 30, 2025
Merged

Added databricks apps run-local command to run Databricks apps locally#2555
andrewnester merged 20 commits into
mainfrom
feature/local-app-run

Conversation

@andrewnester

@andrewnesterandrewnester commented Mar 24, 2025

Copy link
Copy Markdown
Contributor

Changes

Added databricks apps run-local command to run Databricks apps locally.
This command allows to start the Databricks app locally. It starts app proxy which is used to proxy request to the app itself and injects necessary Databricks app related headers.

The command support the following options:

  • --prepare-environment: will setup Python virtual environment and install necessary libraries. It uses uv
  • --debug: starts a Python debugger (based on debugpy) which allows you to attach your IDE debugger to running app.
  • --port: allows to configure which port to start proxy on
  • --entry-point: allows to configure which YAML file to use for Databricks app configuration.

Tests

Added acceptance test

@andrewnesterandrewnester changed the title Feature/local app runAdded databricks apps run-local command to run Databricks apps locallyMar 24, 2025
Comment threadacceptance/cmd/workspace/apps/run-local/script Outdated
Comment threadlibs/apps/python.go Outdated
Comment threadlibs/apps/headers.go
Comment threadlibs/apps/python.go Outdated
Comment threadlibs/apps/python.go
Comment threadlibs/apps/python.go
Comment threadlibs/apps/spec.go
Comment threadNEXT_CHANGELOG.md Outdated
Comment threadcmd/workspace/apps/run_local.go
}
return errors.New("process killed after timeout")
}
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

For follow-up: some wrappers accept a double SIGINT to force kill the wrapped process. With the current approach, the user has to wait for 15 seconds if the wrapped process ignores SIGINT.

Comment threadlibs/apps/headers.go
Comment threadlibs/apps/python.go
Co-authored-by: Pieter Noordhuis <pieter.noordhuis@databricks.com>
@andrewnester
andrewnester merged commit e210a27 into mainApr 30, 2025
@andrewnester
andrewnester deleted the feature/local-app-run branch April 30, 2025 12:12
deco-sdk-taggingBot added a commit that referenced this pull request Apr 30, 2025
## Release v0.250.0
### Notable Changes
* Added inline script execution support to bundle run. You can now run scripts in the same authentication context as a DAB using the databricks bundle run command. ([#2413](#2413))
### Dependency updates
* Upgrade TF provider to 1.75.0 ([#2775](#2775))
* Upgrade Go SDK to 0.65.0 ([#2786](#2786))
### CLI
* Added `databricks apps run-local` command to run Databricks apps locally ([#2555](#2555))
### Bundles
* Raise an error when Unity Catalog volumes are used for paths other than artifacts ([#2754](#2754))
* Fixed issue with jobs and pipelines declared in Python not showing in "Bundle resource explorer" in VSCode ([#2764](#2764))
* Made `experimental/python/mutators` and `experimental/python/resources` fields optional in JSON schema ([#2761](#2761))
* Annotated deprecated fields in JSON schema ([#2770](#2770))
Comment threadacceptance/cmd/workspace/apps/run-local/script
denik pushed a commit that referenced this pull request May 20, 2026
…lly (#2555)
## Changes
Added `databricks apps run-local` command to run Databricks apps
locally.
This command allows to start the Databricks app locally. It starts app
proxy which is used to proxy request to the app itself and injects
necessary Databricks app related headers.
The command support the following options:
* `--prepare-environment`: will setup Python virtual environment and
install necessary libraries. It uses `uv`
* `--debug`: starts a Python debugger (based on debugpy) which allows
you to attach your IDE debugger to running app.
* `--port`: allows to configure which port to start proxy on
* `--entry-point`: allows to configure which YAML file to use for
Databricks app configuration.
## Tests
Added acceptance test
<!-- If your PR needs to be included in the release notes for next
release,
add a separate entry in NEXT_CHANGELOG.md as part of your PR. -->
---------
Co-authored-by: shreyas-goenka <88374338+shreyas-goenka@users.noreply.github.com>
Co-authored-by: Pieter Noordhuis <pieter.noordhuis@databricks.com>
denik pushed a commit that referenced this pull request May 20, 2026
## Release v0.250.0
### Notable Changes
* Added inline script execution support to bundle run. You can now run scripts in the same authentication context as a DAB using the databricks bundle run command. ([#2413](#2413))
### Dependency updates
* Upgrade TF provider to 1.75.0 ([#2775](#2775))
* Upgrade Go SDK to 0.65.0 ([#2786](#2786))
### CLI
* Added `databricks apps run-local` command to run Databricks apps locally ([#2555](#2555))
### Bundles
* Raise an error when Unity Catalog volumes are used for paths other than artifacts ([#2754](#2754))
* Fixed issue with jobs and pipelines declared in Python not showing in "Bundle resource explorer" in VSCode ([#2764](#2764))
* Made `experimental/python/mutators` and `experimental/python/resources` fields optional in JSON schema ([#2761](#2761))
* Annotated deprecated fields in JSON schema ([#2770](#2770))
Sign up for freeto 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.

4 participants

@andrewnester@pietern@denik@shreyas-goenka