Skip to content

Workflow file for this run

name: Debug parfor Errors
run-name: Debug
on:
push:
workflow_dispatch:
inputs:
debug_enabled:
type: boolean
description: 'Run the build with tmate debugging enabled (https://github.com/marketplace/actions/debugging-with-tmate)'
required: false
default: false
jobs:
compatability:
name: Legacy & OS Compatability Syntax Tests
strategy:
matrix:
platform: [macos-latest]
release: [R2021a]
runs-on: ${{ matrix.platform }}
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Set up MATLAB
uses: matlab-actions/setup-matlab@v2
with:
release: ${{matrix.release}}
products: Signal_Processing_Toolbox Parallel_Computing_Toolbox
- name: Run Tests on Legacy version
uses: matlab-actions/run-command@v2
with:
command: |
clogdir = fullfile(pwd, 'logs','client'),
wlogdir = fullfile(pwd, 'logs','workers'),
mkdir(clogdir);
mkdir(wlogdir);
parallel.internal.logging.enableClientLogging(clogdir, 6)
setSchedulerMessageHandler(@disp);
setenv('MDCE_DEBUG','true');
pctconfig('preservejobs',true);
parpool local;
setup cache; addpath build;
res = runProjectTests("verbosity", "Verbose"),
i = find([res.Failed]); res(i).Name,
rep = arrayfun(@(r) r.Details.DiagnosticRecord.Report, res(i), 'UniformOutput', false);
rep{:}
c = parcluster('local'),
fld = c.JobStorageLocation,
fls = dir(fullfile(fld,'**','*log*'));
fls = string(fullfile({fls.folder}, {fls.name}));
arrayfun(@(s) copyfile(s, wlogdir), fls);
- name: Upload Logs
uses: actions/upload-artifact@v4
with:
name: Logs-${{runner.os}}
path: logs/
# Enable tmate debugging of manually-triggered workflows if the input option was provided
- name: Setup tmate session
uses: mxschmitt/action-tmate@v3
if: ${{ github.event_name == 'workflow_dispatch' && inputs.debug_enabled }}
timeout-minutes: 15