Skip to content

Commit 2477f00

Browse files
authored
Merge branch 'main' into dependabot/github_actions/actions/upload-artifact-7
2 parents 49ff965 + 24bb095 commit 2477f00

233 files changed

Lines changed: 20293 additions & 1466 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"features": {
3+
"ghcr.io/devcontainers/features/common-utils:2": {
4+
"version": "2.5.9",
5+
"resolved": "ghcr.io/devcontainers/features/common-utils@sha256:cb0c4d3c276f157eed17935747e364178d75fee17f55c4e129966f64633deb3a",
6+
"integrity": "sha256:cb0c4d3c276f157eed17935747e364178d75fee17f55c4e129966f64633deb3a"
7+
},
8+
"ghcr.io/devcontainers/features/docker-in-docker:4": {
9+
"version": "4.0.0",
10+
"resolved": "ghcr.io/devcontainers/features/docker-in-docker@sha256:4fa87399214366e320d489991769c4f3f461e1ffe461f54eea78a41b34945bb5",
11+
"integrity": "sha256:4fa87399214366e320d489991769c4f3f461e1ffe461f54eea78a41b34945bb5"
12+
},
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+
},
18+
"ghcr.io/devcontainers/features/python:1": {
19+
"version": "1.8.0",
20+
"resolved": "ghcr.io/devcontainers/features/python@sha256:fbcad6955caeecc5ad3f7886baf652e25cba5225a6c4c2287c536de2e5607511",
21+
"integrity": "sha256:fbcad6955caeecc5ad3f7886baf652e25cba5225a6c4c2287c536de2e5607511"
22+
}
23+
}
24+
}

.devcontainer/devcontainer.json

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{
2+
"name": "SQLMesh Python Dev",
3+
"image": "mcr.microsoft.com/devcontainers/base:ubuntu-24.04",
4+
"features": {
5+
"ghcr.io/devcontainers/features/common-utils:2": {},
6+
"ghcr.io/devcontainers/features/python:1": {
7+
"version": "3.12"
8+
},
9+
"ghcr.io/devcontainers/features/java:1": {
10+
"version": "21"
11+
},
12+
"ghcr.io/devcontainers/features/docker-in-docker:4": {}
13+
},
14+
"postCreateCommand": "bash .devcontainer/post-create-command.sh",
15+
"customizations": {
16+
"vscode": {
17+
"extensions": [
18+
"ms-python.python",
19+
"ms-python.vscode-pylance"
20+
]
21+
}
22+
},
23+
"remoteUser": "vscode"
24+
}
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
#!/bin/bash
2+
3+
# This script is intended to be run by an Ubuntu development container
4+
5+
# Exit immediately if any command returns a non-zero code
6+
set -e
7+
8+
# Install OS-level dependencies
9+
10+
## Ensure that the Microsoft package repository is available as it is required for msodbcsql18. Note that the repository
11+
## may have already been added by a development container feature (e.g. docker-in-docker or java).
12+
if apt-cache policy | grep -q 'packages.microsoft.com'; then
13+
echo "Microsoft package repository already present"
14+
else
15+
echo "Microsoft package repository not present, it will be added."
16+
17+
# ref: https://learn.microsoft.com/en-us/sql/connect/odbc/linux-mac/installing-the-microsoft-odbc-driver-for-sql-server
18+
curl -sSL -O https://packages.microsoft.com/config/ubuntu/$(grep VERSION_ID /etc/os-release | cut -d '"' -f 2)/packages-microsoft-prod.deb
19+
sudo dpkg -i packages-microsoft-prod.deb
20+
rm packages-microsoft-prod.deb
21+
fi
22+
23+
ALL_DEPENDENCIES="libpq-dev netcat-traditional unixodbc-dev default-jdk msodbcsql18"
24+
sudo apt-get clean && sudo apt-get -y update && sudo ACCEPT_EULA='Y' apt-get -y install $ALL_DEPENDENCIES
25+
26+
# Install Python dependencies
27+
make install-dev

.github/scripts/wait-for-db.sh

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,37 @@ spark_ready() {
5050
probe_port 15002
5151
}
5252

53+
starrocks_ready() {
54+
probe_port 9030
55+
56+
echo "Checking for 1 alive StarRocks backends..."
57+
sleep 5
58+
59+
while true; do
60+
echo "Checking StarRocks backends..."
61+
ALIVE_BACKENDS=$(docker exec -i starrocks-fe mysql -h127.0.0.1 -P9030 -uroot -e "show backends \G" | grep -c "^ *Alive: true *$")
62+
63+
# fallback value if failed to get number
64+
if ! [[ "$ALIVE_BACKENDS" =~ ^[0-9]+$ ]]; then
65+
echo "WARN: Unable to parse number of alive backends, got: '$ALIVE_BACKENDS'"
66+
ALIVE_BACKENDS=0
67+
fi
68+
69+
echo "Found $ALIVE_BACKENDS alive backends"
70+
71+
if [ "$ALIVE_BACKENDS" -ge 1 ]; then
72+
echo "StarRocks has 1 or more alive backends"
73+
break
74+
fi
75+
76+
echo "Waiting for more backends to become alive..."
77+
sleep 5
78+
done
79+
80+
# set default replication num to 1 (there is only one be in the docker compose file)
81+
docker exec -i starrocks-fe mysql -h127.0.0.1 -P9030 -uroot -e "ADMIN SET frontend config ('default_replication_num' = '1');"
82+
}
83+
5384
trino_ready() {
5485
# Trino has a built-in healthcheck script, just call that
5586
docker compose -f tests/core/engine_adapter/integration/docker/compose.trino.yaml exec trino /bin/bash -c '/usr/lib/trino/bin/health-check'

.github/workflows/pr.yaml

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -188,15 +188,15 @@ jobs:
188188

189189
ui-style:
190190
needs: [changes]
191-
if:
192-
needs.changes.outputs.client == 'true' || needs.changes.outputs.ci ==
193-
'true' || github.ref == 'refs/heads/main'
191+
if: false
192+
# needs.changes.outputs.client == 'true' || needs.changes.outputs.ci ==
193+
# 'true' || github.ref == 'refs/heads/main'
194194
runs-on: ubuntu-latest
195195
steps:
196196
- uses: actions/checkout@v5
197197
- uses: actions/setup-node@v6
198198
with:
199-
node-version: '20'
199+
node-version: '22'
200200
- uses: pnpm/action-setup@v4
201201
with:
202202
version: latest
@@ -252,7 +252,7 @@ jobs:
252252
fail-fast: false
253253
matrix:
254254
engine:
255-
[duckdb, postgres, mysql, mssql, trino, spark, clickhouse, risingwave]
255+
[duckdb, postgres, mysql, mssql, trino, spark, clickhouse, risingwave, starrocks]
256256
env:
257257
PYTEST_XDIST_AUTO_NUM_WORKERS: 2
258258
SQLMESH__DISABLE_ANONYMIZED_ANALYTICS: '1'
@@ -396,6 +396,7 @@ jobs:
396396
env:
397397
PLAYWRIGHT_SKIP_BROWSER_DOWNLOAD: 1
398398
runs-on: ubuntu-latest
399+
if: false
399400
steps:
400401
- uses: actions/checkout@v5
401402
- uses: actions/setup-node@v6
@@ -513,7 +514,12 @@ jobs:
513514
echo "DBT version is ${{ matrix.dbt-version }} (>= 1.6.0), keeping semantic_models and metrics sections"
514515
fi
515516
516-
make dbt-fast-test
517+
# dbt 1.6 installs without web/lsp (pydantic conflict); skip collecting those tests
518+
if [[ "${{ matrix.dbt-version }}" == "1.6" ]]; then
519+
pytest -n auto -m "dbt and fast" --reruns 3 --ignore=tests/lsp --ignore=tests/web
520+
else
521+
make dbt-fast-test
522+
fi
517523
- name: Test SQLMesh info in sushi_dbt
518524
working-directory: ./examples/sushi_dbt
519525
run: |

.github/workflows/release.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ jobs:
1212
- uses: actions/checkout@v5
1313
- uses: actions/setup-node@v6
1414
with:
15-
node-version: '20'
15+
node-version: '22'
1616
- uses: pnpm/action-setup@v4
1717
with:
1818
version: latest
1919
- name: Install dependencies
20-
run: pnpm install
20+
run: pnpm install --frozen-lockfile
2121
- name: Build UI
2222
run: pnpm --prefix web/client run build
2323
- name: Upload UI build artifact

.github/workflows/release_extension.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
- name: Setup Node.js
3131
uses: actions/setup-node@v6
3232
with:
33-
node-version: '20'
33+
node-version: '22'
3434
- name: Install pnpm
3535
uses: pnpm/action-setup@v4
3636
with:

.github/workflows/release_shared_js.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
- name: Setup Node.js
3434
uses: actions/setup-node@v6
3535
with:
36-
node-version: '20'
36+
node-version: '22'
3737
registry-url: 'https://registry.npmjs.org'
3838
- name: Update npm
3939
run: npm install -g npm@latest

.nvmrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
20
1+
22

.readthedocs.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ build:
66
python: "3.10"
77
jobs:
88
pre_build:
9-
- pip install -e ".[athena,azuresql,bigframes,bigquery,clickhouse,databricks,dbt,dlt,gcppostgres,github,llm,mssql,mysql,mwaa,postgres,redshift,slack,snowflake,trino,web,risingwave]"
9+
- pip install -e ".[athena,azuresql,bigframes,bigquery,clickhouse,databricks,dbt,dlt,gcppostgres,github,llm,mssql,mysql,mwaa,postgres,redshift,slack,snowflake,starrocks,trino,web,risingwave]"
1010
- make api-docs
1111

1212
mkdocs:

0 commit comments

Comments
 (0)