Skip to content

Commit a4bc487

Browse files
committed
Pin Python 3.11 in CI and drop strict per-version defaults
1 parent 133dd5c commit a4bc487

3 files changed

Lines changed: 33 additions & 6 deletions

File tree

.github/workflows/main.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,10 @@ jobs:
2020
steps:
2121
- uses: "actions/checkout@v2"
2222

23+
- uses: "actions/setup-python@v5"
24+
with:
25+
python-version: "3.11"
26+
2327
- name: test snowflake
2428
run: ./run-all-integration-tests.sh snowflake
2529

@@ -30,6 +34,10 @@ jobs:
3034
steps:
3135
- uses: "actions/checkout@v2"
3236

37+
- uses: "actions/setup-python@v5"
38+
with:
39+
python-version: "3.11"
40+
3341
- id: "auth"
3442
name: "Authenticate to Google Cloud"
3543
uses: "google-github-actions/auth@v0"
@@ -64,6 +72,10 @@ jobs:
6472
steps:
6573
- uses: "actions/checkout@v2"
6674

75+
- uses: "actions/setup-python@v5"
76+
with:
77+
python-version: "3.11"
78+
6779
- name: test postgres
6880
run: ./run-all-integration-tests.sh postgres
6981

@@ -89,5 +101,9 @@ jobs:
89101
steps:
90102
- uses: "actions/checkout@v2"
91103

104+
- uses: "actions/setup-python@v5"
105+
with:
106+
python-version: "3.11"
107+
92108
- name: test postgres
93109
run: ./run-all-jaffle-shop-tests.sh postgres

.github/workflows/pr_integration_tests.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ jobs:
2121
with:
2222
ref: ${{ github.event.pull_request.head.sha }}
2323

24+
- uses: "actions/setup-python@v5"
25+
with:
26+
python-version: "3.11"
27+
2428
- name: test snowflake
2529
run: ./run-all-integration-tests.sh snowflake
2630

@@ -34,6 +38,10 @@ jobs:
3438
with:
3539
ref: ${{ github.event.pull_request.head.sha }}
3640

41+
- uses: "actions/setup-python@v5"
42+
with:
43+
python-version: "3.11"
44+
3745
- id: "auth"
3846
name: "Authenticate to Google Cloud"
3947
uses: "google-github-actions/auth@v0"
@@ -71,6 +79,10 @@ jobs:
7179
with:
7280
ref: ${{ github.event.pull_request.head.sha }}
7381

82+
- uses: "actions/setup-python@v5"
83+
with:
84+
python-version: "3.11"
85+
7486
- name: test postgres
7587
run: ./run-all-integration-tests.sh postgres
7688

@@ -99,6 +111,10 @@ jobs:
99111
with:
100112
ref: ${{ github.event.pull_request.head.sha }}
101113

114+
- uses: "actions/setup-python@v5"
115+
with:
116+
python-version: "3.11"
117+
102118
- name: test postgres
103119
run: ./run-all-jaffle-shop-tests.sh postgres
104120

run-tests-on-dbt-version.sh

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,8 @@ VENV_NAME="venv-$PROFILE"
2828
VENV_FOLDER="$SCRIPT_DIR/$VENV_NAME"
2929

3030
DBT_MINOR=$(echo "$DBT_VERSION" | awk -F. '{print $1 "_" $2}')
31-
case "$DBT_MINOR" in
32-
1_3) DEFAULT_PYTHON=python3.10 ;;
33-
1_4|1_5|1_7) DEFAULT_PYTHON=python3.11 ;;
34-
*) DEFAULT_PYTHON=python3 ;;
35-
esac
3631
PYTHON_VAR="PYTHON_${DBT_MINOR}"
37-
PYTHON_BIN="${!PYTHON_VAR:-${PYTHON:-$DEFAULT_PYTHON}}"
32+
PYTHON_BIN="${!PYTHON_VAR:-${PYTHON:-python3}}"
3833

3934
if ! command -v "$PYTHON_BIN" >/dev/null 2>&1; then
4035
echo "Error: '$PYTHON_BIN' (selected for dbt $DBT_VERSION) not found on PATH."

0 commit comments

Comments
 (0)