Hi,
I've been trying to get MATLAB's 'OutOfProcess' Python support to work on a Windows runner, but I've encountered an issue that I can't get past. This is my workflow:
name: MATLAB Windows OutOfProcess Bug
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
main:
runs-on: 'windows-latest'
steps:
- name: Set up MATLAB
uses: matlab-actions/setup-matlab@v1
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.8'
- name: Create MATLAB script
run: |
"pyenv('ExecutionMode', 'OutOfProcess')" | Out-File -FilePath run.m
"py.list({'Monday','Tuesday','Wednesday','Thursday','Friday'})" | Out-File -FilePath run.m -Append
- name: Run script
run: matlab -batch "run"
The output from the last step is:
MATLAB is running in headless mode. Figure windows will not be displayed.
Sponsored License -- for use in support of a program or activity sponsored by MathWorks.
Not for government, commercial or other non-sponsored organizational use.
Caught "std::exception" Exception message is:
Unable to launch Simple server: Unable to launch C:\Program Files\MATLAB\R2021b\interprocess\bin\win64\pycli\MATLABPyHost.exe
because: An error occurred while initializing child process: While attempting to execute "C:\Program Files\MATLAB\R2021b\interprocess\bin\win64\pycli\MATLABPyHost.exe -mvmInputPipe 138736 0 0 0 0 0 -mvmOutputPipe 0 139588 0 0 0 0": CreateProcessW: The parameter is incorrect
ans =
PythonEnvironment with properties:
Version: "3.8"
Executable: "C:\hostedtoolcache\windows\Python\3.8.[10](https://github.com/H0R5E/matlab-actions-windows-bug/runs/5096231061#step:5:10)\x64\python.EXE"
Library: "C:\hostedtoolcache\windows\Python\3.8.10\x64\python38.dll"
Home: "C:\hostedtoolcache\windows\Python\3.8.10\x64"
Status: NotLoaded
ExecutionMode: OutOfProcess
thread_monitor::launch: _beginthreadex failed
ERROR: MATLAB error Exit Status: 0x00000001
Error: Process completed with exit code 1.
I have set up a repo just to test this issue and you can see the outcome here.
I understand that Windows support is not official, as yet, but can you offer me any advice about this issue?
Many thanks,
Mat
Hi,
I've been trying to get MATLAB's 'OutOfProcess' Python support to work on a Windows runner, but I've encountered an issue that I can't get past. This is my workflow:
The output from the last step is:
I have set up a repo just to test this issue and you can see the outcome here.
I understand that Windows support is not official, as yet, but can you offer me any advice about this issue?
Many thanks,
Mat