Uh oh!
There was an error while loading. Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork 214
Update templates to use serverless environment version 4 and matching Python version#3897
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Uh oh!
There was an error while loading. Please reload this page.
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
82f49e7
Update serverless environment version to 4 in templates
lennartkats-db 7d245e9
Update bundle templates to serverless environment version 4 and Pytho…
lennartkats-db 6e67551
Cleanup
lennartkats-db c5f1db8
Remove experimental-jobs-as-code Python version changes
lennartkats-db 93dd6d5
Add NEXT_CHANGELOG entry for serverless environment version update
lennartkats-db bd3ead2
Add rationale for Python version spec in template
lennartkats-db c54d302
Merge branch 'main' into update-environment-version
lennartkats-db afcd213
Update NEXT_CHANGELOG.md
lennartkats-db f6ba2b8
Merge main into update-environment-version
lennartkats-db File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Uh oh!
There was an error while loading. Please reload this page.
Jump to
Jump to file
Failed to load files.
Loading
Uh oh!
There was an error while loading. Please reload this page.
Diff view
Diff view
There are no files selected for viewing
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
2 changes: 1 addition & 1 deletion
2 acceptance/bundle/templates/dbt-sql/output/my_dbt_sql/resources/my_dbt_sql.job.yml
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
2 changes: 1 addition & 1 deletion
2 acceptance/bundle/templates/default-python/classic/out.compare-vs-serverless.diff
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
2 changes: 1 addition & 1 deletion
2 acceptance/bundle/templates/default-python/classic/output/my_default_python/pyproject.toml
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
4 changes: 2 additions & 2 deletions
4 ...undle/templates/default-python/classic/output/my_default_python/src/sample_notebook.ipynb
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
2 changes: 1 addition & 1 deletion
2 ...ptance/bundle/templates/default-python/serverless/output/my_default_python/pyproject.toml
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
2 changes: 1 addition & 1 deletion
2 ...templates/default-python/serverless/output/my_default_python/resources/sample_job.job.yml
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
4 changes: 2 additions & 2 deletions
4 ...le/templates/default-python/serverless/output/my_default_python/src/sample_notebook.ipynb
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
2 changes: 1 addition & 1 deletion
2 ...ce/bundle/templates/lakeflow-pipelines/python/output/my_lakeflow_pipelines/pyproject.toml
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
2 changes: 1 addition & 1 deletion
2 ...lates/lakeflow-pipelines/python/output/my_lakeflow_pipelines/resources/sample_job.job.yml
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -29,4 +29,4 @@ resources: | ||
| environments: | ||
| - environment_key: default | ||
| spec: | ||
| environment_version: "2" | ||
| environment_version: "4" | ||
2 changes: 1 addition & 1 deletion
2 ...emplates/lakeflow-pipelines/sql/output/my_lakeflow_pipelines/resources/sample_job.job.yml
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -29,4 +29,4 @@ resources: | ||
| environments: | ||
| - environment_key: default | ||
| spec: | ||
| environment_version: "2" | ||
| environment_version: "4" | ||
2 changes: 1 addition & 1 deletion
2 acceptance/bundle/templates/pydabs/init-classic/output/my_pydabs/pyproject.toml
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
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
2 changes: 1 addition & 1 deletion
2 ...ate/templates/dbt-sql/template/{{.project_name}}/resources/{{.project_name}}.job.yml.tmpl
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,4 +1,5 @@ | ||
| {{/* The latest LTS DBR version; this should be updated a few months after each LTS. | ||
| * See https://docs.databricks.com/release-notes/runtime/index.html for available versions. | ||
| */}} | ||
| {{define "latest_lts_dbr_version" -}} | ||
| 16.4.x-scala2.12 | ||
| @@ -11,16 +12,39 @@ | ||
| * only connect to compute of that same version and higher. If the version is | ||
| * deemed too old, customers can update the version themselves after initializing | ||
| * the template. | ||
| * | ||
| * See https://docs.databricks.com/dev-tools/databricks-connect/python/index.html#requirements | ||
| * for DB Connect release notes and version compatibility. | ||
| */}} | ||
| {{define "conservative_db_connect_version_spec" -}} | ||
| >=15.4,<15.5 | ||
| {{- end}} | ||
| {{/* DB Connect 15 only supports versions up to 3.13 because of a limitation in | ||
| * pyarrow: https://arrow.apache.org/docs/python/install.html#python-compatibility | ||
| {{/* The serverless environment version to use. | ||
| * See https://docs.databricks.com/release-notes/runtime/index.html for available versions. | ||
| */}} | ||
| {{define "serverless_environment_version" -}} | ||
| 4 | ||
| {{- end}} | ||
| {{/* Python version specification for the template. | ||
| * This needs to be compatible with the version of DB Connect and the serverless_environment_version. | ||
| * | ||
| * Serverless environment version 4 (and upcoming v5), DBR 16, and DBR 17 all use Python 3.12. | ||
| * DB Connect 15 supports all of these and is compatible with Python 3.10-3.12. | ||
| * | ||
| * We use >=3.10,<3.13 rather than pinning to 3.12 specifically because overly narrow pinning | ||
| * means users always need to use uv or similar tools to install the exact version. A broader | ||
| * range improves usability while maintaining compatibility with both DB Connect and serverless. | ||
| */}} | ||
| {{define "python_version_spec" -}} | ||
| >=3.10,<3.13 | ||
lennartkats-db marked this conversation as resolved.
Uh oh!There was an error while loading. Please reload this page. | ||
| {{- end}} | ||
| {{/* The default Python version used in notebook metadata. | ||
| */}} | ||
| {{define "conservative_db_connect_python_version_spec" -}} | ||
| >=3.10,<=3.13 | ||
| {{define "default_python_version" -}} | ||
| 3.12 | ||
| {{- end}} | ||
| {{define "latest_databricks_bundles_version" -}}0.277.0{{- end}} | ||
2 changes: 1 addition & 1 deletion
2 libs/template/templates/default/template/{{.project_name}}/pyproject.toml.tmpl
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -2,7 +2,7 @@ | ||
| name = "{{.project_name}}" | ||
| version = "0.0.1" | ||
| authors = [{ name = "{{user_name}}" }] | ||
| requires-python = "{{template "conservative_db_connect_python_version_spec"}}" | ||
| requires-python = "{{template "python_version_spec"}}" | ||
lennartkats-db marked this conversation as resolved.
Uh oh!There was an error while loading. Please reload this page. | ||
| dependencies = [ | ||
| # Any dependencies for jobs and pipelines in this project can be added here | ||
| # See also https://docs.databricks.com/dev-tools/bundles/library-dependencies | ||
2 changes: 1 addition & 1 deletion
2 libs/template/templates/default/template/{{.project_name}}/resources/sample_job.job.yml.tmpl
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
2 changes: 1 addition & 1 deletion
2 libs/template/templates/default/template/{{.project_name}}/resources/sample_job.py.tmpl
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
4 changes: 2 additions & 2 deletions
4 libs/template/templates/default/template/{{.project_name}}/src/sample_notebook.ipynb.tmpl
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
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.
Uh oh!
There was an error while loading. Please reload this page.