Skip to content

python: use missing #1348

python: use missing

python: use missing #1348

Workflow file for this run

name: ci
on:
push:
paths:
- "**.m"
- "**.h"
- "**.cpp"
- ".github/workflows/ci.yml"
- ".github/workflows/*/action.yml"
- "!scripts/**"
- "!example/**"
# avoid wasted runs
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
linux-2024a-newer:
timeout-minutes: 15
runs-on: ubuntu-22.04
strategy:
matrix:
release: [R2024a, R2025b, R2026a]
# Linux:
# R2022b..R2025b needs GCC 10.x and hence Github Actions runner ubuntu-22.04.
# if using ubuntu-latest the java_exe tests fail.
steps:
- &matlab-install
name: Install MATLAB
timeout-minutes: 5
uses: matlab-actions/setup-matlab@v3
with:
release: ${{ matrix.release }}
cache: true
- &checkout
uses: actions/checkout@v6
- &tell-ext
name: Matlab tell External Language Interface versions
uses: matlab-actions/run-command@v3
with:
command: stdlib.doctor()
- &code-issues
name: Check codeIssues
if: ${{ matrix.release >= 'R2024a' || matrix.release == 'latest-including-prerelease' }}
uses: matlab-actions/run-build@v3
with:
tasks: check
# Matlab < R2024a has false positives that would break tests
- &test-main
name: Main Tests
uses: ./.github/workflows/composite-nomex
- name: package
if: ${{ matrix.release == 'R2026a' }}
uses: matlab-actions/run-command@v3
with:
startup-options: -sd ${{ github.workspace }}/scripts
command: packageToolbox()
- name: upload .mltbx
if: ${{ hashFiles('stdlib.mltbx') != '' && matrix.release == 'R2026a' }}
uses: actions/upload-artifact@v7
with:
name: stdlib.mltbx
path: stdlib.mltbx
macos-2024a-newer:
timeout-minutes: 15
runs-on: macos-latest
strategy:
matrix:
release: [R2025b, R2026a]
# macOS:
# Matlab >= R2023b compatible with Xcode 15
# Matlab >= R2024b compatible with Xcode 16
steps:
- *matlab-install
- &mac-fc
name: Fortran FC
if: runner.os == 'macOS'
run: echo "FC=gfortran-15" >> $GITHUB_ENV
- *checkout
- *tell-ext
- *test-main
windows-2024a-newer:
timeout-minutes: 15
runs-on: windows-latest
strategy:
matrix:
release: [R2025b, R2026a]
steps:
- *matlab-install
- *checkout
- *tell-ext
- *test-main
matlab-2022a-2023b:
needs: linux-2024a-newer
timeout-minutes: 15
runs-on: ${{ matrix.os }}
strategy:
matrix:
# windows and macos also work, just saving CI resources
os: [ubuntu-22.04]
release: [R2023b]
# R2022a, R2022b, R2023a, R2023b works, saving CI resources
steps:
- *matlab-install
- *mac-fc
- *checkout
- *tell-ext
- *test-main
# just saving CI resources
# matlab-older-R2022a:
# R2021a..R2022a officially need Ubuntu 20.04, which is no longer available on Github Actions
# needs: linux-2024a-newer
# timeout-minutes: 15
# runs-on: ${{ matrix.os }}
# strategy:
# matrix:
# os: [ubuntu-22.04]
# release: [R2021a]
# # , R2021b works, saving CI resources
# steps:
# - *matlab-install
# - *checkout
# - *tell-ext
# - *test-main
# just saving CI resources
# matlab-nojvm:
# needs: matlab-at-least-r2024a
# timeout-minutes: 15
# runs-on: ubuntu-latest
# strategy:
# matrix:
# release: [R2024a]
# steps:
# - *matlab-install
# - *checkout
# - name: Matlab tell External Language Interface versions
# uses: matlab-actions/run-command@v3
# with:
# command: stdlib.doctor()
# startup-options: -nojvm
# - name: Main Tests NoJVM
# uses: matlab-actions/run-build@v3
# with:
# tasks: test_main
# startup-options: -nojvm