ci-black-formatting - use variables for min Python versions

This commit is contained in:
Andrej730
2026-03-18 11:44:13 +05:00
parent f0b27a0910
commit 3385872e8b
+7 -4
View File
@@ -7,6 +7,9 @@ on:
jobs: jobs:
lint-formatting: lint-formatting:
runs-on: ubuntu-latest runs-on: ubuntu-latest
env:
MIN_IOS_PY_VERSION: "3.10"
MIN_BLENDER_PY_VERSION: "3.11"
steps: steps:
- name: Action - checkout repository - name: Action - checkout repository
uses: actions/checkout@v6 uses: actions/checkout@v6
@@ -14,12 +17,12 @@ jobs:
- name: Action - install python - name: Action - install python
uses: actions/setup-python@v6 uses: actions/setup-python@v6
with: with:
python-version: "3.10" python-version: ${{ env.MIN_IOS_PY_VERSION }}
- name: Action - install python - name: Action - install python
uses: actions/setup-python@v6 uses: actions/setup-python@v6
with: with:
python-version: "3.11" python-version: ${{ env.MIN_BLENDER_PY_VERSION }}
- name: Install dependencies - name: Install dependencies
run: | run: |
@@ -35,8 +38,8 @@ jobs:
ERROR=0 ERROR=0
# Using 2 Python versions - one minimum required for IfcOpenShell # Using 2 Python versions - one minimum required for IfcOpenShell
# and other that's used by Blender currently. # and other that's used by Blender currently.
python3.10 -W error -m compileall -q src/ifcopenshell-python || ERROR=1 python${{ env.MIN_IOS_PY_VERSION }} -W error -m compileall -q src/ifcopenshell-python || ERROR=1
python3.11 -W error -m compileall -q src/bonsai || ERROR=1 python${{ env.MIN_BLENDER_PY_VERSION }} -W error -m compileall -q src/bonsai || ERROR=1
exit $ERROR exit $ERROR
continue-on-error: true continue-on-error: true