Skip to content

Commit 8fc7b96

Browse files
authored
acc: Fix default-python integration test (#2592)
This failure is caused by 6 digit timestamp being converted to 5 digit if there is a leading zero: ``` >>> [CLI] bundle deploy -t dev Building python_artifact... -Uploading dist/project_name_[UNIQUE_NAME]-0.0.1+[NUMBER].[NUMBER]-py3-none-any.whl... +Uploading dist/project_name_[UNIQUE_NAME]-0.0.1+[NUMBER].63807-py3-none-any.whl... Uploading bundle files to /Workspace/Users/[USERNAME]/.bundle/project_name_[UNIQUE_NAME]/dev/files... Deploying resources... Updating deployment state... ``` Also fix Python selection variable: it's not UV_VERSION, it's UV_PYTHON.
1 parent 04e7c43 commit 8fc7b96

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

acceptance/bundle/templates/default-python/integration_classic/output.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
11

2+
>>> python -c import sys; print("%s.%s" % sys.version_info[:2])
3+
[UV_PYTHON]
4+
25
>>> [CLI] bundle init default-python --config-file ./input.json --output-dir .
36

47
Welcome to the default Python template for Databricks Asset Bundles!

acceptance/bundle/templates/default-python/integration_classic/script

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ export PYTHONDONTWRITEBYTECODE=1
22

33
uv venv -q .venv
44
venv_activate
5+
trace python -c 'import sys; print("%s.%s" % sys.version_info[:2])'
56
uv pip install -q setuptools
67

78
envsubst < input.json.tmpl > input.json

acceptance/bundle/templates/default-python/integration_classic/test.toml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Ignore = [
99
]
1010

1111
[EnvMatrix]
12-
UV_VERSION = [
12+
UV_PYTHON = [
1313
"3.9",
1414
"3.10",
1515
"3.11",
@@ -18,7 +18,8 @@ UV_VERSION = [
1818
]
1919

2020
[[Repls]]
21-
Old = '\d{6,}'
21+
# for some reason leading number is lost converting "%H%M%S" 061234 to 61234
22+
Old = '\d{5,}'
2223
New = '[NUMBER]'
2324

2425
[[Repls]]

0 commit comments

Comments
 (0)