Skip to content

Commit 6b31c77

Browse files
authored
Merge branch 'main' into main
2 parents 2ebc7a0 + 8d0b4de commit 6b31c77

58 files changed

Lines changed: 1339 additions & 176 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.devcontainer/devcontainer-lock.json‎

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,6 @@
1010
"resolved": "ghcr.io/devcontainers/features/docker-in-docker@sha256:4fa87399214366e320d489991769c4f3f461e1ffe461f54eea78a41b34945bb5",
1111
"integrity": "sha256:4fa87399214366e320d489991769c4f3f461e1ffe461f54eea78a41b34945bb5"
1212
},
13-
"ghcr.io/devcontainers/features/java:1": {
14-
"version": "1.8.1",
15-
"resolved": "ghcr.io/devcontainers/features/java@sha256:8157bab2d8d71e40b2f3128c162fab763e2b11038fdd33784549290a5d386b48",
16-
"integrity": "sha256:8157bab2d8d71e40b2f3128c162fab763e2b11038fdd33784549290a5d386b48"
17-
},
1813
"ghcr.io/devcontainers/features/python:1": {
1914
"version": "1.8.0",
2015
"resolved": "ghcr.io/devcontainers/features/python@sha256:fbcad6955caeecc5ad3f7886baf652e25cba5225a6c4c2287c536de2e5607511",

‎.devcontainer/devcontainer.json‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,6 @@
66
"ghcr.io/devcontainers/features/python:1": {
77
"version": "3.12"
88
},
9-
"ghcr.io/devcontainers/features/java:1": {
10-
"version": "21"
11-
},
129
"ghcr.io/devcontainers/features/docker-in-docker:4": {}
1310
},
1411
"postCreateCommand": "bash .devcontainer/post-create-command.sh",

‎.github/workflows/pr.yaml‎

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050
steps:
5151
- uses: actions/checkout@v7
5252
- name: Set up Python
53-
uses: actions/setup-python@v6
53+
uses: actions/setup-python@v7
5454
with:
5555
python-version: '3.10'
5656
- name: Install uv
@@ -83,7 +83,7 @@ jobs:
8383
with:
8484
fetch-depth: 0
8585
- name: Set up Python
86-
uses: actions/setup-python@v6
86+
uses: actions/setup-python@v7
8787
with:
8888
python-version: ${{ matrix.python-version }}
8989
- name: Install uv
@@ -135,7 +135,7 @@ jobs:
135135
- name: Install make
136136
run: choco install make which -y
137137
- name: Set up Python
138-
uses: actions/setup-python@v6
138+
uses: actions/setup-python@v7
139139
with:
140140
python-version: '3.12'
141141
- name: Install SQLMesh dev dependencies
@@ -172,7 +172,7 @@ jobs:
172172
with:
173173
fetch-depth: 0
174174
- name: Set up Python
175-
uses: actions/setup-python@v6
175+
uses: actions/setup-python@v7
176176
with:
177177
python-version: '3.10'
178178
- name: Install uv
@@ -194,16 +194,16 @@ jobs:
194194
runs-on: ubuntu-latest
195195
steps:
196196
- uses: actions/checkout@v7
197-
- uses: actions/setup-node@v6
197+
- uses: actions/setup-node@v7
198198
with:
199199
node-version: '22'
200-
- uses: pnpm/action-setup@v4
200+
- uses: pnpm/action-setup@v6
201201
with:
202202
version: latest
203203
- name: Get pnpm store directory
204204
id: pnpm-cache
205205
run: echo "store=$(pnpm store path)" >> $GITHUB_OUTPUT
206-
- uses: actions/cache@v5
206+
- uses: actions/cache@v6
207207
with:
208208
path: ${{ steps.pnpm-cache.outputs.store }}
209209
key: pnpm-store-${{ hashFiles('pnpm-lock.yaml') }}
@@ -260,7 +260,7 @@ jobs:
260260
steps:
261261
- uses: actions/checkout@v7
262262
- name: Set up Python
263-
uses: actions/setup-python@v6
263+
uses: actions/setup-python@v7
264264
with:
265265
python-version: '3.12'
266266
- name: Install uv
@@ -344,7 +344,7 @@ jobs:
344344
steps:
345345
- uses: actions/checkout@v7
346346
- name: Set up Python
347-
uses: actions/setup-python@v6
347+
uses: actions/setup-python@v7
348348
with:
349349
python-version: '3.12'
350350
- name: Install uv
@@ -399,10 +399,10 @@ jobs:
399399
if: false
400400
steps:
401401
- uses: actions/checkout@v7
402-
- uses: actions/setup-node@v6
402+
- uses: actions/setup-node@v7
403403
with:
404404
node-version: '22'
405-
- uses: pnpm/action-setup@v4
405+
- uses: pnpm/action-setup@v6
406406
with:
407407
version: latest
408408
- name: Install dependencies
@@ -416,16 +416,16 @@ jobs:
416416
if: false
417417
steps:
418418
- uses: actions/checkout@v7
419-
- uses: actions/setup-node@v6
419+
- uses: actions/setup-node@v7
420420
with:
421421
node-version: '22'
422-
- uses: pnpm/action-setup@v4
422+
- uses: pnpm/action-setup@v6
423423
with:
424424
version: latest
425425
- name: Install dependencies
426426
run: pnpm install
427427
- name: Set up Python
428-
uses: actions/setup-python@v6
428+
uses: actions/setup-python@v7
429429
with:
430430
python-version: '3.12'
431431
- name: Install uv
@@ -457,11 +457,11 @@ jobs:
457457
strategy:
458458
fail-fast: false
459459
matrix:
460-
dbt-version: ['1.3', '1.4', '1.5', '1.6', '1.7', '1.8', '1.9', '1.10']
460+
dbt-version: ['1.3', '1.4', '1.5', '1.6', '1.7', '1.8', '1.9', '1.10', '1.11', '1.12']
461461
steps:
462462
- uses: actions/checkout@v7
463463
- name: Set up Python
464-
uses: actions/setup-python@v6
464+
uses: actions/setup-python@v7
465465
with:
466466
python-version: '3.10'
467467
- name: Install uv

‎.github/workflows/release.yaml‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@ jobs:
1010
runs-on: ubuntu-latest
1111
steps:
1212
- uses: actions/checkout@v7
13-
- uses: actions/setup-node@v6
13+
- uses: actions/setup-node@v7
1414
with:
1515
node-version: '22'
16-
- uses: pnpm/action-setup@v4
16+
- uses: pnpm/action-setup@v6
1717
with:
1818
version: latest
1919
- name: Install dependencies
@@ -38,7 +38,7 @@ jobs:
3838
name: ui-dist
3939
path: web/client/dist/
4040
- name: Set up Python
41-
uses: actions/setup-python@v6
41+
uses: actions/setup-python@v7
4242
with:
4343
python-version: '3.10'
4444
- name: Install uv
@@ -65,7 +65,7 @@ jobs:
6565
with:
6666
fetch-depth: 0
6767
- name: Create release on GitHub
68-
uses: softprops/action-gh-release@v2
68+
uses: softprops/action-gh-release@v3
6969
with:
7070
generate_release_notes: true
7171
tag_name: ${{ github.ref_name }}

‎.github/workflows/release_extension.yaml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,11 @@ jobs:
2828
fi
2929
echo "Version format is valid: $version"
3030
- name: Setup Node.js
31-
uses: actions/setup-node@v6
31+
uses: actions/setup-node@v7
3232
with:
3333
node-version: '22'
3434
- name: Install pnpm
35-
uses: pnpm/action-setup@v4
35+
uses: pnpm/action-setup@v6
3636
with:
3737
version: 10
3838
- name: Install dependencies

‎.github/workflows/release_shared_js.yaml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131
fi
3232
echo "Version format is valid: $version"
3333
- name: Setup Node.js
34-
uses: actions/setup-node@v6
34+
uses: actions/setup-node@v7
3535
with:
3636
node-version: '22'
3737
registry-url: 'https://registry.npmjs.org'
@@ -40,7 +40,7 @@ jobs:
4040
- name: Print npm version
4141
run: npm --version
4242
- name: Install pnpm
43-
uses: pnpm/action-setup@v4
43+
uses: pnpm/action-setup@v6
4444
with:
4545
version: 10
4646
- name: Install dependencies

‎Makefile‎

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@ install-dev-dbt-%:
3333
echo "Installing dbt version: $$version"; \
3434
cp pyproject.toml pyproject.toml.backup; \
3535
$(SED_INPLACE) 's/"pydantic>=2.0.0"/"pydantic"/g' pyproject.toml; \
36-
if [ "$$version" = "1.10.0" ]; then \
37-
echo "Applying special handling for dbt 1.10.0"; \
36+
if [ "$$version" = "1.10.0" ] || [ "$$version" = "1.11.0" ] || [ "$$version" = "1.12.0" ]; then \
37+
echo "Applying special handling for dbt $$version"; \
3838
$(SED_INPLACE) -E 's/"(dbt-core)[^"]*"/"\1~='"$$version"'"/g' pyproject.toml; \
3939
$(SED_INPLACE) -E 's/"(dbt-(bigquery|duckdb|snowflake|athena-community|clickhouse|redshift|trino))[^"]*"/"\1"/g' pyproject.toml; \
4040
$(SED_INPLACE) -E 's/"(dbt-databricks)[^"]*"/"\1~='"$$version"'"/g' pyproject.toml; \
@@ -132,13 +132,13 @@ engine-up: engine-clickhouse-up engine-mssql-up engine-mysql-up engine-postgres-
132132
engine-down: engine-clickhouse-down engine-mssql-down engine-mysql-down engine-postgres-down engine-spark-down engine-trino-down
133133

134134
fast-test:
135-
pytest -n auto -m "fast and not cicdonly" --junitxml=test-results/junit-fast-test.xml && pytest -m "isolated" && pytest -m "registry_isolation" && pytest -m "dialect_isolated"
135+
pytest -n auto -m "fast and not cicdonly and not isolated" --junitxml=test-results/junit-fast-test.xml && pytest -m "isolated and not slow" && pytest -m "registry_isolation" && pytest -m "dialect_isolated"
136136

137137
slow-test:
138-
pytest -n auto -m "(fast or slow) and not cicdonly" && pytest -m "isolated" && pytest -m "registry_isolation" && pytest -m "dialect_isolated"
138+
pytest -n auto -m "(fast or slow) and not cicdonly and not isolated" && pytest -m "isolated" && pytest -m "registry_isolation" && pytest -m "dialect_isolated"
139139

140140
cicd-test:
141-
pytest -n auto -m "(fast or slow) and not pyspark" --junitxml=test-results/junit-cicd.xml && pytest -m "pyspark" && pytest -m "isolated" && pytest -m "registry_isolation" && pytest -m "dialect_isolated"
141+
pytest -n auto -m "(fast or slow) and not pyspark and not isolated" --junitxml=test-results/junit-cicd.xml && pytest -m "pyspark" && pytest -m "isolated and not pyspark" && pytest -m "registry_isolation" && pytest -m "dialect_isolated"
142142

143143
core-fast-test:
144144
pytest -n auto -m "fast and not web and not github and not dbt and not jupyter"

‎docs/concepts/models/overview.md‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,6 +190,7 @@ This table lists each engine's support for `TABLE` and `VIEW` object comments:
190190
| Redshift | Y | N |
191191
| Snowflake | Y | Y |
192192
| Spark | Y | Y |
193+
| StarRocks | Y | Y |
193194
| Trino | Y | Y |
194195

195196

‎docs/concepts/overview.md‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,9 @@ Bad data is worse than no data. The best way to keep bad data out of your system
5252
### [Tests](./tests.md)
5353
SQLMesh "tests" are similar to unit tests in software development, where the unit is a single model. SQLMesh tests validate model *code* — you specify the input data and expected output, then SQLMesh runs the test and compares the expected and actual output.
5454

55-
SQLMesh automatically runs tests when you apply a `plan`, or you can run them on demand with the [`test` command](../reference/cli.md#test).
55+
SQLMesh automatically runs all unit tests when a `plan` is created. Use `--test-changed-only` to run tests only for models included in the plan (added, modified, or restated), `--skip-tests` to skip, run tests for specific models with [`sqlmesh test --select-model`](../reference/cli.md#test), or run the full suite on demand with the [`test` command](../reference/cli.md#test).
56+
57+
Learn more in the [testing guide](../guides/testing.md).
5658

5759
### [Audits](./audits.md)
5860
In contrast to tests, SQLMesh "audits" validate the results of model code applied to your actual data.

‎docs/concepts/tests.md‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# Testing
22

3-
Testing allows you to protect your project from regression by continuously verifying that the output of each model matches your expectations. Unlike [audits](audits.md), tests are executed either on demand (for example, as part of a CI/CD job) or every time a new [plan](plans.md) is created.
3+
Testing allows you to protect your project from regression by continuously verifying that the output of each model matches your expectations. Unlike [audits](audits.md), tests are executed either on demand (for example, as part of a CI/CD job or via [`sqlmesh test`](../reference/cli.md#test)) or when a new [plan](plans.md) is created.
4+
5+
By default, `sqlmesh plan` runs all unit tests. Use `--test-changed-only` to run tests only for models included in the plan (added, modified, or restated), or `--skip-tests` to run none. With both `--select-model` and `--test-changed-only`, tests run only for selected models that changed.
46

57
Similar to unit testing in software development, SQLMesh evaluates the model's logic against predefined inputs and then compares the output to expected outcomes provided as part of each test.
68

0 commit comments

Comments
 (0)