Update Python version from 3.11 to 3.14 #2171
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and test installer | |
| on: | |
| push: | |
| # Only build for pushes to branches | |
| branches: | |
| - main | |
| tags-ignore: | |
| - '**' | |
| pull_request: | |
| branches: | |
| - main | |
| schedule: | |
| - cron: '6 2 * * *' | |
| workflow_dispatch: | |
| jobs: | |
| build-installer: | |
| name: Build installer | |
| if: github.repository == 'DIRACGrid/DIRACOS2' | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| include: | |
| - target_arch: linux-64 | |
| os: ubuntu-latest | |
| - target_arch: linux-aarch64 | |
| os: ubuntu-24.04-arm | |
| - target_arch: osx-arm64 | |
| os: macos-14 | |
| - target_arch: osx-64 | |
| os: macos-15-intel | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: prefix-dev/setup-pixi@v0.9.3 | |
| with: | |
| cache: true | |
| - name: Build installer | |
| run: pixi run build-installer | |
| - name: Upload installer | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: installer-${{ matrix.target_arch }} | |
| path: DIRACOS-*.sh | |
| get-info: | |
| name: Create environment.yaml | |
| if: github.repository == 'DIRACGrid/DIRACOS2' | |
| needs: build-installer | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| target_arch: ["linux-64"] | |
| steps: | |
| - name: Download installer | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: installer-${{ matrix.target_arch }} | |
| - name: Generate environment.yaml | |
| run: | | |
| bash DIRACOS-*.sh | |
| source diracos/diracosrc | |
| conda env export --file environment.yaml --prefix $DIRACOS | |
| - name: Upload environment.yaml | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: environment-yaml-${{ matrix.target_arch }} | |
| path: | | |
| environment.yaml | |
| release-notes: | |
| name: Show release notes and diff | |
| if: github.repository == 'DIRACGrid/DIRACOS2' | |
| needs: get-info | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: prefix-dev/setup-pixi@v0.9.3 | |
| with: | |
| cache: true | |
| environments: release | |
| - name: Download artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| path: artifacts | |
| - name: Create release notes | |
| run: | | |
| pixi run -e release release-notes \ | |
| --token="${{ secrets.GITHUB_TOKEN }}" \ | |
| --artifacts-dir="${PWD}/artifacts" \ | |
| > release-notes.md | |
| cat release-notes.md | |
| - name: Upload release-notes.md | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: release-notes | |
| path: | | |
| release-notes.md | |
| basic-tests: | |
| name: Basic tests | |
| if: github.repository == 'DIRACGrid/DIRACOS2' | |
| needs: build-installer | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| # x86_64 tests: run against CentOS 7 and 8 with the linux-64 installer | |
| - os: ubuntu-latest | |
| docker_image: centos:7 | |
| installer: installer-linux-64 | |
| - os: ubuntu-latest | |
| docker_image: centos:8 | |
| installer: installer-linux-64 | |
| - os: ubuntu-latest | |
| docker_image: almalinux:9 | |
| installer: installer-linux-64 | |
| # ARM tests: run only AlmaLinux 9 tests with the linux-aarch64 installer | |
| - os: ubuntu-24.04-arm | |
| docker_image: almalinux:9 | |
| installer: installer-linux-aarch64 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Download installer | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: ${{ matrix.installer }} | |
| - name: Run tests | |
| run: scripts/run_basic_tests.sh ${{ matrix.docker_image }} DIRACOS-*.sh | |
| macos-64-tests: | |
| name: macOS (x86_64) tests | |
| if: github.repository == 'DIRACGrid/DIRACOS2' | |
| needs: build-installer | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [macos-15-intel] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Download installer | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: installer-osx-64 | |
| - name: Run tests | |
| run: | | |
| bash DIRACOS-*.sh | |
| set -x | |
| source diracos/diracosrc | |
| pip install DIRAC | |
| macos-tests: | |
| name: macOS (arm64) tests | |
| if: github.repository == 'DIRACGrid/DIRACOS2' | |
| needs: build-installer | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [macos-14, macos-15] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Download installer | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: installer-osx-arm64 | |
| - name: Run tests | |
| run: | | |
| bash DIRACOS-*.sh | |
| set -x | |
| source diracos/diracosrc | |
| pip install DIRAC | |
| integration-tests-client-and-server: | |
| name: Integration tests (Py3 server) | |
| if: github.repository == 'DIRACGrid/DIRACOS2' | |
| needs: build-installer | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| dirac-branch: | |
| - rel-v8r0 | |
| - integration | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v4 | |
| with: | |
| python-version: '3.9' | |
| - name: Download installer | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: installer-linux-64 | |
| - name: Prepare environment | |
| run: | | |
| pip install typer pyyaml gitpython packaging | |
| git clone https://github.com/DIRACGrid/DIRAC.git -b "${{ matrix.dirac-branch }}" DIRACRepo | |
| - name: Run tests | |
| run: | | |
| DIRACOS_TARBALL_PATH=$(echo ${PWD}/DIRACOS-*.sh) | |
| echo "DIRACOS_TARBALL_PATH is ${DIRACOS_TARBALL_PATH}" | |
| cd DIRACRepo | |
| ./integration_tests.py create \ | |
| "DIRACOS_TARBALL_PATH=${DIRACOS_TARBALL_PATH}" |